@ouro.bot/cli 0.1.0-alpha.4 → 0.1.0-alpha.41
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AdoptionSpecialist.ouro/agent.json +70 -9
- package/AdoptionSpecialist.ouro/psyche/SOUL.md +5 -2
- package/AdoptionSpecialist.ouro/psyche/identities/monty.md +2 -2
- package/README.md +117 -188
- package/assets/ouroboros.png +0 -0
- package/changelog.json +170 -0
- package/dist/heart/config.js +81 -8
- package/dist/heart/core.js +78 -45
- package/dist/heart/daemon/agent-discovery.js +81 -0
- package/dist/heart/daemon/daemon-cli.js +987 -77
- package/dist/heart/daemon/daemon-entry.js +14 -5
- package/dist/heart/daemon/daemon-runtime-sync.js +90 -0
- package/dist/heart/daemon/daemon.js +177 -9
- package/dist/heart/daemon/hatch-animation.js +35 -0
- package/dist/heart/daemon/hatch-flow.js +4 -20
- package/dist/heart/daemon/hooks/bundle-meta.js +92 -0
- package/dist/heart/daemon/launchd.js +134 -0
- package/dist/heart/daemon/message-router.js +15 -6
- package/dist/heart/daemon/ouro-bot-entry.js +0 -0
- package/dist/heart/daemon/ouro-bot-global-installer.js +128 -0
- package/dist/heart/daemon/ouro-entry.js +0 -0
- package/dist/heart/daemon/ouro-path-installer.js +178 -0
- package/dist/heart/daemon/ouro-uti.js +11 -2
- package/dist/heart/daemon/process-manager.js +1 -1
- package/dist/heart/daemon/run-hooks.js +37 -0
- package/dist/heart/daemon/runtime-metadata.js +118 -0
- package/dist/heart/daemon/sense-manager.js +266 -0
- package/dist/heart/daemon/specialist-orchestrator.js +129 -0
- package/dist/heart/daemon/specialist-prompt.js +99 -0
- package/dist/heart/daemon/specialist-tools.js +283 -0
- package/dist/heart/daemon/staged-restart.js +114 -0
- package/dist/heart/daemon/subagent-installer.js +10 -1
- package/dist/heart/daemon/update-checker.js +111 -0
- package/dist/heart/daemon/update-hooks.js +138 -0
- package/dist/heart/daemon/wrapper-publish-guard.js +86 -0
- package/dist/heart/identity.js +96 -4
- package/dist/heart/kicks.js +1 -19
- package/dist/heart/providers/anthropic.js +16 -2
- package/dist/heart/sense-truth.js +61 -0
- package/dist/heart/streaming.js +96 -21
- package/dist/mind/bundle-manifest.js +70 -0
- package/dist/mind/context.js +7 -7
- package/dist/mind/first-impressions.js +2 -1
- package/dist/mind/friends/channel.js +43 -0
- package/dist/mind/friends/store-file.js +19 -0
- package/dist/mind/friends/types.js +9 -1
- package/dist/mind/memory.js +10 -3
- package/dist/mind/pending.js +10 -2
- package/dist/mind/phrases.js +1 -0
- package/dist/mind/prompt.js +222 -7
- package/dist/mind/token-estimate.js +8 -12
- package/dist/nerves/cli-logging.js +15 -2
- package/dist/repertoire/ado-client.js +4 -2
- package/dist/repertoire/coding/feedback.js +134 -0
- package/dist/repertoire/coding/index.js +4 -1
- package/dist/repertoire/coding/manager.js +62 -4
- package/dist/repertoire/coding/spawner.js +3 -3
- package/dist/repertoire/coding/tools.js +41 -2
- package/dist/repertoire/data/ado-endpoints.json +188 -0
- package/dist/repertoire/tasks/index.js +2 -9
- package/dist/repertoire/tasks/transitions.js +1 -2
- package/dist/repertoire/tools-base.js +202 -219
- package/dist/repertoire/tools-bluebubbles.js +93 -0
- package/dist/repertoire/tools-teams.js +58 -25
- package/dist/repertoire/tools.js +55 -35
- package/dist/senses/bluebubbles-client.js +434 -0
- package/dist/senses/bluebubbles-entry.js +11 -0
- package/dist/senses/bluebubbles-media.js +338 -0
- package/dist/senses/bluebubbles-model.js +261 -0
- package/dist/senses/bluebubbles-mutation-log.js +74 -0
- package/dist/senses/bluebubbles-session-cleanup.js +72 -0
- package/dist/senses/bluebubbles.js +832 -0
- package/dist/senses/cli.js +327 -138
- package/dist/senses/debug-activity.js +127 -0
- package/dist/senses/inner-dialog.js +103 -55
- package/dist/senses/pipeline.js +124 -0
- package/dist/senses/teams.js +427 -112
- package/dist/senses/trust-gate.js +112 -2
- package/package.json +14 -3
- package/subagents/README.md +40 -53
- package/subagents/work-doer.md +26 -24
- package/subagents/work-merger.md +24 -30
- package/subagents/work-planner.md +34 -25
- package/dist/inner-worker-entry.js +0 -4
|
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.
|
|
6
|
+
exports.teamsToolDefinitions = void 0;
|
|
7
7
|
exports.summarizeTeamsArgs = summarizeTeamsArgs;
|
|
8
8
|
const graph_client_1 = require("./graph-client");
|
|
9
9
|
const ado_client_1 = require("./ado-client");
|
|
@@ -11,16 +11,6 @@ const graph_endpoints_json_1 = __importDefault(require("./data/graph-endpoints.j
|
|
|
11
11
|
const ado_endpoints_json_1 = __importDefault(require("./data/ado-endpoints.json"));
|
|
12
12
|
const runtime_1 = require("../nerves/runtime");
|
|
13
13
|
const MUTATE_METHODS = ["POST", "PATCH", "DELETE"];
|
|
14
|
-
// Map HTTP method to authority action name for canWrite() checks
|
|
15
|
-
const METHOD_TO_ACTION = {
|
|
16
|
-
POST: "createWorkItem",
|
|
17
|
-
PATCH: "updateWorkItem",
|
|
18
|
-
DELETE: "deleteWorkItem",
|
|
19
|
-
};
|
|
20
|
-
// Check if a tool response indicates a 403 PERMISSION_DENIED (authority checker removed; this is now a no-op kept for call-site stability)
|
|
21
|
-
function checkAndRecord403(_result, _integration, _scope, _action, _ctx) {
|
|
22
|
-
// No-op: AuthorityChecker eliminated. 403 recording removed.
|
|
23
|
-
}
|
|
24
14
|
const DEFAULT_ADO_QUERY = "SELECT [System.Id], [System.Title], [System.State], [System.AssignedTo] FROM WorkItems WHERE [System.AssignedTo] = @Me AND [System.State] <> 'Closed' ORDER BY [System.ChangedDate] DESC";
|
|
25
15
|
exports.teamsToolDefinitions = [
|
|
26
16
|
// -- Generic Graph tools --
|
|
@@ -82,7 +72,7 @@ exports.teamsToolDefinitions = [
|
|
|
82
72
|
type: "function",
|
|
83
73
|
function: {
|
|
84
74
|
name: "ado_query",
|
|
85
|
-
description: "GET or POST (for WIQL read queries) any Azure DevOps API endpoint. Use ado_docs first to look up the correct path.",
|
|
75
|
+
description: "GET or POST (for WIQL read queries) any Azure DevOps API endpoint. Use ado_docs first to look up the correct path and host.",
|
|
86
76
|
parameters: {
|
|
87
77
|
type: "object",
|
|
88
78
|
properties: {
|
|
@@ -90,6 +80,7 @@ exports.teamsToolDefinitions = [
|
|
|
90
80
|
path: { type: "string", description: "ADO API path after /{org}, e.g. /_apis/wit/wiql" },
|
|
91
81
|
method: { type: "string", enum: ["GET", "POST"], description: "HTTP method (defaults to GET)" },
|
|
92
82
|
body: { type: "string", description: "JSON request body (optional, used with POST for WIQL)" },
|
|
83
|
+
host: { type: "string", description: "API host override for non-standard APIs (e.g. 'vsapm.dev.azure.com' for entitlements, 'vssps.dev.azure.com' for users). Omit for standard dev.azure.com." },
|
|
93
84
|
},
|
|
94
85
|
required: ["organization", "path"],
|
|
95
86
|
},
|
|
@@ -100,9 +91,7 @@ exports.teamsToolDefinitions = [
|
|
|
100
91
|
return "AUTH_REQUIRED:ado -- I need access to Azure DevOps. Please sign in when prompted.";
|
|
101
92
|
}
|
|
102
93
|
const method = args.method || "GET";
|
|
103
|
-
|
|
104
|
-
checkAndRecord403(result, "ado", args.organization, method, ctx);
|
|
105
|
-
return result;
|
|
94
|
+
return (0, ado_client_1.adoRequest)(ctx.adoToken, method, args.organization, args.path, args.body, args.host);
|
|
106
95
|
},
|
|
107
96
|
integration: "ado",
|
|
108
97
|
},
|
|
@@ -111,7 +100,7 @@ exports.teamsToolDefinitions = [
|
|
|
111
100
|
type: "function",
|
|
112
101
|
function: {
|
|
113
102
|
name: "ado_mutate",
|
|
114
|
-
description: "POST/PATCH/DELETE any Azure DevOps API endpoint for actual mutations. Use ado_docs first to look up the correct path.",
|
|
103
|
+
description: "POST/PATCH/DELETE any Azure DevOps API endpoint for actual mutations. Use ado_docs first to look up the correct path and host.",
|
|
115
104
|
parameters: {
|
|
116
105
|
type: "object",
|
|
117
106
|
properties: {
|
|
@@ -119,6 +108,7 @@ exports.teamsToolDefinitions = [
|
|
|
119
108
|
organization: { type: "string", description: "Azure DevOps organization name" },
|
|
120
109
|
path: { type: "string", description: "ADO API path after /{org}" },
|
|
121
110
|
body: { type: "string", description: "JSON request body (optional)" },
|
|
111
|
+
host: { type: "string", description: "API host override for non-standard APIs (e.g. 'vsapm.dev.azure.com' for entitlements, 'vssps.dev.azure.com' for users). Omit for standard dev.azure.com." },
|
|
122
112
|
},
|
|
123
113
|
required: ["method", "organization", "path"],
|
|
124
114
|
},
|
|
@@ -131,11 +121,7 @@ exports.teamsToolDefinitions = [
|
|
|
131
121
|
if (!MUTATE_METHODS.includes(args.method)) {
|
|
132
122
|
return `Invalid method "${args.method}". Must be one of: ${MUTATE_METHODS.join(", ")}`;
|
|
133
123
|
}
|
|
134
|
-
|
|
135
|
-
const action = METHOD_TO_ACTION[args.method] || args.method;
|
|
136
|
-
const result = await (0, ado_client_1.adoRequest)(ctx.adoToken, args.method, args.organization, args.path, args.body);
|
|
137
|
-
checkAndRecord403(result, "ado", args.organization, action, ctx);
|
|
138
|
-
return result;
|
|
124
|
+
return (0, ado_client_1.adoRequest)(ctx.adoToken, args.method, args.organization, args.path, args.body, args.host);
|
|
139
125
|
},
|
|
140
126
|
integration: "ado",
|
|
141
127
|
confirmationRequired: true,
|
|
@@ -201,6 +187,53 @@ exports.teamsToolDefinitions = [
|
|
|
201
187
|
},
|
|
202
188
|
integration: "ado",
|
|
203
189
|
},
|
|
190
|
+
// -- Proactive messaging --
|
|
191
|
+
{
|
|
192
|
+
tool: {
|
|
193
|
+
type: "function",
|
|
194
|
+
function: {
|
|
195
|
+
name: "teams_send_message",
|
|
196
|
+
description: "send a proactive 1:1 Teams message to a user. requires their AAD object ID (use graph_query /users to find it). the message appears as coming from the bot.",
|
|
197
|
+
parameters: {
|
|
198
|
+
type: "object",
|
|
199
|
+
properties: {
|
|
200
|
+
user_id: { type: "string", description: "AAD object ID of the user to message" },
|
|
201
|
+
user_name: { type: "string", description: "display name of the user (for logging)" },
|
|
202
|
+
message: { type: "string", description: "message text to send" },
|
|
203
|
+
tenant_id: { type: "string", description: "tenant ID (optional, defaults to current conversation tenant)" },
|
|
204
|
+
},
|
|
205
|
+
required: ["user_id", "message"],
|
|
206
|
+
},
|
|
207
|
+
},
|
|
208
|
+
},
|
|
209
|
+
/* v8 ignore start -- proactive messaging requires live Teams SDK conversation client @preserve */
|
|
210
|
+
handler: async (args, ctx) => {
|
|
211
|
+
if (!ctx?.botApi) {
|
|
212
|
+
return "proactive messaging is not available -- no bot API context (this tool only works in the Teams channel)";
|
|
213
|
+
}
|
|
214
|
+
try {
|
|
215
|
+
const tenantId = args.tenant_id || ctx.tenantId;
|
|
216
|
+
// Cast to the SDK's ConversationClient shape (kept as `unknown` in ToolContext to avoid type coupling)
|
|
217
|
+
const conversations = ctx.botApi.conversations;
|
|
218
|
+
const conversation = await conversations.create({
|
|
219
|
+
bot: { id: ctx.botApi.id },
|
|
220
|
+
members: [{ id: args.user_id, role: "user", name: args.user_name || args.user_id }],
|
|
221
|
+
tenantId,
|
|
222
|
+
isGroup: false,
|
|
223
|
+
});
|
|
224
|
+
await conversations.activities(conversation.id).create({
|
|
225
|
+
type: "message",
|
|
226
|
+
text: args.message,
|
|
227
|
+
});
|
|
228
|
+
return `message sent to ${args.user_name || args.user_id}`;
|
|
229
|
+
}
|
|
230
|
+
catch (e) {
|
|
231
|
+
return `failed to send proactive message: ${e instanceof Error ? e.message : String(e)}`;
|
|
232
|
+
}
|
|
233
|
+
},
|
|
234
|
+
/* v8 ignore stop */
|
|
235
|
+
confirmationRequired: true,
|
|
236
|
+
},
|
|
204
237
|
// -- Documentation tools --
|
|
205
238
|
{
|
|
206
239
|
tool: {
|
|
@@ -243,10 +276,6 @@ exports.teamsToolDefinitions = [
|
|
|
243
276
|
integration: "ado",
|
|
244
277
|
},
|
|
245
278
|
];
|
|
246
|
-
// Backward-compat: extract just the OpenAI tool schemas
|
|
247
|
-
exports.teamsTools = exports.teamsToolDefinitions.map((d) => d.tool);
|
|
248
|
-
// Backward-compat: extract just the handlers by name
|
|
249
|
-
exports.teamsToolHandlers = Object.fromEntries(exports.teamsToolDefinitions.map((d) => [d.tool.function.name, d.handler]));
|
|
250
279
|
function searchEndpoints(entries, query) {
|
|
251
280
|
(0, runtime_1.emitNervesEvent)({
|
|
252
281
|
component: "repertoire",
|
|
@@ -268,6 +297,8 @@ function searchEndpoints(entries, query) {
|
|
|
268
297
|
` ${e.description}`,
|
|
269
298
|
` Params: ${e.params || "none"}`,
|
|
270
299
|
];
|
|
300
|
+
if (e.host)
|
|
301
|
+
lines.push(` Host: ${e.host}`);
|
|
271
302
|
if (e.scopes)
|
|
272
303
|
lines.push(` Scopes: ${e.scopes}`);
|
|
273
304
|
return lines.join("\n");
|
|
@@ -304,5 +335,7 @@ function summarizeTeamsArgs(name, args) {
|
|
|
304
335
|
return summarizeKeyValues(["query"]);
|
|
305
336
|
if (name === "ado_docs")
|
|
306
337
|
return summarizeKeyValues(["query"]);
|
|
338
|
+
if (name === "teams_send_message")
|
|
339
|
+
return summarizeKeyValues(["user_name", "user_id"]);
|
|
307
340
|
return undefined;
|
|
308
341
|
}
|
package/dist/repertoire/tools.js
CHANGED
|
@@ -1,29 +1,43 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.REMOTE_BLOCKED_LOCAL_TOOLS = exports.finalAnswerTool = exports.tools = void 0;
|
|
4
4
|
exports.getToolsForChannel = getToolsForChannel;
|
|
5
5
|
exports.isConfirmationRequired = isConfirmationRequired;
|
|
6
6
|
exports.execTool = execTool;
|
|
7
7
|
exports.summarizeArgs = summarizeArgs;
|
|
8
8
|
const tools_base_1 = require("./tools-base");
|
|
9
9
|
const tools_teams_1 = require("./tools-teams");
|
|
10
|
+
const tools_bluebubbles_1 = require("./tools-bluebubbles");
|
|
10
11
|
const ado_semantic_1 = require("./ado-semantic");
|
|
11
12
|
const tools_github_1 = require("./tools-github");
|
|
13
|
+
const types_1 = require("../mind/friends/types");
|
|
14
|
+
const channel_1 = require("../mind/friends/channel");
|
|
12
15
|
const runtime_1 = require("../nerves/runtime");
|
|
13
16
|
// Re-export types and constants used by the rest of the codebase
|
|
14
17
|
var tools_base_2 = require("./tools-base");
|
|
15
18
|
Object.defineProperty(exports, "tools", { enumerable: true, get: function () { return tools_base_2.tools; } });
|
|
16
19
|
Object.defineProperty(exports, "finalAnswerTool", { enumerable: true, get: function () { return tools_base_2.finalAnswerTool; } });
|
|
17
|
-
var tools_teams_2 = require("./tools-teams");
|
|
18
|
-
Object.defineProperty(exports, "teamsTools", { enumerable: true, get: function () { return tools_teams_2.teamsTools; } });
|
|
19
20
|
// All tool definitions in a single registry
|
|
20
|
-
const allDefinitions = [...tools_base_1.baseToolDefinitions, ...tools_teams_1.teamsToolDefinitions, ...ado_semantic_1.adoSemanticToolDefinitions, ...tools_github_1.githubToolDefinitions];
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
if (!isRemoteChannel)
|
|
21
|
+
const allDefinitions = [...tools_base_1.baseToolDefinitions, ...tools_bluebubbles_1.bluebubblesToolDefinitions, ...tools_teams_1.teamsToolDefinitions, ...ado_semantic_1.adoSemanticToolDefinitions, ...tools_github_1.githubToolDefinitions];
|
|
22
|
+
/** Tool names blocked for untrusted remote contexts. Shared with prompt.ts for restriction messaging. */
|
|
23
|
+
exports.REMOTE_BLOCKED_LOCAL_TOOLS = new Set(["shell", "read_file", "write_file", "edit_file", "glob", "grep"]);
|
|
24
|
+
function isTrustedRemoteContext(context) {
|
|
25
|
+
if (!context?.friend || !(0, channel_1.isRemoteChannel)(context.channel))
|
|
26
|
+
return false;
|
|
27
|
+
return (0, types_1.isTrustedLevel)(context.friend.trustLevel);
|
|
28
|
+
}
|
|
29
|
+
function shouldBlockLocalTools(capabilities, context) {
|
|
30
|
+
if (!(0, channel_1.isRemoteChannel)(capabilities))
|
|
31
|
+
return false;
|
|
32
|
+
return !isTrustedRemoteContext(context);
|
|
33
|
+
}
|
|
34
|
+
function blockedLocalToolMessage() {
|
|
35
|
+
return "I can't do that because my trust level with you isn't high enough for local shell/file operations. Ask me for a remote-safe alternative (Graph/ADO/web), or run that operation from CLI.";
|
|
36
|
+
}
|
|
37
|
+
function baseToolsForCapabilities(capabilities, context) {
|
|
38
|
+
if (!shouldBlockLocalTools(capabilities, context))
|
|
25
39
|
return tools_base_1.tools;
|
|
26
|
-
return tools_base_1.tools.filter((tool) => !REMOTE_BLOCKED_LOCAL_TOOLS.has(tool.function.name));
|
|
40
|
+
return tools_base_1.tools.filter((tool) => !exports.REMOTE_BLOCKED_LOCAL_TOOLS.has(tool.function.name));
|
|
27
41
|
}
|
|
28
42
|
// Apply a single tool preference to a tool schema, returning a new object.
|
|
29
43
|
function applyPreference(tool, pref) {
|
|
@@ -39,15 +53,20 @@ function applyPreference(tool, pref) {
|
|
|
39
53
|
// Base tools (no integration) are always included.
|
|
40
54
|
// Teams/integration tools are included only if their integration is in availableIntegrations.
|
|
41
55
|
// When toolPreferences is provided, matching preferences are appended to tool descriptions.
|
|
42
|
-
function getToolsForChannel(capabilities, toolPreferences) {
|
|
43
|
-
const baseTools = baseToolsForCapabilities(capabilities);
|
|
56
|
+
function getToolsForChannel(capabilities, toolPreferences, context) {
|
|
57
|
+
const baseTools = baseToolsForCapabilities(capabilities, context);
|
|
58
|
+
const bluebubblesTools = capabilities?.channel === "bluebubbles"
|
|
59
|
+
? tools_bluebubbles_1.bluebubblesToolDefinitions.map((d) => d.tool)
|
|
60
|
+
: [];
|
|
44
61
|
if (!capabilities || capabilities.availableIntegrations.length === 0) {
|
|
45
|
-
return baseTools;
|
|
62
|
+
return [...baseTools, ...bluebubblesTools];
|
|
46
63
|
}
|
|
47
64
|
const available = new Set(capabilities.availableIntegrations);
|
|
48
|
-
const
|
|
65
|
+
const channelDefs = [...tools_teams_1.teamsToolDefinitions, ...ado_semantic_1.adoSemanticToolDefinitions, ...tools_github_1.githubToolDefinitions];
|
|
66
|
+
// Include tools whose integration is available, plus channel tools with no integration gate (e.g. teams_send_message)
|
|
67
|
+
const integrationDefs = channelDefs.filter((d) => d.integration ? available.has(d.integration) : capabilities.channel === "teams");
|
|
49
68
|
if (!toolPreferences || Object.keys(toolPreferences).length === 0) {
|
|
50
|
-
return [...baseTools, ...integrationDefs.map((d) => d.tool)];
|
|
69
|
+
return [...baseTools, ...bluebubblesTools, ...integrationDefs.map((d) => d.tool)];
|
|
51
70
|
}
|
|
52
71
|
// Build a map of integration -> preference text for fast lookup
|
|
53
72
|
const prefMap = new Map();
|
|
@@ -60,7 +79,7 @@ function getToolsForChannel(capabilities, toolPreferences) {
|
|
|
60
79
|
const pref = prefMap.get(d.integration);
|
|
61
80
|
return pref ? applyPreference(d.tool, pref) : d.tool;
|
|
62
81
|
});
|
|
63
|
-
return [...baseTools, ...enrichedIntegrationTools];
|
|
82
|
+
return [...baseTools, ...bluebubblesTools, ...enrichedIntegrationTools];
|
|
64
83
|
}
|
|
65
84
|
// Check whether a tool requires user confirmation before execution.
|
|
66
85
|
// Reads from ToolDefinition.confirmationRequired instead of a separate Set.
|
|
@@ -87,15 +106,14 @@ async function execTool(name, args, ctx) {
|
|
|
87
106
|
});
|
|
88
107
|
return `unknown: ${name}`;
|
|
89
108
|
}
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
const message = "I can't do that from here because I'm talking to multiple people in a shared remote channel, and local shell/file/git/gh operations could let conversations interfere with each other. Ask me for a remote-safe alternative (Graph/ADO/web), or run that operation from CLI.";
|
|
109
|
+
if (shouldBlockLocalTools(ctx?.context?.channel, ctx?.context) && exports.REMOTE_BLOCKED_LOCAL_TOOLS.has(name)) {
|
|
110
|
+
const message = blockedLocalToolMessage();
|
|
93
111
|
(0, runtime_1.emitNervesEvent)({
|
|
94
112
|
level: "warn",
|
|
95
113
|
event: "tool.error",
|
|
96
114
|
component: "tools",
|
|
97
115
|
message: "blocked local tool in remote channel",
|
|
98
|
-
meta: { name, channel:
|
|
116
|
+
meta: { name, channel: ctx?.context?.channel?.channel },
|
|
99
117
|
});
|
|
100
118
|
return message;
|
|
101
119
|
}
|
|
@@ -152,34 +170,28 @@ function summarizeArgs(name, args) {
|
|
|
152
170
|
// Base tools
|
|
153
171
|
if (name === "read_file" || name === "write_file")
|
|
154
172
|
return summarizeKeyValues(args, ["path"]);
|
|
155
|
-
if (name === "
|
|
156
|
-
return summarizeKeyValues(args, ["command"]);
|
|
157
|
-
if (name === "list_directory")
|
|
173
|
+
if (name === "edit_file")
|
|
158
174
|
return summarizeKeyValues(args, ["path"]);
|
|
159
|
-
if (name === "
|
|
160
|
-
return summarizeKeyValues(args, ["
|
|
161
|
-
if (name === "
|
|
175
|
+
if (name === "glob")
|
|
176
|
+
return summarizeKeyValues(args, ["pattern", "cwd"]);
|
|
177
|
+
if (name === "grep")
|
|
178
|
+
return summarizeKeyValues(args, ["pattern", "path", "include"]);
|
|
179
|
+
if (name === "shell")
|
|
162
180
|
return summarizeKeyValues(args, ["command"]);
|
|
163
181
|
if (name === "load_skill")
|
|
164
182
|
return summarizeKeyValues(args, ["name"]);
|
|
165
|
-
if (name === "task_create")
|
|
166
|
-
return summarizeKeyValues(args, ["title", "type", "category"]);
|
|
167
|
-
if (name === "task_update_status")
|
|
168
|
-
return summarizeKeyValues(args, ["name", "status"]);
|
|
169
|
-
if (name === "task_board_status")
|
|
170
|
-
return summarizeKeyValues(args, ["status"]);
|
|
171
|
-
if (name === "task_board_action")
|
|
172
|
-
return summarizeKeyValues(args, ["scope"]);
|
|
173
|
-
if (name === "task_board" || name === "task_board_deps" || name === "task_board_sessions")
|
|
174
|
-
return "";
|
|
175
183
|
if (name === "coding_spawn")
|
|
176
184
|
return summarizeKeyValues(args, ["runner", "workdir", "taskRef"]);
|
|
177
185
|
if (name === "coding_status")
|
|
178
186
|
return summarizeKeyValues(args, ["sessionId"]);
|
|
187
|
+
if (name === "coding_tail")
|
|
188
|
+
return summarizeKeyValues(args, ["sessionId"]);
|
|
179
189
|
if (name === "coding_send_input")
|
|
180
190
|
return summarizeKeyValues(args, ["sessionId", "input"]);
|
|
181
191
|
if (name === "coding_kill")
|
|
182
192
|
return summarizeKeyValues(args, ["sessionId"]);
|
|
193
|
+
if (name === "bluebubbles_set_reply_target")
|
|
194
|
+
return summarizeKeyValues(args, ["target", "threadOriginatorGuid"]);
|
|
183
195
|
if (name === "claude")
|
|
184
196
|
return summarizeKeyValues(args, ["prompt"]);
|
|
185
197
|
if (name === "web_search")
|
|
@@ -195,5 +207,13 @@ function summarizeArgs(name, args) {
|
|
|
195
207
|
}
|
|
196
208
|
if (name === "ado_backlog_list")
|
|
197
209
|
return summarizeKeyValues(args, ["organization", "project"]);
|
|
210
|
+
if (name === "ado_batch_update")
|
|
211
|
+
return summarizeKeyValues(args, ["organization", "project"]);
|
|
212
|
+
if (name === "ado_create_epic" || name === "ado_create_issue")
|
|
213
|
+
return summarizeKeyValues(args, ["organization", "project", "title"]);
|
|
214
|
+
if (name === "ado_move_items")
|
|
215
|
+
return summarizeKeyValues(args, ["organization", "project", "workItemIds"]);
|
|
216
|
+
if (name === "ado_restructure_backlog")
|
|
217
|
+
return summarizeKeyValues(args, ["organization", "project"]);
|
|
198
218
|
return summarizeUnknownArgs(args);
|
|
199
219
|
}
|