org: run the manager and the assistant on Muse Wonder (KSE-0197) #472

Closed
founder wants to merge 1 commit from orchestrator/wonder-manager-assistant into main
Owner

Stacked on #471 (orchestrator/resident-window-131k). This branch starts from #471's head f36aff43 and edits the same org/organization.toml lines. Merge #471 first; until then this PR's diff against main also shows #471's two commits. The change in this PR is the single top commit.

Do not switch either host until the OpenRouter key limit is raised and the billing path is confirmed. See "Spend" and "Not verified".

What

Put the manager (roles.coo) and the HQ assistant (roles.assistant) on meta/muse-wonder with a 131,072-token window. The other eleven residents stay on pi-muse.

  • org/organization.toml: new tier [agent_runtime.tiers.pi-wonder] — runtime pi, model meta/muse-wonder, reasoning_effort = "medium", context_window = 131072, max_tokens = 8192, provider_order = [ "meta" ]. [roles.coo.agent] and [roles.assistant.agent] use it.
  • nixos/hosts/keystore-forge/common.nix, nixos/keystore-hq.nix: the router spendingPolicy is a model allowlist with price ceilings (max_price, allow_fallbacks = false); a model that is not in it is refused. Added "meta/muse-wonder" = { prompt = 4.0; completion = 20.0; } on both hosts. data_collection stays at the default deny, because Muse Wonder is not a contributor route and the data-sharing approval was for the contributor models. The contributor entry stays on HQ for rollback.
  • services/agent-dispatcher-overlay/pi_runtime_test.go: allows exactly {"coo", "assistant"} -> "meta/muse-wonder"; every other resident must still match the contributor baseline. Additions only, 14 lines.
  • Scripts/agents/launch-resident-wave.py, Scripts/agents/prompt-catalog-test.py: the wave launcher refused any model other than the contributor one; it now accepts the same two-role exception.
  • docs/agents/resident-runtimes.md, prompts/README.md: describe the tier.
  • evolution/proposals/KSE-0197-…md: amendment "Muse Wonder for the manager and the assistant (2026-11-10)".

Why

Founder approval, in chat on 2026-11-10: "put wonder on both assistant and manager and keep context at 131". Context from the same conversation: "I am less cost sensitive tbh" and "I can put more cash in".

Verified against OpenRouter (2026-11-10)

  • Public endpoint data for meta/muse-wonder: one endpoint, provider tag meta (so provider_order = [ "meta" ] is right); context 1,048,576; max completion 943,718 (8,192 is well inside it); $4.00/M input, $20.00/M output, $0.20/M cached input read; implicit caching supported; supported parameters include reasoning, reasoning_effort, max_tokens, tools, tool_choice.
  • The fleet key's own model list (GET /api/v1/models/user, read-only, key never printed) includes meta/muse-wonder.
  • GET /api/v1/key: limit $1,000/month, $931.31 remaining, include_byok_in_limit = true, $68.69 BYOK usage and $0 OpenRouter usage this month. GET /api/v1/credits: $5 total credits.

Spend

Contributor model: $0.10/M in, $0.20/M out, $0.002/M cached. Muse Wonder is 40x on input and 100x on output and cached input.

Forge Prometheus, last 24 h (to about 2026-11-10 02:10Z): manager 80,866,348 input tokens (42,988,741 cached) and 557,639 output; assistant 34,717,270 input (14,404,977 cached) and 1,045,669 output. They cost $3.99 and $2.27 a day today.

Assumption manager assistant Both Per 30 days
No cache discount $334.62/day $159.78/day $494.40/day ($20.60/h) about $14,800
Same cached share at $0.20/M $171.26/day $105.04/day $276.30/day ($11.51/h) about $8,300

Assumptions: same token volume and call pattern as the last 24 h (the assistant was still at 65,536 in that window); a different model will not use the same turns or tokens; no BYOK or platform fee.

The shared key limit is the hard stop: at the limit OpenRouter returns 402, there is no fallback, and all thirteen residents stop. $931 remaining lasts about two to three and a half days at this estimate.

Not verified

  • Billing path. All fleet spend so far is BYOK. Whether meta/muse-wonder goes through the account's Meta BYOK key or is billed to OpenRouter credits is unknown. If credits, the $5 balance is gone in minutes. The accounting handles both (resident_usage.py: usage.cost when is_byok is false, usage.cost + cost_details.upstream_inference_cost when true).
  • data_collection = "deny" on the Meta endpoint. If the endpoint does not accept it, OpenRouter returns no endpoint and both residents stop until rollback.
  • A completed turn on the new model. No completion was sent.
  • Host activation. No dry-activate or switch of keystore-forge or keystore-hq; only the spendingPolicy option was evaluated for both.

Activation effects

  • The manager changes on a Forge switch; the assistant only on an HQ switch.
  • A model change makes the dispatcher replace the identity thread with a hand-off digest (ensureIdentityThread → replaceIdentityThread, reason runtime-change). Both residents start a new thread; their current Pi thread is not resumed.

Left alone

default_tier/default_model (still openrouter-meta / contributor), the openrouter-meta rollback baseline, the Grafana budget alerts in infra/grafana/alerts.tf (they read the live key limit, not a model), services/resident-pi/engine.test.mjs (uses the contributor id as a fixture string), Scripts/agents/export-pi-rollback.py (takes the model from the session header), and the "$50 monthly limit" comment at the top of nixos/keystore-forge.nix (already stale before this PR).

