refactor: merge skill tool into slashcommand to reduce system prompt size

This commit is contained in:
Bo Li
2026-02-09 23:51:57 +08:00
parent 8c726f5589
commit 42b082b469
6 changed files with 155 additions and 12 deletions
+3 -10
View File
@@ -11,7 +11,6 @@ import {
createBackgroundTools,
createCallOmoAgent,
createLookAt,
createSkillTool,
createSkillMcpTool,
createSlashcommandTool,
createGrepTools,
@@ -89,14 +88,6 @@ export function createToolRegistry(args: {
const getSessionIDForMcp = (): string => getMainSessionID() || ""
const skillTool = createSkillTool({
skills: skillContext.mergedSkills,
mcpManager: managers.skillMcpManager,
getSessionID: getSessionIDForMcp,
gitMasterConfig: pluginConfig.git_master,
disabledSkills: skillContext.disabledSkills,
})
const skillMcpTool = createSkillMcpTool({
manager: managers.skillMcpManager,
getLoadedSkills: () => skillContext.mergedSkills,
@@ -107,6 +98,9 @@ export function createToolRegistry(args: {
const slashcommandTool = createSlashcommandTool({
commands,
skills: skillContext.mergedSkills,
mcpManager: managers.skillMcpManager,
getSessionID: getSessionIDForMcp,
gitMasterConfig: pluginConfig.git_master,
})
const taskSystemEnabled = pluginConfig.experimental?.task_system ?? false
@@ -134,7 +128,6 @@ export function createToolRegistry(args: {
call_omo_agent: callOmoAgent,
...(lookAt ? { look_at: lookAt } : {}),
task: delegateTask,
skill: skillTool,
skill_mcp: skillMcpTool,
slashcommand: slashcommandTool,
interactive_bash,