fix(engine): the baseline judgment records its verdict — a native project is never re-asked - #1090
Open
leeovery wants to merge 2 commits into
Open
fix(engine): the baseline judgment records its verdict — a native project is never re-asked#1090leeovery wants to merge 2 commits into
leeovery wants to merge 2 commits into
Conversation
…ject is never re-asked Boot reported `baseline: none` for every project that never recorded a status, and workflow-start's Step 0.4 judged "does a codebase predate the workflows?" from whatever was in context, recording nothing when the answer was no. Every boot of a native project re-rolled the judgment, and one wrong roll rendered the brownfield offer to a project that grew up on the workflows (Folio, 2026-09-02: straight from the migration commit to the offer, no evidence gathered). - `native` joins the baseline statuses: Step 0.4 writes it when the project grew up on the workflows and commits, so the judgment is made once, ever. Hidden on every menu but manage, like `none`; the offer gate and the mid-flight surfaces refuse over it. - Boot's `none` response carries `baseline_signal` — the repository's own history (`domain/baseline.cjs` `baselineSignal`): first-commit date, the date of the first commit touching `.workflows/` (null when none is committed yet), commits before that arrival against the total, tracked project files at the last commit before it; null with no history. The prose judges from it, and "when in doubt, offer once" is gone — the tree resolves the doubt, never the user. - No backfill migration: the next boot of an existing native project judges once on evidence and records the answer. - Prose worlds stamp `native` (was `skipped`); the harness strips the stamp only where the expected world carries no baseline, so a case can pin the verdict write. New case `start-records-a-native-verdict`. - Tests: boot (statuses, signal shapes, null), start gateway rows, render refusals, the simulation's baseline walk. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…ords through one verb Review pass over #1090 (eight finders) and Lee's rulings: the test is code precedence, read by cognition — hand the agent the commits before the workflows arrived and the tree they arrived into, never a count to threshold. - `baseline_signal` reshaped: `history_before` (the pre-arrival commits as `date subject`, head and tail around an elision), `files_at_arrival` + `tree_at_arrival` (the project tree the workflows arrived into — a legacy codebase put under git at install is no longer a fresh start), the counts and dates as context. Ancestry-exact (`rev-list --parents` / `--count` from the arrival's parent, not the log listing's neighbour), `--no-show-signature`, author dates, every read bounded through the kernel's new `tryGit` (64 MiB), null on a shallow clone, no commits, no repository, or a failed read. - `engine baseline record <native|skipped>`: validated, refuses once recorded, writes under the project lock, commits confined to the project manifest — `commit --workflows` swept a peer session's dirty files under the verdict's message. Both Step 0.4 arms use it, each with the sibling failure clause. - Step 0.4 is the Baseline Judgment (CONVENTIONS' sub-step example too); native is scaffolding-only before the arrival, predating is application code and the history of building it — one binary question, no gap. - workflow-start's migration confirm and tmux opt-in menus move to the engine (`render migration-gate`, `render label-gate`) — touching a file adopts its menus. - Refusals name the status; stale "never started"/"offer" wording fixed in the baseline skill, scope-areas' back-out line, the offer-gate comment; docs and the design doc restated positively. - Prose harness: a `.git/prose-stamp.json` marker records what materialise stamped so the differ strips exactly that; a layered project manifest is stamped when its layer lands, so a case can put commits before the workflows' arrival. `start-records-a-native-verdict` is now Folio's shape (three scaffolding commits, then `.workflows/`); new `start-offers-the-baseline-on-a-predating-codebase` walks the offer and the decline. - Tests: the verb (`test-engine-baseline.cjs`), signal shapes (root arrival over a legacy tree, branched history, elision, showSignature, shallow, not-ready boot), the projection matrix, the boot gates, the harness stamp. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
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.
Summary
The baseline offer fired on Folio, a project created from scratch with the workflows. Boot reported
baseline: nonefor any project that never recorded a status, and workflow-start's Step 0.4 judged "does a codebase predate the workflows?" per boot from context, recording nothing on a "no" and telling the session to offer when in doubt. Every boot of a native project re-rolled the judgment; the Sep 2 roll went straight from the migration commit to the offer with no evidence gathered.The test is code precedence, read by cognition. Was there real development before the workflows arrived, or only setup? Boot hands the session the evidence and the prose asks for the read — no thresholds.
baseline_signalon anoneboot:history_before(the commits before.workflows/first landed, asdate subject, head and tail kept around one elision),files_at_arrival+tree_at_arrival(the project tree the workflows arrived into, top-level shape),commits_before/commits_total,root_date/workflows_date(null when nothing under.workflows/is committed yet). Ancestry-exact, signature-blind, author-dated, every read bounded through the kernel'stryGit; null on a shallow clone, no commits, no repository, or a failed read. Folio reads eight setup/wip commits over three days, seven files, a scaffold tree — native beyond doubt.nativeis a recorded status. Step 0.4 (now Baseline Judgment) records it when the project grew up on the workflows; the offer's decline recordsskipped. Both land throughengine baseline record <native|skipped>— validated, refuses once recorded, one write under the project lock committed confined to the project manifest (commit --workflowsswept a peer session's dirty files). Hidden on every menu but manage; the offer gate and the mid-flight surfaces refuse over it; the baseline skill treats it as never started.native; a.git/prose-stamp.jsonmarker records what was stamped so the differ strips exactly that; a layered project manifest is stamped when its layer lands, so a case can put commits before the arrival.start-records-a-native-verdictis Folio's shape; newstart-offers-the-baseline-on-a-predating-codebasewalks the offer and the decline.Design doc rewritten in place; CLAUDE.md, CONVENTIONS' sub-step example, the engine command docs and
docs/configuration.mdupdated. Reviewed by the eight-dimension finder fleet; every verified finding landed here.Test plan
npm test— 2769 pass (newtest-engine-baseline.cjs; signal shapes: brownfield history, root-commit arrival over a legacy tree, branched history, long-run elision,log.showSignature, shallow clone, no history, not-ready boot; boot gates; projection matrix; harness stamp round-trips and the layered-manifest world)npm run test:clinpm run typecheck/prose-testonstart-records-a-native-verdict,start-offers-the-baseline-on-a-predating-codebase, and the intersecting start cases🤖 Generated with Claude Code