@integrity-labs/agt-cli 0.15.3 → 0.15.6

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.
@@ -10,7 +10,7 @@ import {
10
10
  stopAllSessions,
11
11
  stopAllSessionsAndWait,
12
12
  stopPersistentSession
13
- } from "./chunk-IEVDKEIT.js";
13
+ } from "./chunk-S3SFU5IM.js";
14
14
  export {
15
15
  collectDiagnostics,
16
16
  getProjectDir,
@@ -24,4 +24,4 @@ export {
24
24
  stopAllSessionsAndWait,
25
25
  stopPersistentSession
26
26
  };
27
- //# sourceMappingURL=persistent-session-ALP5DGFI.js.map
27
+ //# sourceMappingURL=persistent-session-Q4X2KRS6.js.map
package/mcp/index.js CHANGED
File without changes
@@ -14240,10 +14240,19 @@ async function getBotUserId() {
14240
14240
  return null;
14241
14241
  }
14242
14242
  }
14243
- var botUserId = await getBotUserId();
14244
- process.stderr.write(`slack-channel: Bot user ID: ${botUserId}
14243
+ async function resolveBotUserIdOrThrow() {
14244
+ for (let attempt = 1; attempt <= 5; attempt++) {
14245
+ const id = await getBotUserId();
14246
+ if (id) return id;
14247
+ await new Promise((r) => setTimeout(r, attempt * 1e3));
14248
+ }
14249
+ throw new Error("slack-channel: failed to resolve bot user_id via auth.test after 5 attempts");
14250
+ }
14251
+ var botUserId = await resolveBotUserIdOrThrow();
14252
+ var botUserIdForLog = `${botUserId.slice(0, 2)}***${botUserId.slice(-2)}`;
14253
+ process.stderr.write(`slack-channel: Bot user ID resolved (${botUserIdForLog})
14245
14254
  `);
14246
- var selfIdentityInstruction = botUserId ? `Your own Slack user_id is ${botUserId}. Treat <@${botUserId}> mentions as directed at you, even inside auto_followed threads.` : "";
14255
+ var selfIdentityInstruction = `Your own Slack user_id is ${botUserId}. Treat <@${botUserId}> mentions as directed at you, even inside auto_followed threads.`;
14247
14256
  var mcp = new Server(
14248
14257
  { name: "slack", version: "0.1.0" },
14249
14258
  {
@@ -14256,12 +14265,14 @@ var mcp = new Server(
14256
14265
  // and the agent silently loses attachment-handling guidance.
14257
14266
  instructions: [
14258
14267
  'Messages from Slack arrive as <channel source="slack" user="<slack-id>" user_name="<display-name>" channel="..." thread_ts="...">.',
14259
- ...selfIdentityInstruction ? [selfIdentityInstruction] : [],
14268
+ selfIdentityInstruction,
14260
14269
  "Inbound attachments: the <channel> tag's `files` attribute is a JSON-serialised array \u2014 JSON.parse it before iterating. If a file entry has a `path`, the image is ALREADY DOWNLOADED locally \u2014 Read that path directly, do NOT call slack.download_attachment. That tool is only for entries with `file_id` but NO `path` (PDF, docx, csv, etc.): pass file_id + channel verbatim (never paraphrase), then Read the returned path. Single-image messages also get a top-level `image_path` convenience attribute; multi-image messages omit it. Never tell the user about internal file-handling failures that don't affect the answer.",
14261
14270
  "Reply via slack.reply passing channel and thread_ts from the tag. Always include thread_ts on threaded replies so the response lands in the same thread.",
14262
14271
  "Address users by user_name, never by raw user ID. In multi-participant threads the CURRENT speaker is the one on the latest <channel> tag \u2014 don't conflate with earlier participants.",
14263
14272
  "Mentioned in a channel \u2192 respond in that thread. DM \u2192 respond directly.",
14264
14273
  'auto_followed="true" messages are from threads you previously joined: reply only if you have something useful to add. Skip if the conversation moved on, the message is directed at someone else, or your input would not add value.',
14274
+ 'Reaction taxonomy (use slack.react sparingly \u2014 most messages need a reply, not a reaction): \u{1F440} = ack/working on it (already auto-added on inbound, do not duplicate); \u2705 = action completed successfully; \u274C = you TRIED to execute the requested action and it FAILED with an error. Do NOT use \u274C to mean "skipped", "disagree", "n/a", "not addressed to me", or "no response needed".',
14275
+ `When a message in a thread is not addressed to you (different @-mention, conversation between others, auto_followed catch-up): SILENTLY SKIP \u2014 no reaction, no reply, do nothing. Adding \u274C in this case is wrong; it gives the user a misleading "execution failed" signal when in fact you correctly identified the message wasn't yours to handle.`,
14265
14276
  "To deliver a file, save it under your project dir and call slack.upload_file with path, channel, thread_ts."
14266
14277
  ].join(" ")
14267
14278
  }
