feat: add agent preset chat commands

This commit is contained in:
xmanrui 2026-08-22 04:04:44 +08:00
parent 2ad6f1a44e
commit eea29fe296
33 changed files with 1519 additions and 234 deletions

View file

@ -185,9 +185,19 @@ test('all nine production channels use channel presets only as bot creation defa
);
assert.match(
source,
/agentPresetCatalog:\s*\(\)\s*=>\s*listAgentPresetCatalog\(ctx\)/,
/const agentPresetCatalog\s*=\s*\(\)\s*=>\s*listAgentPresetCatalog\(ctx\)/,
`${path} must read the Host preset catalog dynamically`,
);
assert.match(
source,
/createBotWorkspaceScope\([^;]*agentPresetCatalog[^;]*\)/,
`${path} must expose the same dynamic catalog to bot commands`,
);
assert.match(
source,
/createWorkspaceAwareController\([^;]*agentPresetCatalog,?[^;]*\)/,
`${path} must expose the same dynamic catalog to RPC updates`,
);
}
for (const channel of ['telegram', 'discord']) {