[{"data":1,"prerenderedAt":417},["ShallowReactive",2],{"insight-model-routing":3,"insight-related-model-routing":154},{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":8,"description":7,"slug":9,"date":10,"duration":11,"category":12,"author":13,"tags":14,"body":18,"_type":148,"_id":149,"_source":150,"_file":151,"_stem":152,"_extension":153},"\u002Finsights\u002F06-model-routing","insights",false,"","模型路由：什么场景用 Opus，什么用 Haiku","model-routing","2026-01-08",7,"AI 工程","浩途技术团队",[15,16,17],"LLM","成本优化","模型选择",{"type":19,"children":20,"toc":141},"root",[21,29,43,47,52,87,90,95,119,128,131,136],{"type":22,"tag":23,"props":24,"children":26},"element","h2",{"id":25},"引子",[27],{"type":28,"value":25},"text",{"type":22,"tag":30,"props":31,"children":32},"p",{},[33,35,41],{"type":28,"value":34},"客户问浩途：\"你们都用 Claude Opus \u002F GPT-4 吗？\"——并不是。生产环境里我们大概\n60% 的请求路由到中小模型（Haiku、Sonnet 或开源 7B\u002F14B），关键决策才上 Opus。\n这套",{"type":22,"tag":36,"props":37,"children":38},"strong",{},[39],{"type":28,"value":40},"模型路由",{"type":28,"value":42},"逻辑省下大量成本。",{"type":22,"tag":44,"props":45,"children":46},"hr",{},[],{"type":22,"tag":23,"props":48,"children":50},{"id":49},"路由的三个维度",[51],{"type":28,"value":49},{"type":22,"tag":53,"props":54,"children":55},"ol",{},[56,67,77],{"type":22,"tag":57,"props":58,"children":59},"li",{},[60,65],{"type":22,"tag":36,"props":61,"children":62},{},[63],{"type":28,"value":64},"任务类型",{"type":28,"value":66},"：分类、抽取、改写 → 小模型；推理、规划、生成 → 大模型",{"type":22,"tag":57,"props":68,"children":69},{},[70,75],{"type":22,"tag":36,"props":71,"children":72},{},[73],{"type":28,"value":74},"后果严重性",{"type":28,"value":76},"：可被人工审核 → 容忍小模型偶尔错；不可挽回 → 必须大模型",{"type":22,"tag":57,"props":78,"children":79},{},[80,85],{"type":22,"tag":36,"props":81,"children":82},{},[83],{"type":28,"value":84},"延迟约束",{"type":28,"value":86},"：用户在线等待 → 小模型 + 缓存；后台批处理 → 大模型可接受",{"type":22,"tag":44,"props":88,"children":89},{},[],{"type":22,"tag":23,"props":91,"children":93},{"id":92},"路由实现的两个层面",[94],{"type":28,"value":92},{"type":22,"tag":96,"props":97,"children":98},"ul",{},[99,109],{"type":22,"tag":57,"props":100,"children":101},{},[102,107],{"type":22,"tag":36,"props":103,"children":104},{},[105],{"type":28,"value":106},"静态路由",{"type":28,"value":108},"：按业务类型固定路由",{"type":22,"tag":57,"props":110,"children":111},{},[112,117],{"type":22,"tag":36,"props":113,"children":114},{},[115],{"type":28,"value":116},"动态路由",{"type":28,"value":118},"：用一个小模型 \u002F 规则先做\"难度评估\"，难任务升级到大模型",{"type":22,"tag":120,"props":121,"children":122},"blockquote",{},[123],{"type":22,"tag":30,"props":124,"children":125},{},[126],{"type":28,"value":127},"（路由架构图与开源实现示例后续补）",{"type":22,"tag":44,"props":129,"children":130},{},[],{"type":22,"tag":23,"props":132,"children":134},{"id":133},"写在最后",[135],{"type":28,"value":133},{"type":22,"tag":30,"props":137,"children":138},{},[139],{"type":28,"value":140},"LLM 成本治理不是\"选最便宜\"，而是\"在每个场景选最合适\"。这套思路与传统 BI 系统的\n\"冷数据放对象存储、热数据放 Redis\"是同一个底层思想。",{"title":7,"searchDepth":142,"depth":142,"links":143},2,[144,145,146,147],{"id":25,"depth":142,"text":25},{"id":49,"depth":142,"text":49},{"id":92,"depth":142,"text":92},{"id":133,"depth":142,"text":133},"markdown","content:insights:06-model-routing.md","content","insights\u002F06-model-routing.md","insights\u002F06-model-routing","md",[155,297],{"_path":156,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":157,"description":7,"slug":158,"date":159,"duration":160,"category":12,"author":13,"cover":161,"tags":162,"featured":166,"body":167,"_type":148,"_id":294,"_source":150,"_file":295,"_stem":296,"_extension":153},"\u002Finsights\u002F01-agent-pitfalls","把 Agent 接进真实业务系统时，我们踩过的 7 个坑","agent-7-pitfalls","2026-04-18",14,"\u002Fimages\u002Finsights\u002Fagent-pitfalls-cover.png",[163,15,164,165],"Agent","RAG","业务系统",true,{"type":19,"children":168,"toc":287},[169,173,178,181,187,195,200,217,220,226,231,234,240,268,271,275],{"type":22,"tag":23,"props":170,"children":171},{"id":25},[172],{"type":28,"value":25},{"type":22,"tag":30,"props":174,"children":175},{},[176],{"type":28,"value":177},"2024 年起，浩途陆续把 LLM Agent 嵌入到客户的真实业务系统里——审批流、知识问答、\n工单分发、报表分析等。一年下来，复盘了 7 类反复踩过的坑，写下来给同行做避雷参考。",{"type":22,"tag":44,"props":179,"children":180},{},[],{"type":22,"tag":23,"props":182,"children":184},{"id":183},"坑-1权限边界没想清楚就让-agent-全能",[185],{"type":28,"value":186},"坑 1：权限边界没想清楚就让 Agent \"全能\"",{"type":22,"tag":120,"props":188,"children":189},{},[190],{"type":22,"tag":30,"props":191,"children":192},{},[193],{"type":28,"value":194},"现象：Agent 调用 API 时，能看到不属于本用户的数据。",{"type":22,"tag":30,"props":196,"children":197},{},[198],{"type":28,"value":199},"业务系统的权限模型通常是基于\"会话用户\"的，但 Agent 工作时是另一个身份。\n我们最早的做法是给 Agent 一个\"超级账号\"——很快就出问题：审批流里，Agent 帮 A 用户\n看了 B 用户的工单详情。",{"type":22,"tag":30,"props":201,"children":202},{},[203,208,210,215],{"type":22,"tag":36,"props":204,"children":205},{},[206],{"type":28,"value":207},"Plan B",{"type":28,"value":209},"：让 Agent ",{"type":22,"tag":36,"props":211,"children":212},{},[213],{"type":28,"value":214},"以调用者身份",{"type":28,"value":216},"访问业务 API，所有权限控制由原系统继承。",{"type":22,"tag":44,"props":218,"children":219},{},[],{"type":22,"tag":23,"props":221,"children":223},{"id":222},"坑-2上下文窗口一旦满了行为就开始抖",[224],{"type":28,"value":225},"坑 2：上下文窗口一旦满了，行为就开始抖",{"type":22,"tag":30,"props":227,"children":228},{},[229],{"type":28,"value":230},"（… 因篇幅省略，正文未来由内容运营补齐 …）",{"type":22,"tag":44,"props":232,"children":233},{},[],{"type":22,"tag":23,"props":235,"children":237},{"id":236},"坑-37占位",[238],{"type":28,"value":239},"坑 3—7：（占位）",{"type":22,"tag":96,"props":241,"children":242},{},[243,248,253,258,263],{"type":22,"tag":57,"props":244,"children":245},{},[246],{"type":28,"value":247},"幻觉与业务规则的协调",{"type":22,"tag":57,"props":249,"children":250},{},[251],{"type":28,"value":252},"工具调用的失败重试",{"type":22,"tag":57,"props":254,"children":255},{},[256],{"type":28,"value":257},"多轮对话状态管理",{"type":22,"tag":57,"props":259,"children":260},{},[261],{"type":28,"value":262},"成本失控与模型路由",{"type":22,"tag":57,"props":264,"children":265},{},[266],{"type":28,"value":267},"灰度上线与可回滚",{"type":22,"tag":44,"props":269,"children":270},{},[],{"type":22,"tag":23,"props":272,"children":273},{"id":133},[274],{"type":28,"value":133},{"type":22,"tag":30,"props":276,"children":277},{},[278,280,285],{"type":28,"value":279},"把 LLM 接进业务系统，难的不是模型，而是 ",{"type":22,"tag":36,"props":281,"children":282},{},[283],{"type":28,"value":284},"业务约束如何被表达成 Agent 能理解的规则",{"type":28,"value":286},"。\n浩途下一篇会写\"如何把审批流的 50 条规则，结构化喂给 Agent 而不超 token\"。",{"title":7,"searchDepth":142,"depth":142,"links":288},[289,290,291,292,293],{"id":25,"depth":142,"text":25},{"id":183,"depth":142,"text":186},{"id":222,"depth":142,"text":225},{"id":236,"depth":142,"text":239},{"id":133,"depth":142,"text":133},"content:insights:01-agent-pitfalls.md","insights\u002F01-agent-pitfalls.md","insights\u002F01-agent-pitfalls",{"_path":298,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":299,"description":7,"slug":300,"date":301,"duration":302,"category":12,"author":13,"tags":303,"body":305,"_type":148,"_id":414,"_source":150,"_file":415,"_stem":416,"_extension":153},"\u002Finsights\u002F04-rag-knowledge-gap","RAG 在企业内的\"知识断层\"——为什么准确率上不去","rag-knowledge-gap","2026-03-22",11,[164,304,15],"企业知识库",{"type":19,"children":306,"toc":408},[307,311,323,326,332,344,354,357,363,381,389,392,396],{"type":22,"tag":23,"props":308,"children":309},{"id":25},[310],{"type":28,"value":25},{"type":22,"tag":30,"props":312,"children":313},{},[314,316,321],{"type":28,"value":315},"把 PDF 制度、Wiki、邮件归档全部 embedding 进 RAG 系统后，业务部门用了一周回来反馈：\n\"答案看起来对，细节都不对\"。我们复盘了 4 个项目的 RAG 准确率数据，得出的结论是\n——问题不在 embedding 模型，而在",{"type":22,"tag":36,"props":317,"children":318},{},[319],{"type":28,"value":320},"企业知识本身的断层",{"type":28,"value":322},"。",{"type":22,"tag":44,"props":324,"children":325},{},[],{"type":22,"tag":23,"props":327,"children":329},{"id":328},"断层-1切片粒度不匹配业务粒度",[330],{"type":28,"value":331},"断层 1：切片粒度不匹配业务粒度",{"type":22,"tag":30,"props":333,"children":334},{},[335,337,342],{"type":28,"value":336},"文档切片用 token 长度分块，业务问题却以\"任务\"为单位。一个\"如何提报年终预算\"\n跨 3 份文档：制度、流程图、表格模板。RAG 召回的 3 个 chunk 来自 3 份文档，但\n",{"type":22,"tag":36,"props":338,"children":339},{},[340],{"type":28,"value":341},"chunk 之间没有上下文链接",{"type":28,"value":343},"——LLM 无法重组成完整答案。",{"type":22,"tag":30,"props":345,"children":346},{},[347,352],{"type":22,"tag":36,"props":348,"children":349},{},[350],{"type":28,"value":351},"做法",{"type":28,"value":353},"：按业务任务建知识图谱，chunk 之上加\"任务-文档\"映射。",{"type":22,"tag":44,"props":355,"children":356},{},[],{"type":22,"tag":23,"props":358,"children":360},{"id":359},"断层-234占位",[361],{"type":28,"value":362},"断层 2、3、4（占位）",{"type":22,"tag":96,"props":364,"children":365},{},[366,371,376],{"type":22,"tag":57,"props":367,"children":368},{},[369],{"type":28,"value":370},"部门术语演化：同一个词在 IT 和业务部分别意指不同",{"type":22,"tag":57,"props":372,"children":373},{},[374],{"type":28,"value":375},"时间维度断层：旧规章和新规章并存，RAG 不知道哪个生效",{"type":22,"tag":57,"props":377,"children":378},{},[379],{"type":28,"value":380},"隐性知识缺失：流程之外的\"惯例\"从来没写进文档",{"type":22,"tag":120,"props":382,"children":383},{},[384],{"type":22,"tag":30,"props":385,"children":386},{},[387],{"type":28,"value":388},"（详细案例与方法论由后续内容运营展开）",{"type":22,"tag":44,"props":390,"children":391},{},[],{"type":22,"tag":23,"props":393,"children":394},{"id":133},[395],{"type":28,"value":133},{"type":22,"tag":30,"props":397,"children":398},{},[399,401,406],{"type":28,"value":400},"RAG 不是把文档塞进向量库就行。",{"type":22,"tag":36,"props":402,"children":403},{},[404],{"type":28,"value":405},"先治理知识，再做 RAG",{"type":28,"value":407},"——这才是企业落地 LLM 的正确顺序。",{"title":7,"searchDepth":142,"depth":142,"links":409},[410,411,412,413],{"id":25,"depth":142,"text":25},{"id":328,"depth":142,"text":331},{"id":359,"depth":142,"text":362},{"id":133,"depth":142,"text":133},"content:insights:04-rag-knowledge-gap.md","insights\u002F04-rag-knowledge-gap.md","insights\u002F04-rag-knowledge-gap",1780542368494]