Repository navigation
feat(vibe): Test named mechanisms and decision provenance in vibe sessions - #299
Merged
Merged
Conversation
…sions - The handoff guardrails reviewer checks each new poller, lane, socket, channel, route, table, cursor, or write into another tool's files: the existing mechanism it could reuse, what its cost scales with at 10x and 100x, and its per-device idle cost, against the plan's Cost Scaling table when there is one. - A finding that needs a human decision becomes an Engineering decision item on the live ticket's Engineering checklist; the writer never resolves, downgrades, or absorbs it, and it never reaches the person. - The change worker treats a mechanism a ticket names as a proposal, builds the better option when it is dominated, and logs the swap as an Engineering decision. Plans with periodic or cross-surface work carry a Cost Scaling table. - The requirements worker tags named mechanisms as proposals instead of acceptance criteria. - A decision is settled only when it traces to a human statement; conflicts are never resolved by recency. - A closedloop-graph route for existing channels between surfaces. - Frozen rows describe user-visible behavior, never mechanism. - Release vibe 1.0.48. Testing: node --test over every plugin test file (392 pass), pytest plugins/ (2316 pass, 3 skipped), ruff and pyright clean, manifest version check passes. New contract tests fail when each pinned phrase is removed. Risks: Reviewers may flag ordinary routes or tables as mechanisms; the check only asks for the reuse and cost reasoning, so the cost is a longer review.
- Move flat, section, paragraph and agent into tools/python/vibe_contract_text.py and import them from all 22 vibe contract tests instead of keeping a copy in each. - section stops at the next heading of the same or a higher level and matches its heading at the start of a line, preferring an exact line. Older copies stopped at the same level only, at "## " only, or took a level argument; one required an exact line. - paragraph also splits list items; one copy did not. - agent returns raw text; the three files whose copy flattened it now call flat(agent(...)). Testing: pytest plugins/vibe (252 pass) and pytest plugins/ (2316 pass, 3 skipped); ruff and pyright clean. Every call site whose result changed was compared against its old helper; each only narrowed a section or paragraph that positive assertions still find. Risks: None identified
- Guardrails item 12 counts a recorded decision as the cited human decision only when it traces to a human statement; a Decisions section alone is a record, and an untraced one is an engineering decision finding. Testing: pytest plugins/vibe (252 pass); the new assertion fails when the sentence is removed. Risks: None identified
shafty023
added a commit
that referenced
this pull request
Oct 16, 2026
…sion's base (#301) * fix(vibe): Judge Storybook stories by the lifecycle scheme of the session's base symphony-alpha #8867 (ISS-12610) made the plain roots current and moved the old ones to <Level> v1.0 with a deprecated tag. The handoff inventory read every plain-root story as frozen v1.0, so a synced session was blocked. - Read the scheme from the base's story-group-order.ts: the lifecycle scheme takes its frozen tag and v1.0 root suffix from StorybookLifecycle and storybookBaselineVersion; an older base keeps the v1.0/v2.0 rules. - Keep the freeze, the compile-only repair, the retitle check against the synced base and the Start Here exemption on both schemes. - Translate the placement rules in guardrails, the decomposer, the writer, the reviewer, design pass, handoff and README. * chore(vibe): Release 1.0.49 Changelog entry for the Storybook lifecycle scheme fix, and the base-scheme contract test reads agent text through flat() after the shared helpers from #299 started returning raw text.
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.
Purpose
#298 taught
cl-executeto weigh a mechanism a ticket names against what already exists, to trace recorded decisions to a human, and to keep human-decision findings out of the planner's hands. Vibe sessions had none of that, so a writer could still build whatever mechanism a ticket named, read a Decisions section as settled, and a reviewer finding that needed a human could be quietly absorbed. This ports the same intent to vibe without adding a plan review, a lint script or a build-loop step, and without asking the vibe person any engineering question.What changed
Engineering decision: <question>; built: <...>; evidence: <...>item. Handoff section 6 andquality-loop.md: a finding that a mechanism, a one-way door, or an unratified or conflicting decision needs a human decision is never the writer's to resolve, downgrade or absorb; it goes on the live ticket's Engineering checklist, never to the person. Ticket template and ticket worker place it.NEEDS_PERSON). Plans that add periodic or cross-surface work carry a Cost Scaling table using cl-execute'splanning-and-gates.mdcolumns and rules.mechanism (proposal)instead of acceptance criteria.quality-loop.mddefines settled: a decision traces to a human statement (who, where, which question). Unratified or conflicting ones go through the existing product necessity gate or become an Engineering decision; never resolved by recency. Every "never re-ask a settled decision" now points at that definition.closedloop-graph.mdgains a route for channels that already connect two surfaces.Commands run
New
test_vibe_mechanism_provenance_contract.pypins the rules above; each test fails when its pinned phrase is removed. Three existing tests pin the Engineering checklist row in the ticket template's ownership table; that row now also lists engineering decisions, and the assertions were updated to the new row (no rule removed). The lean loop, same-family and no-plan-review contract tests pass unchanged.Second commit:
tools/python/vibe_contract_text.pynow holds theflat,section,paragraphandagenthelpers that 22 vibe contract tests each kept a copy of. Where copies differed, the sharedsectionstops at the same or a higher heading level and matches its heading at line start (exact line preferred),paragraphsplits list items, andagentreturns raw text (three files now callflat(agent(...))). Every call site whose output changed was compared against its old helper, and only positive assertions read those sites. pytest plugins/vibe: 252 passed; pytest plugins/: 2316 passed, 3 skipped.