iter(g154): MCP 搜索补组件级命中

原 search_components 只搜包级字段,命中后返回包,Agent 还得再猜组件 id。
改为返回 { packages, components } 两级,组件按 id / 标题 / props 名命中并带 package。
This commit is contained in:
HIsheR
2026-10-26 15:54:05 +08:00
parent c423d9cb2d
commit ab758ab9fc
2 changed files with 19 additions and 3 deletions
+8
View File
@@ -1588,6 +1588,14 @@
"acceptance": "ua search a b 取各词命中的最弱档做 AND 过滤仍保持 id>标题>props>步骤 的排序;未命中输出相近建议并 exit 1;无参数打印用法。",
"notes": "",
"status": "done"
},
{
"id": "g154",
"title": "MCP search_components 补组件级命中",
"motivation": "原实现只在包级字段(name/description/tags/api.exports)里搜,命中后只返回包:Agent 搜「日期」得到 @ui-arch/ui,还得再猜组件 id。",
"acceptance": "返回 { packages, components } 两级结构,components 按 id/标题/props 名命中并带 package 字段;空 query 与无命中都抛明确错误;工具描述同步。",
"notes": "",
"status": "open"
}
]
}