Skip to content

sminos: MW2 ops — the side question, compact's instructions, /mcp as measured (1.12.0) - #397

Merged
SSFSKIM merged 3 commits into
mainfrom
desk-ctl-mw2
Oct 26, 2026
Merged

SSFSKIM merged 3 commits into
mainfrom
desk-ctl-mw2

Conversation

@SSFSKIM

@SSFSKIM SSFSKIM commented Oct 26, 2026 •

Copy link
Copy Markdown
Owner

The machine half of MW2 ("ops") of the desk control surface spec (MAWS docs/doperpowers/specs/2026-10-22-desk-control-surface-design.md, Plan of Work, MW2). sminos 1.11.0 → 1.12.0. The hub half is SSFSKIM/MAWS#157.

What it builds

  • The side question, btw. A new bridge op in sminos/hooks/mods/bridge-btw.tsx puts the spec's frame in front of the question (Answer the following without using any tools and without continuing your current task; one reply, then stop.), calls $.model.fork, and answers {started: true, id} straight away. If the engine says within 250 ms that there is nothing to fork, the op is refused instead (code: "nothing-to-fork"). Then it posts btw start and end events. An end carries either text and usage {input, output, cacheRead, cacheWrite} or a reason. The text is capped at 65,536 bytes of UTF-8, cut between code points and marked truncated: true. An api-error end adds status and error, and a fork that rejects ends reason: "failed", so every side question that started also ends.
  • The child (sminos_bridge.py) keeps the RPC nonce for a btw op, as it does for a run. It stamps the nonce on the start and end events and keeps the end (text cut to 4,096 characters).
  • The daemon. sminos_requests.py adds btw to WANTED. sminos_rpc.py adds the btw RPC: the prompt must be text, not blank, at most 8,192 characters. The op path is now general: the op's kind is stored on its claim, so restart, reconcile and recovery all report a btw event as op: "btw".
  • compact takes instructions of at most 4,096 characters and passes them to the bridge.
  • /mcp's grammar, measured on 2.1.310. A new fixture, sminos/tests/routes-2.1.310.json, is carried from 2.1.307 with only mcp re-measured. routes_check.py now takes every fixture, checks the carry and the mcp row, and writes bridge-routes.tsx with one table per engine. The 2.1.307 fixture is byte-unchanged, so MAWS's vendored copy stays identical. The 2.1.310 mcp row:
    • One server by its configured name: ^(?:enable|disable|reconnect) (?!all$)[^\s\x00-\x1f\x7f][^\x00-\x1f\x7f]*$. Spaces inside the name are allowed; all is excluded.
    • Every server (a bare enable or disable, … all, reconnect all) goes through otherwise, with confirm and an outlives that names the plugins' own tool servers.
    • Refused: a bare reconnect (it opens a panel), a doubled space, a control character, and any other verb.

Validation Evidence

The live check: engine 2.1.310, fully isolated.

  • Isolation: fresh HOME, CLAUDE_CONFIG_DIR and SMINOS_HOME under /private/tmp/mw2-live/<case>, launched under env -i.
  • No real inference: ANTHROPIC_BASE_URL points at a recording stub on 127.0.0.1 with a dummy key, so zero inference was spent.
  • What ran: the working-copy sminos, loaded with --plugin-dir, with the bridge child's /command driven directly.
  • Where it lives: script /tmp/dsk-scripts/mw-wave/mw2-live/live.py, evidence /tmp/dsk-scripts/mw-wave/mw2-live/evidence/{b1,g1,r1}.

python3 -I live.py btw b1:

  • Before the first model request: {"ok": false, "code": "nothing-to-fork"} in 3 ms.
  • Idle: started in 15 ms. The start and end carry rpc: "nonce-btw-1". The end has text: "BTW stub answer" and usage {input 100, output 10, cacheRead 50, cacheWrite 7}.
  • The request's last user text was exactly the frame, a blank line, then the question.
  • Long reply (the stub sent 30,000 × 가, 90,000 bytes): the end has truncated: true, with 21,845 characters = 65,535 bytes, a prefix of the reply.
  • Mid-turn (a main request held for 8 s): started in 11 ms, the answer came 0.01 s after the ask, and the turn ended 8.6 s after it.
  • compact with instructions: the marker reached the summarizer's request.

python3 -I live.py grammar g1 ran on a measurement copy whose mcp form admitted any text, so the engine's own answer is what got recorded:

form engine disabledMcpServers after
disable probe_server (the tool spelling) MCP server "probe_server" not found unchanged
disable probe server / enable probe server disabled / enabled + / − probe server
reconnect probe server Successfully reconnected to probe server —
disable (bare) Disabled 3 MCP server(s) + probe server, plain, sminos
disable all / enable all / reconnect all Disabled 4 / Enabled 4 / No MCP servers need reconnecting all / [] / —
reconnect (bare) opens the Manage MCP servers panel; the run ends only after Escape —

python3 -I live.py routes r1 used the built table. Every admitted form ran with the same answers as above. reconnect, remove plain, enable a\tb, reconnect probe server and enable plain each answered bad-args in 2–7 ms and never reached the engine.

