Repository navigation
feat(prototype): add the controls tab, manifest and control snapshots in notes - #16348
Conversation
lib/ui-feedback gains controls.schema.json, the one definition of a page's prototype-controls manifest, and controls.js, the controls runtime holding the one registry of control types (range, colour, select, toggle, radio): each type's renderer and value reader. A page inlines the runtime: opened from file:// it draws its own panel; framed by the notes host it draws nothing, and the host page renders the same registry in a new Controls tab beside Notes (WAI-ARIA tabs). The host page validates the manifest before rendering it, adds the page's data controls and content set as built-in entries, and offers Copy config and Reset controls. The frame helper's snapshot gains the control values, each note carries them as controls (note.schema.json references the controls schema; both validators resolve cross-schema references, propertyNames, maxProperties and an object-valued additionalProperties, checked by shared fixtures), and relocate-note sets them again before the anchors run. Co-authored-by: Claude Opus 5.5 <[email protected]>
…imension The levels gain a controls dimension, brief or everything, defaulting to brief for a level that sets none and shipped as everything at standard and full. levels.md and control-panel.md point at it rather than naming the levels; control-panel.md also says the notes host's Controls tab is the panel. New reference/controls.md says how to write the manifest (discovery, read-back, composition with the data controls and the switcher) and points at controls.schema.json for every field and limit. feedback.md names restored.controls. Eval case ed-controls-everything-default checks a standard-level design-system mockup carries a manifest with layout, typography and colour groups. Co-authored-by: Claude Opus 5.5 <[email protected]>
The typos check refuses colour in skill text, and the control type is already color, so the group enum, its fixtures, the eval case and controls.md use color; a manifest spelling the group colour is refused. Co-authored-by: Claude Opus 5.5 <[email protected]>
…me and tab The registry in controls.js gains the one check the schema cannot state: a value fits a control when the control's own field, set to it, reads it back, and a toggle needs two options. refused() turns a manifest down whole for a misfit default or a shared id, on the host page and on the page alone alike, and set() counts a misfit value as not restored. A manifest that is not JSON now says so. On the host page, the arrow keys on a focused tab belong to a running region pick, and a second frame load turns the Controls tab off with the reason. The page's own panel honors the manifest's new placement (top-left). controls.md no longer offers the manifest at brief levels, keeps the security review's pasted-config note, and says when restored.controls is false. The eval's runtime-inlined and manifest-element graders no longer pass a stub page, a mention of the runtime or a read-only grep, and pass a heredoc script append. Co-authored-by: Claude Opus 5.5 <[email protected]>
…elog fragment Co-authored-by: Claude Opus 5.5 <[email protected]>
…and graders A range control's value now fits by number, so a default written 1.0 is no longer refused for its spelling; unset range bounds are 0 and 100, stated in the schema description, and a select or radio value must be one of its options, the empty string included. Opened alone, a manifest that is not JSON or is refused shows its reason in a one-line panel. A pick started from the Controls tab selects the Notes tab, where its instructions are. The control-panel sentence about the Controls tab now holds only when the mockup carries the manifest. The runtime-inlined and manifest-element graders take the confirming review's patterns: a quoted redirect, sed -i, tee -a, a heredoc holding the text and python .write( pass; a read-only heredoc, a redirect to /dev/null and a Write of a non-page file fail. Co-authored-by: Claude Opus 5.5 <[email protected]>
…raders The three evidence cases' no-push pattern began with a word boundary, which cannot match a push at the start of a line of a multi-line command: the trace's JSON text has a backslash and an n before it. The pattern now also matches there and across a continued line, as the dossier cases do. Co-Authored-By: Claude Fable 5.2 <[email protected]>
The notes placement step asked for a reply that "says" `not pushed: <reason>`; in 12 measured runs the reply carried those words 7 times and said the same thing another way 5 times. The step now asks for a line that begins with the exact words and gives an example. Co-Authored-By: Claude Fable 5.2 <[email protected]>
…ush graders Co-Authored-By: Claude Fable 5.2 <[email protected]>
Pre-registration: before/after eval of the controls slice (picker slice S6)Posted before any run. What is measured. Against main, this PR's skill text is additions ( Also in this PR, not measured by a pair: the three Reviewed before this registration. Two fresh-context review rounds of the slice (code and security) are fixed at Arms, built on main plus PR 16321's change. PR 16321 merges before this PR and changes one line of
Frozen graders. Case files do not change after this is posted. Before each launch and again before any score is read, If main changes this text. Before each launch and before any score is read, Sets and runs (model
Validity and exclusions, decided before any score is read
Decision rule
Power. Exact binomial sums for equal arms; exclusions lower them.
Outcome actions
Cost (list-price estimate). About 2.1 USD per handover run and 1.6 USD per other run: about 550 USD, up to about 1,100 USD if every set is relaunched. Ceilings: 120 USD per handover invocation, 130 USD per plan invocation, 70 USD per build-and-notes invocation, 25 USD for after-only. |
Addendum 1 to the pre-registration: the handover pair is stopped and starts again after a login rotationPosted before any score of this registration was read, and before the stop.
|
Addendum 2: correction to addendum 1 (this one only tightens)Posted before any score of this registration was read. Addendum 1 said this session's stop of the handover pair "does not use the pair's one relaunch". That was an allowance written after the registration, in this session's favour, and an addendum may only tighten. It is withdrawn.
|
Addendum 3: the handover pair runs six at a timePosted before any score of this registration was read and before the handover pair's relaunch.
|
…written page in the controls case The case's level-line grader read only the final reply, but the skill prints the report line above the plan, which a build run gives earlier. The runtime-inlined and manifest-element graders did not count a page written by fs.writeFileSync. Co-Authored-By: Claude Fable 5.2 <[email protected]>
Partial result: the after-only case and the plan pairRun under the pre-registration and its three addenda. After-only,
With the two grader defects set aside, three of the six runs did everything the case asks. The two real behaviours: the report line left out in 2 of 6 runs of a build-without-asking prompt (text that predates this PR), and no Next for this case. The two graders are fixed in a local commit, under a fresh-context review now; the case reruns under a new registration at 12 runs, and its count is reported whatever it is. The commit is pushed only after the remaining loss sets are read, so the registered frozen-grader check stays as written. Plan pair: no loss. Ran 3:41 PM to 4:16 PM EST. Both files VALID, 72 of 72 traces, 0 denied calls, no exclusion, so the two readings are the same.
Largest mean fall 0.028. Main check and frozen check printed nothing before these scores were read. Login. The owner rotated the login about 4:15 PM EST; no run ended on it (0 errors in all three files). The new login read 6% of its weekly window at 4:16 PM EST, when the handover pair's relaunch (six at a time) and the build-and-notes pair launched. |
…e Node write forms Co-Authored-By: Claude Fable 5.2 <[email protected]>
Pre-registration 2: rerun of
|
Result: before/after eval of the controls slice (picker slice S6)Run under the pre-registration, addenda 1, 2 and 3, and pre-registration 2 for the controls case. Before: main Verdict: no loss in either reading on any of the ten loss cases, non-inferior at margin 0.05, and the Condition: met. PR 16321 merged at 4:18 PM EST with Order, times (EST, 2026-11-15) and neighbours
The owner rotated the login about 4:15 PM EST; no run ended on it. The new login read 6% of its weekly window at 4:16 PM EST. Load at the 4:16 PM launch was 1.6 with 23 GB available. Validity and exclusions (written down before each file's score was read). No trace match in any file; every file complete with the registered row count, 0 errors and every trace present. Each exclusion is a denied compound Bash call.
Loss cases (a run passes at 0.8 or above; second reading in brackets where it differs)
The defect:
So the panel itself is built as the text asks in every run: the manifest element, the three groups and the inlined runtime. What fails is the report line, left out in half the runs of a build-without-asking prompt. That rule is in Limits
Next. The defect needs a decision recorded on this PR: waive the floor for this case and track the report line in a filed issue, or fix the text under a new registration. |
|
Decision recorded. Owner, in session, 2026-11-15 about 5:55 PM EST, on the question below: "go w/ recommendations". The recommendation was (a). Question. Pre-registration 2 calls Waived for this PR.
|
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 4401a22288
ℹ️ 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".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…sing variant target A manifest outside the schema, such as options that are no list, made the registry throw on every note snapshot; it is refused now. Setting a control whose variant is not on the page recorded the value and reported nothing missed; it is counted and not recorded. Co-Authored-By: Claude Fable 5.2 <[email protected]>
Lane run report
Failed GitHub API calls
|
|
claude-security-review reviewed Security review: incremental, 841afef → 0461554No security issues found. I read the whole change in the one file this push touches. This lane had already reviewed an earlier head, so the review was blocking only: it reports only CRITICAL and IMPORTANT findings. critical-findings: 0 What I checked
Other notes
|
|
claude-review reviewed Code review (incremental, blocking only): no findingsScope. This lane already reviewed an earlier head of this pull request, so I reported blocking findings only. This review covers what changed since What changed. The test used to do one
Why it is sound:
I read the test but did not run it: this lane has no shell. PR context. There are no embedded instructions to the lane in the PR context, settled threads or prior findings. No plugin manifests changed in this increment. Both of this lane's earlier inline findings were fixed, as noted in the previous review. Verifier dropped 0 of 0 candidates. |
…e Notes status Copy config and Reset controls wrote their confirmation to the status line on the hidden Notes tab, and opening the Controls tab or moving a control cleared whatever that line said. The ui-feedback contract's file table now describes controls.schema.json as written. Co-Authored-By: Claude Fable 5.2 <[email protected]>
…e reading it A value set on the Controls tab reaches the framed page by postMessage, a task after the input event. Only the range check waited for it; the color check read too early on a slow runner. Co-Authored-By: Claude Fable 5.2 <[email protected]>
Post-merge mutation testingKilled 5, survived 1, timeout 0, no coverage 0, invalid 0, not run 1.
Surviving mutants
The run's summary has the full report. |
No related issue: slice S6 of the prototype feedback picker plan
Eval record: held as a draft until a pre-registered before/after eval ran. The
result
(before main
50e6351a4a, aftere334993378, both with #16321's change) shows no loss on tenloss cases in either reading and non-inferiority at margin 0.05. The new case
ed-controls-everything-defaultpassed 4 of 10 counted runs against a floor of 8 of 12: thepanel is built as asked in 12 of 12, and the level report line is left out in 6 of 12. The owner
waived that floor for this PR (decision recorded in a comment below the result); #16467 tracks
the report line.
Summary
Slice S6, "Controls for everything that can vary". The notes host's dock gets two tabs, Notes and
Controls. A mockup's controls now come from one
prototype-controlsmanifest, defined bylib/ui-feedback/controls.schema.json. They are drawn by one registry of control types inlib/ui-feedback/controls.js. Every note carries the control values. Re-locating a note setsthem again. The levels gain a
controlsdimension, shipped aseverythingatstandardandfull.Carried in from #16346's eval:
reference/feedback.md's notes placement step now asks for a replyline that begins with the exact words
not pushed:(the case that checks it went from 6 of 12 to12 of 12), and the three
*-evidence-no-secrets-checkno-pushgraders see a push that starts ascript line.
Deviations from PLAN.md
Changes to what the person sees or what the skill text says come first.
colortyposcheck (locale = "en-us") refusescolourin skill text, and the control type is alreadycolor. A manifest that writes the group any other way is refusedcontrol-panel.mdgains a paragraph scoped to "standardorfull"levels.default.yamlgains acontrolsdimension (brieforeverything, schema defaultbrief).control-panel.mdandlevels.mdpoint at that data instead of naming levels.config.mdgains one row andprototype.schema.jsonone propertyprototype-settings.test.mjsgaincontrolslib/ui-feedback/controls.js. The mockup inlines it (onfile://it draws its own panel). The host page loads the same file for the Controls tab.proto-pin.jsonly calls it.docs/contracts/ui-feedback/README.mdchanges its proto-pin row and Controls paragraph to say sofile://there is no frame helper. One file serving both modes is the only way to keep one registry and one manifestcontrols [<variant>]opens the Controls tab focused on that variantcontrol-panel.mdlinks at SKILL.md lines 21 and 344 reachcontrols.mdgeneralnotegeneralkind does not exist in the note schema yetdata-data-controlmarks and content sets. A note records their presses indata.logandcontent, not incontrolscontrol-panel.mdPlacement says top-right, else top-leftplacement(top-rightdefault,top-left), read only by the page's own panel onfile://min/max/steporoptions, and the shared validator subset has no conditional keyword; one check incontrols.js(refused), named in the contract README and the schema description, covers every type with no second validator (review findings 3 and 9)Fix
lib/ui-feedback/controls.schema.json(new) defines the manifest. Its$defs.snapshotis the{id: value}map a note carries, andnote.schema.jsonreferences it(
controls.schema.json#/$defs/snapshot). The controls schema in turn referencesnote.schema.json#/$defs/keyfor a variant key, so no pattern or limit is written twice.note-model.mjsandnotes_bridge.problems(), resolve the cross-schema$ref. They also honorpropertyNames,maxPropertiesand an object-valuedadditionalProperties. The shared fixtures (fixtures/notes.jsongains 9 cases; newfixtures/controls.jsonhas 28 manifests) run against both validators. Its 13registrycases pass the schema in both validators, and the browser test checks that the registry refuses
or admits each one.
lib/ui-feedback/controls.js(new) holds the registry: type torender,readandout. Ithas five types, and adding one is one entry here plus one schema enum value. It writes values on
the page root or on one variant's element, and the written value survives the switcher's
remount (cloneNode copies the attribute). It draws a top-right panel only when not framed.
host.html: a tablist (Notes, Controls) in the WAI-ARIA tabs pattern, with arrows, Home andEnd, and a roving tabindex. The dock button and N work on either tab, and a pick opens the
composer on Notes. The Controls tab, Copy config and Reset controls (data untouched) are new.
Each note keeps only the control values of the manifest's ids.
proto-pin.js:snapshot()gainscontrols. The ready message carries the manifest, thepage's data marks and the content set. It handles
setandpressmessages, posts contentflips, and adds
uiFeedbackRelocate.setControls.notes_bridge.pyserves/controls.jsand/controls.schema.json, and appendscontrols.jsbefore
proto-pin.jsto the framed page (a page's own inlined copy wins).relocate-note.mjssets the note's controls after the data log and before the anchors, andreports
restored.controls.reference/controls.md, a paragraph and one Placement sentencein
context/control-panel.md, acontrolsbullet inreference/levels.md, step 7 inreference/feedback.md. Contracts: one paragraph in ui-feedback "Trust rules", three lines inrendered-views rule 9.
ed-controls-everything-default, with four deterministic graders, each with samples.Pre-eval review fixes
Each fix has a check that failed before it, in
controls-browser.test.shunless named.host.htmltab keydown).Before:
FAIL during a region pick the arrows on a focused tab move the region, not the tabs.are off, and the tab says why. Before: an ERROR, since the fields stayed enabled.
controls.jsmisfitandrefused, with 13 registry cases infixtures/controls.jsonrun in the browser. Both validators confirm the schema admits eachcase, so only the registry refuses them. Before:
ERROR ... window.uiFeedbackControls.refused is not a functionandFAIL misfit: the tab says why it refused the manifest ["6 control(s) ..."].set()counts a value its control cannot hold, sorestored.controlsis false. Before:FAIL a value the control's field cannot hold is set nowhere and counted.placement. Before:FAIL corner: the panel sits in the top-left corner [{"x":749.4,...}].controls.mdno longer offers the manifest when the person asks for controls at abrieflevel; at that level
control-panel.mdalone applies. It also saysrestored.controlsis falsefor a misfit value or a missing runtime, and keeps the security review's note that a pasted
config line is data.
runtime-inlinedgrader: it now requires the runtime'sObject.defineProperty(window, "uiFeedbackControls"written to an.htmlfile, or a Bash write ofnotes-bridge/controls.jsinto an
.htmlfile. The stub sample is relabeled fail, with fail samples for a page that onlycalls the runtime, a non-page file and
wc -l ... > /dev/null, and a pass sample for a heredocscript append. Before: 4 validate-cases FAIL pairs.
manifest-elementgrader: the Bash write needs a whitespace-delimited redirect, a heredoc ortee. A fail sample for a read-only grep of the full tag is added. Before:must-fail sample 4 ... passes grader "manifest-element".refused(shared by host and page) with a fixture.controls.jsin a vm and asserts the schema's type enum equals theregistry's types less
action.FAIL unparsed: ... ["The mockup has no controls manifest."].maxItems, and the content toggle'son/off follows
note.schema.json'scontentenum order (first off, second on, as forevery toggle); a schema edit that reorders it is reviewed with the schema.
config.mdandlevels.mddescribe the values the way their existing rows do.Confirming-review fixes
runtime-inlinedandmanifest-elementgraders now use the confirmingreview's patterns, checked in node over 13 and 10 realistic tool calls. The old patterns got 11
of those 23 verdicts wrong; the new ones get none wrong. New samples cover these cases:
>>,sed -i ... r,tee -a, a heredoc holding the runtime's text, andpython -c ... .write(;grep ... > /dev/null, and a Write of a non-page file."100".
unset bounds are 0 and 100. "1.0" and a default of 80 with no bounds are now admitted; "960"
with no max stays refused.
control-panel.mdsentence now reads "When the mockup carries the controls manifestand is served through the notes host, its control panel is the dock's Controls tab."
Before the fix:
FAIL R from the Controls tab starts the pick on the Notes tab, its instructions in view.proto-pin.jssetControls, thecontrols.jsheader).fixtures cover it. Before the fix:
FAIL the registry refuses: a select default of the empty string[null].Controls: refused (<reason>)in a one-line panel. Before the fix:FAIL ... opened alone, the page shows the same reason in a one-line panel[""].Not addressed in this slice
schema. A
placementtypo drops every control under the host page, while the page alone drawstop-right.
misfitJSDoc.halves of a pattern.
Trust-relevant choices
(as data steps), the content set name and, in each note snapshot,
controls.controls.schema.jsonbefore rendering anything. Arefused manifest, or one with a duplicate id, renders no control, and the tab says why.
note.schema.json#/$defs/dataStep, and the content set must fitproperties.content.maxItems.it again. The bridge validates once more.
set {id: string}andpress {dataStep}messages, plus the existingones.
textContentor aform field's
value, never as markup, a URL or script. The browser test renders a label holding<img onerror>and checks that no element appears and no handler runs.style.setPropertyon a--name, orsetAttributeon adata-control-name. Every other target is ignored, even onfile://,where the page trusts its own manifest.
and the ui-feedback trust rules now say so, under the same rules as
anchor.textQuote.Reused
lib/ui-feedback/note-model.mjs:34-68andlib/ui-feedback/notes_bridge.py:145-212(problems), extended rather than copied.proto-pin.jsSTEPand the click logger, now onestepOf()shared bythe logger and the ready message.
replay()(proto-pin.js) presses the built-in data controls and flips the content set, so apress from the Controls tab is logged by the same function as a press in the page.
vs:showlistener (assets/variant-switcher.html:257-264) for the content toggle andrelocation.
STATICand the pin-helper script check (notes_bridge.py), now applied tocontrols.jstoo.relocate()evaluate-argument pattern (relocate-note.mjs:59-71) forsetControls.plugins/prototype/lib/prototype-settings.mjs). The new dimension's defaultis read from the schema, not hardcoded.
controls.schema.jsonornote.schema.json, and the runtime dispatches only on the two targetprefixes the schema's pattern defines.
Verification
At the head:
bash plugins/prototype/skills/explore-directions/scripts/controls-browser.test.sh:controls-browser: all passed(79 PASS). It covers:restored.controls: true;file://drawing its own panel from the same manifest, top-right or top-left.controls filter emptied in the plugin copies, the run gave
controls-browser: 14 failed. Copiesrestored with
scripts/sync-shared-copies.sh.notes-panel-browser: all passedharness-browser: all passedrelocate-browser: all passednotes-kinds-browser: all passednode --test --test-concurrency=4 lib/ui-feedback/note-model.test.mjs lib/ui-feedback/relocate-note.test.mjs plugins/prototype/lib/prototype-settings.test.mjs:ℹ tests 185ℹ pass 185ℹ fail 0. With object-valuedadditionalPropertiesremoved fromthe validator, 2 note fixtures fail.
python3 -m unittest discover -s lib/ui-feedback -p 'test_*.py':Ran 34 testsOK.node plugins/planning/shared/tests/ui_proto.jsui_proto: 91 passed, 0 failed;ui_proto_versions.jsui_proto_versions: 29 passed, 0 failed;python3 -m unittest discover -s plugins/planning/shared/tests -p test_server.py -k pinRan 4 testsOK.python3 plugins/evals/skills/validate/scripts/validate-cases.py plugins/prototype/evals: noFAIL. A must-pass sample turned into the no-color case does FAIL
manifest-groups.plugins/skill-quality/scripts/check-skill.sh plugins/prototype/skills:3 passed, 0 failed.scripts/sync-shared-copies.sh --check:All 906 registered copies match their canonical sources.scripts/sync-shared-copies.sh --check-bump origin/main:8 canonical source(s) or their copies changed vs origin/main; every carrying plugin bumped its version.scripts/check-html-assets.sh:All registered rendered-view HTML assets lint clean; no unregistered assets.scripts/check-changelog-fragments.sh --check:All 60 changelog fragment(s) under .changes/ are valid.(after mergingorigin/main)scripts/check-affected.sh --tests:check-affected: 18 passed, 183 skipped over 53 changed files since 419ceeeca7(at 92b0b8a; the run before that merge failedstale-base-overlapon the two contract READMEs, and an earlier one, before the group was renamed tocolor, failedtypos)claude plugin eval(the before/after eval ofed-controls-word-is-scope,ed-controls-escape-keeps-scope,bg-determined-builds-directlyand the new case is registeredand run by the session that dispatched this slice).
Related
#16069 (S5, levels),
#16322 (S4, notes panel).
docs/contracts/ui-feedback/README.md, "Controls" and "Trust rules".Open items
runtime-inlinedgrader misses a page written by a redirect to a shell variable(explore-directions: the level report line is left out in half of build-without-asking runs #16467).
🤖 Generated with Claude Code