feat(ai-writing): 检索类型加回「知识库检索」(直连内网 ES 接口)
弱模型常识别不了配置技能(deepseek-chat 等),恢复旧的"不用技能"检索路径 作为独立检索类型 knowledge_base:绕过技能编排,直接调 ai_writing.intranet_search_url 内网知识库 ES 接口(IntranetSearchProvider) 对检索词并发检索;未配地址 → 无素材 + skill_error 告警。 - researcher.py: material_source 归一保留 knowledge_base + 新增直连内网分支 - state.py: material_source 三值注释 - 前端 AIWritingForm/WritingFormContext/types: 下拉新增「知识库检索」 - tests/test_ai_writing_knowledge_base.py: 直连/未配/不编排技能 3 用例 - backend CLAUDE.md: 检索类型段更新为三值 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
a400989f64
commit
3d60651491
7 files changed
+182
-16
No files matched your search
@@ -40,11 +40,12 @@ const INPUT_CLASS =
|
||||
|
||||
const DEFAULT_KEYWORD_COUNT = 1;
|
||||
const DEFAULT_AUDIENCE = '普通读者';
|
||||
type MaterialSource = 'general' | 'notebook';
|
||||
type MaterialSource = 'general' | 'knowledge_base' | 'notebook';
|
||||
const MAX_INTENT_LENGTH = 500;
|
||||
|
||||
const MATERIAL_SOURCE_OPTIONS: Array<{ value: MaterialSource; label: string; desc: string }> = [
|
||||
{ value: 'general', label: '通用检索', desc: '用素材收集专家配置的技能检索(默认:知识库检索)' },
|
||||
{ value: 'knowledge_base', label: '知识库检索', desc: '直连内网知识库检索接口,不走技能编排' },
|
||||
{ value: 'notebook', label: '我的空间', desc: '从空间中检索素材' },
|
||||
];
|
||||
|
||||
|
||||
Reference in new issue
Block a user