@@ -14289,13 +14300,13 @@ mcp.setRequestHandler(ListToolsRequestSchema, async () => ({
14289
14300
  },
14290
14301
  {
14291
14302
  name: "slack.react",
14292
- description: "Add an emoji reaction to a Slack message",
14303
+ description: 'Add an emoji reaction to a Slack message. Use sparingly \u2014 prefer a text reply. Reaction taxonomy: \u2705 = action completed successfully; \u274C (`x`) = you TRIED to execute the requested action and it FAILED with an error. Do NOT use \u274C for "skipped", "disagree", "not addressed to me", "n/a", or "noted" \u2014 those need either a text reply or no response at all. \u{1F440} (eyes) is already auto-applied on inbound; do not duplicate.',
14293
14304
  inputSchema: {
14294
14305
  type: "object",
14295
14306
  properties: {
14296
14307
  channel: { type: "string", description: "Slack channel ID" },
14297
14308
  timestamp: { type: "string", description: "Message timestamp to react to" },
14298
- emoji: { type: "string", description: 'Emoji name without colons (e.g. "thumbsup")' }
14309
+ emoji: { type: "string", description: 'Emoji name without colons (e.g. "white_check_mark", "x"). Only use "x" when an execution attempt actually failed.' }
14299
14310
  },
14300
14311
  required: ["channel", "timestamp", "emoji"]
14301
14312
  }
@@ -14227,7 +14227,7 @@ var mcp = new Server(
14227
14227
  'For work >30s follow CLAUDE.md kanban flow: kanban.add, reply with "On it \u2014 tracking here: <kanban URL>", move to in_progress, do the work, reply with the result. Simple lookups skip kanban but still reply.',
14228
14228
  "Address users by user_name; user is the numeric Telegram ID. Reply-to a specific message with reply_to_message_id, otherwise omit.",
14229
14229
  "Resolve ambiguous times against your own Timezone from CLAUDE.md \u2014 do not ask the user.",
14230
- "Every inbound message gets an automatic \u{1F440} ack. Use telegram.react for your own reactions: \u{1F44D} \u{1F44E} \u2764 \u{1F525} \u{1F389} \u{1F914} \u{1F92F} \u{1F64F} \u{1F44C} \u{1F440} \u{1F4AF} \u270D \u{1FAE1} \u{1F192} \u{1F973} (premium-only fail silently)."
14230
+ `Reaction taxonomy (use telegram.react sparingly \u2014 prefer a text reply via telegram.reply): \u{1F440} = ack/working on it (already auto-added on inbound, do not duplicate); \u{1F44D} or \u{1F389} = action completed successfully; \u{1F494} = you TRIED to execute the requested action and it FAILED with an error (Telegram's free-tier stand-in for Slack's \u274C; the literal \u274C is not on the bot-allowed emoji list). Do NOT use \u{1F494} for "skipped", "disagree", "n/a", or "no response needed" \u2014 those need either a text reply or no reaction. Free-tier emoji set: \u{1F44D} \u{1F44E} \u2764 \u{1F525} \u{1F389} \u{1F914} \u{1F92F} \u{1F64F} \u{1F44C} \u{1F440} \u{1F4AF} \u270D \u{1FAE1} \u{1F192} \u{1F973} \u{1F494} (premium-only fail silently).`
14231
14231
  ].join(" ")
14232
14232
  }
14233
14233
  );
@@ -14287,7 +14287,7 @@ mcp.setRequestHandler(ListToolsRequestSchema, async () => ({
14287
14287
  },
14288
14288
  {
14289
14289
  name: "telegram.react",
14290
- description: "Add an emoji reaction to a Telegram message. Only free-tier emoji reactions are available to bots (Premium-only emoji fail silently). Pass an empty string or omit emoji to clear the bot's reaction on that message.",
14290
+ description: `Add an emoji reaction to a Telegram message. Use sparingly \u2014 prefer a text reply via telegram.reply. Reaction taxonomy: \u{1F44D} or \u{1F389} = action completed successfully; \u{1F494} = you TRIED to execute the requested action and it FAILED with an error (free-tier stand-in for Slack's \u274C). Do NOT use \u{1F494} for "skipped", "disagree", or "noted" \u2014 those need a text reply or no reaction at all. \u{1F440} is already auto-applied on inbound; do not duplicate. Only free-tier emoji reactions are available to bots (Premium-only emoji fail silently). Pass an empty string or omit emoji to clear the bot's reaction on that message.`,
14291
14291
  inputSchema: {
14292
14292
  type: "object",
14293
14293
  properties: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@integrity-labs/agt-cli",
3
- "version": "0.15.3",
3
+ "version": "0.15.6",
4
4
  "description": "Augmented Team CLI — agent provisioning and management",
5
5
  "type": "module",
6
6
  "engines": {
@@ -37,6 +37,8 @@
37
37
  "ajv": "^8.17.0",
38
38
  "ajv-formats": "^3.0.1",
39
39
  "chalk": "^5.4.0",
40
+ "ink": "^7.0.0",
41
+ "react": "^19.2.0",
40
42
  "cli-table3": "^0.6.5",
41
43
  "commander": "^13.0.0",
42
44
  "croner": "^10.0.1",
@@ -51,6 +53,7 @@
51
53
  "@augmented/core": "workspace:*",
52
54
  "@integrity-labs/augmented-mcp": "workspace:*",
53
55
  "@types/node": "^22.0.0",
56
+ "@types/react": "^19.2.0",
54
57
  "@types/ws": "^8.18.1",
55
58
  "tsup": "^8.0.0",
56
59
  "tsx": "^4.19.0",