switchroom 0.21.7 → 0.21.9
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/bin/tmp-reaper.sh +234 -0
- package/dist/agent-scheduler/index.js +1 -1
- package/dist/auth-broker/index.js +2 -2
- package/dist/cli/notion-write-pretool.mjs +1 -1
- package/dist/cli/switchroom.js +3520 -2782
- package/dist/host-control/main.js +177 -13
- package/dist/vault/approvals/kernel-server.js +2 -2
- package/dist/vault/broker/server.js +2 -2
- package/package.json +6 -5
- package/profiles/_base/start.sh.hbs +115 -0
- package/profiles/_shared/local-time.md.hbs +6 -0
- package/profiles/default/CLAUDE.md.hbs +0 -12
- package/skills/switchroom-architecture/telegram.md +12 -10
- package/skills/switchroom-cli/SKILL.md +1 -1
- package/telegram-plugin/README.md +3 -1
- package/telegram-plugin/dist/gateway/gateway.js +1164 -547
- package/telegram-plugin/format.ts +12 -4
- package/telegram-plugin/gateway/agent-process-liveness.ts +558 -0
- package/telegram-plugin/gateway/approval-hold.ts +32 -1
- package/telegram-plugin/gateway/approval-outcome-sources.ts +274 -0
- package/telegram-plugin/gateway/bridge-dead-watchdog.ts +21 -9
- package/telegram-plugin/gateway/callback-query-handlers.ts +87 -15
- package/telegram-plugin/gateway/eval-case-proposal-inbound-builders.ts +197 -0
- package/telegram-plugin/gateway/gateway.ts +12 -10
- package/telegram-plugin/gateway/pending-inbound-buffer.ts +167 -11
- package/telegram-plugin/gateway/self-improve-proposal-wiring.test.ts +333 -0
- package/telegram-plugin/gateway/self-improve-proposal-wiring.ts +152 -3
- package/telegram-plugin/gateway/subagent-handback-marker.ts +19 -0
- package/telegram-plugin/package.json +1 -1
- package/telegram-plugin/render/code-segments.ts +38 -4
- package/telegram-plugin/render/dollar-math-guard.ts +16 -1
- package/telegram-plugin/render/ir.ts +53 -3
- package/telegram-plugin/render/parse.ts +73 -14
- package/telegram-plugin/render/render.ts +53 -15
- package/telegram-plugin/render/unsupported-token-guard.ts +45 -80
- package/telegram-plugin/rich-send.ts +22 -7
- package/telegram-plugin/shared/bot-runtime.ts +3 -2
- package/telegram-plugin/telegraph.ts +6 -4
- package/telegram-plugin/tests/agent-process-liveness.test.ts +406 -0
- package/telegram-plugin/tests/approval-hold-record.test.ts +21 -8
- package/telegram-plugin/tests/boot-resume-gateway-only-respawn.test.ts +752 -0
- package/telegram-plugin/tests/boot-resume-guard-wiring.test.ts +203 -0
- package/telegram-plugin/tests/callback-query-handlers.test.ts +143 -1
- package/telegram-plugin/tests/eval-case-proposal-inbound-builders.test.ts +144 -0
- package/telegram-plugin/tests/grammy-rich-message-types.test.ts +199 -0
- package/telegram-plugin/tests/hermes-messages-paging.test.ts +149 -0
- package/telegram-plugin/tests/hermes-session-search.test.ts +146 -0
- package/telegram-plugin/tests/pending-inbound-buffer.test.ts +443 -2
- package/telegram-plugin/tests/render/dollar-math-guard.test.ts +43 -0
- package/telegram-plugin/tests/render/guard-composition.test.ts +102 -0
- package/telegram-plugin/tests/render/parse.test.ts +30 -5
- package/telegram-plugin/tests/render/render.test.ts +9 -4
- package/telegram-plugin/tests/render/rich-render.test.ts +46 -5
- package/telegram-plugin/tests/render/tg-entity.test.ts +242 -0
- package/telegram-plugin/tests/render/unsupported-token-guard.test.ts +66 -66
- package/telegram-plugin/tests/sent-text-capture.test.ts +3 -3
- package/telegram-plugin/tests/subagent-handback-marker.test.ts +14 -0
- package/telegram-plugin/tests/telegraph.test.ts +1 -1
- package/telegram-plugin/uat/scenarios/jtbd-rich-formatting-render-dm.test.ts +17 -8
|
@@ -6,7 +6,7 @@ Switchroom ships an enhanced `switchroom-telegram` MCP plugin that replaces the
|
|
|
6
6
|
|
|
7
7
|
| Tool | What it does |
|
|
8
8
|
|------|-------------|
|
|
9
|
-
| `reply` | Send text, photos, or documents — the single final-answer tool. Chunks anything over
|
|
9
|
+
| `reply` | Send text, photos, or documents — the single final-answer tool. Chunks anything over the 32768-char rich-message cap (4096 applies only to plain-text degradations). Supports threading, topic routing, file attachments. |
|
|
10
10
|
| `react` | Add emoji reactions to messages (Telegram whitelist: 👍 👎 ❤️ 🔥 👀 🎉 etc). |
|
|
11
11
|
| `edit_message` | Update a previously sent message. Edits are silent (no push notification). |
|
|
12
12
|
| `delete_message` | Remove a bot-sent message (48h Telegram API limit). |
|
|
@@ -40,18 +40,20 @@ History survives process restarts and session resets.
|
|
|
40
40
|
For long tasks you do not need to narrate progress by editing a message. The
|
|
41
41
|
plugin renders an event-driven progress card (Plan → Run → Done with live tool
|
|
42
42
|
bullets, elapsed time, and status emoji) for free while the turn is in-flight.
|
|
43
|
-
Send the final answer once, with `reply` — it chunks anything over
|
|
44
|
-
|
|
43
|
+
Send the final answer once, with `reply` — it chunks anything over the
|
|
44
|
+
32768-char rich-message cap (4096 applies only to plain-text degradations).
|
|
45
|
+
For an explicit mid-turn check-in use `progress_update`.
|
|
45
46
|
|
|
46
47
|
## Formatting
|
|
47
48
|
|
|
48
|
-
|
|
49
|
-
-
|
|
50
|
-
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
49
|
+
Every outbound message is sent as raw GFM markdown via the Bot API 10.1
|
|
50
|
+
rich-message path (`sendRichMessage` / `editMessageText({ markdown })`) —
|
|
51
|
+
Telegram parses the markdown server-side. There is no markdown→HTML
|
|
52
|
+
conversion and no `parse_mode` on this path. Smart chunking
|
|
53
|
+
(`splitMarkdownChunks`) splits anything over the 32768-char rich cap without
|
|
54
|
+
bisecting code fences or table rows; bodies that degrade to plain text fall
|
|
55
|
+
back to the legacy 4096-char cap. See
|
|
56
|
+
`reference/telegram-formatting-guide.md` for the full vocabulary.
|
|
55
57
|
|
|
56
58
|
## Access control
|
|
57
59
|
|
|
@@ -294,7 +294,7 @@ The `switchroom-telegram` plugin is an enhanced fork of the official Telegram MC
|
|
|
294
294
|
|
|
295
295
|
| Tool | Purpose |
|
|
296
296
|
|---|---|
|
|
297
|
-
| `reply` | Send a text/photo message — the single final-answer tool; chunks anything over
|
|
297
|
+
| `reply` | Send a text/photo message — the single final-answer tool; chunks anything over the 32768-char rich-message cap (4096 applies only to plain-text degradations). Optional `reply_to` for threaded quotes |
|
|
298
298
|
| `react` | Emoji reaction on an inbound or outbound message |
|
|
299
299
|
| `edit_message` | Modify an earlier bot message's text |
|
|
300
300
|
| `delete_message` | Remove an earlier bot message |
|
|
@@ -204,7 +204,9 @@ For long tasks the model does **not** need to narrate progress or drive a
|
|
|
204
204
|
streaming message itself. The plugin renders an event-driven progress card
|
|
205
205
|
(Plan → Run → Done with live tool bullets, elapsed time, and status emoji)
|
|
206
206
|
for free while the turn is in-flight. Send the final answer once, with
|
|
207
|
-
`reply` — it chunks anything over
|
|
207
|
+
`reply` — it chunks anything over the rich-message wire cap of 32768 chars
|
|
208
|
+
(`RICH_MESSAGE_MAX_CHARS` in `format.ts`; the legacy 4096 cap applies only to
|
|
209
|
+
plain-text degradations). (The retired
|
|
208
210
|
`stream_reply` tool was a redundant, worse alias of `reply`; the internal
|
|
209
211
|
progress-card streaming that drove it is preserved and is what renders the
|
|
210
212
|
live card.)
|