Skip to content

feat(web): Prism settings in the Providers layout, lanes only for Worker - #35

Merged
lukemaj merged 4 commits into
mainfrom
feat/26-prism-settings-layout
Sep 25, 2026
Merged

lukemaj merged 4 commits into
mainfrom
feat/26-prism-settings-layout

Conversation

@lukemaj

@lukemaj lukemaj commented Sep 25, 2026

Copy link
Copy Markdown
Contributor

This closes #26. The Prism settings page showed a 5x3 grid of lanes, and most of those lanes were never used. The page now uses the Providers layout. On the left is a list of roles, each with an icon, a one-line description and a toggle. On the right is a detail pane with one ordered model list for the selected role. Every change saves on its own, so there are no Save buttons.

Changes

  • Roles: the page shows Dispatcher, Worker, Reviewer, Retry (key correction) and Escalation (key recovery). Planner is gone from the page. Only Retry and Escalation can be switched off. The other roles show a locked toggle with the reason in a tooltip and in the detail pane: Dispatcher is needed until router Wight mode: keep a thread working on continue #117 decides, Reviewer because independent review is required, Worker because it is required.
  • Lists: Only Worker has easy/medium/hard, shown as tabs. Every other role has one list: model plus effort, drag handle or arrows to reorder, first entry primary, the rest fallbacks.
  • Settings schema: a role other than Worker now stores models, and correction/recovery add enabled (default true). Saved per-lane lists still load: the medium list becomes the single list, and the next save writes models.
  • Snapshot compatibility with router feat(server): continue idle threads in Wight mode #127: /api/prism/snapshot still sends lanes.easy/medium/hard for every role. A role other than Worker repeats its single list in all three lanes and also sends it as models. Only correction and recovery carry enabled.
  • spawn_thread: accepts retry and escalation, and still accepts correction and recovery. A role other than Worker uses its single list and ignores lane.
  • Agents panel: each Prism job row is now a heading with no status dot (Job <id> · <status> <route>), so it no longer looks like a second agent.

Proof

  • Tests: vp test run passed for packages/contracts/src/prism.test.ts (6), for the server tests roles.test.ts and snapshotRoute.test.ts (21), and for the web tests PrismSettings.logic/state.test.ts and AgentThreadTree.logic.test.ts (21).
  • Typecheck: tsc --noEmit passed for contracts, server and web.
  • Lint: vp lint is clean on the changed files, and scripts/fork-check.sh reports OK.
  • Live run: I ran an isolated dev instance on the worktree's own .t3 state, seeded with old per-lane lists. The page migrated them. Turning Retry off saved correction.enabled: false. GET /api/prism/snapshot returned three lanes for every role, models on every role except Worker, and enabled only on correction (false) and recovery (true).

Screenshots were taken with Playwright's bundled Chromium (headless shell 1243) against that instance. They are cropped to the roles section.

Page (Dispatcher selected, migrated list):
Prism page

Worker lanes (Hard tab):
Worker lanes

Retry switched off:
Retry off

Not captured: the Agents panel heading. It needs a live Prism job, and the isolated instance has none.

Done with Claude Opus 5.5 in Claude Code.

🤖 Generated with Claude Code

lukemaj and others added 3 commits September 26, 2026 00:06
…ion switchable (#26)

Only the worker keeps easy/medium/hard lists; every other role has one
ordered list under models, and a saved per-lane list keeps its medium
entry as that list. Retry (correction) and Escalation (recovery) gain
enabled. The snapshot still repeats each single list in every lane until
toolboxmd/model-router#127 reads single lists. spawn_thread accepts retry
and escalation next to the old names.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
A role list (icon, name, description, toggle) and a detail pane with one
ordered model list per role, reorderable by drag or arrows and saved on
every change. Only Worker shows easy/medium/hard tabs. Retry and
Escalation can be switched off; Dispatcher, Worker and Reviewer show
locked on with the reason. Planner is no longer on the page. The Agents
panel shows each Prism job as a heading without a status dot.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…one line (#26)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:XL labels Sep 25, 2026
)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@github-actions

github-actions Bot commented Sep 25, 2026 •

Copy link
Copy Markdown
Contributor

Thread transfer impact

✅ Thread transfer remains within every enforced ceiling.

Provider Metric Main baseline This PR Impact PR ceiling
Codex Total thread wire 13.5 KiB 13.5 KiB +23 B (+0.2%) 15.1 KiB ✅
Codex Thread snapshot wire 7.1 KiB 7.1 KiB +1 B (+0.0%) 7.3 KiB ✅
Codex Live turn WebSocket wire 6.4 KiB 6.5 KiB +22 B (+0.3%) 7.8 KiB ✅
Codex Live turn WebSocket decoded 56.2 KiB 56.3 KiB +44 B (+0.1%) 66.4 KiB ✅
Codex Live turn messages 9 10 +1 (+11.1%) 21 ✅
Claude Total thread wire 13.5 KiB 13.5 KiB −13 B (−0.1%) 15.1 KiB ✅
Claude Thread snapshot wire 7.1 KiB 7.1 KiB +1 B (+0.0%) 7.3 KiB ✅
Claude Live turn WebSocket wire 6.5 KiB 6.4 KiB −14 B (−0.2%) 7.8 KiB ✅
Claude Live turn WebSocket decoded 57.0 KiB 57.0 KiB 0 B (0.0%) 66.4 KiB ✅
Claude Live turn messages 9 9 0 (0.0%) 21 ✅

Baseline: 13b7a4f · PR result: f092bd5 · Source CI: success

Scenario and decoded snapshot size

10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.

  • Codex decoded thread snapshot: 113.9 KiB
  • Claude decoded thread snapshot: 114.6 KiB

Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed.

@lukemaj
lukemaj merged commit 8b50929 into main Sep 25, 2026
26 of 27 checks passed
lukemaj added a commit that referenced this pull request Sep 27, 2026
…ker (#26) (#35)

* feat(contracts): single model lists outside Worker, Retry and Escalation switchable (#26)

Only the worker keeps easy/medium/hard lists; every other role has one
ordered list under models, and a saved per-lane list keeps its medium
entry as that list. Retry (correction) and Escalation (recovery) gain
enabled. The snapshot still repeats each single list in every lane until
toolboxmd/model-router#127 reads single lists. spawn_thread accepts retry
and escalation next to the old names.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

* feat(web): Prism settings in the Providers layout with autosave (#26)

A role list (icon, name, description, toggle) and a detail pane with one
ordered model list per role, reorderable by drag or arrows and saved on
every change. Only Worker shows easy/medium/hard tabs. Retry and
Escalation can be switched off; Dispatcher, Worker and Reviewer show
locked on with the reason. Planner is no longer on the page. The Agents
panel shows each Prism job as a heading without a status dot.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

* fix(web): show locked Prism roles with a lock and keep model rows on one line (#26)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

* chore(web): drop unused applyPrismRoleUpdate export flagged by knip (#26)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XL vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Prism settings in the Providers layout: role list with toggles, lanes only for Worker

1 participant