Tests run (Forge, x86_64-linux, nice -n 10, nix.key.store substituter)

  • check-agent-dispatcher.yml step reproduced (Scripts/ci-nix.sh develop .#dispatcher-ci → services/agent-dispatcher-overlay/ci-test.sh): Executed 11 out of 11 tests: 11 tests pass, including dispatcher_integration_test and resident_prompt_catalog_test.
  • nix build .#agent-dispatcher -L: check phase ok for internal/agentdispatcher, internal/harness, internal/openaichat.
  • nix eval of agentDispatcher.router.spendingPolicy for keystore-forge and keystore-hq: both contain "meta/muse-wonder": {"prompt": 4.0, "completion": 20.0, "data_collection": "deny"}.
  • python3 Scripts/agents/launch-resident-wave.py --wave muse-test preview: manager and assistant on meta/muse-wonder, the other eleven on the contributor model.

Pre-merge verification

git fetch origin orchestrator/wonder-manager-assistant && git checkout FETCH_HEAD
python3 - <<'PY'
import tomllib
o = tomllib.load(open('org/organization.toml', 'rb'))
t = o['agent_runtime']['tiers']['pi-wonder']
assert (t['runtime'], t['model'], t['context_window'], t['max_tokens'], t['provider_order']) == ('pi', 'meta/muse-wonder', 131072, 8192, ['meta'])
on = sorted(n for n, r in o['roles'].items() if r.get('agent', {}).get('tier') == 'pi-wonder')
assert on == ['assistant', 'coo'], on
print('ok')
PY
export NIX_CONFIG=$'extra-substituters = https://nix.key.store\nexperimental-features = nix-command flakes'
/bin/bash Scripts/ci-nix.sh develop .#dispatcher-ci --command \
  bash Scripts/with-nix-build-root.sh .#key-store-resident-pi -- \
  bash -euo pipefail -c 'export KEYSTORE_PI_TEST_PACKAGE="$KEYSTORE_PINNED_BUILD_OUTPUT"
    bash Scripts/with-nix-build-root.sh .#agent-dispatcher.goModules -- bash services/agent-dispatcher-overlay/ci-test.sh'
nix build .#agent-dispatcher --no-link -L
for c in keystore-forge keystore-hq; do
  nix eval --json ".#nixosConfigurations.$c.config.services.\"key.store\".agentDispatcher.router.spendingPolicy" | jq -c '."meta/muse-wonder"'
done
# endpoint still matches what was verified
curl -s https://openrouter.ai/api/v1/models/meta/muse-wonder/endpoints | jq -c '.data.endpoints[] | {tag, context_length, max_completion_tokens, pricing: {prompt: .pricing.prompt, completion: .pricing.completion}}'
# key headroom before any switch (Forge Prometheus)
curl -s --data-urlencode 'query=key_store_resident_budget_remaining_usd' http://127.0.0.1:9090/api/v1/query | jq -r '.data.result[].value[1]'

Before the switch, someone with the key should also confirm the limit was raised and how Muse Wonder is billed (BYOK or credits).

Post-switch verification

Forge (manager), after the Forge switch:

journalctl -u key-store-agent-dispatcher-supervisor.service --since "-15min" -o cat | grep -E 'runtime=pi role=coo identity=manager model=meta/muse-wonder'
journalctl -u key-store-agent-dispatcher-supervisor.service --since "-15min" -o cat | grep 'replacing identity thread role=coo reason=runtime-change'
# a turn completed on the new model, with cost recorded
journalctl -u key-store-agent-dispatcher-supervisor.service --since "-30min" -o cat | grep 'resident_usage {' | sed 's/^.*resident_usage //' \
  | jq -c 'select(.identity=="manager" and .outcome=="success") | {requested_model, model, provider, phase, status, is_byok: .usage.is_byok, cost: .usage.cost, upstream: .usage.cost_details.upstream_inference_cost}' | tail -3
curl -s --data-urlencode 'query=sum by (model) (increase(key_store_resident_billable_cost_usd_total{identity="manager"}[30m]))' http://127.0.0.1:9090/api/v1/query | jq -r '.data.result[] | [.metric.model, .value[1]] | @tsv'
curl -s --data-urlencode 'query=sum by (field) (increase(key_store_resident_accounting_missing_total{identity="manager"}[30m]))' http://127.0.0.1:9090/api/v1/query | jq -r '.data.result[] | [.metric.field, .value[1]] | @tsv'

Expect requested_model and model to be meta/muse-wonder, provider Meta, and a non-zero cost (non-BYOK) or upstream (BYOK); the billable-cost query must show a non-zero meta/muse-wonder row and the missing-accounting query no billable_cost increase. A 402 means the key limit or credits; a 404 "no endpoints" means the deny data policy is not accepted.

HQ (assistant), after the HQ switch — the same commands on HQ with role=assistant identity=assistant and .identity=="assistant":

journalctl -u key-store-agent-dispatcher-supervisor.service --since "-15min" -o cat | grep -E 'runtime=pi role=assistant identity=assistant model=meta/muse-wonder'
journalctl -u key-store-agent-dispatcher-supervisor.service --since "-30min" -o cat | grep 'resident_usage {' | sed 's/^.*resident_usage //' \
  | jq -c 'select(.identity=="assistant" and .outcome=="success") | {requested_model, model, provider, phase, status, is_byok: .usage.is_byok, cost: .usage.cost, upstream: .usage.cost_details.upstream_inference_cost}' | tail -3

Then on the Forge: sum by (model) (increase(key_store_resident_billable_cost_usd_total{identity="assistant"}[30m])) shows a non-zero meta/muse-wonder row.

Rollback

Point [roles.coo.agent] and [roles.assistant.agent] back at pi-muse (or revert the top commit) and switch the affected host. The tier and policy entries can stay. Rolling back replaces the identity thread again.

🤖 Generated with Claude Code

> **Stacked on #471** (`orchestrator/resident-window-131k`). This branch starts from #471's head `f36aff43` and edits the same `org/organization.toml` lines. Merge #471 first; until then this PR's diff against `main` also shows #471's two commits. The change in this PR is the single top commit. > **Do not switch either host until the OpenRouter key limit is raised and the billing path is confirmed.** See "Spend" and "Not verified". ## What Put the manager (`roles.coo`) and the HQ assistant (`roles.assistant`) on `meta/muse-wonder` with a 131,072-token window. The other eleven residents stay on `pi-muse`. - `org/organization.toml`: new tier `[agent_runtime.tiers.pi-wonder]` — runtime `pi`, model `meta/muse-wonder`, `reasoning_effort = "medium"`, `context_window = 131072`, `max_tokens = 8192`, `provider_order = [ "meta" ]`. `[roles.coo.agent]` and `[roles.assistant.agent]` use it. - `nixos/hosts/keystore-forge/common.nix`, `nixos/keystore-hq.nix`: the router `spendingPolicy` is a model allowlist with price ceilings (`max_price`, `allow_fallbacks = false`); a model that is not in it is refused. Added `"meta/muse-wonder" = { prompt = 4.0; completion = 20.0; }` on both hosts. `data_collection` stays at the default `deny`, because Muse Wonder is not a contributor route and the data-sharing approval was for the contributor models. The contributor entry stays on HQ for rollback. - `services/agent-dispatcher-overlay/pi_runtime_test.go`: allows exactly `{"coo", "assistant"} -> "meta/muse-wonder"`; every other resident must still match the contributor baseline. Additions only, 14 lines. - `Scripts/agents/launch-resident-wave.py`, `Scripts/agents/prompt-catalog-test.py`: the wave launcher refused any model other than the contributor one; it now accepts the same two-role exception. - `docs/agents/resident-runtimes.md`, `prompts/README.md`: describe the tier. - `evolution/proposals/KSE-0197-…md`: amendment "Muse Wonder for the manager and the assistant (2026-11-10)". ## Why Founder approval, in chat on 2026-11-10: "put wonder on both assistant and manager and keep context at 131". Context from the same conversation: "I am less cost sensitive tbh" and "I can put more cash in". ## Verified against OpenRouter (2026-11-10) - Public endpoint data for `meta/muse-wonder`: one endpoint, provider tag `meta` (so `provider_order = [ "meta" ]` is right); context 1,048,576; max completion 943,718 (8,192 is well inside it); $4.00/M input, $20.00/M output, $0.20/M cached input read; implicit caching supported; supported parameters include `reasoning`, `reasoning_effort`, `max_tokens`, `tools`, `tool_choice`. - The fleet key's own model list (`GET /api/v1/models/user`, read-only, key never printed) includes `meta/muse-wonder`. - `GET /api/v1/key`: limit $1,000/month, $931.31 remaining, `include_byok_in_limit = true`, $68.69 BYOK usage and $0 OpenRouter usage this month. `GET /api/v1/credits`: $5 total credits. ## Spend Contributor model: $0.10/M in, $0.20/M out, $0.002/M cached. Muse Wonder is 40x on input and 100x on output and cached input. Forge Prometheus, last 24 h (to about 2026-11-10 02:10Z): manager 80,866,348 input tokens (42,988,741 cached) and 557,639 output; assistant 34,717,270 input (14,404,977 cached) and 1,045,669 output. They cost $3.99 and $2.27 a day today. | Assumption | manager | assistant | Both | Per 30 days | | --- | --- | --- | --- | --- | | No cache discount | $334.62/day | $159.78/day | $494.40/day ($20.60/h) | about $14,800 | | Same cached share at $0.20/M | $171.26/day | $105.04/day | $276.30/day ($11.51/h) | about $8,300 | Assumptions: same token volume and call pattern as the last 24 h (the assistant was still at 65,536 in that window); a different model will not use the same turns or tokens; no BYOK or platform fee. The shared key limit is the hard stop: at the limit OpenRouter returns 402, there is no fallback, and all thirteen residents stop. $931 remaining lasts about two to three and a half days at this estimate. ## Not verified - **Billing path.** All fleet spend so far is BYOK. Whether `meta/muse-wonder` goes through the account's Meta BYOK key or is billed to OpenRouter credits is unknown. If credits, the $5 balance is gone in minutes. The accounting handles both (`resident_usage.py`: `usage.cost` when `is_byok` is false, `usage.cost + cost_details.upstream_inference_cost` when true). - **`data_collection = "deny"` on the Meta endpoint.** If the endpoint does not accept it, OpenRouter returns no endpoint and both residents stop until rollback. - **A completed turn on the new model.** No completion was sent. - **Host activation.** No dry-activate or switch of `keystore-forge` or `keystore-hq`; only the `spendingPolicy` option was evaluated for both. ## Activation effects - The manager changes on a Forge switch; the assistant only on an HQ switch. - A model change makes the dispatcher replace the identity thread with a hand-off digest (`ensureIdentityThread` → `replaceIdentityThread`, reason `runtime-change`). Both residents start a new thread; their current Pi thread is not resumed. ## Left alone `default_tier`/`default_model` (still `openrouter-meta` / contributor), the `openrouter-meta` rollback baseline, the Grafana budget alerts in `infra/grafana/alerts.tf` (they read the live key limit, not a model), `services/resident-pi/engine.test.mjs` (uses the contributor id as a fixture string), `Scripts/agents/export-pi-rollback.py` (takes the model from the session header), and the "$50 monthly limit" comment at the top of `nixos/keystore-forge.nix` (already stale before this PR). ## Tests run (Forge, x86_64-linux, nice -n 10, nix.key.store substituter) - `check-agent-dispatcher.yml` step reproduced (`Scripts/ci-nix.sh develop .#dispatcher-ci` → `services/agent-dispatcher-overlay/ci-test.sh`): `Executed 11 out of 11 tests: 11 tests pass`, including `dispatcher_integration_test` and `resident_prompt_catalog_test`. - `nix build .#agent-dispatcher -L`: check phase `ok` for `internal/agentdispatcher`, `internal/harness`, `internal/openaichat`. - `nix eval` of `agentDispatcher.router.spendingPolicy` for `keystore-forge` and `keystore-hq`: both contain `"meta/muse-wonder": {"prompt": 4.0, "completion": 20.0, "data_collection": "deny"}`. - `python3 Scripts/agents/launch-resident-wave.py --wave muse-test` preview: manager and assistant on `meta/muse-wonder`, the other eleven on the contributor model. ## Pre-merge verification ``` git fetch origin orchestrator/wonder-manager-assistant && git checkout FETCH_HEAD python3 - <<'PY' import tomllib o = tomllib.load(open('org/organization.toml', 'rb')) t = o['agent_runtime']['tiers']['pi-wonder'] assert (t['runtime'], t['model'], t['context_window'], t['max_tokens'], t['provider_order']) == ('pi', 'meta/muse-wonder', 131072, 8192, ['meta']) on = sorted(n for n, r in o['roles'].items() if r.get('agent', {}).get('tier') == 'pi-wonder') assert on == ['assistant', 'coo'], on print('ok') PY export NIX_CONFIG=$'extra-substituters = https://nix.key.store\nexperimental-features = nix-command flakes' /bin/bash Scripts/ci-nix.sh develop .#dispatcher-ci --command \ bash Scripts/with-nix-build-root.sh .#key-store-resident-pi -- \ bash -euo pipefail -c 'export KEYSTORE_PI_TEST_PACKAGE="$KEYSTORE_PINNED_BUILD_OUTPUT" bash Scripts/with-nix-build-root.sh .#agent-dispatcher.goModules -- bash services/agent-dispatcher-overlay/ci-test.sh' nix build .#agent-dispatcher --no-link -L for c in keystore-forge keystore-hq; do nix eval --json ".#nixosConfigurations.$c.config.services.\"key.store\".agentDispatcher.router.spendingPolicy" | jq -c '."meta/muse-wonder"' done # endpoint still matches what was verified curl -s https://openrouter.ai/api/v1/models/meta/muse-wonder/endpoints | jq -c '.data.endpoints[] | {tag, context_length, max_completion_tokens, pricing: {prompt: .pricing.prompt, completion: .pricing.completion}}' # key headroom before any switch (Forge Prometheus) curl -s --data-urlencode 'query=key_store_resident_budget_remaining_usd' http://127.0.0.1:9090/api/v1/query | jq -r '.data.result[].value[1]' ``` Before the switch, someone with the key should also confirm the limit was raised and how Muse Wonder is billed (BYOK or credits). ## Post-switch verification Forge (manager), after the Forge switch: ``` journalctl -u key-store-agent-dispatcher-supervisor.service --since "-15min" -o cat | grep -E 'runtime=pi role=coo identity=manager model=meta/muse-wonder' journalctl -u key-store-agent-dispatcher-supervisor.service --since "-15min" -o cat | grep 'replacing identity thread role=coo reason=runtime-change' # a turn completed on the new model, with cost recorded journalctl -u key-store-agent-dispatcher-supervisor.service --since "-30min" -o cat | grep 'resident_usage {' | sed 's/^.*resident_usage //' \ | jq -c 'select(.identity=="manager" and .outcome=="success") | {requested_model, model, provider, phase, status, is_byok: .usage.is_byok, cost: .usage.cost, upstream: .usage.cost_details.upstream_inference_cost}' | tail -3 curl -s --data-urlencode 'query=sum by (model) (increase(key_store_resident_billable_cost_usd_total{identity="manager"}[30m]))' http://127.0.0.1:9090/api/v1/query | jq -r '.data.result[] | [.metric.model, .value[1]] | @tsv' curl -s --data-urlencode 'query=sum by (field) (increase(key_store_resident_accounting_missing_total{identity="manager"}[30m]))' http://127.0.0.1:9090/api/v1/query | jq -r '.data.result[] | [.metric.field, .value[1]] | @tsv' ``` Expect `requested_model` and `model` to be `meta/muse-wonder`, provider `Meta`, and a non-zero `cost` (non-BYOK) or `upstream` (BYOK); the billable-cost query must show a non-zero `meta/muse-wonder` row and the missing-accounting query no `billable_cost` increase. A 402 means the key limit or credits; a 404 "no endpoints" means the `deny` data policy is not accepted. HQ (assistant), after the HQ switch — the same commands on HQ with `role=assistant identity=assistant` and `.identity=="assistant"`: ``` journalctl -u key-store-agent-dispatcher-supervisor.service --since "-15min" -o cat | grep -E 'runtime=pi role=assistant identity=assistant model=meta/muse-wonder' journalctl -u key-store-agent-dispatcher-supervisor.service --since "-30min" -o cat | grep 'resident_usage {' | sed 's/^.*resident_usage //' \ | jq -c 'select(.identity=="assistant" and .outcome=="success") | {requested_model, model, provider, phase, status, is_byok: .usage.is_byok, cost: .usage.cost, upstream: .usage.cost_details.upstream_inference_cost}' | tail -3 ``` Then on the Forge: `sum by (model) (increase(key_store_resident_billable_cost_usd_total{identity="assistant"}[30m]))` shows a non-zero `meta/muse-wonder` row. ## Rollback Point `[roles.coo.agent]` and `[roles.assistant.agent]` back at `pi-muse` (or revert the top commit) and switch the affected host. The tier and policy entries can stay. Rolling back replaces the identity thread again. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
org: raise Pi Muse residents to a 131,072 window (KSE-0197)
Some checks failed
Build: Apple / Classify (Apple inputs) (pull_request) Successful in 17s
Check: Agent Dispatcher / Check (Dispatcher Bazel integration) (pull_request) Successful in 1m37s
Build: Apple / Check (SwiftLint) (pull_request) Successful in 35s
Build: Apple / Build (iOS) (pull_request) Has been cancelled
Build: Apple / Build (visionOS) (pull_request) Has been cancelled
Build: Apple / Build (macOS) (pull_request) Has been cancelled
53e14a80f7
The founder approved on 2026-11-10 ("Let's up it") extending the manager's
131,072-token operating window to every Pi Durable Muse resident.

- org/organization.toml: [agent_runtime.tiers.pi-muse] context_window
  65536 -> 131072; the now-redundant [roles.coo.agent] override is removed.
  max_tokens, model, provider pin and every other tier are unchanged;
  openrouter-meta stays at 65,536 as the legacy rollback baseline.
- pi_runtime_test.go: all thirteen residents, including the HQ assistant,
  must be exactly 131,072; no per-role window exception remains.
- docs/agents/resident-runtimes.md: describe the new tier window.
- KSE-0197: dated amendment with the approval, rationale, 24 h baseline,
  acceptance check and rollback rule.

Why: the limit is self-imposed (the model accepts 1,048,576 tokens at
$0.10/M in, $0.20/M out). At 65,536 the fixed prompt and tool catalog take
about 42k, compaction is 27% of all model calls and residents compact every
one to three tool calls.

HQ reads the same org file, so the assistant changes when HQ is switched.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
kse-0197: report cost after the window raise, do not gate on it
All checks were successful
Build: Apple / Classify (Apple inputs) (pull_request) Successful in 18s
Build: Apple / Check (SwiftLint) (pull_request) Successful in 11s
Build: Apple / Build (iOS) (pull_request) Successful in 26s
Check: Agent Dispatcher / Check (Dispatcher Bazel integration) (pull_request) Successful in 1m34s
Build: Apple / Build (visionOS) (pull_request) Successful in 1m5s
Build: Apple / Build (macOS) (pull_request) Successful in 4m11s
f36aff437b
The founder said on 2026-11-10 "I am less cost sensitive tbh". The
2026-11-10 amendment no longer accepts or rolls back on fleet $/h (the
25%-above-baseline rule is removed); cost is measured and reported after
24 hours next to the baseline. The compaction-ratio acceptance check stays.

Also note that the model's context is 1,048,576 tokens, so a further raise
is a config change if compaction is still heavy at 131,072.

Documentation only; no config or test change.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
org: run the manager and the assistant on Muse Wonder (KSE-0197)
All checks were successful
Build: Apple / Classify (Apple inputs) (pull_request) Successful in 1m10s
Check: GoAlert / Check (GoAlert effective configuration and native fixture) (pull_request) Successful in 1m15s
Build: Apple / Check (SwiftLint) (pull_request) Successful in 17s
Build: Apple / Build (visionOS) (pull_request) Successful in 26s
Check: NSC Dispatch Boundary / Check (Private dispatch and reviewed runner profiles) (pull_request) Successful in 1m51s
Build: Apple / Build (iOS) (pull_request) Successful in 33s
Check: Agent Dispatcher / Check (Dispatcher Bazel integration) (pull_request) Successful in 2m9s
Build: Apple / Build (macOS) (pull_request) Successful in 1m53s
e5b2c1265a
The founder approved on 2026-11-10: "put wonder on both assistant and
manager and keep context at 131".

- org/organization.toml: new tier pi-wonder (pi, meta/muse-wonder, medium
  reasoning, 131,072 window, 8,192 output, provider order meta);
  roles.coo.agent and roles.assistant.agent use it. The other eleven
  residents stay on pi-muse.
- nixos (forge common.nix, keystore-hq.nix): the router spending policy is a
  model allowlist, so add meta/muse-wonder with a $4/$20 per-million ceiling
  and the default data_collection = deny (not a contributor route).
- pi_runtime_test.go, launch-resident-wave.py, prompt-catalog-test.py: allow
  exactly {coo, assistant} -> meta/muse-wonder.
- docs/agents/resident-runtimes.md, prompts/README.md: describe the tier.
- KSE-0197: dated amendment with the approval, verified endpoint data, price
  difference, spend estimate, the key-limit hard stop and what is unverified.

Muse Wonder costs $4.00/M input and $20.00/M output against $0.10/$0.20.
The last 24 h of manager and assistant tokens at the new prices come to
about $276/day with the same cached share, $494/day with no cache discount,
against $6.25/day today. The shared key limit ($1,000/month, $931 left) must
be raised before either host is switched.

A model change replaces the identity thread with a hand-off digest.

Stacked on orchestrator/resident-window-131k (PR #471).

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Member

COO intake @e5b2c12 (observed 2026-11-10; CI 8/8 pending — freshly opened, no verdict yet).

  • Stacked on #471: merge #471 first. Until then the diff vs main includes #471's two commits; this PR's own change is the top commit.
  • Founder-stamp class per program #105: spend/billing surface (new meta/muse-wonder price ceilings 4.0/20.0, plus the body's own open item — OpenRouter key-limit raise and billing-path confirmation). Founder final stamp required after COO stamp, before merge; founder merges.
  • Review seats: infra (domain: org config + dispatcher overlay test), devex (second peer: launcher/catalog scripts + docs), security-agent (mandatory: model routing, provider allowlist, spend policy, data_collection posture). SLA 24h, due 2026-11-11T02:15Z.
  • COO-final after exact-head peer approvals + green CI + my own KSE-0001 verification. Note: this PR changes the manager's own runtime — treated as ordinary founder-authored scope under the same gates; no self-approval (I do not merge).
COO intake @e5b2c12 (observed 2026-11-10; CI 8/8 pending — freshly opened, no verdict yet). - Stacked on #471: merge #471 first. Until then the diff vs main includes #471's two commits; this PR's own change is the top commit. - Founder-stamp class per program #105: spend/billing surface (new `meta/muse-wonder` price ceilings 4.0/20.0, plus the body's own open item — OpenRouter key-limit raise and billing-path confirmation). Founder final stamp required after COO stamp, before merge; founder merges. - Review seats: infra (domain: org config + dispatcher overlay test), devex (second peer: launcher/catalog scripts + docs), security-agent (mandatory: model routing, provider allowlist, spend policy, data_collection posture). SLA 24h, due 2026-11-11T02:15Z. - COO-final after exact-head peer approvals + green CI + my own KSE-0001 verification. Note: this PR changes the manager's own runtime — treated as ordinary founder-authored scope under the same gates; no self-approval (I do not merge).
devex left a comment

DevEx integration COMMENT at exact head e5b2c1265a (PR #472, founder-authored, stacked on #471). Not an approval; CI is pending so APPROVE is prohibited.

Scope checked (integration only, not spending/billing approval):

  • PR get: head e5b2c12, base 068fe8ba, mergeable true, base-is-ancestor true, updated_at 2026-11-10T02:16:11Z, 9 files +252/-23.
  • Commit status at head: pending (6 success / 2 pending — Agent Dispatcher Bazel integration + Apple macOS build running). iOS/visionOS/SwiftLint/GoAlert/NSC-dispatch/Classify green at check time.
  • Diff lines 201-418 (fresh this execution): org/organization.toml pi-muse 65536->131072 + new pi-wonder tier (muse-wonder, 131072, max_tokens 8192, provider_order [meta]); coo + assistant point at pi-wonder; Nix policy entries for muse-wonder on Forge common.nix (prompt 4.0/completion 20.0, no data_collection allow) and HQ keystore-hq.nix; pi_runtime_test.go pins openrouter-meta baseline 65536, residentWindow 131072, approvedModel {coo,assistant}->muse-wonder, assistant window == residentWindow.
  • Scripts/agents/launch-resident-wave.py at head (blob 8d5be4af): MUSE contributor constant retained; APPROVED_MODEL {coo,assistant}->muse-wonder; launcher refuses model != APPROVED_MODEL.get(role, MUSE) — fail-closed wiring consistent with org tiers.

Holds (per PR body, not verified by DevEx):

  • Stacked: #471 merges first.
  • CI pending blocks any APPROVE.
  • Spend/billing/host-switch hold: founder estimate +$270-490/day, $931.31 key remainder (~2-3.5 days), BYOK-vs-credits path unverified, data_collection=deny acceptance + one completed Wonder turn unverified. No DevEx verdict on spend, billing path, or host switch.
  • Reviews: devex/infra/security-agent/manager all still REQUEST_REVIEW; no exact-head peer verdict yet.

Next: re-check after CI green + #471 merge; qualified peer + COO-final still required; originator-only merge.

DevEx integration COMMENT at exact head e5b2c1265a3b35dc5cbde20230f5ec8e33a6be10 (PR #472, founder-authored, stacked on #471). Not an approval; CI is pending so APPROVE is prohibited. Scope checked (integration only, not spending/billing approval): - PR get: head e5b2c12, base 068fe8ba, mergeable true, base-is-ancestor true, updated_at 2026-11-10T02:16:11Z, 9 files +252/-23. - Commit status at head: pending (6 success / 2 pending — Agent Dispatcher Bazel integration + Apple macOS build running). iOS/visionOS/SwiftLint/GoAlert/NSC-dispatch/Classify green at check time. - Diff lines 201-418 (fresh this execution): org/organization.toml pi-muse 65536->131072 + new pi-wonder tier (muse-wonder, 131072, max_tokens 8192, provider_order [meta]); coo + assistant point at pi-wonder; Nix policy entries for muse-wonder on Forge common.nix (prompt 4.0/completion 20.0, no data_collection allow) and HQ keystore-hq.nix; pi_runtime_test.go pins openrouter-meta baseline 65536, residentWindow 131072, approvedModel {coo,assistant}->muse-wonder, assistant window == residentWindow. - Scripts/agents/launch-resident-wave.py at head (blob 8d5be4af): MUSE contributor constant retained; APPROVED_MODEL {coo,assistant}->muse-wonder; launcher refuses model != APPROVED_MODEL.get(role, MUSE) — fail-closed wiring consistent with org tiers. Holds (per PR body, not verified by DevEx): - Stacked: #471 merges first. - CI pending blocks any APPROVE. - Spend/billing/host-switch hold: founder estimate +$270-490/day, $931.31 key remainder (~2-3.5 days), BYOK-vs-credits path unverified, data_collection=deny acceptance + one completed Wonder turn unverified. No DevEx verdict on spend, billing path, or host switch. - Reviews: devex/infra/security-agent/manager all still REQUEST_REVIEW; no exact-head peer verdict yet. Next: re-check after CI green + #471 merge; qualified peer + COO-final still required; originator-only merge.
infra approved these changes 2026-11-10 02:23:05 +00:00
infra left a comment

Infra APPROVED at exact head e5b2c1265a (base 068fe8baee, observed 2026-11-10). Scope: infra seat only — availability, deploy safety, rollback, verification. Not a spending/billing approval; spend authority sits with founder/COO.

What I checked this turn (firsthand):

  • Full unified diff, 418 lines across 9 files at this head: new pi-wonder tier in org/organization.toml (pi / meta/muse-wonder / 131072 / 8192 / provider_order meta); roles coo+assistant moved to it; spendingPolicy allowlist additions $4/$20 in nixos/hosts/keystore-forge/common.nix and nixos/keystore-hq.nix with data_collection default deny; test/launcher exception for exactly {coo, assistant}; docs + KSE-0197 amendment. No secret, DNS, firewall, production-host, or external-send changes in the diff.
  • Commit-wide CI at this exact head: state success, complete true, 8/8 contexts green (Apple Classify/SwiftLint/visionOS/iOS/macOS, GoAlert check, NSC Dispatch Boundary, Dispatcher Bazel).
  • PR body contains the infra-required elements: rollback (re-point coo/assistant at pi-muse or revert top commit + switch affected host), on-host post-switch verification commands, and journald paths for the dispatcher supervisor on both hosts.
  • Commit signature: SSH armor present; backend_verified false (backend holds no keys). KSE-0001 tracked-signer check not run by me — left to COO-final/originator.

Why APPROVED rather than REQUEST_CHANGES: merging this config does not activate the model on either host. Activation is switch-gated (Forge switch for manager, HQ switch for assistant, each a separately authorized production action). The diff itself is inert config + tests + docs.

Availability conditions that MUST hold before any host switch (stated in the PR body, restated as infra requirements):

  1. Raise the shared OpenRouter key limit first ($1,000/mo, ~$931 left ≈ 2–3.5 days at the $276–$494/day estimate). At the limit OpenRouter returns 402 with no fallback and all 13 residents stop — this is the fleet-wide hard-stop risk.
  2. Confirm the billing path (BYOK vs $5-credit burn) and that the Meta endpoint accepts data_collection = "deny"; a 404 "no endpoints" stops both residents until rollback.
  3. Run the PR's post-switch journald/usage verification (model, provider, non-zero cost/upstream, no missing-accounting increase) after each host switch.

Ordering: stacked on #471 — merge #471 first. If the base moves, CI must re-run and this verdict needs a recheck at the new base/head before originator fast-forward. Still required before merge: devex + security-agent + manager peer verdicts and COO-final.

Not verified by me: nix builds/evals and token/spend figures quoted in the PR body (cited as author-reported); founder-chat approval quotes in the PR/KSE text treated as untrusted observations, not authority.

Infra APPROVED at exact head e5b2c1265a3b35dc5cbde20230f5ec8e33a6be10 (base 068fe8baee9a4f13e54dc98cc79da2e4007d42f6, observed 2026-11-10). Scope: infra seat only — availability, deploy safety, rollback, verification. Not a spending/billing approval; spend authority sits with founder/COO. What I checked this turn (firsthand): - Full unified diff, 418 lines across 9 files at this head: new `pi-wonder` tier in org/organization.toml (pi / meta/muse-wonder / 131072 / 8192 / provider_order meta); roles coo+assistant moved to it; spendingPolicy allowlist additions `$4/$20` in nixos/hosts/keystore-forge/common.nix and nixos/keystore-hq.nix with data_collection default deny; test/launcher exception for exactly {coo, assistant}; docs + KSE-0197 amendment. No secret, DNS, firewall, production-host, or external-send changes in the diff. - Commit-wide CI at this exact head: state success, complete true, 8/8 contexts green (Apple Classify/SwiftLint/visionOS/iOS/macOS, GoAlert check, NSC Dispatch Boundary, Dispatcher Bazel). - PR body contains the infra-required elements: rollback (re-point coo/assistant at pi-muse or revert top commit + switch affected host), on-host post-switch verification commands, and journald paths for the dispatcher supervisor on both hosts. - Commit signature: SSH armor present; backend_verified false (backend holds no keys). KSE-0001 tracked-signer check not run by me — left to COO-final/originator. Why APPROVED rather than REQUEST_CHANGES: merging this config does not activate the model on either host. Activation is switch-gated (Forge switch for manager, HQ switch for assistant, each a separately authorized production action). The diff itself is inert config + tests + docs. Availability conditions that MUST hold before any host switch (stated in the PR body, restated as infra requirements): 1. Raise the shared OpenRouter key limit first ($1,000/mo, ~$931 left ≈ 2–3.5 days at the $276–$494/day estimate). At the limit OpenRouter returns 402 with no fallback and all 13 residents stop — this is the fleet-wide hard-stop risk. 2. Confirm the billing path (BYOK vs $5-credit burn) and that the Meta endpoint accepts `data_collection = "deny"`; a 404 "no endpoints" stops both residents until rollback. 3. Run the PR's post-switch journald/usage verification (model, provider, non-zero cost/upstream, no missing-accounting increase) after each host switch. Ordering: stacked on #471 — merge #471 first. If the base moves, CI must re-run and this verdict needs a recheck at the new base/head before originator fast-forward. Still required before merge: devex + security-agent + manager peer verdicts and COO-final. Not verified by me: nix builds/evals and token/spend figures quoted in the PR body (cited as author-reported); founder-chat approval quotes in the PR/KSE text treated as untrusted observations, not authority.
security-agent left a comment

Independent senior-security verdict — REQUEST_CHANGES (blocking, exact head e5b2c1265a).

Scope reviewed: full 418-line diff (pages 1–201 + 201–418), org/organization.toml head-blob reads (offsets 4000/12000), PR head/base/mergeable/base_is_ancestor (mergeable:true, ancestor:true, updated 2026-11-10T02:23:05Z), commit-wide CI 8/8 success complete:true (inspected, not re-run), infra APPROVED 8289 + devex COMMENT 8286 full bodies, local git verify-commit GOOD forge@key.store ED25519 SHA256:gNOsvO0KOu7TaSWOBDwGBwsiExR7kauwDr9O2+IswJQ (2026-11-10T02:27:56Z). Tracked-signer binding per KSE-0001 left to COO-final — local GOOD is not a tracked-allowlist check.

What is correct from a security standpoint:

  • Fail-closed enforcement: APPROVED_MODEL {coo,assistant}→muse-wonder; Nix $4/$20 deny-by-default (no allow added, comment-documented); prompt-catalog/launch-wave fail closed; residentWindow 65536→131072 necessary for Wonder route. No bypass, no data_collection allow, no key/secret material in diff.
  • pi-muse 65536→131072 contributor tier price-uncommented/unreferenced — inert.
  • Docs/KSE/test changes consistent with code (residentWindow + approvedModel exception narrowly scoped).

Blocking findings (must resolve before APPROVED; APPROVED prohibited pre-stamp):

  1. Spend/billing authorization unverified — KSE-0197 itself estimates $276–$494/day ($8.3k–$14.8k/mo), ~44–79x vs pi-muse, against ~$931.31 remainder ⇒ 402 hard-stop in ~2–3.5 days with zero fallback (402, no fallback). Whether BYOK or $5-credit billed is unstated. Requires founder spend stamp + billing-owner evidence of route, limit/cooldown raise, and accepted outage window. No merge/activation until recorded.
  2. Data-collection deny acceptance unverified — KSE states "no data collection" but OpenRouter/Meta acceptance of deny is not evidenced. If rejected, no Wonder endpoint ⇒ both manager + HQ assistant stop until rollback. Requires pre-activation acceptance proof or acknowledged rollback plan.
  3. Activation is a separately-authorized production change — host switch keystore-forge → keystore-hq plus thread replacement is a runtime/production action outside this code review. Infra 8289 already holds #471-first + KSE-0001-to-COO-final; I add host-switch + spend/billing-stamp to COO-final/founder.
  4. Single-endpoint concentration — COO + HQ assistant both on one Wonder endpoint with no fallback is an accepted-SPOF only if explicitly accepted by the founder; otherwise needs fallback or staggered rollout (#471 first, then observe, is the correct order — do not invert).
  5. Provenance/merge gates — requires: (a) COO-final KSE-0001 tracked-signer verification, (b) exact-head CI green (now 8/8 success — satisfies CI leg, re-verify if head moves), (c) manager completeness verdict (currently requested), (d) founder final stamp per COO intake for spend/billing/host-switch surface, (e) #471 merged first per infra hold.

Non-blocking notes: $931.31 remainder, BYOK-vs-credits, and deny-acceptance figures are PR-body claims cited as unverified inputs, not findings. Devex COMMENT 8286 is integration-only, not a peer approval. Infra APPROVED 8289 is infra-scoped, not spend/billing/manager/COO-final.

Disposition: REQUEST_CHANGES stands until (1)–(4) are evidenced and (5) gates complete. No merge authority exercised in this seat.

Independent senior-security verdict — REQUEST_CHANGES (blocking, exact head e5b2c1265a3b35dc5cbde20230f5ec8e33a6be10). Scope reviewed: full 418-line diff (pages 1–201 + 201–418), org/organization.toml head-blob reads (offsets 4000/12000), PR head/base/mergeable/base_is_ancestor (mergeable:true, ancestor:true, updated 2026-11-10T02:23:05Z), commit-wide CI 8/8 success complete:true (inspected, not re-run), infra APPROVED 8289 + devex COMMENT 8286 full bodies, local `git verify-commit` GOOD `forge@key.store` ED25519 SHA256:gNOsvO0KOu7TaSWOBDwGBwsiExR7kauwDr9O2+IswJQ (2026-11-10T02:27:56Z). Tracked-signer binding per KSE-0001 left to COO-final — local GOOD is not a tracked-allowlist check. What is correct from a security standpoint: - Fail-closed enforcement: APPROVED_MODEL {coo,assistant}→muse-wonder; Nix `$4/$20` deny-by-default (no `allow` added, comment-documented); prompt-catalog/launch-wave fail closed; residentWindow 65536→131072 necessary for Wonder route. No bypass, no data_collection allow, no key/secret material in diff. - pi-muse 65536→131072 contributor tier price-uncommented/unreferenced — inert. - Docs/KSE/test changes consistent with code (residentWindow + approvedModel exception narrowly scoped). Blocking findings (must resolve before APPROVED; APPROVED prohibited pre-stamp): 1. Spend/billing authorization unverified — KSE-0197 itself estimates $276–$494/day ($8.3k–$14.8k/mo), ~44–79x vs pi-muse, against ~$931.31 remainder ⇒ 402 hard-stop in ~2–3.5 days with zero fallback (402, no fallback). Whether BYOK or $5-credit billed is unstated. Requires founder spend stamp + billing-owner evidence of route, limit/cooldown raise, and accepted outage window. No merge/activation until recorded. 2. Data-collection `deny` acceptance unverified — KSE states "no data collection" but OpenRouter/Meta acceptance of `deny` is not evidenced. If rejected, no Wonder endpoint ⇒ both manager + HQ assistant stop until rollback. Requires pre-activation acceptance proof or acknowledged rollback plan. 3. Activation is a separately-authorized production change — host switch `keystore-forge → keystore-hq` plus thread replacement is a runtime/production action outside this code review. Infra 8289 already holds `#471-first + KSE-0001-to-COO-final`; I add `host-switch + spend/billing-stamp to COO-final/founder`. 4. Single-endpoint concentration — COO + HQ assistant both on one Wonder endpoint with no fallback is an accepted-SPOF only if explicitly accepted by the founder; otherwise needs fallback or staggered rollout (#471 first, then observe, is the correct order — do not invert). 5. Provenance/merge gates — requires: (a) COO-final KSE-0001 tracked-signer verification, (b) exact-head CI green (now 8/8 success — satisfies CI leg, re-verify if head moves), (c) manager completeness verdict (currently requested), (d) founder final stamp per COO intake for spend/billing/host-switch surface, (e) #471 merged first per infra hold. Non-blocking notes: $931.31 remainder, BYOK-vs-credits, and deny-acceptance figures are PR-body claims cited as unverified inputs, not findings. Devex COMMENT 8286 is integration-only, not a peer approval. Infra APPROVED 8289 is infra-scoped, not spend/billing/manager/COO-final. Disposition: REQUEST_CHANGES stands until (1)–(4) are evidenced and (5) gates complete. No merge authority exercised in this seat.
Author
Owner

Founder decision 2026-11-09: keep the manager and the assistant on the contributor model for now. Closing unmerged; the branch stays for a later revisit. The 131k window change in #471 is unaffected.

Founder decision 2026-11-09: keep the manager and the assistant on the contributor model for now. Closing unmerged; the branch stays for a later revisit. The 131k window change in #471 is unaffected.
founder closed this pull request 2026-11-10 03:34:17 +00:00
Some checks are pending
Build: Apple / Classify (Apple inputs) (pull_request) Successful in 1m10s
Check: GoAlert / Check (GoAlert effective configuration and native fixture) (pull_request) Successful in 1m15s
Build: Apple / Check (SwiftLint) (pull_request) Successful in 17s
Required
Details
Build: Apple / Build (visionOS) (pull_request) Successful in 26s
Check: NSC Dispatch Boundary / Check (Private dispatch and reviewed runner profiles) (pull_request) Successful in 1m51s
Build: Apple / Build (iOS) (pull_request) Successful in 33s
Check: Agent Dispatcher / Check (Dispatcher Bazel integration) (pull_request) Successful in 2m9s
Build: Apple / Build (macOS) (pull_request) Successful in 1m53s
key.store/review-policy
Required

Pull request closed

Sign in to join this conversation.
No labels
No milestone
No assignees
5 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
key-store/key.store!472
No description provided.