@iletai/nzb 1.2.0 → 1.2.1

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.
@@ -330,9 +330,9 @@ export function createBot() {
330
330
  const onToolEvent = (event) => {
331
331
  console.log(`[nzb] Bot received tool event: ${event.type} ${event.toolName}`);
332
332
  if (event.type === "tool_start") {
333
- void logDebug(`🔧 Tool start: ${event.toolName}`);
333
+ void logDebug(`🔧 Tool start: ${event.toolName}${event.detail ? ` — ${event.detail}` : ""}`);
334
334
  currentToolName = event.toolName;
335
- toolHistory.push({ name: event.toolName, startTime: Date.now() });
335
+ toolHistory.push({ name: event.toolName, startTime: Date.now(), detail: event.detail });
336
336
  const existingText = lastEditedText.replace(/^🔧 .*\n\n/, "");
337
337
  enqueueEdit(`🔧 ${event.toolName}\n\n${existingText}`.trim() || `🔧 ${event.toolName}`);
338
338
  }
@@ -416,7 +416,7 @@ export function createBot() {
416
416
  const formatted = toTelegramMarkdown(textWithMeta);
417
417
  let fullFormatted = formatted;
418
418
  if (config.showReasoning && toolHistory.length > 0) {
419
- const expandable = formatToolSummaryExpandable(toolHistory.map((t) => ({ name: t.name, durationMs: t.durationMs })));
419
+ const expandable = formatToolSummaryExpandable(toolHistory.map((t) => ({ name: t.name, durationMs: t.durationMs, detail: t.detail })));
420
420
  fullFormatted += expandable;
421
421
  }
422
422
  const chunks = chunkMessage(fullFormatted);
@@ -159,7 +159,8 @@ export function formatToolSummaryExpandable(toolCalls) {
159
159
  const dur = t.durationMs !== undefined
160
160
  ? ` \\(${escapeSegment((t.durationMs / 1000).toFixed(1) + "s")}\\)`
161
161
  : "";
162
- return `${escapeSegment("• ")}${name}${dur}`;
162
+ const detail = t.detail ? `\n> _${escapeSegment(t.detail.slice(0, 60))}_` : "";
163
+ return `${escapeSegment("• ")}${name}${dur}${detail}`;
163
164
  });
164
165
  const header = escapeSegment("🔧 Tools used:");
165
166
  const toolList = lines.join(`\n>`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@iletai/nzb",
3
- "version": "1.2.0",
3
+ "version": "1.2.1",
4
4
  "description": "NZB — a personal AI assistant for developers, built on the GitHub Copilot SDK",
5
5
  "bin": {
6
6
  "nzb": "dist/cli.js"