Tests, run locally:

  • claude plugin test . (in sminos/): 520 pass, 0 fail.
  • bash sminos/tests/test-bridge-control.sh: all 163 passed.
  • python3 sminos/tests/test_rpcs.py -k m2 -k test_l_ -k test_f_ -k test_i_: 34 tests OK.
  • python3 sminos/tests/routes_check.py sminos/tests/routes-*.json: 44 ok, 0 FAIL.
  • tsc -p sminos/hooks/mods/tsconfig.json against the 2.1.310 declarations: clean.
  • bash sminos/tests/run-sminos-tests.sh: 2 of 2,413 assertions failed. Both are the "send to codex without codex on PATH" assertions. They fail locally only because python3 and codex share /opt/homebrew/bin on this machine; the gate's sminos job passes them.

ci-gate (a0febef): GREEN, every gate (repo-checks, sminos-mods, mods-types, shell-lint, board-api, sminos, issue-tracker, sminos-suites): https://github.com/SSFSKIM/doperpowers/actions/runs/40292170462

Review fix wave

  • A btw survives a reload (P1). Each open side question is kept in $.state (sminos/btw) from before its started answer until the child took its end. The next module ends each one it finds there, aborted, under the original nonce.
    • Live, 2.1.310: the reviewer's reload probe, re-run on this head, finds the end in the child's kept record: {"phase": "end", "reason": "aborted", "rpc": "review-btw-pending-reload"}. Before the fix there was none. Evidence: /tmp/dsk-scripts/mw-wave/mw2-live/evidence/fix-reload-21950/.
  • Op ends are kept until taken (P2). run and btw ends are owed until a post the child answered carried them, and every resync is followed by those still owed. The child relays each op's end once, by its id.
  • No U+2028/U+2029 in a server name (P2). The one-server form excludes both.
  • Disabling every server is refused (the orchestrator's row change), bare or all, on 2.1.310 and 2.1.307. The reason: turns off every server, this desk's own tools among them: run it in the terminal. enable all and reconnect all keep their confirm. On 2.1.307 this is a refusal only, recorded measured: I.

ci-gate at 3266824: GREEN, all 9 gates (https://github.com/SSFSKIM/doperpowers/actions/runs/40297214391).

Commits: c7c3cd4 (side-question reload recovery, owed ends, the child's dedupe), 3266824 (the routes). The regenerated bridge-routes.tsx and the new route tests landed in c7c3cd4 by mistake and its fixtures in 3266824, so routes_check and the route tests pass only at the head. No amends, per the brief.

Residue

The orchestrator's ruling on the configured-name gap: ship as measured, and decide it when the web half lands.

  • The gap. /mcp resolves a server only by its configured name. The mcp read names a connected server by its tool spelling (probe server reads as probe_server), and the engine answers "not found" for a tool spelling.
  • What's missing: the configured-name mapping for user, local and project servers (the plane already reads those config files for the disabled list).
  • Plugin servers (plugin:<p>:<s>), which are most of the owner's MCP servers.
  • Scope of the gap. The web can already send any configured name through the command typeahead, so the gap is only the MCP panel's one-tap actions.
  • The web's formRoute follows one level of otherwise without checking its pattern. The bridge and the fake check each level, but the web would offer disable all behind a confirm (the bridge then refuses it) and draw a 2.1.307 restart x as that drop's reason. It should follow the chain as the bridge does.

Sminos-Session: desk-sminos-orchestrator#b4948247 (doperpowers on macbook)

…measured (1.12.0)

- btw: the bridge op (bridge-btw.tsx) frames the question, answers started
  at once (nothing-to-fork within 250 ms refuses it), and posts btw start and
  end, the answer bounded at 64 KiB of UTF-8 (truncated when cut); the child
  carries the RPC's nonce on both and keeps the end; the daemon's btw RPC
  (prompt at most 8,192) relays them as DX4 op "btw", through a stop too.
- compact takes instructions (at most 4,096), passed to the bridge.
- /mcp on 2.1.310: routes-2.1.310.json, carried from 2.1.307 with mcp
  re-measured: one server by its configured name (spaces admitted), the
  every-server forms through otherwise with confirm, a bare reconnect refused;
  routes_check.py checks every fixture and the carry, and writes one table
  per engine. 2.1.307's fixture is unchanged.

Sminos-Session: desk-sminos-orchestrator#b4948247 (doperpowers on macbook)
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 26, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-26T08:41:16.874367Z a0febef PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

…pt until taken

- The ids of side questions answered started are kept in session-scoped
  $.state (sminos/btw) until the child took their end; the module that
  loads after a reload ends each it finds and does not hold, aborted, and
  the child names that end by the original nonce.
- A run or btw end is owed until a post the child answered carried it:
  every resync is followed by the ends still owed, so one that came while
  no child was there, or whose post failed, reaches the next child.
- The child relays each op's end once, by its id (an end kept beside an
  answer counts), dropping one the mod posts again.

Sminos-Session: desk-sminos-orchestrator#b4948247 (doperpowers on macbook)
… a server name

- /mcp disable, bare or all, is refused on 2.1.310 and 2.1.307 alike:
  "turns off every server, this desk's own tools among them: run it in the
  terminal" (the write persists for the project and turns off the desk's own
  tool servers). enable all and reconnect all keep their confirm. On 2.1.307
  it is a refusal only, not a new measurement (measured: I).
- 2.1.310 parses /mcp's arguments with a `.` that stops at U+2028/U+2029:
  the one-server form excludes both, so such a name never opens the panel.

Sminos-Session: desk-sminos-orchestrator#b4948247 (doperpowers on macbook)
@SSFSKIM
SSFSKIM merged commit 85b90fd into main Oct 26, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant