switchroom 0.13.4 → 0.13.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.
- package/README.md +36 -45
- package/dist/agent-scheduler/index.js +80 -80
- package/dist/auth-broker/index.js +80 -80
- package/dist/cli/drive-write-pretool.mjs +10 -10
- package/dist/cli/skill-validate-pretool.mjs +72 -72
- package/dist/cli/switchroom.js +361 -357
- package/dist/host-control/main.js +99 -99
- package/dist/vault/approvals/kernel-server.js +82 -82
- package/dist/vault/broker/server.js +83 -83
- package/package.json +1 -1
- package/profiles/_shared/telegram-style.md.hbs +1 -1
- package/profiles/_shared/vault-protocol.md.hbs +12 -0
- package/profiles/default/CLAUDE.md +192 -0
- package/telegram-plugin/dist/bridge/bridge.js +112 -112
- package/telegram-plugin/dist/gateway/gateway.js +210 -192
- package/telegram-plugin/dist/server.js +160 -160
- package/telegram-plugin/runtime-metrics.ts +14 -8
- package/telegram-plugin/silence-poke.ts +49 -1
- package/telegram-plugin/tests/silence-poke.test.ts +135 -3
- package/telegram-plugin/uat/scenarios/jtbd-fast-ack-dm.test.ts +217 -0
- package/telegram-plugin/uat/scenarios/jtbd-soft-commit-dm.test.ts +16 -11
package/README.md
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<p align="center">
|
|
2
|
-
<img src="docs/assets/switchroom-hero-wide.png" alt="Switchroom:
|
|
2
|
+
<img src="docs/assets/switchroom-hero-wide.png" alt="Switchroom: a standing team of specialist assistants on your Claude Pro or Max subscription, run from Telegram" width="100%">
|
|
3
3
|
</p>
|
|
4
4
|
|
|
5
5
|
# Switchroom
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
[](https://github.com/switchroom/switchroom/actions/workflows/ci-evals.yml)
|
|
11
11
|
[](https://github.com/switchroom/switchroom/actions/workflows/ci-evals.yml)
|
|
12
12
|
|
|
13
|
-
**A switchboard for your Pro or Max.** Your
|
|
13
|
+
**A switchboard for your Pro or Max.** Your standing team. Specialist assistants who remember you, own their patch, and act, while you get on with life. You text them from Telegram. They run on the Claude subscription you already pay for.
|
|
14
14
|
|
|
15
15
|
[Latest release notes →](CHANGELOG.md)
|
|
16
16
|
|
|
@@ -18,44 +18,34 @@
|
|
|
18
18
|
|
|
19
19
|
> *I loved OpenClaw + Telegram. I wanted my Claude subscription. And the UX done properly. So I built this.*
|
|
20
20
|
|
|
21
|
-
|
|
21
|
+
The use case came from OpenClaw: always-on assistants in a chat app, each with a personality and a job. Good idea. Three things stopped it being the one I needed, and nothing else fixed them:
|
|
22
22
|
|
|
23
|
-
|
|
23
|
+
- **On the subscription, properly.** The Claude plan I already pay for, the same OAuth as the desktop. Compliant. Predictable cost. Not an API meter. Not a second invoice.
|
|
24
|
+
- **On the leash.** Give an assistant broad standing access and one day it helpfully does something irreversible. Credentials, tools, skills: granted deliberately, approved by a human, no way around it.
|
|
25
|
+
- **Telegram, done properly.** Not a bridge spread thin across Slack, Discord, Teams. One channel. Opinionated. Excellent.
|
|
24
26
|
|
|
25
|
-
|
|
26
|
-
- **Claude Code's built-in Telegram channel.** Uses the subscription correctly. But it's an MVP black box. Send a message, wait, eventually something comes back. What did the agent actually do? Which tools ran? Did it get stuck? No idea.
|
|
27
|
-
|
|
28
|
-
Switchroom is the third option. Subscription-honest, and the UX done properly. The headline: the agent is never a black box and never silent. You always see what it is doing, what it is waiting on, and when it is done.
|
|
27
|
+
So I built it.
|
|
29
28
|
|
|
30
29
|
## See it work
|
|
31
30
|
|
|
32
|
-
|
|
31
|
+
You text a specialist the way you'd text a good assistant. Here is `clerk`, a chief of staff that runs the calendar, watches the health data, and fields the household asks, all in one voice, because it knows you across all of it.
|
|
33
32
|
|
|
34
|
-
|
|
35
|
-
🟡 quiet · no turns yet
|
|
36
|
-
⚙️ working since 2m ago
|
|
37
|
-
🟢 idle · last reply 5m ago
|
|
38
|
-
```
|
|
33
|
+
> **You:** move my 3pm to Thursday and tell Sarah why
|
|
39
34
|
|
|
40
|
-
|
|
35
|
+
clerk knows your week and knows who Sarah is. It gets on with it, then tells you in plain words what it did. No tool-call log to babysit.
|
|
41
36
|
|
|
42
37
|
```
|
|
43
|
-
|
|
44
|
-
|
|
38
|
+
clerk
|
|
39
|
+
Thursday 3 to 4pm is clear. Moved "Design review" there.
|
|
45
40
|
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
41
|
+
Drafted a note to Sarah:
|
|
42
|
+
"Had to shift our 3pm to Thursday. Same agenda,
|
|
43
|
+
see you then."
|
|
49
44
|
|
|
50
|
-
|
|
51
|
-
🔵 implement · Edit jwt.ts
|
|
52
|
-
🔵 test-runner · Bash npm test
|
|
53
|
-
[ Steer ]
|
|
45
|
+
Send it? [ Send ] [ Edit ]
|
|
54
46
|
```
|
|
55
47
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
Older sub-agents collapse to `+N more` once the live set passes 5. Tool arguments are sanitised before they render: file paths show the basename only, token-shaped strings get redacted, so a secret never lands in a status message. The card is posted and edited in the topic, not pinned, so it never leaves a stale `⚙️ Working…` stranded at the top of your chat. [Full UX behaviour →](docs/telegram-plugin.md)
|
|
48
|
+
It does the work itself. It stops at the one thing that matters, the message leaving your hands, and waits for your tap. Nothing with consequences happens on the agent's say-so alone. You are never left wondering what it is doing, and you never have to watch it. [Full UX behaviour →](docs/telegram-plugin.md)
|
|
59
49
|
|
|
60
50
|
## Quickstart
|
|
61
51
|
|
|
@@ -93,21 +83,21 @@ Full new-user walkthrough, zero to first Telegram message in ~15 minutes, plus t
|
|
|
93
83
|
|
|
94
84
|
| Feature | What it does |
|
|
95
85
|
|---|---|
|
|
96
|
-
| **
|
|
97
|
-
| **
|
|
98
|
-
| **
|
|
86
|
+
| **A standing team** | One bot per specialist, each with its own persona, memory, skills, tools, and credentials. Add a specialist in ten lines of YAML. You don't fork the product. |
|
|
87
|
+
| **You hold the leash** | Per-agent least-privilege ACL over an AES-256-GCM vault. Anything extra needs your tap on an inline Telegram Approve/Deny card. No heartbeats: beck-and-call plus the schedules you set, never roaming. |
|
|
88
|
+
| **Persistent memory** | Hindsight semantic memory, including a per-user mental model that carries across conversations and restarts. |
|
|
99
89
|
| **Claude Pro/Max auth** | OAuth, not API keys. No per-token billing. Fleet-wide active account plus fallback order, broker-owned refresh and credential fanout. |
|
|
100
|
-
| **
|
|
101
|
-
| **
|
|
90
|
+
| **Always available** | Long-running service per agent. Survives reboots, network drops, your laptop closing. Resumes mid-turn with a wake-audit. |
|
|
91
|
+
| **Honest status** | Every topic shows plain-language state: quiet, working, or idle. Never a black box, never silent, never a tool-call log to babysit. |
|
|
92
|
+
| **Live replies** | The reply streams in place while the agent works, with a Steer button to redirect mid-turn. Posted in the topic, not pinned, no stale cards. |
|
|
93
|
+
| **Sub-agents** | Opus plans, Sonnet implements. Delegated work surfaces as live rows in a shared fleet block. |
|
|
102
94
|
| **Config cascade** | Defaults, then profiles, then per-agent YAML. Change one line, every agent updates. |
|
|
103
95
|
| **Scheduled tasks** | Cron-syntax tasks that fire across reboots. Headless secret access through the vault broker. |
|
|
104
|
-
| **Persistent memory** | Hindsight semantic memory, including a per-user mental model that carries across conversations. |
|
|
105
|
-
| **Always-on** | Long-running service per agent. Survives reboots, network drops, your laptop closing. Resumes mid-turn with a wake-audit. |
|
|
106
96
|
| **17 Telegram MCP tools** | reply, stream, react, edit, pin, delete, forward, typing, history, checklists (+update), stickers, GIFs, attachment download, ask-user, vault request access/save. |
|
|
107
97
|
|
|
108
98
|
## Subscription-honest, and safe by default
|
|
109
99
|
|
|
110
|
-
**Stock CLI, real OAuth.** Each agent runs the unmodified `claude` binary, authenticated with Anthropic through the same OAuth flow you use on the desktop app. No API key. No harness. No patched CLI. No proxied inference. One bill, the one you already pay. See the [Compliance Attestation](docs/compliance-attestation.md) for the full analysis
|
|
100
|
+
**Stock CLI, real OAuth.** Each agent runs the unmodified `claude` binary, authenticated with Anthropic through the same OAuth flow you use on the desktop app. No API key. No Agent SDK. No harness. No patched CLI. No proxied inference. This is a hard constraint, not a preference: running the native CLI on the subscription is what keeps switchroom inside Anthropic's third-party policy. One bill, the one you already pay. See the [Compliance Attestation](docs/compliance-attestation.md) for the full analysis.
|
|
111
101
|
|
|
112
102
|
**Least privilege, and you hold the keys.** This is the core opinion. An agent never holds the vault passphrase and never sees a secret it was not given. Secrets live in an AES-256-GCM vault. Each agent reaches the vault broker over its own socket whose identity is the bind path, so a compromised agent cannot pose as another. An agent can read a key only if you listed it for that agent's task: that is the standing, least-privilege ACL. Anything beyond that is just-in-time. The agent asks, you get an inline Telegram Approve/Deny card showing exactly what and why, and only your tap mints a scoped, expiring grant. The agent cannot self-elevate.
|
|
113
103
|
|
|
@@ -121,7 +111,7 @@ Switchroom's position: agents should collaborate with you on real documents, not
|
|
|
121
111
|
|
|
122
112
|
## Survives real life
|
|
123
113
|
|
|
124
|
-
Always
|
|
114
|
+
Always available is not enough on its own. Things still die. The product has to handle that or the illusion breaks.
|
|
125
115
|
|
|
126
116
|
<p align="center"><img src="docs/diagrams/wake-audit-lifecycle.svg" width="700" alt="Wake-audit lifecycle: kill, crash-pane snapshot, auto-restart, agent boots with SWITCHROOM_PENDING_TURN, acks with three options"></p>
|
|
127
117
|
|
|
@@ -134,16 +124,17 @@ Always-on is not enough on its own. Things still die. The product has to handle
|
|
|
134
124
|
|
|
135
125
|
| | Switchroom | Claude Code channels | OpenClaw | NanoClaw |
|
|
136
126
|
|---|---|---|---|---|
|
|
137
|
-
|
|
|
138
|
-
| Runtime | Claude Code CLI | Claude Code CLI | Custom runtime | Agents SDK |
|
|
127
|
+
| Runtime | Stock Claude Code CLI | Claude Code CLI | Custom runtime | Agents SDK |
|
|
139
128
|
| Auth | Pro/Max OAuth | Pro/Max OAuth | API key | API key |
|
|
140
|
-
|
|
|
141
|
-
| Parallel display | Shared fleet status, up to 5 rows | No | No | No |
|
|
129
|
+
| Standing access | Per-agent least-privilege ACL | None | Broad/permissive | Broad/permissive |
|
|
142
130
|
| Approval UX | Inline Telegram cards | None | None | None |
|
|
131
|
+
| Specialist fleet | One bot per specialist, own persona | Single | Yes | Yes |
|
|
132
|
+
| Sub-agent tracking | Yes, live fleet block | No | No | No |
|
|
133
|
+
| Progress visibility | Deterministic status, never silent | Black box | None | None |
|
|
143
134
|
| Config | YAML with cascade | None | JSON/TOML | Env vars |
|
|
144
135
|
| Setup | `switchroom setup` | Built-in (limited) | Docker compose | Docker compose |
|
|
145
136
|
|
|
146
|
-
The wedge against OpenClaw and NanoClaw is not the substrate. It is the stock `claude` CLI under your subscription, instead of a custom runtime under your API key. [vs OpenClaw](docs/vs-openclaw.md) and [vs NanoClaw](docs/vs-nanoclaw.md).
|
|
137
|
+
The wedge against OpenClaw and NanoClaw is not the substrate. It is the stock `claude` CLI under your subscription, on your leash, instead of a custom runtime under your API key with broad standing access. [vs OpenClaw](docs/vs-openclaw.md) and [vs NanoClaw](docs/vs-nanoclaw.md).
|
|
147
138
|
|
|
148
139
|
## Architecture
|
|
149
140
|
|
|
@@ -192,17 +183,17 @@ See [`docs/architecture.md`](docs/architecture.md) for the process model, IPC la
|
|
|
192
183
|
**Can I use a Claude Pro or Max subscription instead of an API key?**
|
|
193
184
|
Yes. That is the whole point. Switchroom runs the unmodified `claude` CLI with the same OAuth flow you use on the desktop app. No API key. No per-token billing.
|
|
194
185
|
|
|
195
|
-
**
|
|
196
|
-
|
|
186
|
+
**What is the leash, exactly?**
|
|
187
|
+
An agent only ever uses the credentials and tools you granted it. It can ask for more, and you get an inline Telegram Approve/Deny card showing what and why. Only your tap grants it, the grant is scoped and expiring, and the agent cannot self-elevate or route around you. There are no heartbeats: agents are beck-and-call plus the schedules you set, never roaming on their own.
|
|
197
188
|
|
|
198
189
|
**Does it work with multiple agents at the same time?**
|
|
199
|
-
Yes. Each
|
|
190
|
+
Yes. Each specialist gets its own Telegram forum topic, its own persona, memory, and tools. When an agent delegates, its sub-agents show up as live rows in a shared fleet block (up to 5, then `+N more`), each with role and current tool.
|
|
200
191
|
|
|
201
192
|
**What does it cost to run?**
|
|
202
193
|
A cheap Linux VPS (around $6/mo on Hetzner, DigitalOcean, wherever), plus your existing Claude Pro ($20/mo) or Max ($100/mo) subscription. Switchroom itself is MIT-licensed, free.
|
|
203
194
|
|
|
204
195
|
**Is this against Anthropic's terms of service?**
|
|
205
|
-
No. Switchroom uses the official `claude` binary with the official OAuth flow. See [docs/compliance-attestation.md](docs/compliance-attestation.md) for the full analysis.
|
|
196
|
+
No. Switchroom uses the official `claude` binary with the official OAuth flow, and only ever the interactive CLI on the subscription. See [docs/compliance-attestation.md](docs/compliance-attestation.md) for the full analysis.
|
|
206
197
|
|
|
207
198
|
## Telemetry
|
|
208
199
|
|