feat(presets): split control-assistant tiers by role, surface, and panels - #573
Merged
Conversation
…nels The tutorial roster now ships alice as the write-capable operator and bob as the read-only viewer, each with a role-naming browser tab title. The personas pin the full tier contract, not just the write switch: expert vs simple web surface, and the EVENTS/BLUESKY panel declarations move from the shared base into the readwrite persona so the read-only terminal is built without them (a persona delta cannot subtract inherited config, and enabled: false is inert for URL panels). Both terminals default to the main theme in light mode. Preset content hashes are re-pinned knowingly; the persona contract test asserts the three-axis tier boundary wholesale, and the multi-user guide and landing screenshot track the shipped shape.
| assert rw_cfg.pop(WRITES_KEY) is True | ||
| # With the axis key removed, the rendered config overrides are identical. | ||
| # Axis 2 — surface: chat-first for the viewer, full dock for the operator. | ||
| assert ro_cfg.pop(UI_MODE_KEY) == "simple" |
| # With the axis key removed, the rendered config overrides are identical. | ||
| # Axis 2 — surface: chat-first for the viewer, full dock for the operator. | ||
| assert ro_cfg.pop(UI_MODE_KEY) == "simple" | ||
| assert rw_cfg.pop(UI_MODE_KEY) == "expert" |
The static preset gate requires every web_panels id to be a builtin or be backed by a web.panels.<id>.url override in the same resolved preset. With the URL overrides now living in the readwrite persona, the events/bluesky list entries follow them there: the base and readonly presets no longer list panels they do not declare, and the readwrite persona lists exactly the two it does. The artifact-parity test now pins panels as the one deliberate list difference; preset hashes re-pinned accordingly.
The events-panel guard now checks the readwrite persona, where the panel id and its URL override live, and asserts the base carries neither. The emitted-delta comment check pins phrases as they flow in the current readonly preset prose.
# Conflicts: # tests/cli/test_preset_hash_pin.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Redesigns the
control-assistanttutorial's two-user personas so the tiers are coherent end to end:control_system.writes_enabledweb.ui_modeBoth terminals default to the
maintheme pinned light (web.theme: light).Why the panels move instead of being disabled
web.panels.<id>.enabled: falseis checked only for builtin panel ids — URL/iframe panels (EVENTS, BLUESKY) are appended unconditionally, so the key is inert for exactly these two. And a persona delta cannot subtract inheritedconfig:keys (configis deliberately non-excludable). The one mechanism that makes the panels genuinely absent from the read-only build is declaring them only in the readwrite persona. The base project still gets both panels via the dispatch/bluesky-panels injector defaults; its EVENTS entry loses thehealth_endpoint/env-overridable URL the explicit declaration carried, which only affects a host-runosprey webfrom the base project directory.Contract updates
test_personas_differ_only_on_writes_enabledbecomestest_personas_differ_only_on_the_tier_contract, asserting the three axes (write switch, ui_mode, readwrite-only panel keys) and then wholesale equality, so any fourth drift still fails.Testing
Feature-scoped suites pass locally (120 tests: persona presets, preset render, hash pin, persona emission, profile roundtrip) plus ruff on the changed files. Full suite left to CI.