diff --git a/src/tui/tui.ts b/src/tui/tui.ts index 24e657ddc1f..a842294dec2 100644 --- a/src/tui/tui.ts +++ b/src/tui/tui.ts @@ -704,8 +704,7 @@ export async function runTui(opts: RunTuiOptions): Promise { root.addChild(footer); root.addChild(editor); - const resolveDynamicSlashCommandsKey = () => - JSON.stringify([currentAgentId, sessionInfo.modelProvider ?? ""]); + const resolveDynamicSlashCommandsKey = () => currentAgentId; const applyAutocompleteProvider = () => { const dynamicKey = resolveDynamicSlashCommandsKey(); @@ -737,10 +736,9 @@ export async function runTui(opts: RunTuiOptions): Promise { dynamicSlashCommandsInFlightKey = key; const requestId = ++dynamicSlashCommandsRequestId; const agentId = currentAgentId; - const provider = sessionInfo.modelProvider; - void client.listCommands({ + void client + .listCommands({ agentId, - ...(provider ? { provider } : {}), scope: "text", includeArgs: false, })