switchroom 0.20.21 → 0.21.0
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/dist/auth-broker/index.js +1 -1
- package/dist/cli/switchroom.js +1953 -1539
- package/dist/host-control/main.js +286 -122
- package/dist/vault/approvals/kernel-server.js +1 -1
- package/dist/vault/broker/server.js +1 -1
- package/package.json +1 -1
- package/skills/switchroom-release/SKILL.md +12 -1
- package/telegram-plugin/dist/gateway/gateway.js +1405 -851
- package/telegram-plugin/gateway/always-allow-persist-queue.ts +2 -2
- package/telegram-plugin/gateway/boot-beacon.ts +9 -2
- package/telegram-plugin/gateway/gateway-heartbeat.ts +4 -3
- package/telegram-plugin/gateway/gateway.ts +42 -15
- package/telegram-plugin/gateway/inbound-router.ts +31 -6
- package/telegram-plugin/gateway/missed-approvals-store.ts +2 -2
- package/telegram-plugin/gateway/pending-card-store.ts +2 -2
- package/telegram-plugin/gateway/privacy-state.ts +2 -2
- package/telegram-plugin/gateway/scoped-grant-store.ts +2 -2
- package/telegram-plugin/gateway/system-message-observer.ts +242 -0
- package/telegram-plugin/gateway/turn-active-marker.ts +3 -4
- package/telegram-plugin/history.ts +178 -11
- package/telegram-plugin/registry/turns-schema.ts +8 -2
- package/telegram-plugin/tests/buzz-mirror.test.ts +12 -1
- package/telegram-plugin/tests/card-history-lane.test.ts +394 -0
- package/telegram-plugin/tests/system-message-observer.test.ts +216 -0
- package/vendor/hindsight-memory/scripts/drain_pending.py +88 -4
- package/vendor/hindsight-memory/scripts/lib/config.py +112 -11
- package/vendor/hindsight-memory/scripts/recall.py +11 -2
- package/vendor/hindsight-memory/scripts/reconcile_tail.py +36 -0
- package/vendor/hindsight-memory/scripts/retain.py +6 -1
- package/vendor/hindsight-memory/scripts/tests/test_config_retain_env.py +99 -0
- package/vendor/hindsight-memory/scripts/tests/test_recall_types_filter.py +81 -0
- package/vendor/hindsight-memory/scripts/tests/test_reconcile_durability.py +113 -0
- package/vendor/hindsight-memory/settings.json +2 -2
- package/vendor/hindsight-memory/tests/test_config.py +8 -3
- package/vendor/hindsight-memory/tests/test_hooks.py +10 -1
- package/vendor/hindsight-memory/tests/test_retain_context.py +69 -0
|
@@ -19466,7 +19466,7 @@ function allocateAgentUid(name) {
|
|
|
19466
19466
|
var HINDSIGHT_RECALL_TAG_WEIGHT_SEED = Object.freeze({ sidechain: 0.8 });
|
|
19467
19467
|
var HINDSIGHT_RECALL_PROMPT_PREAMBLE_DEFAULT = "Relevant memories from past conversations (prioritize recent when " + "conflicting). Only use memories that are directly useful to continue " + "this conversation; ignore the rest:";
|
|
19468
19468
|
var RECALL_PASSTHROUGH_DEFAULTS = Object.freeze({
|
|
19469
|
-
budget: "
|
|
19469
|
+
budget: "mid",
|
|
19470
19470
|
maxTokens: 1024,
|
|
19471
19471
|
preferObservations: true,
|
|
19472
19472
|
contextTurns: 2,
|
|
@@ -19707,7 +19707,7 @@ function allocateAgentUid(name) {
|
|
|
19707
19707
|
var HINDSIGHT_RECALL_TAG_WEIGHT_SEED = Object.freeze({ sidechain: 0.8 });
|
|
19708
19708
|
var HINDSIGHT_RECALL_PROMPT_PREAMBLE_DEFAULT = "Relevant memories from past conversations (prioritize recent when " + "conflicting). Only use memories that are directly useful to continue " + "this conversation; ignore the rest:";
|
|
19709
19709
|
var RECALL_PASSTHROUGH_DEFAULTS = Object.freeze({
|
|
19710
|
-
budget: "
|
|
19710
|
+
budget: "mid",
|
|
19711
19711
|
maxTokens: 1024,
|
|
19712
19712
|
preferObservations: true,
|
|
19713
19713
|
contextTurns: 2,
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "switchroom",
|
|
3
3
|
"//version": "NOT the release version — source of truth is the git tag, resolved by scripts/build.mjs:resolveVersion() (see CLAUDE.md > Standard release process). This field is stale by design and only the Layer-4 dev/non-tag fallback for build.mjs + src/cli/resolve-version.ts; do NOT bump it expecting a release to pick it up. npm-pack tarball naming needs a real version — do that as an UNCOMMITTED pack-time bump (see release step 6), never a committed one.",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.21.0",
|
|
5
5
|
"description": "Run Claude Code 24/7 on your Claude Pro/Max subscription over Telegram. Open-source alternative to OpenClaw and NanoClaw — no API keys.",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"bin": {
|
|
@@ -125,7 +125,18 @@ The tag push triggers `docker-images` and `release`. `release` internally waits
|
|
|
125
125
|
### Rehearsing a workflow change without releasing anything
|
|
126
126
|
`gh workflow run release.yml --ref <branch>` — `dry_run` defaults to `true`, so it builds, checksums and verifies the full bundle and attaches it as a workflow artifact, touching no GitHub Release, no npm, and no image tags. This is the only supported way to prove a change to the release pipeline before a real tag.
|
|
127
127
|
|
|
128
|
-
## Step 4 —
|
|
128
|
+
## Step 4 — HOST OPERATOR CLI FIRST (#4571)
|
|
129
|
+
|
|
130
|
+
**The host CLI is upgraded BEFORE the fleet, not after.** It is what runs `switchroom apply`, `vault`, `doctor` and the *next* roll host-side, so a host CLI left behind means every later host-shell command runs retired code. Treating it as a trailing chore is how it silently drifted to **0.20.16 while the fleet ran 0.20.21** — five releases, with every roll exiting green.
|
|
131
|
+
|
|
132
|
+
This is now **enforced, not advised**: `switchroom rollout` reads `~/.switchroom/host-cli.json` (the stamp every host-context CLI invocation refreshes) and **refuses to start** when the host CLI is observably older than the target — before a single agent restarts. The refusal names the exact install command, derived from how the host CLI was *actually* installed.
|
|
133
|
+
|
|
134
|
+
- Ask the operator to run the upgrade on the host **before** you fire the roll. Do not hand them `sudo npm i -g switchroom@X` from memory: that is wrong on a user-owned nvm prefix (it installs into a different tree, or root-poisons this one). Take the command from `switchroom doctor`'s `cli (host)` fix line or from the rollout refusal text — both derive it from the stamp.
|
|
135
|
+
- Confirm it landed: `switchroom --version` on the host shell reports the target. Any host-context switchroom command also refreshes the stamp, so the gate sees the new version immediately.
|
|
136
|
+
- `--allow-stale-host-cli` is the escape hatch and must be a deliberate, stated decision — it leaves the host CLI drifted and says so loudly in the roll's warnings.
|
|
137
|
+
- A host CLI predating this feature writes no stamp. The gate then does not block (it cannot know), and the roll's terminal card says so instead of claiming convergence. Confirm host-side.
|
|
138
|
+
|
|
139
|
+
## Step 5 — Fleet rollout (operator-gated, canary-first)
|
|
129
140
|
|
|
130
141
|
- Fire the rollout via the hostd rollout path (`mcp__hostd__rollout`), which pops an **approval card**. Do NOT roll without the operator tapping approve.
|
|
131
142
|
- Canary discipline: roll the release-critical canary agent first (the test-harness agent, per CLAUDE.md > Release canary discipline), monitor its logs + a smoke check, then stagger the rest per-agent with a `--version` assertion each (guards the `:latest` pull-race).
|