@bytesbrains/pi-telegram-bridge 1.1.4 → 1.1.5

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/index.ts +7 -7
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bytesbrains/pi-telegram-bridge",
3
- "version": "1.1.4",
3
+ "version": "1.1.5",
4
4
  "description": "Telegram bot bridge for pi agents — send messages, ask questions, and listen for human replies via Telegram.",
5
5
  "keywords": [
6
6
  "pi-package",
package/src/index.ts CHANGED
@@ -295,16 +295,16 @@ export default function telegramBridge(pi: ExtensionAPI) {
295
295
  ];
296
296
  const timeoutMs = (params.timeoutMinutes ?? 30) * 60000;
297
297
 
298
- let message = `🛑 *Supervisor blocked an action*\n\n`;
299
- message += `*Command:* \`${params.command.slice(0, 200)}\`\n`;
300
- message += `*Reason:* ${params.reason.slice(0, 300)}\n`;
298
+ let message = `🛑 <b>Supervisor blocked an action</b>\n\n`;
299
+ message += `<b>Command:</b> <code>${params.command.slice(0, 200)}</code>\n`;
300
+ message += `<b>Reason:</b> ${params.reason.slice(0, 300)}\n`;
301
301
  if (params.context) {
302
- message += `*Context:* ${params.context.slice(0, 300)}\n`;
302
+ message += `<b>Context:</b> ${params.context.slice(0, 300)}\n`;
303
303
  }
304
- message += `\n_What should I do?_`;
304
+ message += `\n<i>What should I do?</i>`;
305
305
 
306
306
  const kb = opts.map((o: string) => [{ text: o, callback_data: o }]);
307
- const mid = await sendMsg(message, { inline_keyboard: kb }, "Markdown");
307
+ const mid = await sendMsg(message, { inline_keyboard: kb }, "HTML");
308
308
  const reply = await pollReply(mid, chatId, timeoutMs);
309
309
 
310
310
  if (!reply) {
@@ -336,7 +336,7 @@ export default function telegramBridge(pi: ExtensionAPI) {
336
336
  action = "explain";
337
337
  }
338
338
 
339
- await sendMsg(`✅ Choice received: _${choice}_`, undefined, "Markdown");
339
+ await sendMsg(`✅ Choice received: <i>${choice}</i>`, undefined, "HTML");
340
340
 
341
341
  return {
342
342
  content: [