王福强的个人博客:一个架构士的思考与沉淀

王福强的个人博客:一个架构士的思考与沉淀

跟着福强老师一分钟了解Claude Skills

跟着福强老师一分钟了解Claude Skills -王福强的个人博客:一个架构士的思考与沉淀 pre > code{ white-space: pre-wrap; font-family: monospace; font-size: 14px; /* border-left: blueviolet; border-left-width: thick; border-left-style: double; padding-left: 1rem !important; */ } .x-indicator{ display:none; } .htmx-request .x-indicator{ display:inline; } .htmx-request.x-indicator{ display:inline; } pre > code.sourceCode { white-space: pre; position: relative; } pre > code.sourceCode > span { line-height: 1.25; } pre > code.sourceCode > span:empty { height: 1.2em; } .sourceCode { overflow: visible; } code.sourceCode > span { color: inherit; text-decoration: inherit; } div.sourceCode { margin: 1em 0; } pre.sourceCode { margin: 0; } @media screen { div.sourceCode { overflow: auto; } } @media print { pre > code.sourceCode { white-space: pre-wrap; } pre > code.sourceCode > span { display: inline-block; text-indent: -5em; padding-left: 5em; } } pre.numberSource code { counter-reset: source-line 0; } pre.numberSource code > span { position: relative; left: -4em; counter-increment: source-line; } pre.numberSource code > span > a:first-child::before { content: counter(source-line); position: relative; left: -1em; text-align: right; vertical-align: baseline; border: none; display: inline-block; -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; padding: 0 4px; width: 4em; color: #aaaaaa; } pre.numberSource { margin-left: 3em; border-left: 1px solid #aaaaaa; padding-left: 4px; } div.sourceCode { } @media screen { pre > code.sourceCode > span > a:first-child::before { text-decoration: underline; } } code span.al { color: #ff0000; font-weight: bold; } /* Alert */ code span.an { color: #60a0b0; font-weight: bold; font-style: italic; } /* Annotation */ code span.at { color: #7d9029; } /* Attribute */ code span.bn { color: #40a070; } /* BaseN */ code span.bu { color: #008000; } /* BuiltIn */ code span.cf { color: #007020; font-weight: bold; } /* ControlFlow */ code span.ch { color: #4070a0; } /* Char */ code span.cn { color: #880000; } /* Constant */ code span.co { color: #60a0b0; font-style: italic; } /* Comment */ code span.cv { color: #60a0b0; font-weight: bold; font-style: italic; } /* CommentVar */ code span.do { color: #ba2121; font-style: italic; } /* Documentation */ code span.dt { color: #902000; } /* DataType */ code span.dv { color: #40a070; } /* DecVal */ code span.er { color: #ff0000; font-weight: bold; } /* Error */ code span.ex { } /* Extension */ code span.fl { color: #40a070; } /* Float */ code span.fu { color: #06287e; } /* Function */ code span.im { color: #008000; font-weight: bold; } /* Import */ code span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Information */ code span.kw { color: #007020; font-weight: bold; } /* Keyword */ code span.op { color: #666666; } /* Operator */ code span.ot { color: #007020; } /* Other */ code span.pp { color: #bc7a00; } /* Preprocessor */ code span.sc { color: #4070a0; } /* SpecialChar */ code span.ss { color: #bb6688; } /* SpecialString */ code span.st { color: #4070a0; } /* String */ code span.va { color: #19177c; } /* Variable */ code span.vs { color: #4070a0; } /* VerbatimString */ code span.wa { color: #60a0b0; font-weight: bold; font-style: italic; } /* Warning */ { "@context": "https://schema.org", "@type": "NewsArticle", "headline": "跟着福强老师一分钟了解Claude Skills", "image": [ "https://afoo.me/images/fb_subscribe.jpg" ], "datePublished": "2025-10-19", "author": [{ "@type": "Person", "name": "王福强", "url": "https://afoo.me" }] } 福强私学 福强AI学堂 架构百科 博客文章 创作出版 产品与服务 登录信息 更多链接 (adsbygoogle = window.adsbygoogle || []).push({}); (adsbygoogle = window.adsbygoogle || []).push({}); 跟着福强老师一分钟了解Claude Skills 王福强 2025-10-19 (adsbygoogle = window.adsbygoogle || []).push({}); 读官方文档是最直接的:https://www.anthropic.com/news/skills Claude can now use Skills to improve how it performs specific tasks. 这句话说明,Skills是面向特定任务的设计。 Skills are folders that include instructions, scripts, and resources that Claude can load when needed. 这句话说明了Skills的交付和组织形式,就是个目录,目录里包含了指令(md编写的,AI友好嘛)、脚本和需要的资源。 Claude可以按需加载目录里这些东西。 Claude will only access a skill when it’s relevant to the task at hand. When used, skills make Claude better at specialized tasks like working with Excel or following your organization’s brand guidelines. 这个遵循组织的品牌指南挺好,一致性才是根本。 Now, you can build your own skills and use them across Claude apps, Claude Code, and our API. 可以在Anthropic家的产品上通用。 估计马上其他家就会有类似的概念和组件出现了🤣 While working on tasks, Claude scans available skills to find relevant matches. When one matches, it loads only the minimal information and files needed—keeping Claude fast while accessing specialized expertise. Skills这个frontmatter + body的行为设计,跟Scala里的Partial Functions很像,也就是必要匹配之后才会执行主体逻辑。从AI Agent角度它是为了省tokens,但从程序逻辑角度,其实就是条件匹配(predicates)。 这种设计还有个好处就是级联,比如,在KVectors向量数据库启动的时候,根据不同向量集合类型初始化的时候,用Partial Function的设计就可以实现优雅的级联: val vectorCollection: KVectorCollection = Option(collectionDir).collect(IVFIndexedKVectorCollection orElse HyperplanesLshKVectorCollection) match { case Some(vc) => logger.info(s"collected from specific collection partial function: ${vc.getClass}") vc case None => ... } 而Claude Skills,其实就是把条件检测+逻辑+级联的设计思想应用到了AI Agent的设计之中(也就是Claude的自家产品中)。 Skills are Composable: Skills stack together. Claude automatically identifies which skills are needed and coordinates their use 这里的composable就是级联, identify就是条件检测(predicates)。 (Skills are) Efficient: Only loads what’s needed, when it’s needed. 也就是匹配之后才执行, 跟PartialFunction的定义Perfect Match (Skills are) Powerful: Skills can include executable code for tasks where traditional programming is more reliable than token generation. 把MCP提供的原子能力本地化,可以融合自然语言和程序语言形成一个独立的模块。毕竟,程序语言比token生成更可靠,能用为啥不用?🤪 那Skills跟MCP有啥区别呢? MCP connects Claude to external services and data sources. Skills provide procedural knowledge—instructions for how to complete specific tasks or workflows. You can use both together: MCP connections give Claude access to tools, while Skills teach Claude how to use those tools effectively. 简单来说,IMO,MCP提供原子能力,怎么用这些原子能力,Skill是可以模块化的方式封装和使用。当然,如果只是本地需求,也可以在Skills里写脚本,这时候也不一定非得用MCP调用外部能力。 当然,有人把Skills类比为SOP(Standard Operating Procedure/标准作业流程),这个嘛,也可以这么理解: 只不过,就算是SOP, 它其实也是模块化内部的SOP,也就是完成一个任务(Task)所需的步骤。 福强老师觉得,这东西会是继MCP之后,另一个会在业界快速流行的AI生态一员。 Ref https://support.claude.com/en/articles/12512176-what-are-skills https://www.anthropic.com/engineering/equipping-agents-for-the-real-world-with-agent-skills https://github.com/anthropics/skills (adsbygoogle = window.adsbygoogle || []).push({}); >>>>>> 更多阅读 <<<<<< LLM框架与应用要解决的问题的本质 ChatGPT的宿命 Maven项目发布到公司内部Repository(Nexus) #阶段性反刍# 「福强私学」来一个? 「福强私学」, 一部沉淀了个人成长、技术与架构、组织与管理以及商业上的方法与心法的百科全书。 福强老师的 AI 通识课 开天窗,拉认知,订阅「福报」,即刻拥有自己的全模态人工智能。 Copyright © 王福强个人版权所有 - Since 2004 (Everything is homebrewed with Pandoc and Markdown, little Scala also included.) // Set "light" theme as default if (!localStorage.theme) { localStorage.theme = "light"; } if ( localStorage.theme === 'dark' || (!('theme' in localStorage) && window.matchMedia('(prefers-color-scheme: dark)').matches) ) { document.documentElement.classList.add('dark'); } else { document.documentElement.classList.remove('dark'); } function attachEvent(selector, event, fn) { const matches = document.querySelectorAll(selector); if (matches && matches.length) { matches.forEach((elem) => { elem.addEventListener(event, () => fn(elem), false); }); } } window.onload = function () { attachEvent('[data-toggle-menu]', 'click', function (elem) { elem.classList.toggle('expanded'); document.body.classList.toggle('overflow-hidden'); document.getElementById('header')?.classList.toggle('h-screen'); document.querySelector('#header nav')?.classList.toggle('hidden'); }); attachEvent("[data-toggle-color-scheme]", "click", function () { document.documentElement.classList.toggle("light"); localStorage.theme = "light"; }); }; window.onpageshow = function () { const elem = document.querySelector('[data-toggle-menu]'); if (elem) { elem.classList.remove('expanded'); } document.body.classList.remove('overflow-hidden'); document.getElementById('header')?.classList.remove('h-screen'); document.querySelector('#header nav')?.classList.add('hidden'); }; var gitalk = new Gitalk({ clientID: '518a605d711883414ac0', clientSecret: '69fb8ccc0616c5bcbc64d24ece0d06d279da91ff', repo: 'afoo.me.comments', owner: 'fujohnwang', admin: ['fujohnwang'], id: location.pathname.substring(0, 49), // Ensure uniqueness and length less than 50 distractionFreeMode: false // Facebook-like distraction free mode }) gitalk.render('comments') /* paste this line in verbatim */ window.formbutton=window.formbutton||function(){(formbutton.q=formbutton.q||[]).push(arguments)}; /* customize formbutton below*/ formbutton("create", { action: "https://formspree.io/f/xknlpkkd", title: "有什么可以帮到您?💕💕💕 How can I help you?", buttonImg: "", fields: [ { type: "email", label: "您的电子邮箱(方便与您联系):", name: "email", required: true, placeholder: "your@email.com" }, { type: "textarea", label: "您想提交的反馈和询问信息:", name: "message", placeholder: "What's on your mind?", }, { type: "submit" } ], styles: { title: { backgroundColor: "blue" }, button: { backgroundColor: "blue" } } }); // tooltips tippy('#aiedu', { content: "As to AI nowadays, LLM and Stable Diffusion are hot even hottest among them, If your want to both know-why and know-how with them, instead of only know-how which can't repeat itself, you should get you to https://ai.afoo.me right now ❗" });

2025/10/19
articleCard.readMore

向量数据库系列第二期企业培训圆满落幕!

向量数据库系列第二期企业培训圆满落幕! -王福强的个人博客:一个架构士的思考与沉淀 pre > code{ white-space: pre-wrap; font-family: monospace; font-size: 14px; /* border-left: blueviolet; border-left-width: thick; border-left-style: double; padding-left: 1rem !important; */ } .x-indicator{ display:none; } .htmx-request .x-indicator{ display:inline; } .htmx-request.x-indicator{ display:inline; } { "@context": "https://schema.org", "@type": "NewsArticle", "headline": "向量数据库系列第二期企业培训圆满落幕!", "image": [ "https://afoo.me/images/fb_subscribe.jpg" ], "datePublished": "2025-10-17", "author": [{ "@type": "Person", "name": "王福强", "url": "https://afoo.me" }] } 福强私学 福强AI学堂 架构百科 博客文章 创作出版 产品与服务 登录信息 更多链接 (adsbygoogle = window.adsbygoogle || []).push({}); (adsbygoogle = window.adsbygoogle || []).push({}); 向量数据库系列第二期企业培训圆满落幕! 王福强 2025-10-17 (adsbygoogle = window.adsbygoogle || []).push({}); (杭州,2025年10月17日)—— 今日,由杭州福强科技有限公司历经4个大版本迭代+180个小时精心打造的“向量数据库系列之向量数据库索引:从理论到产品化落地”成功交付客户企业。 本次培训聚焦向量数据库这一AI时代的核心基础设施,通过理论与实践的深度结合,为来自轻奢电商的企业技术团队提供了一场高质量的技术盛宴,收获了学员们的高度赞誉。 AI驱动下,向量数据库成企业数字化转型新引擎 随着生成式AI、大模型应用的普及,企业对非结构化数据(如文本、图像、音频)的处理需求呈爆炸式增长。向量数据库凭借其高效存储和检索高维向量数据的能力,已成为支撑智能推荐、语义搜索、图像识别、AIGC应用等场景的关键技术。据行业报告显示,全球向量数据库市场规模正以每年超过50%的速度增长,如何熟练掌握其底层技术,尤其是核心的索引算法,已成为企业技术团队的核心竞争力之一。 课程直击痛点:从理论到实践,拆解核心索引技术 本次培训针对企业在向量数据库实践中遇到的“索引选择难、性能优化无头绪、大规模数据检索效率低”等痛点,设计了层层递进的课程体系。其中,对主流索引类型的深度剖析与实战演练,成为本次培训的最大亮点。 课程核心内容聚焦以下三大典型索引技术: 1. 倒排文件索引(IVF) - 作为工业界应用最广泛的索引之一,IVF通过“分桶”思想,先对向量进行聚类,检索时仅在目标聚类中搜索,大幅降低计算成本。课程中,讲师不仅系统讲解了IVF的聚类原理、参数调优方法(如聚类数量、nprobe参数的选择),还通过动手实验,让学员对比不同参数下的检索精度与速度,掌握在“性能”与“召回率”之间的平衡技巧。 2. 分层导航小世界图(HNSW) - 针对IVF在高召回率场景下的不足,HNSW通过构建多层导航图结构,实现近似线性的检索速度,是当前学术界和工业界公认的性能最优索引之一。培训中,讲师结合源码级案例,拆解了HNSW的图构建逻辑、搜索路径优化策略,并指导学员完成基于HNSW的索引构建与性能压测,让学员直观感受其在亿级数据量下的检索效率。 3. 乘积量化(PQ)与Scalar Quantization - 为解决大规模数据存储成本高的问题,课程详细介绍了量化索引技术。PQ通过将高维向量分解为低维子向量并分别量化,在保证一定精度的前提下,将存储成本降低数倍;而Scalar Quantization则通过对整个向量的数值范围进行压缩,实现更轻量级的存储优化。学员通过实战,掌握了不同量化策略的适用场景及精度补偿方法。 学员高度认可:理论扎实,实战性强 培训结束后,参训学员纷纷表示,课程内容“干货满满”,尤其是对索引技术的深度解析,让他们对向量数据库的底层逻辑有了更清晰的认知。 “以前在项目中只用过现成的向量数据库,但对索引的选择一直凭感觉。这次培训系统讲解了IVF、HNSW的原理和区别,还通过实验对比了不同索引的性能,以后做架构设计心里更有底了。”,客户企业参与培训的高级技术工程师说道。 客户的CTO提到, “不仅讲了理论,还分享了很多一线的调优经验,比如如何根据数据量和业务场景选择索引、如何解决高并发下的检索延迟问题,这些实战技巧直接就能用到我们的商品推荐项目中,非常实用。” 持续赋能企业:杭州福强科技有限公司引领AI与向量数据库技术落地新趋势 本次培训的成功交付,不仅展现了杭州福强科技有限公司在向量数据库、AI基础设施等领域的技术沉淀,也体现了其助力企业技术团队成长、推动AI技术产业化落地的责任与担当。 未来,杭州福强科技有限公司将持续紧跟技术前沿,围绕向量数据库、大模型应用、大数据与数据安全等核心领域,推出更多针对性的技术培训与解决方案,帮助企业攻克技术难关,加速数字化转型进程。   (adsbygoogle = window.adsbygoogle || []).push({}); >>>>>> 更多阅读 <<<<<< 谷歌 L6 级别 9 年司龄女员工离职对你有啥启发? How Time Flies… 人口红利或者工程师红利到底在强调什么? 「福强私学」来一个? 「福强私学」, 一部沉淀了个人成长、技术与架构、组织与管理以及商业上的方法与心法的百科全书。 福强老师的 AI 通识课 开天窗,拉认知,订阅「福报」,即刻拥有自己的全模态人工智能。 Copyright © 王福强个人版权所有 - Since 2004 (Everything is homebrewed with Pandoc and Markdown, little Scala also included.) // Set "light" theme as default if (!localStorage.theme) { localStorage.theme = "light"; } if ( localStorage.theme === 'dark' || (!('theme' in localStorage) && window.matchMedia('(prefers-color-scheme: dark)').matches) ) { document.documentElement.classList.add('dark'); } else { document.documentElement.classList.remove('dark'); } function attachEvent(selector, event, fn) { const matches = document.querySelectorAll(selector); if (matches && matches.length) { matches.forEach((elem) => { elem.addEventListener(event, () => fn(elem), false); }); } } window.onload = function () { attachEvent('[data-toggle-menu]', 'click', function (elem) { elem.classList.toggle('expanded'); document.body.classList.toggle('overflow-hidden'); document.getElementById('header')?.classList.toggle('h-screen'); document.querySelector('#header nav')?.classList.toggle('hidden'); }); attachEvent("[data-toggle-color-scheme]", "click", function () { document.documentElement.classList.toggle("light"); localStorage.theme = "light"; }); }; window.onpageshow = function () { const elem = document.querySelector('[data-toggle-menu]'); if (elem) { elem.classList.remove('expanded'); } document.body.classList.remove('overflow-hidden'); document.getElementById('header')?.classList.remove('h-screen'); document.querySelector('#header nav')?.classList.add('hidden'); }; var gitalk = new Gitalk({ clientID: '518a605d711883414ac0', clientSecret: '69fb8ccc0616c5bcbc64d24ece0d06d279da91ff', repo: 'afoo.me.comments', owner: 'fujohnwang', admin: ['fujohnwang'], id: location.pathname.substring(0, 49), // Ensure uniqueness and length less than 50 distractionFreeMode: false // Facebook-like distraction free mode }) gitalk.render('comments') /* paste this line in verbatim */ window.formbutton=window.formbutton||function(){(formbutton.q=formbutton.q||[]).push(arguments)}; /* customize formbutton below*/ formbutton("create", { action: "https://formspree.io/f/xknlpkkd", title: "有什么可以帮到您?💕💕💕 How can I help you?", buttonImg: "", fields: [ { type: "email", label: "您的电子邮箱(方便与您联系):", name: "email", required: true, placeholder: "your@email.com" }, { type: "textarea", label: "您想提交的反馈和询问信息:", name: "message", placeholder: "What's on your mind?", }, { type: "submit" } ], styles: { title: { backgroundColor: "blue" }, button: { backgroundColor: "blue" } } }); // tooltips tippy('#aiedu', { content: "As to AI nowadays, LLM and Stable Diffusion are hot even hottest among them, If your want to both know-why and know-how with them, instead of only know-how which can't repeat itself, you should get you to https://ai.afoo.me right now ❗" });

2025/10/17
articleCard.readMore

Google Gemini CLI extensions是个什么东西?

Google Gemini CLI extensions是个什么东西? -王福强的个人博客:一个架构士的思考与沉淀 pre > code{ white-space: pre-wrap; font-family: monospace; font-size: 14px; /* border-left: blueviolet; border-left-width: thick; border-left-style: double; padding-left: 1rem !important; */ } .x-indicator{ display:none; } .htmx-request .x-indicator{ display:inline; } .htmx-request.x-indicator{ display:inline; } { "@context": "https://schema.org", "@type": "NewsArticle", "headline": "Google Gemini CLI extensions是个什么东西?", "image": [ "https://afoo.me/images/fb_subscribe.jpg" ], "datePublished": "2025-10-16", "author": [{ "@type": "Person", "name": "王福强", "url": "https://afoo.me" }] } 福强私学 福强AI学堂 架构百科 博客文章 创作出版 产品与服务 登录信息 更多链接 (adsbygoogle = window.adsbygoogle || []).push({}); (adsbygoogle = window.adsbygoogle || []).push({}); Google Gemini CLI extensions是个什么东西? 王福强 2025-10-16 (adsbygoogle = window.adsbygoogle || []).push({}); 上周的福强的本周AI热点回顾与简评已经提到Gemini CLI发布的新版v0.8.0支持extensions这个特性了,那什么是Gemini CLI的extensions呢? Bundle MCP servers, context files, and custom commands into one package. Allowing users and companies to package and share Gemini CLI customizations. With extensions, you can expand the capabilities of Gemini CLI and share those capabilities with others. 关键词大概就是: 模块化 插件化 市场化 除了可以在Hosted Extension Marketplace with already over 100 extensions使用/extensions install命令安装别人发布的extensions,还可以: Install extensions directly via GitHub URLs or local file paths. 基本上就是为“自己动手吃自己狗粮”设计的fallback,当然也包含开发和测试支持。 e.g. gemini extensions install https://github.com/gemini-cli-extensions/security 现在大多还是国外公司的一些产品和服务集成: 更多参考信息: https://geminicli.com/docs/extensions/ https://geminicli.com/docs/extensions/getting-started-extensions/ extensions市场地址: https://geminicli.com/extensions/ (adsbygoogle = window.adsbygoogle || []).push({}); >>>>>> 更多阅读 <<<<<< 从Quicksilver到Alfred再到Raycast 大语言模型的输出长度为啥都不长? 核酸码系统拆解与设计推演 「福强私学」来一个? 「福强私学」, 一部沉淀了个人成长、技术与架构、组织与管理以及商业上的方法与心法的百科全书。 福强老师的 AI 通识课 开天窗,拉认知,订阅「福报」,即刻拥有自己的全模态人工智能。 Copyright © 王福强个人版权所有 - Since 2004 (Everything is homebrewed with Pandoc and Markdown, little Scala also included.) // Set "light" theme as default if (!localStorage.theme) { localStorage.theme = "light"; } if ( localStorage.theme === 'dark' || (!('theme' in localStorage) && window.matchMedia('(prefers-color-scheme: dark)').matches) ) { document.documentElement.classList.add('dark'); } else { document.documentElement.classList.remove('dark'); } function attachEvent(selector, event, fn) { const matches = document.querySelectorAll(selector); if (matches && matches.length) { matches.forEach((elem) => { elem.addEventListener(event, () => fn(elem), false); }); } } window.onload = function () { attachEvent('[data-toggle-menu]', 'click', function (elem) { elem.classList.toggle('expanded'); document.body.classList.toggle('overflow-hidden'); document.getElementById('header')?.classList.toggle('h-screen'); document.querySelector('#header nav')?.classList.toggle('hidden'); }); attachEvent("[data-toggle-color-scheme]", "click", function () { document.documentElement.classList.toggle("light"); localStorage.theme = "light"; }); }; window.onpageshow = function () { const elem = document.querySelector('[data-toggle-menu]'); if (elem) { elem.classList.remove('expanded'); } document.body.classList.remove('overflow-hidden'); document.getElementById('header')?.classList.remove('h-screen'); document.querySelector('#header nav')?.classList.add('hidden'); }; var gitalk = new Gitalk({ clientID: '518a605d711883414ac0', clientSecret: '69fb8ccc0616c5bcbc64d24ece0d06d279da91ff', repo: 'afoo.me.comments', owner: 'fujohnwang', admin: ['fujohnwang'], id: location.pathname.substring(0, 49), // Ensure uniqueness and length less than 50 distractionFreeMode: false // Facebook-like distraction free mode }) gitalk.render('comments') /* paste this line in verbatim */ window.formbutton=window.formbutton||function(){(formbutton.q=formbutton.q||[]).push(arguments)}; /* customize formbutton below*/ formbutton("create", { action: "https://formspree.io/f/xknlpkkd", title: "有什么可以帮到您?💕💕💕 How can I help you?", buttonImg: "", fields: [ { type: "email", label: "您的电子邮箱(方便与您联系):", name: "email", required: true, placeholder: "your@email.com" }, { type: "textarea", label: "您想提交的反馈和询问信息:", name: "message", placeholder: "What's on your mind?", }, { type: "submit" } ], styles: { title: { backgroundColor: "blue" }, button: { backgroundColor: "blue" } } }); // tooltips tippy('#aiedu', { content: "As to AI nowadays, LLM and Stable Diffusion are hot even hottest among them, If your want to both know-why and know-how with them, instead of only know-how which can't repeat itself, you should get you to https://ai.afoo.me right now ❗" });

2025/10/16
articleCard.readMore

十年

十年 -王福强的个人博客:一个架构士的思考与沉淀 pre > code{ white-space: pre-wrap; font-family: monospace; font-size: 14px; /* border-left: blueviolet; border-left-width: thick; border-left-style: double; padding-left: 1rem !important; */ } .x-indicator{ display:none; } .htmx-request .x-indicator{ display:inline; } .htmx-request.x-indicator{ display:inline; } { "@context": "https://schema.org", "@type": "NewsArticle", "headline": "十年", "image": [ "https://afoo.me/images/fb_subscribe.jpg" ], "datePublished": "2025-10-15", "author": [{ "@type": "Person", "name": "王福强", "url": "https://afoo.me" }] } 福强私学 福强AI学堂 架构百科 博客文章 创作出版 产品与服务 登录信息 更多链接 (adsbygoogle = window.adsbygoogle || []).push({}); (adsbygoogle = window.adsbygoogle || []).push({}); 十年 王福强 2025-10-15 (adsbygoogle = window.adsbygoogle || []).push({}); 看这标题是不是想起陈奕迅的那首《十年》? 其实 我就是借这个词儿感叹下 谁让很多事情在这个词儿下面撞车了呢 有兄弟这阵子一直念叨要买我那辆老奔子 昨天又念叨 才发现,这车也10年车龄了… 今天果总群里又跟始祖鸟过不去了(当然,还跟东bell家也一直过不去🤣) 其实,作为拥有两件始祖鸟的买家 我觉得始祖鸟挺好的 第一件红色软壳,想来也10年左右了 当年好像是看到51信用卡原CEO孙海淘穿了件始祖鸟T恤 回来查了下这个牌子后买的。 有时候背着11寸的macbook air出去讲课 经常被问这电脑有年头儿了吧? 嗯,应该也超过10年了… 很多东西,初看起来好像很贵 但回头再看 平均下来其实远比平均价钱买的“短命鬼”要划算很多 更不要说频繁的筛选成本和情绪消耗… 品牌这东西 看似很玄乎 但其实确有其价值 当你为各种低价款埋过单、被各种低价坑过之后,你就会理解品牌的价值了。 品牌其实帮我们屏蔽了选品的成本与风险,稍有溢价也是合理的。 品牌是什么? 品牌是你长期信用的积累。 伟大的公司,始于产品,终于品牌。 很多年前,我跟成哥聊天的时候说 我就算趴着,这家也得做10年… 嗯,还有两年就快到了,加油,😂 (adsbygoogle = window.adsbygoogle || []).push({}); >>>>>> 更多阅读 <<<<<< 从消防通道的治理谈管理的日常 When people meet something they don’t know at first time 不听话的员工就应该开掉吗?! 「福强私学」来一个? 「福强私学」, 一部沉淀了个人成长、技术与架构、组织与管理以及商业上的方法与心法的百科全书。 福强老师的 AI 通识课 开天窗,拉认知,订阅「福报」,即刻拥有自己的全模态人工智能。 Copyright © 王福强个人版权所有 - Since 2004 (Everything is homebrewed with Pandoc and Markdown, little Scala also included.) // Set "light" theme as default if (!localStorage.theme) { localStorage.theme = "light"; } if ( localStorage.theme === 'dark' || (!('theme' in localStorage) && window.matchMedia('(prefers-color-scheme: dark)').matches) ) { document.documentElement.classList.add('dark'); } else { document.documentElement.classList.remove('dark'); } function attachEvent(selector, event, fn) { const matches = document.querySelectorAll(selector); if (matches && matches.length) { matches.forEach((elem) => { elem.addEventListener(event, () => fn(elem), false); }); } } window.onload = function () { attachEvent('[data-toggle-menu]', 'click', function (elem) { elem.classList.toggle('expanded'); document.body.classList.toggle('overflow-hidden'); document.getElementById('header')?.classList.toggle('h-screen'); document.querySelector('#header nav')?.classList.toggle('hidden'); }); attachEvent("[data-toggle-color-scheme]", "click", function () { document.documentElement.classList.toggle("light"); localStorage.theme = "light"; }); }; window.onpageshow = function () { const elem = document.querySelector('[data-toggle-menu]'); if (elem) { elem.classList.remove('expanded'); } document.body.classList.remove('overflow-hidden'); document.getElementById('header')?.classList.remove('h-screen'); document.querySelector('#header nav')?.classList.add('hidden'); }; var gitalk = new Gitalk({ clientID: '518a605d711883414ac0', clientSecret: '69fb8ccc0616c5bcbc64d24ece0d06d279da91ff', repo: 'afoo.me.comments', owner: 'fujohnwang', admin: ['fujohnwang'], id: location.pathname.substring(0, 49), // Ensure uniqueness and length less than 50 distractionFreeMode: false // Facebook-like distraction free mode }) gitalk.render('comments') /* paste this line in verbatim */ window.formbutton=window.formbutton||function(){(formbutton.q=formbutton.q||[]).push(arguments)}; /* customize formbutton below*/ formbutton("create", { action: "https://formspree.io/f/xknlpkkd", title: "有什么可以帮到您?💕💕💕 How can I help you?", buttonImg: "", fields: [ { type: "email", label: "您的电子邮箱(方便与您联系):", name: "email", required: true, placeholder: "your@email.com" }, { type: "textarea", label: "您想提交的反馈和询问信息:", name: "message", placeholder: "What's on your mind?", }, { type: "submit" } ], styles: { title: { backgroundColor: "blue" }, button: { backgroundColor: "blue" } } }); // tooltips tippy('#aiedu', { content: "As to AI nowadays, LLM and Stable Diffusion are hot even hottest among them, If your want to both know-why and know-how with them, instead of only know-how which can't repeat itself, you should get you to https://ai.afoo.me right now ❗" });

2025/10/15
articleCard.readMore

盘古开天辟地也只才一次…

盘古开天辟地也只才一次… -王福强的个人博客:一个架构士的思考与沉淀 pre > code{ white-space: pre-wrap; font-family: monospace; font-size: 14px; /* border-left: blueviolet; border-left-width: thick; border-left-style: double; padding-left: 1rem !important; */ } .x-indicator{ display:none; } .htmx-request .x-indicator{ display:inline; } .htmx-request.x-indicator{ display:inline; } { "@context": "https://schema.org", "@type": "NewsArticle", "headline": "盘古开天辟地也只才一次…", "image": [ "https://afoo.me/images/fb_subscribe.jpg" ], "datePublished": "2025-10-10", "author": [{ "@type": "Person", "name": "王福强", "url": "https://afoo.me" }] } 福强私学 福强AI学堂 架构百科 博客文章 创作出版 产品与服务 登录信息 更多链接 (adsbygoogle = window.adsbygoogle || []).push({}); (adsbygoogle = window.adsbygoogle || []).push({}); 盘古开天辟地也只才一次… 王福强 2025-10-10 (adsbygoogle = window.adsbygoogle || []).push({}); 我叫向佑,是一个1024维的向量,你们可能不太了解我是个什么东西,简单来说就是长度为1024的数组。 我出生在一片混沌的向量空间 纠缠,漫弥,用你最多理解到三维空间甚至四维空间的小脑瓜,可能理解不了 不过,这些都无所谓了 因为我会告诉你怎么找到我 当天地一片混沌的时候, 是盘古一斧子将混沌一分为二,一半成了天,一半成了地 盘古的那把斧子,在我们向量空间,通常体现为一个随机向量。(对,跟我向佑一样,也是个向量,只不过是随机的,而且得是高斯随机) 当我们用这个随机向量去划过整个向量空间的时候,就像盘古用斧头劈向混沌一样,这个随机向量会在向量空间形成一个超平面,这个超平面会把混沌的向量空间一分为二,划到两边的向量就成了两组,比如我现在就被这个超平面划到了A组… 跟盘古不一样,我们不会只砍一斧子,我们会多砍几斧子,也就是多创建几个随机向量,然后用它们创建新的超平面去划开混沌的向量空间,这时候,我们就有了好多个一分为二的组,我一会儿在C组,一会儿又被另一个超平面划到了E组… 哎,颠破流离啊… 好在,它们终于停下来了,我有了固定的空间位置坐标: [1,0,1,1…] Oh, No~ 它们又开始了… 也不知道又过去了多久,我被颠簸的都快吐了,等它们停下来的时候,我发现我被贴了好多个门牌号: [1,0,1,1…] [1,1,0,0…] [1,0,1,0…] … 我也不知道这些门牌号是干啥用的,直到有一天,有个人终于找到了我,跟我说了他是怎么找到我的,我才明白是怎么回事。 原来,他将我的画像(近似)交给向量空间的管理员(类似天地衙门),让他帮忙找一下我,管理员就把我的近似画像扔给了旁边的智能体助手,智能助手回头给了他一组坐标,他就是拿这些坐标跟我被贴的那些门牌号做对比找到我的。 但为啥要那么多坐标? 管理员说是因为一开始天地混沌,搞不清楚谁是谁,所以管理局就做了个随机网格管理策略,把每个向量划分到不同网格,为了避免遗漏找不着某个向量主体,就多划了一些片区。仅此而已,以防万一嘛~ 这个策略有个正式名称叫啥来着? 哦,好像是叫 LSH - Locality-sensitive hashing “你叫向佑吧? 门口有人找” “谁啊?” 我开门一看,愣住了,这货为啥跟我那么像,我都怀疑我是在做梦… (adsbygoogle = window.adsbygoogle || []).push({}); >>>>>> 更多阅读 <<<<<< DisplayTag Tutorial 天赋,培训与个性化 Swift极速快打 「福强私学」来一个? 「福强私学」, 一部沉淀了个人成长、技术与架构、组织与管理以及商业上的方法与心法的百科全书。 福强老师的 AI 通识课 开天窗,拉认知,订阅「福报」,即刻拥有自己的全模态人工智能。 Copyright © 王福强个人版权所有 - Since 2004 (Everything is homebrewed with Pandoc and Markdown, little Scala also included.) // Set "light" theme as default if (!localStorage.theme) { localStorage.theme = "light"; } if ( localStorage.theme === 'dark' || (!('theme' in localStorage) && window.matchMedia('(prefers-color-scheme: dark)').matches) ) { document.documentElement.classList.add('dark'); } else { document.documentElement.classList.remove('dark'); } function attachEvent(selector, event, fn) { const matches = document.querySelectorAll(selector); if (matches && matches.length) { matches.forEach((elem) => { elem.addEventListener(event, () => fn(elem), false); }); } } window.onload = function () { attachEvent('[data-toggle-menu]', 'click', function (elem) { elem.classList.toggle('expanded'); document.body.classList.toggle('overflow-hidden'); document.getElementById('header')?.classList.toggle('h-screen'); document.querySelector('#header nav')?.classList.toggle('hidden'); }); attachEvent("[data-toggle-color-scheme]", "click", function () { document.documentElement.classList.toggle("light"); localStorage.theme = "light"; }); }; window.onpageshow = function () { const elem = document.querySelector('[data-toggle-menu]'); if (elem) { elem.classList.remove('expanded'); } document.body.classList.remove('overflow-hidden'); document.getElementById('header')?.classList.remove('h-screen'); document.querySelector('#header nav')?.classList.add('hidden'); }; var gitalk = new Gitalk({ clientID: '518a605d711883414ac0', clientSecret: '69fb8ccc0616c5bcbc64d24ece0d06d279da91ff', repo: 'afoo.me.comments', owner: 'fujohnwang', admin: ['fujohnwang'], id: location.pathname.substring(0, 49), // Ensure uniqueness and length less than 50 distractionFreeMode: false // Facebook-like distraction free mode }) gitalk.render('comments') /* paste this line in verbatim */ window.formbutton=window.formbutton||function(){(formbutton.q=formbutton.q||[]).push(arguments)}; /* customize formbutton below*/ formbutton("create", { action: "https://formspree.io/f/xknlpkkd", title: "有什么可以帮到您?💕💕💕 How can I help you?", buttonImg: "", fields: [ { type: "email", label: "您的电子邮箱(方便与您联系):", name: "email", required: true, placeholder: "your@email.com" }, { type: "textarea", label: "您想提交的反馈和询问信息:", name: "message", placeholder: "What's on your mind?", }, { type: "submit" } ], styles: { title: { backgroundColor: "blue" }, button: { backgroundColor: "blue" } } }); // tooltips tippy('#aiedu', { content: "As to AI nowadays, LLM and Stable Diffusion are hot even hottest among them, If your want to both know-why and know-how with them, instead of only know-how which can't repeat itself, you should get you to https://ai.afoo.me right now ❗" });

2025/10/10
articleCard.readMore

KVectors向量数据库IVF索引,这测试结果我自己都想不到…

KVectors向量数据库IVF索引,这测试结果我自己都想不到… -王福强的个人博客:一个架构士的思考与沉淀 pre > code{ white-space: pre-wrap; font-family: monospace; font-size: 14px; /* border-left: blueviolet; border-left-width: thick; border-left-style: double; padding-left: 1rem !important; */ } .x-indicator{ display:none; } .htmx-request .x-indicator{ display:inline; } .htmx-request.x-indicator{ display:inline; } { "@context": "https://schema.org", "@type": "NewsArticle", "headline": "KVectors向量数据库IVF索引,这测试结果我自己都想不到…", "image": [ "https://afoo.me/images/fb_subscribe.jpg" ], "datePublished": "2025-09-27", "author": [{ "@type": "Person", "name": "王福强", "url": "https://afoo.me" }] } 福强私学 福强AI学堂 架构百科 博客文章 创作出版 产品与服务 登录信息 更多链接 (adsbygoogle = window.adsbygoogle || []).push({}); (adsbygoogle = window.adsbygoogle || []).push({}); KVectors向量数据库IVF索引,这测试结果我自己都想不到… 王福强 2025-09-27 (adsbygoogle = window.adsbygoogle || []).push({}); 测试数据集是Sift的100万向量数据, 向量维度是128维。 第一版的数据先作为基准,大家先有个感性对标: 从Sift的这100万向量数据集中查询一万条向量,一共用时159042毫秒(ms), 平均15.9毫秒, 跟KVectors里提供的HNSW+DiskANN版本查询性能相比,差八九毫秒,不过,也还不错,因为我第一版并没有严格按照IVF索引的语义进行的设计和实现,即向量数据我没有全都搬到内存里存放。 所以,从这角度来说,IO层面应该还有很大的提升空间。 于是,我就在重构完KVectors第三个版本的整体设计与实现之后,为向量存储新增了 loadAllVectorsIntoMemory 这个选项,并把它的默认值设置成了true,毕竟,现在生产服务器的内存轻轻松松就能搞定百万级别的向量数据存储。 搞定之后, 下面是几次粗略测试的结果截图(粗略测试是因为,我只是在2019年的老Intel MacbookPro上跑的这个测试): 一开始我没细看,以为省了几毫秒,细看发现, 这tmd平均不到2毫秒啊!!! 1.1毫秒到1.3毫秒… 我都没想到有这么惊喜,那看来HNSW+DiskANN版本也有很大提升空间咯~ 后来,为了再看看没有构建IVF索引之前查询同样数据会是怎么样一个结果,我又跑了下(当然,还是全量数据放内存): 性能急降,平均单次查询直接给干到了230毫秒, 😂 所以,IVF索引功不可没啊! 另外,感谢王总预约了下个月的新培训,感兴趣的企业也欢迎预约哟~ (adsbygoogle = window.adsbygoogle || []).push({}); >>>>>> 更多阅读 <<<<<< 关于钱磊在Shy3框架中使用的“动态URL”功能的小记 有关PGP的基本概念 我们”有薪人”上线啦~ 「福强私学」来一个? 「福强私学」, 一部沉淀了个人成长、技术与架构、组织与管理以及商业上的方法与心法的百科全书。 福强老师的 AI 通识课 开天窗,拉认知,订阅「福报」,即刻拥有自己的全模态人工智能。 Copyright © 王福强个人版权所有 - Since 2004 (Everything is homebrewed with Pandoc and Markdown, little Scala also included.) // Set "light" theme as default if (!localStorage.theme) { localStorage.theme = "light"; } if ( localStorage.theme === 'dark' || (!('theme' in localStorage) && window.matchMedia('(prefers-color-scheme: dark)').matches) ) { document.documentElement.classList.add('dark'); } else { document.documentElement.classList.remove('dark'); } function attachEvent(selector, event, fn) { const matches = document.querySelectorAll(selector); if (matches && matches.length) { matches.forEach((elem) => { elem.addEventListener(event, () => fn(elem), false); }); } } window.onload = function () { attachEvent('[data-toggle-menu]', 'click', function (elem) { elem.classList.toggle('expanded'); document.body.classList.toggle('overflow-hidden'); document.getElementById('header')?.classList.toggle('h-screen'); document.querySelector('#header nav')?.classList.toggle('hidden'); }); attachEvent("[data-toggle-color-scheme]", "click", function () { document.documentElement.classList.toggle("light"); localStorage.theme = "light"; }); }; window.onpageshow = function () { const elem = document.querySelector('[data-toggle-menu]'); if (elem) { elem.classList.remove('expanded'); } document.body.classList.remove('overflow-hidden'); document.getElementById('header')?.classList.remove('h-screen'); document.querySelector('#header nav')?.classList.add('hidden'); }; var gitalk = new Gitalk({ clientID: '518a605d711883414ac0', clientSecret: '69fb8ccc0616c5bcbc64d24ece0d06d279da91ff', repo: 'afoo.me.comments', owner: 'fujohnwang', admin: ['fujohnwang'], id: location.pathname.substring(0, 49), // Ensure uniqueness and length less than 50 distractionFreeMode: false // Facebook-like distraction free mode }) gitalk.render('comments') /* paste this line in verbatim */ window.formbutton=window.formbutton||function(){(formbutton.q=formbutton.q||[]).push(arguments)}; /* customize formbutton below*/ formbutton("create", { action: "https://formspree.io/f/xknlpkkd", title: "有什么可以帮到您?💕💕💕 How can I help you?", buttonImg: "", fields: [ { type: "email", label: "您的电子邮箱(方便与您联系):", name: "email", required: true, placeholder: "your@email.com" }, { type: "textarea", label: "您想提交的反馈和询问信息:", name: "message", placeholder: "What's on your mind?", }, { type: "submit" } ], styles: { title: { backgroundColor: "blue" }, button: { backgroundColor: "blue" } } }); // tooltips tippy('#aiedu', { content: "As to AI nowadays, LLM and Stable Diffusion are hot even hottest among them, If your want to both know-why and know-how with them, instead of only know-how which can't repeat itself, you should get you to https://ai.afoo.me right now ❗" });

2025/9/27
articleCard.readMore

使用KVectors向量数据库构建以图搜图应用

使用KVectors向量数据库构建以图搜图应用 -王福强的个人博客:一个架构士的思考与沉淀 pre > code{ white-space: pre-wrap; font-family: monospace; font-size: 14px; /* border-left: blueviolet; border-left-width: thick; border-left-style: double; padding-left: 1rem !important; */ } .x-indicator{ display:none; } .htmx-request .x-indicator{ display:inline; } .htmx-request.x-indicator{ display:inline; } pre > code.sourceCode { white-space: pre; position: relative; } pre > code.sourceCode > span { line-height: 1.25; } pre > code.sourceCode > span:empty { height: 1.2em; } .sourceCode { overflow: visible; } code.sourceCode > span { color: inherit; text-decoration: inherit; } div.sourceCode { margin: 1em 0; } pre.sourceCode { margin: 0; } @media screen { div.sourceCode { overflow: auto; } } @media print { pre > code.sourceCode { white-space: pre-wrap; } pre > code.sourceCode > span { display: inline-block; text-indent: -5em; padding-left: 5em; } } pre.numberSource code { counter-reset: source-line 0; } pre.numberSource code > span { position: relative; left: -4em; counter-increment: source-line; } pre.numberSource code > span > a:first-child::before { content: counter(source-line); position: relative; left: -1em; text-align: right; vertical-align: baseline; border: none; display: inline-block; -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; padding: 0 4px; width: 4em; color: #aaaaaa; } pre.numberSource { margin-left: 3em; border-left: 1px solid #aaaaaa; padding-left: 4px; } div.sourceCode { } @media screen { pre > code.sourceCode > span > a:first-child::before { text-decoration: underline; } } code span.al { color: #ff0000; font-weight: bold; } /* Alert */ code span.an { color: #60a0b0; font-weight: bold; font-style: italic; } /* Annotation */ code span.at { color: #7d9029; } /* Attribute */ code span.bn { color: #40a070; } /* BaseN */ code span.bu { color: #008000; } /* BuiltIn */ code span.cf { color: #007020; font-weight: bold; } /* ControlFlow */ code span.ch { color: #4070a0; } /* Char */ code span.cn { color: #880000; } /* Constant */ code span.co { color: #60a0b0; font-style: italic; } /* Comment */ code span.cv { color: #60a0b0; font-weight: bold; font-style: italic; } /* CommentVar */ code span.do { color: #ba2121; font-style: italic; } /* Documentation */ code span.dt { color: #902000; } /* DataType */ code span.dv { color: #40a070; } /* DecVal */ code span.er { color: #ff0000; font-weight: bold; } /* Error */ code span.ex { } /* Extension */ code span.fl { color: #40a070; } /* Float */ code span.fu { color: #06287e; } /* Function */ code span.im { color: #008000; font-weight: bold; } /* Import */ code span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Information */ code span.kw { color: #007020; font-weight: bold; } /* Keyword */ code span.op { color: #666666; } /* Operator */ code span.ot { color: #007020; } /* Other */ code span.pp { color: #bc7a00; } /* Preprocessor */ code span.sc { color: #4070a0; } /* SpecialChar */ code span.ss { color: #bb6688; } /* SpecialString */ code span.st { color: #4070a0; } /* String */ code span.va { color: #19177c; } /* Variable */ code span.vs { color: #4070a0; } /* VerbatimString */ code span.wa { color: #60a0b0; font-weight: bold; font-style: italic; } /* Warning */ { "@context": "https://schema.org", "@type": "NewsArticle", "headline": "使用KVectors向量数据库构建以图搜图应用", "image": [ "https://afoo.me/images/fb_subscribe.jpg" ], "datePublished": "2025-09-20", "author": [{ "@type": "Person", "name": "王福强", "url": "https://afoo.me" }] } 福强私学 福强AI学堂 架构百科 博客文章 创作出版 产品与服务 登录信息 更多链接 (adsbygoogle = window.adsbygoogle || []).push({}); (adsbygoogle = window.adsbygoogle || []).push({}); 使用KVectors向量数据库构建以图搜图应用 王福强 2025-09-20 (adsbygoogle = window.adsbygoogle || []).push({}); 以图搜图是电商平台上很常见的用户需求, 今天,我们尝试用最轻量级的方式, 为大家演示如何用KVector向量数据库构建一个以图搜图应用。 KVectors 支持三层访问模式: 我们选择最内核的方式,即以Library/类库的方式使用KVectors,因为这可以帮助我们构建最内聚的应用集成度, 安装与部署和使用对用户来说都更为友好。 整个以图搜图的应用流程很简单,主要两个方向: 上传图片到图片存储到时候(比如云上的对象存储,或者其他第三方图床), 我们会使用图像Embedding模型对上传的图片进行embedding操作, 然后将获得的图片对应的embedding(即向量)存入KVectors向量数据库。 当然,图片的上传与计算图像Embedding可以是并行的(也可以串行),这个根据应用的时延(Latency)要求决定就可以了。 搜索图像的时候,用户提交一个图像,我们依然是先针对这个图像进行Embedding,获得对应的embedding向量之后,拿着它去KVectors向量数据库中去搜索相似的embeddings,然后将相似的embeddings作为搜索结果,并根据其对应的元信息(metadata)获取对应的原始图像信息(比如存储地址),然后再展示给用户,从而完成整体的以图搜图闭环功能。 既然本次我们主要专注在轻量与集成度上,图像的embedding模型我们选择了一个比较老的小模型:MobileNetV2,相对于最新的VL模型或者CLIP模型,效果上可能不是最好的,但完成基础的以图搜图能力还是没有问题的(无非搜索的时候threshold要降低下标准🤪) 图像embedding与存入KVectors的代码大体如下: public float[] embed(String imagePath) throws IOException, OrtException { float[] preprocessedData = MobileNetV2ImagePreprocessor.preprocessImage(imagePath); long[] inputShape = {1, 3, 224, 224}; OnnxTensor inputTensor = OnnxTensor.createTensor(environment, FloatBuffer.wrap(preprocessedData), inputShape); try (OrtSession.Result result = session.run(Collections.singletonMap("pixel_values", inputTensor))) { return ImageEmbeddingExtractor.extractWithGlobalAvgPooling(result); } } val collectionOption = kdb.getCollection("ImageSearchVectorCollectionName") if (collectionOption.isDefined) { val vectorCollection = collectionOption.get vectorCollection.add(VectorRecord(vector, VectorMetadata(url, None))) } else { throw new IllegalStateException(s"no vector collection found in kvectors db at ${kdb.dataDir}") } kdb即KVectors向量数据库的对象引用,它的初始化也很简单: val kdb = new KVectors(new File(keeboxDir, "kvectors")) // <<< 主要这一行 Shutdowns.addShutdownRunnable(() => Cleaner.closeWithLog(kdb)) // 这行是为了擦屁股,在程序关闭后清理KVectors的相应资源 KVectors的设计包含向量数据库和向量集合(KVectorCollection)两级概念,一个KVectors向量数据库可以包含很多向量集合(KVectorCollection), 向量最终存入相应的向量集合(KVectorCollection),比如上面是用一个假名字ImageSearchVectorCollectionName作为向量集合的名字(这个参数你可以根据情况取)获得对应的向量集合对象引用,然后向其中添加向量。(向量集合预先已经在其他地方创建) 最后就是, VectorRecord的第一个参数vector就是前面embed方法返回的结果。 至于文件上传的代码,就不演示了,根据选用的公有云不同而API不同。 当图像的embedding存入KVectors向量数据库之后, 我们就可以针对他们进行相似度搜索了,来了一个图像,我们依然对其进行embed调用获得图像对应的embedding向量, 然后根据获得的这个embedding向量到KVectors向量数据库中查询: val embeddingVector = imageEmbeddingExecutor.embed(tmpFile.getAbsolutePath) val collectionOption = kdb.getCollection("ImageSearchVectorCollectionName") if (collectionOption.isDefined) { val ab = new ArrayBuffer[SearchResult]() logger.info(s"start search with topK=${topK}, threshold=${threshold} ..") collectionOption.get.query(embeddingVector, topK = topK, threshold = threshold).forEach(vectorResult => { val score = vectorResult.score.get val url = vectorResult.meta.getString("rid") logger.info(s"found image meet threshold at ${url} with score=${score}") ab.append(SearchResult(url, score)) }) ab.toArray } else { Array.empty } KVectors的设计中要求每个向量存入之前都要有一个 relation id 与之对应,在以图搜图这个场景中,我们使用图像的url作为这个relation id,即meta元信息中的rid的值就是图像的url, 这个值我们将用来获取图像展示给用户。(同时,用户点击图像的时候,会打开对应图像) 搜索的时候,除了图像的embedding向量, 还有两个参数要跟大家说明下: topK,这个参数主要控制搜索结果的数量,比如返回11条相似性结果或者50条,这个根据应用需求决定就好了; threshold, 这个参数控制相似性匹配的标准,取值一般在0到1之间,假如Embedding模型质量很好,一般设置0.8以上就可以了,我们选择的 MobileNetV2 模型因为年代久远而且参数量比较少,有些时候效果不理想,所以,偶尔需要降低threshold的值,比如降低到0.6,0.7这样。 下面是以图搜图的一个JavaFX应用的简单界面,供大家参考视觉效果: 用户通过拖拽或者剪切板粘贴要搜索的图像到目标区域(即Drop File Here图标位置),点击Search就可以获得搜索结果了。 当然,点击搜索之前,也可以调整topK和threshold两个参数的默认值。 至此,一个基于KVectors向量数据库的以图搜图应用就算构建完成了,是不是很简单? 除了以图搜图场景,KVectors向量数据库还可以在产品推荐、客服知识库、传统与各种RAG变种等不同场景发挥同样强大的作用。 海量向量数据集中搜索时延 6.8 毫秒,可不是谁家的向量数据库都能达到的指标哟 🤪 同时欢迎各大企业预定与选购KVectors向量数据库,让自己在AI时代划出美丽的第二增长曲线。😎 (adsbygoogle = window.adsbygoogle || []).push({}); >>>>>> 更多阅读 <<<<<< 人口红利或者工程师红利到底在强调什么? 你被人死缠烂打过吗? Event Driven Style API Design Instead of Old Procedure Style Ones 「福强私学」来一个? 「福强私学」, 一部沉淀了个人成长、技术与架构、组织与管理以及商业上的方法与心法的百科全书。 福强老师的 AI 通识课 开天窗,拉认知,订阅「福报」,即刻拥有自己的全模态人工智能。 Copyright © 王福强个人版权所有 - Since 2004 (Everything is homebrewed with Pandoc and Markdown, little Scala also included.) // Set "light" theme as default if (!localStorage.theme) { localStorage.theme = "light"; } if ( localStorage.theme === 'dark' || (!('theme' in localStorage) && window.matchMedia('(prefers-color-scheme: dark)').matches) ) { document.documentElement.classList.add('dark'); } else { document.documentElement.classList.remove('dark'); } function attachEvent(selector, event, fn) { const matches = document.querySelectorAll(selector); if (matches && matches.length) { matches.forEach((elem) => { elem.addEventListener(event, () => fn(elem), false); }); } } window.onload = function () { attachEvent('[data-toggle-menu]', 'click', function (elem) { elem.classList.toggle('expanded'); document.body.classList.toggle('overflow-hidden'); document.getElementById('header')?.classList.toggle('h-screen'); document.querySelector('#header nav')?.classList.toggle('hidden'); }); attachEvent("[data-toggle-color-scheme]", "click", function () { document.documentElement.classList.toggle("light"); localStorage.theme = "light"; }); }; window.onpageshow = function () { const elem = document.querySelector('[data-toggle-menu]'); if (elem) { elem.classList.remove('expanded'); } document.body.classList.remove('overflow-hidden'); document.getElementById('header')?.classList.remove('h-screen'); document.querySelector('#header nav')?.classList.add('hidden'); }; var gitalk = new Gitalk({ clientID: '518a605d711883414ac0', clientSecret: '69fb8ccc0616c5bcbc64d24ece0d06d279da91ff', repo: 'afoo.me.comments', owner: 'fujohnwang', admin: ['fujohnwang'], id: location.pathname.substring(0, 49), // Ensure uniqueness and length less than 50 distractionFreeMode: false // Facebook-like distraction free mode }) gitalk.render('comments') /* paste this line in verbatim */ window.formbutton=window.formbutton||function(){(formbutton.q=formbutton.q||[]).push(arguments)}; /* customize formbutton below*/ formbutton("create", { action: "https://formspree.io/f/xknlpkkd", title: "有什么可以帮到您?💕💕💕 How can I help you?", buttonImg: "", fields: [ { type: "email", label: "您的电子邮箱(方便与您联系):", name: "email", required: true, placeholder: "your@email.com" }, { type: "textarea", label: "您想提交的反馈和询问信息:", name: "message", placeholder: "What's on your mind?", }, { type: "submit" } ], styles: { title: { backgroundColor: "blue" }, button: { backgroundColor: "blue" } } }); // tooltips tippy('#aiedu', { content: "As to AI nowadays, LLM and Stable Diffusion are hot even hottest among them, If your want to both know-why and know-how with them, instead of only know-how which can't repeat itself, you should get you to https://ai.afoo.me right now ❗" });

2025/9/20
articleCard.readMore

Java 25 尝鲜体验

Java 25 尝鲜体验 -王福强的个人博客:一个架构士的思考与沉淀 pre > code{ white-space: pre-wrap; font-family: monospace; font-size: 14px; /* border-left: blueviolet; border-left-width: thick; border-left-style: double; padding-left: 1rem !important; */ } .x-indicator{ display:none; } .htmx-request .x-indicator{ display:inline; } .htmx-request.x-indicator{ display:inline; } pre > code.sourceCode { white-space: pre; position: relative; } pre > code.sourceCode > span { line-height: 1.25; } pre > code.sourceCode > span:empty { height: 1.2em; } .sourceCode { overflow: visible; } code.sourceCode > span { color: inherit; text-decoration: inherit; } div.sourceCode { margin: 1em 0; } pre.sourceCode { margin: 0; } @media screen { div.sourceCode { overflow: auto; } } @media print { pre > code.sourceCode { white-space: pre-wrap; } pre > code.sourceCode > span { display: inline-block; text-indent: -5em; padding-left: 5em; } } pre.numberSource code { counter-reset: source-line 0; } pre.numberSource code > span { position: relative; left: -4em; counter-increment: source-line; } pre.numberSource code > span > a:first-child::before { content: counter(source-line); position: relative; left: -1em; text-align: right; vertical-align: baseline; border: none; display: inline-block; -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; padding: 0 4px; width: 4em; color: #aaaaaa; } pre.numberSource { margin-left: 3em; border-left: 1px solid #aaaaaa; padding-left: 4px; } div.sourceCode { } @media screen { pre > code.sourceCode > span > a:first-child::before { text-decoration: underline; } } code span.al { color: #ff0000; font-weight: bold; } /* Alert */ code span.an { color: #60a0b0; font-weight: bold; font-style: italic; } /* Annotation */ code span.at { color: #7d9029; } /* Attribute */ code span.bn { color: #40a070; } /* BaseN */ code span.bu { color: #008000; } /* BuiltIn */ code span.cf { color: #007020; font-weight: bold; } /* ControlFlow */ code span.ch { color: #4070a0; } /* Char */ code span.cn { color: #880000; } /* Constant */ code span.co { color: #60a0b0; font-style: italic; } /* Comment */ code span.cv { color: #60a0b0; font-weight: bold; font-style: italic; } /* CommentVar */ code span.do { color: #ba2121; font-style: italic; } /* Documentation */ code span.dt { color: #902000; } /* DataType */ code span.dv { color: #40a070; } /* DecVal */ code span.er { color: #ff0000; font-weight: bold; } /* Error */ code span.ex { } /* Extension */ code span.fl { color: #40a070; } /* Float */ code span.fu { color: #06287e; } /* Function */ code span.im { color: #008000; font-weight: bold; } /* Import */ code span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Information */ code span.kw { color: #007020; font-weight: bold; } /* Keyword */ code span.op { color: #666666; } /* Operator */ code span.ot { color: #007020; } /* Other */ code span.pp { color: #bc7a00; } /* Preprocessor */ code span.sc { color: #4070a0; } /* SpecialChar */ code span.ss { color: #bb6688; } /* SpecialString */ code span.st { color: #4070a0; } /* String */ code span.va { color: #19177c; } /* Variable */ code span.vs { color: #4070a0; } /* VerbatimString */ code span.wa { color: #60a0b0; font-weight: bold; font-style: italic; } /* Warning */ { "@context": "https://schema.org", "@type": "NewsArticle", "headline": "Java 25 尝鲜体验", "image": [ "https://afoo.me/images/fb_subscribe.jpg" ], "datePublished": "2025-09-17", "author": [{ "@type": "Person", "name": "王福强", "url": "https://afoo.me" }] } 福强私学 福强AI学堂 架构百科 博客文章 创作出版 产品与服务 登录信息 更多链接 (adsbygoogle = window.adsbygoogle || []).push({}); (adsbygoogle = window.adsbygoogle || []).push({}); Java 25 尝鲜体验 王福强 2025-09-17 (adsbygoogle = window.adsbygoogle || []).push({}); Java 25 出来啦~ 把 JavaFX相关的几个项目先直接升级到了Java 25,没任何错误需要修复,相当丝滑,最主要的是,换完jdk,重新打包后,keeboxfx的安装包从919+M降到了715.6M🤣 ,就一个字,帅,三个字,干得漂亮 顺便把 KVectors 也一并升了: LuckyJohn💫 ➜ kVectors git:(master) ✗ git ci -m "bump up java to 25" [master 982663f] bump up java to 25 2 files changed, 27 insertions(+), 2 deletions(-) 有小兄弟说我追新,哈哈哈,只要这个新带来的是好的,就应该追。 什么都不做,只要升级单一依赖就能带来性能和效率上的绝大提升,干嘛不追?🤣 Java 25 这次发布主要包含了如下几个大的JEP特性: JEP 470 PEM Encodings of Cryptographic Objects // 这个好 JEP 502 Stable Values // 线程安全的lazy init, 有点儿loading cache那种API设计风格。 JEP 503 Remove the 32-bit x86 Port JEP 505 Structured Concurrency // // 这个可以 JEP 506 Scoped Values // virtual threads的完美搭档 JEP 507 Primitive Types in Patterns, instanceof, and switch // java语法特性 JEP 508 Vector API (Tenth Incubator)// 这阵子个人关注最多的JEP JEP 509 JFR CPU-Time Profiling // JFR打头儿的都是技术保障部的事儿,性能与稳定性🤣 JEP 510 Key Derivation Function API // 这个也好, 量子计算来了也不怕。 JEP 511 Module Import Declarations // jpms带来的那啥 JEP 512 Compact Source Files and Instance Main Methods // java 写脚本 JEP 513 Flexible Constructor Bodies // 继承上的改进,super()和this()不用非得在方法第一行了。 JEP 514 Ahead-of-Time Command-Line Ergonomics // AOT 打头儿的估计都从graalvm剥离出来的?Project Leyden vs. graalvm JEP 515 Ahead-of-Time Method Profiling JEP 518 JFR Cooperative Sampling JEP 519 Compact Object Headers // 省内存,$ java -XX:+UseCompactObjectHeaders … JEP 520 JFR Method Timing & Tracing JEP 521 Generational Shenandoah // 垃圾回收(gc)上的改进 当然,还有成千的微小改进和bug修复,这一般都一笔带过,但积攒多了带来的也是质变。 每个特性详细介绍,这篇文章我觉得写的挺好(下面表格也是整理自这篇文章),感兴趣的同学可以看看:https://hanno.codes/2025/09/16/heres-java-25/ JEP Title Status Project Feature Type Changes since Java 24 (#jep-470-pem-encodings-of-cryptographic-objects-preview) PEM Encodings of Cryptographic Objects Preview Security Libs Security New feature (#jep-502-stable-values-preview) Stable Values Preview Core Libs New API New feature (#jep-503-remove-the-32-bit-x86-port) Remove the 32-bit x86 Port HotSpot Deprecation Removal (#jep-505-structured-concurrency-fifth-preview) Structured Concurrency Fifth Preview Loom Concurrency Major (#jep-506-scoped-values) Scoped Values Loom Concurrency Minor (#jep-507-primitive-types-in-patterns-instanceof-and-switch-third-preview) Primitive Types in Patterns, instanceof, and switch Third Preview Amber Language None (#jep-508-vector-api-tenth-incubator) Vector API Tenth Incubator Panama New API Minor (#jep-509-jfr-cpu-time-profiling-experimental) JFR CPU-Time Profiling Experimental HotSpot / JFR Profiling New feature (#jep-510-key-derivation-function-api) Key Derivation Function API Security Libs Security None (#jep-511-module-import-declarations) Module Import Declarations Amber Language None (#jep-512-compact-source-files-and-instance-main-methods) Compact Source Files and Instance Main Methods Amber Language Major (#jep-513-flexible-constructor-bodies) Flexible Constructor Bodies Amber Language None (#jep-514-ahead-of-time-command-line-ergonomics) Ahead-of-Time Command-Line Ergonomics Leyden Performance New feature (#jep-515-ahead-of-time-method-profiling) Ahead-of-Time Method Profiling Leyden Performance New feature (#jep-518-jfr-cooperative-sampling) JFR Cooperative Sampling HotSpot / JFR Profiling New feature (#jep-519-compact-object-headers) Compact Object Headers HotSpot Performance None (#jep-520-jfr-method-timing–tracing) JFR Method Timing & Tracing HotSpot / JFR Profiling New feature (#jep-521-generational-shenandoah) Generational Shenandoah HotSpot / GC Performance Stability and performance improvements NOTE JEP life stages: incubation -> preview -> finalized. (adsbygoogle = window.adsbygoogle || []).push({}); >>>>>> 更多阅读 <<<<<< 借记卡 学习笔记:LEAD框架 我为什么不喜欢子项目或者子模块的概念 「福强私学」来一个? 「福强私学」, 一部沉淀了个人成长、技术与架构、组织与管理以及商业上的方法与心法的百科全书。 福强老师的 AI 通识课 开天窗,拉认知,订阅「福报」,即刻拥有自己的全模态人工智能。 Copyright © 王福强个人版权所有 - Since 2004 (Everything is homebrewed with Pandoc and Markdown, little Scala also included.) // Set "light" theme as default if (!localStorage.theme) { localStorage.theme = "light"; } if ( localStorage.theme === 'dark' || (!('theme' in localStorage) && window.matchMedia('(prefers-color-scheme: dark)').matches) ) { document.documentElement.classList.add('dark'); } else { document.documentElement.classList.remove('dark'); } function attachEvent(selector, event, fn) { const matches = document.querySelectorAll(selector); if (matches && matches.length) { matches.forEach((elem) => { elem.addEventListener(event, () => fn(elem), false); }); } } window.onload = function () { attachEvent('[data-toggle-menu]', 'click', function (elem) { elem.classList.toggle('expanded'); document.body.classList.toggle('overflow-hidden'); document.getElementById('header')?.classList.toggle('h-screen'); document.querySelector('#header nav')?.classList.toggle('hidden'); }); attachEvent("[data-toggle-color-scheme]", "click", function () { document.documentElement.classList.toggle("light"); localStorage.theme = "light"; }); }; window.onpageshow = function () { const elem = document.querySelector('[data-toggle-menu]'); if (elem) { elem.classList.remove('expanded'); } document.body.classList.remove('overflow-hidden'); document.getElementById('header')?.classList.remove('h-screen'); document.querySelector('#header nav')?.classList.add('hidden'); }; var gitalk = new Gitalk({ clientID: '518a605d711883414ac0', clientSecret: '69fb8ccc0616c5bcbc64d24ece0d06d279da91ff', repo: 'afoo.me.comments', owner: 'fujohnwang', admin: ['fujohnwang'], id: location.pathname.substring(0, 49), // Ensure uniqueness and length less than 50 distractionFreeMode: false // Facebook-like distraction free mode }) gitalk.render('comments') /* paste this line in verbatim */ window.formbutton=window.formbutton||function(){(formbutton.q=formbutton.q||[]).push(arguments)}; /* customize formbutton below*/ formbutton("create", { action: "https://formspree.io/f/xknlpkkd", title: "有什么可以帮到您?💕💕💕 How can I help you?", buttonImg: "", fields: [ { type: "email", label: "您的电子邮箱(方便与您联系):", name: "email", required: true, placeholder: "your@email.com" }, { type: "textarea", label: "您想提交的反馈和询问信息:", name: "message", placeholder: "What's on your mind?", }, { type: "submit" } ], styles: { title: { backgroundColor: "blue" }, button: { backgroundColor: "blue" } } }); // tooltips tippy('#aiedu', { content: "As to AI nowadays, LLM and Stable Diffusion are hot even hottest among them, If your want to both know-why and know-how with them, instead of only know-how which can't repeat itself, you should get you to https://ai.afoo.me right now ❗" });

2025/9/17
articleCard.readMore

Java Web框架历史演化: 看这一篇就够了 (Java web frameworks in different ages)

Java Web框架历史演化: 看这一篇就够了 (Java web frameworks in different ages) -王福强的个人博客:一个架构士的思考与沉淀 pre > code{ white-space: pre-wrap; font-family: monospace; font-size: 14px; /* border-left: blueviolet; border-left-width: thick; border-left-style: double; padding-left: 1rem !important; */ } .x-indicator{ display:none; } .htmx-request .x-indicator{ display:inline; } .htmx-request.x-indicator{ display:inline; } { "@context": "https://schema.org", "@type": "NewsArticle", "headline": "Java Web框架历史演化: 看这一篇就够了 (Java web frameworks in different ages)", "image": [ "https://afoo.me/images/fb_subscribe.jpg" ], "datePublished": "2025-09-17", "author": [{ "@type": "Person", "name": "王福强", "url": "https://afoo.me" }] } 福强私学 福强AI学堂 架构百科 博客文章 创作出版 产品与服务 登录信息 更多链接 (adsbygoogle = window.adsbygoogle || []).push({}); (adsbygoogle = window.adsbygoogle || []).push({}); Java Web框架历史演化: 看这一篇就够了 (Java web frameworks in different ages) 王福强 2025-09-17 (adsbygoogle = window.adsbygoogle || []).push({}); 今天看到一海外老哥发了这么条短文字: You can learn 100 JavaScript frameworks… or you can learn Java and Spring once, and it’ll pay you back for years. 💚 虽然JavaScript作为前端事实上的语言带动了前端JS框架的蓬勃发展,包括但不限于Jquery,React,Vue,Svelte 1, Angular,HTMX2, etc 但Java其实也不是只有Spring一家,只不过,Spring确实一家独大了20十多年,哈哈哈哈 今天帮大家梳理下Java这片国土上的Web frameworks的发展与演化… 早在2003年之前笔者还没本科毕业那会儿,J2EE一家独大,笨重的EJB/EJB2还得依托JBuilder才能省点儿开发的劲儿,那时候最流行的web framework叫webwork,struts那时候还是1.x时代。 后来(此时想起刘若英的歌声)… 除了几个怪咖, Google 的 GWT 和 Sun 自己搞的JSF, GWT还好, Gmail就是用它搞出来的,当年也是轰动一时, 这JSF嘛,就雷声大雨点儿小了… 再后来, 咚咚咚咚,Spring开始风风火火了,SpringMVC也一并跃入Web开发主流… (这时候有没有想起哥的传说?🤣) Spring称霸Java开发界20多年之后,出来了新生代Web frameworks 他们的代表是: Quarkus Micronaut 他们的主要特征是利用了Java语言以及Java虚拟机的新特性,比如GraalVM以及Project Layden的AoT特性。 而且,除了Java主航道,Scala/Groovy/Clojure/Kotlin等旁支也有自己的web frameworks演化,其中比较有名的有: play framework (scala) grails (groovy) 所以,综合来看,Java平台上的web frameworks也不少,但也不得不承认,Spring依然是主流🤣 最后,作者自己还写了个自己用的小web framework叫 Kate以及基于上扩展的keewebx, 当然,纯粹玩票性质,只是个人项目用用。 Simple Svelte,https://afoo.me/books.html↩︎ HTMX揭秘, https://afoo.me/books.html↩︎ (adsbygoogle = window.adsbygoogle || []).push({}); >>>>>> 更多阅读 <<<<<< 清迈, 刷我滴卡 Maven项目发布到公司内部Repository(Nexus) #阶段性反刍# ClassWorking With Spring Framework 「福强私学」来一个? 「福强私学」, 一部沉淀了个人成长、技术与架构、组织与管理以及商业上的方法与心法的百科全书。 福强老师的 AI 通识课 开天窗,拉认知,订阅「福报」,即刻拥有自己的全模态人工智能。 Copyright © 王福强个人版权所有 - Since 2004 (Everything is homebrewed with Pandoc and Markdown, little Scala also included.) // Set "light" theme as default if (!localStorage.theme) { localStorage.theme = "light"; } if ( localStorage.theme === 'dark' || (!('theme' in localStorage) && window.matchMedia('(prefers-color-scheme: dark)').matches) ) { document.documentElement.classList.add('dark'); } else { document.documentElement.classList.remove('dark'); } function attachEvent(selector, event, fn) { const matches = document.querySelectorAll(selector); if (matches && matches.length) { matches.forEach((elem) => { elem.addEventListener(event, () => fn(elem), false); }); } } window.onload = function () { attachEvent('[data-toggle-menu]', 'click', function (elem) { elem.classList.toggle('expanded'); document.body.classList.toggle('overflow-hidden'); document.getElementById('header')?.classList.toggle('h-screen'); document.querySelector('#header nav')?.classList.toggle('hidden'); }); attachEvent("[data-toggle-color-scheme]", "click", function () { document.documentElement.classList.toggle("light"); localStorage.theme = "light"; }); }; window.onpageshow = function () { const elem = document.querySelector('[data-toggle-menu]'); if (elem) { elem.classList.remove('expanded'); } document.body.classList.remove('overflow-hidden'); document.getElementById('header')?.classList.remove('h-screen'); document.querySelector('#header nav')?.classList.add('hidden'); }; var gitalk = new Gitalk({ clientID: '518a605d711883414ac0', clientSecret: '69fb8ccc0616c5bcbc64d24ece0d06d279da91ff', repo: 'afoo.me.comments', owner: 'fujohnwang', admin: ['fujohnwang'], id: location.pathname.substring(0, 49), // Ensure uniqueness and length less than 50 distractionFreeMode: false // Facebook-like distraction free mode }) gitalk.render('comments') /* paste this line in verbatim */ window.formbutton=window.formbutton||function(){(formbutton.q=formbutton.q||[]).push(arguments)}; /* customize formbutton below*/ formbutton("create", { action: "https://formspree.io/f/xknlpkkd", title: "有什么可以帮到您?💕💕💕 How can I help you?", buttonImg: "", fields: [ { type: "email", label: "您的电子邮箱(方便与您联系):", name: "email", required: true, placeholder: "your@email.com" }, { type: "textarea", label: "您想提交的反馈和询问信息:", name: "message", placeholder: "What's on your mind?", }, { type: "submit" } ], styles: { title: { backgroundColor: "blue" }, button: { backgroundColor: "blue" } } }); // tooltips tippy('#aiedu', { content: "As to AI nowadays, LLM and Stable Diffusion are hot even hottest among them, If your want to both know-why and know-how with them, instead of only know-how which can't repeat itself, you should get you to https://ai.afoo.me right now ❗" });

2025/9/17
articleCard.readMore

瞧不起知识产权的三个典型人物

瞧不起知识产权的三个典型人物 -王福强的个人博客:一个架构士的思考与沉淀 pre > code{ white-space: pre-wrap; font-family: monospace; font-size: 14px; /* border-left: blueviolet; border-left-width: thick; border-left-style: double; padding-left: 1rem !important; */ } .x-indicator{ display:none; } .htmx-request .x-indicator{ display:inline; } .htmx-request.x-indicator{ display:inline; } { "@context": "https://schema.org", "@type": "NewsArticle", "headline": "瞧不起知识产权的三个典型人物", "image": [ "https://afoo.me/images/fb_subscribe.jpg" ], "datePublished": "2025-09-14", "author": [{ "@type": "Person", "name": "王福强", "url": "https://afoo.me" }] } 福强私学 福强AI学堂 架构百科 博客文章 创作出版 产品与服务 登录信息 更多链接 (adsbygoogle = window.adsbygoogle || []).push({}); (adsbygoogle = window.adsbygoogle || []).push({}); 瞧不起知识产权的三个典型人物 王福强 2025-09-14 (adsbygoogle = window.adsbygoogle || []).push({}); 乔布斯 乔布斯在某个大学还是什么场合讲香蕉那个段子 1,相信大家都看到过吧? 瞧不起咨询公司,不就是瞧不起知识产权嘛 问题是,咨询公司也是公司,咨询公司也分段位啊,橘子非得跟香蕉比啊? 柏拉图 几千年前柏拉图也瞧不上知识产权,说画家比木匠差两个档次。 但今天大家也看到了, 木匠作品挣大钱的有,不怎么挣钱的也有,画家也是,要比也得顶级对顶级比吧? 他可能就是觉得实物才算创造?🤪 杨吉光 当然了,说到不尊重知识产权的,最典型的就是《插翅难逃》里的杨吉光了 天天跟张世豪要五五分账,到死也没分成… 所以,江湖上才会流传: 五五分账杨吉光 知识产权张世豪 🤣🤣🤣 我之前也谈到过这个话题↩︎ (adsbygoogle = window.adsbygoogle || []).push({}); >>>>>> 更多阅读 <<<<<< 说说我日常把玩的小工具 部署属于自己的ChatGPT的三种方式 Struts中的文件上传 「福强私学」来一个? 「福强私学」, 一部沉淀了个人成长、技术与架构、组织与管理以及商业上的方法与心法的百科全书。 福强老师的 AI 通识课 开天窗,拉认知,订阅「福报」,即刻拥有自己的全模态人工智能。 Copyright © 王福强个人版权所有 - Since 2004 (Everything is homebrewed with Pandoc and Markdown, little Scala also included.) // Set "light" theme as default if (!localStorage.theme) { localStorage.theme = "light"; } if ( localStorage.theme === 'dark' || (!('theme' in localStorage) && window.matchMedia('(prefers-color-scheme: dark)').matches) ) { document.documentElement.classList.add('dark'); } else { document.documentElement.classList.remove('dark'); } function attachEvent(selector, event, fn) { const matches = document.querySelectorAll(selector); if (matches && matches.length) { matches.forEach((elem) => { elem.addEventListener(event, () => fn(elem), false); }); } } window.onload = function () { attachEvent('[data-toggle-menu]', 'click', function (elem) { elem.classList.toggle('expanded'); document.body.classList.toggle('overflow-hidden'); document.getElementById('header')?.classList.toggle('h-screen'); document.querySelector('#header nav')?.classList.toggle('hidden'); }); attachEvent("[data-toggle-color-scheme]", "click", function () { document.documentElement.classList.toggle("light"); localStorage.theme = "light"; }); }; window.onpageshow = function () { const elem = document.querySelector('[data-toggle-menu]'); if (elem) { elem.classList.remove('expanded'); } document.body.classList.remove('overflow-hidden'); document.getElementById('header')?.classList.remove('h-screen'); document.querySelector('#header nav')?.classList.add('hidden'); }; var gitalk = new Gitalk({ clientID: '518a605d711883414ac0', clientSecret: '69fb8ccc0616c5bcbc64d24ece0d06d279da91ff', repo: 'afoo.me.comments', owner: 'fujohnwang', admin: ['fujohnwang'], id: location.pathname.substring(0, 49), // Ensure uniqueness and length less than 50 distractionFreeMode: false // Facebook-like distraction free mode }) gitalk.render('comments') /* paste this line in verbatim */ window.formbutton=window.formbutton||function(){(formbutton.q=formbutton.q||[]).push(arguments)}; /* customize formbutton below*/ formbutton("create", { action: "https://formspree.io/f/xknlpkkd", title: "有什么可以帮到您?💕💕💕 How can I help you?", buttonImg: "", fields: [ { type: "email", label: "您的电子邮箱(方便与您联系):", name: "email", required: true, placeholder: "your@email.com" }, { type: "textarea", label: "您想提交的反馈和询问信息:", name: "message", placeholder: "What's on your mind?", }, { type: "submit" } ], styles: { title: { backgroundColor: "blue" }, button: { backgroundColor: "blue" } } }); // tooltips tippy('#aiedu', { content: "As to AI nowadays, LLM and Stable Diffusion are hot even hottest among them, If your want to both know-why and know-how with them, instead of only know-how which can't repeat itself, you should get you to https://ai.afoo.me right now ❗" });

2025/9/14
articleCard.readMore

KVectors 压缩向量搜索重要跑通了…

KVectors 压缩向量搜索重要跑通了… -王福强的个人博客:一个架构士的思考与沉淀 pre > code{ white-space: pre-wrap; font-family: monospace; font-size: 14px; /* border-left: blueviolet; border-left-width: thick; border-left-style: double; padding-left: 1rem !important; */ } .x-indicator{ display:none; } .htmx-request .x-indicator{ display:inline; } .htmx-request.x-indicator{ display:inline; } { "@context": "https://schema.org", "@type": "NewsArticle", "headline": "KVectors 压缩向量搜索重要跑通了…", "image": [ "https://afoo.me/images/fb_subscribe.jpg" ], "datePublished": "2025-09-13", "author": [{ "@type": "Person", "name": "王福强", "url": "https://afoo.me" }] } 福强私学 福强AI学堂 架构百科 博客文章 创作出版 产品与服务 登录信息 更多链接 (adsbygoogle = window.adsbygoogle || []).push({}); (adsbygoogle = window.adsbygoogle || []).push({}); KVectors 压缩向量搜索重要跑通了… 王福强 2025-09-13 (adsbygoogle = window.adsbygoogle || []).push({}); blocking了半个月,终于通过读原始代码解决了KVectors绕不过去的一个大坑… 之前总是segment fault, 这错误让我这种对操作系统和硬件比较打怵的人来说,有点儿抓瞎😂 不过,这个问题不解决,一直block在那儿也不行,给依赖类库也提交了issue,作者没屌我,可能觉得问题太小儿科,或者海外工作节奏比较闲适? 🤪 问AI其实更无解,最后只能自己啃依赖库的源代码,昨天发现苗头儿,今天修改验证后,一切OK了 ✅ 用Sift的数据集做的测试(128维向量) 从100万条向量数据中查询1万条简单跑了下,数据看起来还可以, 平均6.3毫秒 而且是在2019年的老 MacbookPro 上跑的… #KVectors #向量数据库 (adsbygoogle = window.adsbygoogle || []).push({}); >>>>>> 更多阅读 <<<<<< 随笔 扩展Spring的依赖注入行为两例 奔向下一站… 「福强私学」来一个? 「福强私学」, 一部沉淀了个人成长、技术与架构、组织与管理以及商业上的方法与心法的百科全书。 福强老师的 AI 通识课 开天窗,拉认知,订阅「福报」,即刻拥有自己的全模态人工智能。 Copyright © 王福强个人版权所有 - Since 2004 (Everything is homebrewed with Pandoc and Markdown, little Scala also included.) // Set "light" theme as default if (!localStorage.theme) { localStorage.theme = "light"; } if ( localStorage.theme === 'dark' || (!('theme' in localStorage) && window.matchMedia('(prefers-color-scheme: dark)').matches) ) { document.documentElement.classList.add('dark'); } else { document.documentElement.classList.remove('dark'); } function attachEvent(selector, event, fn) { const matches = document.querySelectorAll(selector); if (matches && matches.length) { matches.forEach((elem) => { elem.addEventListener(event, () => fn(elem), false); }); } } window.onload = function () { attachEvent('[data-toggle-menu]', 'click', function (elem) { elem.classList.toggle('expanded'); document.body.classList.toggle('overflow-hidden'); document.getElementById('header')?.classList.toggle('h-screen'); document.querySelector('#header nav')?.classList.toggle('hidden'); }); attachEvent("[data-toggle-color-scheme]", "click", function () { document.documentElement.classList.toggle("light"); localStorage.theme = "light"; }); }; window.onpageshow = function () { const elem = document.querySelector('[data-toggle-menu]'); if (elem) { elem.classList.remove('expanded'); } document.body.classList.remove('overflow-hidden'); document.getElementById('header')?.classList.remove('h-screen'); document.querySelector('#header nav')?.classList.add('hidden'); }; var gitalk = new Gitalk({ clientID: '518a605d711883414ac0', clientSecret: '69fb8ccc0616c5bcbc64d24ece0d06d279da91ff', repo: 'afoo.me.comments', owner: 'fujohnwang', admin: ['fujohnwang'], id: location.pathname.substring(0, 49), // Ensure uniqueness and length less than 50 distractionFreeMode: false // Facebook-like distraction free mode }) gitalk.render('comments') /* paste this line in verbatim */ window.formbutton=window.formbutton||function(){(formbutton.q=formbutton.q||[]).push(arguments)}; /* customize formbutton below*/ formbutton("create", { action: "https://formspree.io/f/xknlpkkd", title: "有什么可以帮到您?💕💕💕 How can I help you?", buttonImg: "", fields: [ { type: "email", label: "您的电子邮箱(方便与您联系):", name: "email", required: true, placeholder: "your@email.com" }, { type: "textarea", label: "您想提交的反馈和询问信息:", name: "message", placeholder: "What's on your mind?", }, { type: "submit" } ], styles: { title: { backgroundColor: "blue" }, button: { backgroundColor: "blue" } } }); // tooltips tippy('#aiedu', { content: "As to AI nowadays, LLM and Stable Diffusion are hot even hottest among them, If your want to both know-why and know-how with them, instead of only know-how which can't repeat itself, you should get you to https://ai.afoo.me right now ❗" });

2025/9/13
articleCard.readMore