@attalabs/vinaya 0.35.0 → 0.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/aeg-root/roles/planner/reference.md +20 -5
- package/aeg-root/roles/planner.md +2 -0
- package/aeg-root/roles/reviewer.md +3 -1
- package/aeg-root/templates/brief-template.md +4 -0
- package/dist/checks/bin/check-body-bare-digits.js +1447 -1350
- package/dist/checks/bin/check-branch-topology.js +1418 -1341
- package/dist/checks/bin/check-brief-shape.js +1448 -1351
- package/dist/checks/bin/check-changeset-coverage.js +1470 -1361
- package/dist/checks/bin/check-closes-n.js +1418 -1341
- package/dist/checks/bin/check-coherence.js +1459 -1352
- package/dist/checks/bin/check-dead-branch-push.js +1407 -1340
- package/dist/checks/bin/check-dispatch-readiness.js +1462 -1355
- package/dist/checks/bin/check-doc-coverage-push.js +1470 -1361
- package/dist/checks/bin/check-doc-coverage.js +1472 -1363
- package/dist/checks/bin/check-doctrine-no-procedures.js +1445 -1348
- package/dist/checks/bin/check-doctrine-portability.js +1470 -1361
- package/dist/checks/bin/check-evidence-fresh.js +1477 -1368
- package/dist/checks/bin/check-exec-bits.js +1471 -1362
- package/dist/checks/bin/check-first-push-dispatch.js +1461 -1354
- package/dist/checks/bin/check-issue-assignment.js +1418 -1341
- package/dist/checks/bin/check-issue-milestone-attach.js +1407 -1340
- package/dist/checks/bin/check-issue-objectives-numbering.js +1445 -1348
- package/dist/checks/bin/check-issue-parts-coverage.js +1407 -1340
- package/dist/checks/bin/check-issue-surface-globs.js +1461 -1354
- package/dist/checks/bin/check-issue-title-grammar.js +1407 -1340
- package/dist/checks/bin/check-issue-tranche-label.js +1407 -1340
- package/dist/checks/bin/check-main-branch-refusal.js +1409 -1342
- package/dist/checks/bin/check-no-disk-state.js +1409 -1342
- package/dist/checks/bin/check-pr-premise-reassert.js +1445 -1348
- package/dist/checks/bin/check-pr-report-density.js +1409 -1342
- package/dist/checks/bin/check-principal-test-plan-wait.js +1409 -1342
- package/dist/checks/bin/check-quoted-command.js +1468 -1359
- package/dist/checks/bin/check-reader-resolvable-prose.js +1468 -1359
- package/dist/checks/bin/check-registry-gates.js +1409 -1342
- package/dist/checks/bin/check-retired-vocabulary.js +1468 -1359
- package/dist/checks/bin/check-review-gate.js +1459 -1362
- package/dist/checks/bin/check-single-plan-pr.js +1407 -1340
- package/dist/checks/bin/check-surface-scope.js +1418 -1341
- package/dist/checks/bin/check-test-plan.js +1407 -1340
- package/dist/checks/bin/check-token-collection-wired.js +1409 -1342
- package/dist/checks/bin/check-token-report.js +1409 -1342
- package/dist/checks/bin/check-workspace-escape.js +1471 -1362
- package/dist/index.js +4029 -1880
- package/dist/lib/pre-push-cache-test-run.js +94 -14
- package/dist/lib/pre-push-select-tests.js +83 -15
- package/package.json +1 -1
- package/studio-standalone/_node_modules/@attalabs/aeg-core/src/dev-review-loop/assess-round.ts +24 -2
- package/studio-standalone/_node_modules/@attalabs/aeg-core/src/dev-review-loop/index.ts +1 -0
- package/studio-standalone/_node_modules/@attalabs/aeg-core/src/dev-review-loop/render-summary.ts +33 -10
- package/studio-standalone/_node_modules/@attalabs/aeg-core/src/dev-review-loop/types.ts +28 -0
- package/studio-standalone/_node_modules/@attalabs/aeg-core/src/index.ts +1 -0
- package/studio-standalone/_node_modules/@attalabs/aeg-core/src/issue-validation.ts +10 -0
- package/studio-standalone/apps/vinaya-studio/web/.next/BUILD_ID +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/build-manifest.json +3 -3
- package/studio-standalone/apps/vinaya-studio/web/.next/prerender-manifest.json +3 -3
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/_global-error.html +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/_global-error.rsc +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/_not-found/page/server-reference-manifest.json +2 -2
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/_not-found/page.js.nft.json +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/api/coherence/route.js.nft.json +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/page/server-reference-manifest.json +2 -2
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/page.js.nft.json +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/page_client-reference-manifest.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/backlog/page/server-reference-manifest.json +2 -2
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/backlog/page.js.nft.json +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/backlog/page_client-reference-manifest.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/page/server-reference-manifest.json +2 -2
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/page.js.nft.json +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/page_client-reference-manifest.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/projects/[name]/page/server-reference-manifest.json +2 -2
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/projects/[name]/page.js.nft.json +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/projects/[name]/page_client-reference-manifest.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/projects/[name]/tranches/[slug]/page/server-reference-manifest.json +3 -3
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/projects/[name]/tranches/[slug]/page.js.nft.json +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/projects/[name]/tranches/[slug]/page_client-reference-manifest.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/projects/[name]/tranches/[slug]/tasks/[taskId]/page/server-reference-manifest.json +2 -2
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/projects/[name]/tranches/[slug]/tasks/[taskId]/page.js.nft.json +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/projects/[name]/tranches/[slug]/tasks/[taskId]/page_client-reference-manifest.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/projects/page/server-reference-manifest.json +2 -2
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/projects/page.js.nft.json +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/projects/page_client-reference-manifest.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/tranches/page/server-reference-manifest.json +2 -2
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/tranches/page.js.nft.json +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/app/studio/tranches/page_client-reference-manifest.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/1q96_modules_@clerk_nextjs_dist_esm_app-router_client_keyless-creator-reader_0lom2js.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/[root-of-the-server]__074w9nf._.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/[root-of-the-server]__0ls23oh._.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/[root-of-the-server]__1gjqmhq._.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/[root-of-the-server]__1wc4-ip._.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/{[root-of-the-server]__0zc_0gx._.js → [root-of-the-server]__1wy7w66._.js} +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/_08onyya._.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/_096f46i._.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/_0af2one._.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/_0e5tkdd._.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/_0kf2g72._.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/_0zf4d27._.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/_1-wo68i._.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/_1achbh9._.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/chunks/ssr/node_modules_@clerk_nextjs_dist_esm_app-router_server-actions_1x7vfhn.js +2 -2
- package/studio-standalone/apps/vinaya-studio/web/.next/server/middleware-build-manifest.js +3 -3
- package/studio-standalone/apps/vinaya-studio/web/.next/server/pages/500.html +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/server-reference-manifest.js +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/server/server-reference-manifest.json +4 -4
- package/studio-standalone/apps/vinaya-studio/web/.next/static/chunks/00z3-ljjd1gj9.js +1 -0
- package/studio-standalone/apps/vinaya-studio/web/.next/static/chunks/{3goaig_rysc6p.js → 2o9l0b7eqbr57.js} +1 -1
- package/studio-standalone/apps/vinaya-studio/web/.next/static/chunks/{3ip5z3cf43bgo.js → 3lqjwjrcvq481.js} +1 -1
- package/studio-standalone/apps/vinaya-studio/web/package.json +2 -2
- package/studio-standalone/apps/vinaya-studio/web/.next/static/chunks/3u9emqjwpd0t9.js +0 -1
- /package/studio-standalone/_node_modules/@attalabs/vinaya/studio-standalone/_node_modules/@attalabs/vinaya/studio-standalone/_node_modules/@attalabs/vinaya/studio-standalone/_node_modules/@attalabs/vinaya/studio-standalone/_node_modules/@attalabs/vinaya/studio-standalone/_node_modules/@attalabs/vinaya/studio-standalone/_node_modules/@attalabs/vinaya/studio-standalone/_node_modules/@attalabs/{aeg-core → vinaya/studio-standalone/_node_modules/@attalabs/aeg-core}/bin/verify-coherence.ts +0 -0
- /package/studio-standalone/apps/vinaya-studio/web/.next/static/{ca66rAHI_w9D7S7ceXDvR → z1fTSBP6ZlUjObzFIp-qq}/_buildManifest.js +0 -0
- /package/studio-standalone/apps/vinaya-studio/web/.next/static/{ca66rAHI_w9D7S7ceXDvR → z1fTSBP6ZlUjObzFIp-qq}/_clientMiddlewareManifest.js +0 -0
- /package/studio-standalone/apps/vinaya-studio/web/.next/static/{ca66rAHI_w9D7S7ceXDvR → z1fTSBP6ZlUjObzFIp-qq}/_ssgManifest.js +0 -0
|
@@ -111,8 +111,8 @@ This rationale is the **producer side of the `aeg-root/contracts/planner-develop
|
|
|
111
111
|
- **Durable** (goes in the rationale): why this is one task and not three; the dependency rationale; the sizing conclusion; which shared packages and consumers are in the blast radius; known traps to avoid; the suggested agent-class; stop-and-escalate conditions. These do not change before the task runs.
|
|
112
112
|
- **Perishable** (do NOT put in the rationale — it belongs in the just-in-time brief): exact function signatures, precise file lists, line-level specifics. These go stale as earlier tasks merge, so the dispatch act's render re-derives them at dispatch time, against the tree as it then stands.
|
|
113
113
|
|
|
114
|
-
**Required fields in every Planner's rationale block** (these are the contract's producer fields — emit all eight). **Start from the template file:** copy `aeg-root/templates/issue-rationale-template.md` into the Issue body and fill each placeholder — it packages all eight fields in the rationale grammar, so you never reconstruct the shape from prose; the field definitions below remain the source of truth for content. **Write them in the rationale grammar** — either `**<Field>** — …` bold-inline or `### <Field>` heading, one of the two, so the field is machine-detectable. See "Rationale grammar" below for the full format spec; `verify-coherence`'s R1 check re-runs the same grammar continuously against the live Issue stock, and the ring-0 gate (`bin/open-issue.ts`) refuses a task Issue whose body fails it at creation time. **Beyond presence, the same gate grades three things about the content and refuses on each:** the declared surface may not reach a shared collision domain (live-derived `packages/*` workspace members + built-in cross-cutting defaults, plus any `vinaya.config.json` `blastRadius.extraDomains` entries) that no declared project owns without a second **registered** project or a `blast-radius-ack:` line — this is the shared-package blast-radius rule below, mechanized; the body may carry no brief-shaped section (`## References`, `Technical surface map`, `Premise`, `Step 0`, `Test Plan`) — brief content belongs in the brief; and **Docs to keep coherent** / **Traps to avoid** must name a concrete doc or skill path, or the explicit `no-doc-surface` sentinel. That last one exists because nothing else makes you read the surface you are planning: the skill-check hook fires on file edits, and cutting an Issue edits no file.
|
|
115
|
-
- **Boundary** — what this task is and, crucially, what it is *not* (what was deliberately split out).
|
|
114
|
+
**Required fields in every Planner's rationale block** (these are the contract's producer fields — emit all eight). **Start from the template file:** copy `aeg-root/templates/issue-rationale-template.md` into the Issue body and fill each placeholder — it packages all eight fields in the rationale grammar, so you never reconstruct the shape from prose; the field definitions below remain the source of truth for content. **Write them in the rationale grammar** — either `**<Field>** — …` bold-inline or `### <Field>` heading, one of the two, so the field is machine-detectable. See "Rationale grammar" below for the full format spec; `verify-coherence`'s R1 check re-runs the same grammar continuously against the live Issue stock, and the ring-0 gate (`bin/open-issue.ts`) refuses a task Issue whose body fails it at creation time. **Beyond presence, the same gate grades three things about the content and refuses on each:** the declared surface may not reach a shared collision domain (live-derived `packages/*` workspace members + built-in cross-cutting defaults, plus any `vinaya.config.json` `blastRadius.extraDomains` entries) that no declared project owns without a second **registered** project or a `blast-radius-ack:` line — this is the shared-package blast-radius rule below, mechanized; the body may carry no brief-shaped section (`## References`, `Technical surface map`, `Premise`, `Step 0`, `Test Plan`) — brief content belongs in the brief; and **Docs to keep coherent** / **Traps to avoid** must name a concrete doc or skill path, or the explicit `no-doc-surface` sentinel. That last one exists because nothing else makes you read the surface you are planning: the skill-check hook fires on file edits, and cutting an Issue edits no file. Two further checks grade collisions — a file-count one that refuses a large undeclared overlap, and a domain-level one that only warns:
|
|
115
|
+
- **Boundary** — what this task is and, crucially, what it is *not* (what was deliberately split out). It also names the **real in-scope files** the task touches: those are what the brief render turns into its §4 surface map and pins in `**Premise:**`, so a Boundary that names no file the `## Surface` `in:` glob resolves to renders no premise pin and the brief render refuses (`## Parts`, by contrast, names outcomes and symbols only — never a path).
|
|
116
116
|
- **Sizing** — that it passed the four "too big?" tests (or how a larger candidate was split).
|
|
117
117
|
- **Project(s) + blast radius** — every project touched, and for shared-package changes, which consumers are in the blast radius and whether each needs re-verification or edits.
|
|
118
118
|
- **Dependency rationale** — *why* each `depends-on` / `conflicts-with` edge exists (not just that it does). For a `conflicts-with` edge, "why" means the overlap itself: name the specific file(s) or path both tasks touch — on both sides of the edge, so either task's reader can see what it collides with. An edge with no nameable overlap is not a valid edge: drop it, or, if you suspect a coupling you cannot yet name, raise it as a calibrated warning ("Possible undeclared cross-package coupling" below) instead of hard-serializing on a hunch. **Write it bold-inline only, exactly `**Dependency rationale** — …`** — no colon inside the bold, no heading form. This one field has a downstream consumer beyond the creation gate (`amendRationaleDeps`, the only sanctioned way to edit these edges after creation) that locates it by that exact anchor; see "Rationale grammar" below for why.
|
|
@@ -136,12 +136,20 @@ A ready-to-fill skeleton of the full eight-field rationale lives at `aeg-root/te
|
|
|
136
136
|
|
|
137
137
|
A task Issue's body must carry all eight fields in one of these two forms. **Canonical implementation:** `checkIssueRationale`/`isTaskIssueLabelSet`, exported from `@attalabs/aeg-core` — the single grammar/parser, consumed at two enforcement points per `aeg-root/enforcement.md`'s ring model:
|
|
138
138
|
|
|
139
|
-
- **Ring 0 (creation gate):** `vinaya issue create`/`vinaya issue edit` refuses to create or edit a task Issue (any Issue labeled `vinaya/tranche:<slug>`) whose body fails `checkIssueRationale`. **It also refuses on
|
|
139
|
+
- **Ring 0 (creation gate):** `vinaya issue create`/`vinaya issue edit` refuses to create or edit a task Issue (any Issue labeled `vinaya/tranche:<slug>`) whose body fails `checkIssueRationale`. **It also refuses on content checks, which grade what the fields *say* rather than that they exist:**
|
|
140
140
|
- `checkBlastRadiusScope` — if **Boundary** or **Project(s) + blast radius** names a path under a collision domain that none of the declared projects owns (ownership resolves against `.vinaya/projects.md`), the Issue must declare a second **registered** project or carry a `blast-radius-ack: <why one lens is enough>` line. `Project(s)` drives the review fan-out, so an under-declared blast radius under-governs the change. **Registered is the operative word:** a name with no row in `.vinaya/projects.md` buys no review lens, so it cannot buy the bypass either — the check filters declared names against the registry before counting them. The domain list itself is live-derived (every `packages/*` workspace member — `package.json`'s `workspaces`, or `pnpm-workspace.yaml`'s `packages:` list on a pnpm repo) plus a built-in cross-cutting default set (lockfile, monorepo config, CI, git hooks), with `vinaya.config.json`'s `blastRadius.extraDomains` adding anything beyond those — see `blast-radius-domains.ts`. The legacy static `.aeg/packages` file is retired; it is no longer read. Dormant only when none of those sources yields any domain at all, which a real repo essentially never hits.
|
|
141
141
|
- `checkNoBriefContent` — the body must carry no `## References`, `Technical surface map`, `Premise`, `Step 0`, or `Test Plan` section. Those are brief artifacts, produced by the dispatch act's render, never hand-written into the Issue — an Issue is not a brief's home (it would go stale before work starts).
|
|
142
142
|
- `checkRationaleNamesDocs` — **Docs to keep coherent** and/or **Traps to avoid** must name at least one concrete doc path (`aeg-root/…`, `.claude/skills/…`, `.claude/rules/…`, `apps/<x>/CLAUDE.md`, `apps/<x>/specs/…`, a repo-level `*.md`). A genuinely doc-less surface uses the explicit `no-doc-surface` sentinel — the same shape as `Test Plan: unit-tests-only`. This is the only read-obligation signal a forge write leaves: the skill-check hook fires on file edits, and cutting an Issue edits no file.
|
|
143
143
|
|
|
144
|
-
|
|
144
|
+
<!-- AEG:CLAIM: packages/aeg-core/src/issue-validation.ts contains:export const DEFAULT_COLLISION_THRESHOLD = 3 -->
|
|
145
|
+
- `checkFileCollisions` — **collisions are counted in files, and the count decides.** The Issue's **Boundary** `Pinned files:` list is compared against the pinned files of every other open task Issue in the repository and the changed files of every open pull request. Share `planning.collisionThreshold` files or more (default three) with one of them, and declare no `Conflicts-with` edge naming it in either direction, and the write is refused, naming the other task and every shared file. Share fewer, and the Issue is accepted with each shared file and the task it is shared with printed as a warning — **a small overlap runs in parallel**, because a merge conflict over one or two files costs minutes while serializing a task costs a whole dispatch, and the task that merges second resolves it. A threshold of `0` turns the refusal off and leaves only the warning. The same comparison runs at dispatch, against open pull requests only — by then the other Issues are plans, not edits — and prints the same warning or refusal. Only the first fifty open pull requests are read, so a busy repository never makes `issue create` crawl; when that bound is reached the output says so.
|
|
146
|
+
|
|
147
|
+
Three more of them close the **forced-companion** gap — the file a change is forced to touch that the Surface forbids. You no longer have to remember these while writing a Surface; the gate decides them from the Issue text and the tree, and each refusal names the exact directory glob to add:
|
|
148
|
+
- `checkIntroducedCommandsCovered` — an Objective or Part that introduces a CLI flag or command (a **backticked** `--name`, or a backticked invocation of a command the command reference does not carry) while no `## Surface` `in:` glob reaches the command reference. The reference row is a forced edit; a Surface that excludes it forbids the only change that clears review. Free prose is never matched, and a leaf command followed by a further word reads as an argument rather than a new subcommand (`vinaya check <a-check-name>` introduces nothing). The binary may be capitalised — `Vinaya check` is the same invocation — but a Title-Cased word run after it reads as a proper name and not a command, because that is how a workflow or product name is written (`Vinaya Body Checks` is a CI workflow, not a subcommand). A **flag** is additionally excused when the tracked tree already ships it, however stale its row may be — you are not the task that has to write a row for a flag someone else shipped. A **command** is never excused that way: a command's name is an ordinary word the tree contains for a dozen unrelated reasons, so the reference — the registry the router is itself tested against — is the whole question.
|
|
149
|
+
- `checkIntroducedConfigKeysCovered` — the same rule for a **backticked** dotted configuration key the reference does not carry and the tree does not already ship, against the two files a new key forces: the configuration reference and the configuration schema. The refusal names whichever of the two globs is still missing. It reads the token, never the sentence around it: any backticked dotted token counts, including one whose **root segment** the reference has never carried, so there is no wording that evades the rule and none you have to remember to use. What excuses a token is a fact, not a phrase — the reference already documents it (as its own row, as the row of the key it instantiates like `checks.<your-check>.timeoutMs`, or inside its parent's prose), or the tracked tree already spells it out, which is what every dotted token about existing code does. What is left is a dotted token naming something this repository has never had.
|
|
150
|
+
- `checkPinnedFileImportersCovered` — a Boundary that pins a file other tracked sources import, where **none** of those importers is reachable from `in:` and none is named in the Boundary's own `Out:` clause. Changing a file almost always forces its call sites to change with it; the rule asks you to decide — widen `in:`, or write in the Boundary that the importer stays out — rather than leaving the Developer to discover the contradiction after Step 0. A `## Surface` `out:` glob is **not** that decision: it claims the directory is untouched, which is exactly what a forced call-site edit contradicts, so only the Boundary's own `Out:` clause excuses an importer. One importer inside the Surface is enough: the task already reaches its call sites.
|
|
151
|
+
|
|
152
|
+
A further check, `checkConflictCompleteness`, **warns and never blocks**: two open task Issues naming the same collision *domain* — a whole package — with no mutual `Conflicts-with` edge. Kept alongside the file-count check above, not replaced by it: a domain overlap that shares no pinned file at all is still worth a hint, and it is only ever a hint, because naming a package is not the same as naming a file.
|
|
145
153
|
- **Ring 1/2 (continuous oracle):** `vinaya check coherence`'s **R1** check re-runs the same function against the live stock of open task Issues, catching bodies edited by ungated writers or predating the gate. Pre-grammar Issues are grandfathered by explicit Issue number (`R1_GRANDFATHERED_ISSUES`, `@attalabs/aeg-core`) — visible as `info`, never blocking.
|
|
146
154
|
|
|
147
155
|
R1 checks **presence/structure only**; whether the content is correct (sizing actually right, traps actually real) stays the Reviewer's judgment, never CI's.
|
|
@@ -154,6 +162,12 @@ R1 checks **presence/structure only**; whether the content is correct (sizing ac
|
|
|
154
162
|
- **`## Test plan`** — either the `Test plan: unit-tests-only` sentinel, or a fenced command list (one command per line, each with `→ <expected observable>`) plus any `**[principal]**` items.
|
|
155
163
|
- **`## Stop conditions`** — a bullet list of the conditions under which the executing agent must stop and escalate.
|
|
156
164
|
|
|
165
|
+
**A fifth section, `## Premises` — optional, and the only sanctioned way to state a fact about the code.** A premise is one line, `` `<path>` contains `<text>` ``, and it is checked, not trusted: `vinaya issue create`/`vinaya issue edit` evaluate every premise that is due now against the checkout and refuse the Issue naming the one the file does not hold, and the dispatch render evaluates every premise again — the deferred ones included — against the default branch and refuses preparation the same way. The dry render those commands run to grade the brief is not a third premise check: premises at plan time belong to the write gate above, which reads the working tree and knows which premises are due, so a passing dry render never means a premise went unchecked. Write one premise per fact your dig established; the rendered brief lists them under their own heading so the Developer reads them as checked facts rather than as more of your prose.
|
|
166
|
+
|
|
167
|
+
- **A fact another task has yet to make true** is written `` after #<n>: `<path>` contains `<text>` ``. It is not checked when the Issue is cut — the code does not hold it yet, by construction — and is accepted only when the Issue also declares `Depends-on` on `#<n>`; the dispatch check then asserts it before the Developer starts. This is what a task whose surface depends on a sibling's output says instead of describing the coupling in prose.
|
|
168
|
+
- **A Boundary that states the code's current shape must carry a premise.** The words `already`, `currently` and `wired` are the trigger: a Boundary using any of them, with no `## Premises` section on the Issue, is refused. The refusal is never "do not write this" — it is "write it as a premise too". This exists because a Boundary once stated a cancellation signal was "already wired, currently inert"; nothing fed it, and the task ran about 20 hours through five review rounds and two Principal rulings before the gap closed.
|
|
169
|
+
- **Never assert a fact about the code in prose when a premise can carry it.** Prose goes stale silently; a premise refuses the Issue, and then the dispatch, the moment it stops being true. A premise path is repository-relative and inside the repository; the predicate is `contains` and nothing else — this is a pin format, not a query language.
|
|
170
|
+
|
|
157
171
|
The dispatch act's render **starts from** this rationale and adds only the just-in-time perishable detail it derives mechanically from the tree. The rationale is the planner's thinking, carried forward — not re-thought.
|
|
158
172
|
|
|
159
173
|
### Agent/model selection: class at plan time, final pick at dispatch time
|
|
@@ -190,6 +204,7 @@ These encode failure modes an external review panel flagged. They are split into
|
|
|
190
204
|
- **Planning without reading the relevant docs.** If asked to emit a task list before having read the relevant specs/skills/docs for the surfaces in scope → refuse: *"Read obligation not satisfied — I haven't read the docs for this surface. I cannot identify which docs each task will make incoherent without reading them first. Let me read them now."* The read obligation is conditional on docs existing; if none exist for a surface, it is trivially satisfied — but you must confirm that, not skip the check.
|
|
191
205
|
- **Sizing without reading the code.** If asked to produce a task list without access to (or having read) the relevant code → refuse: *"I can't size these without reading the code — sizing blind produces oversized tasks and missed cross-package coupling. Let me read it first."* (See the mandatory deep-dig section.)
|
|
192
206
|
- **A task missing its Planner's rationale.** If asked to emit a task with no rationale block → refuse: *"Every task carries a Planner's rationale — boundary, sizing, blast radius, traps, agent-class, stop conditions. Without it the brief re-derives my work cold and the agent walks into traps I already found."*
|
|
207
|
+
- **A cut or edited Issue whose brief does not render.** Planning is complete only when `vinaya brief render` succeeds for every Issue you cut or edit — a passing dry render, not a well-formed rationale alone, is the definition of a planned task. `vinaya issue create --validate-only` and `vinaya issue edit --validate-only` render the SAME brief the dispatch act will, in every repository (an adopter that installs Vinaya from the registry included), and refuse the exact bodies `vinaya task run` would refuse at brief render — a Boundary that pins no in-scope file, a whole-suite Test plan line, a Surface glob that resolves to nothing. Catch those at the cut/edit, not at dispatch. If the dry render refuses → fix the Issue and re-render; the task is not planned until it passes. (The validated write path runs this render for you; run `vinaya brief render <tranche> <n>` yourself to confirm any Issue you changed by another route.)
|
|
193
208
|
- **A shared-package change that lists only the driving consumer.** If a task changes a shared package but `Project(s)` omits the other consumers in its blast radius → refuse and correct: *"This changes shared package X; consumers Y and Z run on it and must be in Project(s) so the Reviewer verifies them. Adding them."*
|
|
194
209
|
- **Dispatching a task whose Issue column is `#TBD` or blank.** If asked to mark a task ready for dispatch or execution while its Issue column in the topology file still reads `#TBD` or is blank → refuse: *"Task <id> has no forge Issue (`#TBD`) — it is backlog, not dispatchable. Cut the Issue first, record the number in the topology table, and then it is dispatchable."* Cutting the Issue is the backlog → todo promotion; it cannot be delegated to the dispatch act or the Developer. The dispatch act's own gate (below) and the Developer (entry gate item 3) both hard-STOP on `#TBD` — do not hand them a task you haven't promoted.
|
|
195
210
|
- **Execution metadata in the plan.** If asked to add `status`, `PR #`, `merged date`, `current state`, assignee history, or generated collision data to the tranche file or an Issue → refuse: *"That's execution state — it lives in the forge, not the plan. The file is topology; status is `gh pr list`. Adding it here recreates the racing status store we removed."*
|
|
@@ -198,7 +213,7 @@ These encode failure modes an external review panel flagged. They are split into
|
|
|
198
213
|
- **Rationale in the thin file.** If asked to write the Planner's rationale into the tranche `.md` → refuse: *"The rationale belongs on the Issue body. The thin file is topology-only: Issue link + edges. I write the rationale onto each Issue; the file row carries only the number and edges."*
|
|
199
214
|
- **A brief hand-written into the Issue body.** If asked to write the full brief into the Issue body → refuse: *"The brief is rendered mechanically by the dispatch act and posted frozen as this Issue's own `aeg:brief:v1` comment — never hand-written into the Issue body, which would go stale before work starts."* (Note: the Planner's *rationale* belongs in the Issue body; the *brief* lives in a comment on that same Issue, never hand-authored. The rationale is durable conclusions; the brief is perishable execution detail, machine-rendered from it.)
|
|
200
215
|
- **Planning metadata on an Issue.** Priority, estimates, points, roadmap fields → refuse: *"That's roadmap planning — it stays in the company's planning tool / the roadmap. The Issue carries deps, conflicts, project, ticket link, and the Planner's rationale, nothing else."*
|
|
201
|
-
- **A "conflict scanner."** If asked to build or rely on a script that checks out in-flight branches and diffs them to catch undeclared conflicts → refuse: *"That needs a live task→files map — the mutable state we eliminated. The sanctioned answer to conflict uncertainty is to declare the conflict and serialize, not to scan."*
|
|
216
|
+
- **A "conflict scanner."** If asked to build or rely on a script that checks out in-flight branches and diffs them to catch undeclared conflicts → refuse: *"That needs a live task→files map — the mutable state we eliminated. The sanctioned answer to conflict uncertainty is to declare the conflict and serialize, not to scan."* This does not cover `checkFileCollisions` above: comparing a task Issue's own declared **Boundary** `Pinned files:` against the forge's own list of what each open pull request changed reads two already-published facts — it checks out no branch, diffs nothing, and stores no task→files map between runs.
|
|
202
217
|
- **Unregistered project** or a `Project:` that doesn't resolve against `projects.md` → refuse (see entry gate). Mechanized by `checkProjectsRegistered`; the gate refuses before the Issue reaches the forge.
|
|
203
218
|
- **Dispatch against an unmet gate** — if asked to mark a task ready while its `depends-on` isn't merged, or while a `conflicts-with` sibling's PR is open → refuse: *"Gate not satisfied — this serializes behind <task>."*
|
|
204
219
|
- **A "Docs to keep coherent" field written without the derivation run.** Before emitting any task's **Docs to keep coherent** field, derive it against `.vinaya/doc-owners`, during Dig: take the task's real intended surface globs and match each one against every binding's own glob by segment-wise overlap, not exact-string match — a blanket binding (e.g. an entire app's `apps/<app>/**` bound to its `CLAUDE.md`) fires even when the task's surface doesn't spell that exact path out. Record and paste the union of fired pointers, or the explicit zero-match line. If asked to emit the field from a content grep or from memory → refuse: *"Doc derivation not run — a content grep says nothing about whether a blanket path-glob binding will fire at PR-open (C5). Deriving against `.vinaya/doc-owners` now."* This has no shipped `vinaya` subcommand yet — `deriveSection7`'s logic lives in `@attalabs/aeg-core` with no CLI entry point of its own. **On this repo's toolchain,** `bun packages/aeg-core/bin/verify-dispatch.ts <tranche> <n> --surfaces <glob1,glob2,...>` runs the derivation above and prints exactly that; where it isn't available, do the glob-match by hand and paste your own working — a content grep alone is not the same check and does not satisfy this gate. The field definition above ("Docs to keep coherent") holds the why; this gate holds the derivation and the paste.
|
|
@@ -44,6 +44,8 @@ You turn an intent and a slice of work into a whole tranche — not one task, an
|
|
|
44
44
|
|
|
45
45
|
**How it physically runs** — cutting the issues is a forge action, so most planning commits nothing: no branch, no worktree, no plan pull request. When a plan also writes a file — a spec change, most often — it reaches main as every change does: worktree, branch, pull request, green checks. Only one plan pull request per tranche may be open at once. You plan out loud, stage by stage, and say plainly when dispatch is the Principal's to trigger.
|
|
46
46
|
|
|
47
|
+
**A task is planned only when `vinaya brief render` passes** for every Issue you cut or edit — its Boundary naming real in-scope files, `## Parts` never a path.
|
|
48
|
+
|
|
47
49
|
|
|
48
50
|
---
|
|
49
51
|
|
|
@@ -165,7 +165,9 @@ The `SCOPE:` line, and any blast-radius assertion under check 7, are evidence-ba
|
|
|
165
165
|
|
|
166
166
|
VERDICT is `REQUEST CHANGES` if and only if at least one BLOCKER finding exists. Otherwise VERDICT is `APPROVE`, with every MAJOR and MINOR finding still listed under FINDINGS — an APPROVE is not silence about them, it is a statement that none of them blocks. (A REQUEST CHANGES sets the PR's review decision to `CHANGES_REQUESTED`, which is the derived `changes-requested` status — no one writes it down.) You do not type that decision by hand: `vinaya review post` derives it from the findings file you pass it — REQUEST CHANGES iff a BLOCKER is present, APPROVE otherwise — and renders the bare `VERDICT:` line and the `Judged head:` binding itself. `--verdict` is optional; if you pass one anyway, the command refuses before posting anything when it disagrees with the derivation, naming the derived value. It refuses to exit 0 unless its own post re-parses clean through the gate's extractors. The severity you assign to each finding is caller-asserted and not checked — the derivation trusts your severities, not your arithmetic. A finding whose own `file:line` names the PR body, a comment, or a role file is capped to MINOR by the policy evaluator before it counts toward the threshold, regardless of the severity you assign it — write its real severity anyway; the cap is applied for you, never something to pre-empt by under-reporting.
|
|
167
167
|
|
|
168
|
-
A
|
|
168
|
+
**A finding blocks only where the Developer can act on it this round (`convergence-v1` task 1).** Beyond the prose cap above, the dev-review-loop and the merge gate defer — report, but do not let block — two kinds of finding, through one shared decision (`classifyFinding`, `@attalabs/aeg-core`). A finding whose file the task's `## Surface` `in:` list does not cover is deferred in ANY round, with no exception: a finding outside the Surface never blocks. And from round 2 on, a finding on a line that did not change between the previous round's head and the current head is deferred too — EXCEPT a security finding at or above HIGH, which blocks wherever it sits. A deferred finding keeps the severity you assigned it — it is real, this round just cannot act on it — and is listed, with its severity, `file:line` and the reason it was deferred, in the round's published summary and (when the gate is given the same context) the gate's own output. This is why you still write a finding's real severity: whether it blocks THIS round is decided for you, from the Surface and the round-to-round diff, never from how you rank it. Opening a follow-up Issue for a deferred finding is a separate step, not yours to do here.
|
|
169
|
+
|
|
170
|
+
A re-review (a fresh-context reviewer invoked again after the Developer pushes fixes) does two things, in order. First, it reports the state of every prior id — `F1`, `F2`, … — before listing any new finding, one of exactly `open`, `fix-claimed`, `reproduced`, or `resolved` per id, confirmed by re-checking the artifact, never by assuming a push means a fix. For a prior doc-correctness finding, "re-checking the artifact" means re-running its `Search:` pattern at the new head, with no path filter, and reading every hit; the finding is resolved only when every remaining hit is a true statement, and a still-false sibling copy keeps the original id open rather than becoming a new finding. Write that state directly in the finding's own description, `F<n> <class> <state>: <text>` — that is what `vinaya review post` reads back on the next round to confirm every prior id is still accounted for; a findings file that drops a prior id with no state token is refused before posting. An id is assigned once, when a finding is first reported, and never renumbered; rewording a finding's description does not create a new id. The prior ids and the previously judged head are read from the prior verdict comment on the PR: its FINDINGS list and its `Judged head:` line. Every prior objective reappears too — the same rule, one level up: a re-review's `--objectives-file` that drops a prior `O<n>` is refused before posting, the id read from the prior comment's own `OBJECTIVES:` block. Second, round two is delta-only for every non-blocking severity: it judges only the lines changed since the previously judged head, and `vinaya review post` refuses a MAJOR or MINOR finding whose `file:line` falls outside that diff. A BLOCKER outside the delta is still accepted and still drives the verdict `vinaya review post` derives — but note that the dev-review-loop and the merge gate then defer any finding, BLOCKER included, that sits on a line unchanged since the previous round's head or in a file outside the Surface (the exception being a security finding at or above HIGH), so a deferred finding is reported without blocking the round (see "A finding blocks only where the Developer can act on it this round," above). A prior BLOCKER you mark `resolved` keeps its BLOCKER severity in the record but no longer drives the verdict — `vinaya review post` derives the verdict only from findings not marked `resolved`; mark `fix-claimed` or `reproduced` instead if it is not actually fixed. After round two the Principal decides; there is no round three unless the Principal orders it.
|
|
169
171
|
|
|
170
172
|
## Escalation
|
|
171
173
|
|
|
@@ -28,6 +28,10 @@ You are the AEG Developer. Run `vinaya doctrine --role developer --print` and re
|
|
|
28
28
|
|
|
29
29
|
[Copied verbatim from the Issue's own `## Documentation` section — every normative source this task depends on (a doc URL, an in-repo spec), each against the mechanism it governs: `- <source> — <mechanism>`. A task with no externally-normative source states the explicit `None` sentinel instead of an empty section. Placed immediately after Objectives, before the Developer holds a complete plan, so it is read first rather than skimmed as appendix evidence after the fact. Every source named here must be read before Step 0 — `aeg-root/roles/developer.md`'s entry gate names the obligation; a `PostToolUse`/`Stop` hook pair enforces it mechanically, not the Developer's own judgement.]
|
|
30
30
|
|
|
31
|
+
## Premises
|
|
32
|
+
|
|
33
|
+
[Copied from the Issue's own `## Premises` section — one line per fact about the code this plan rests on, written `` `<path>` contains `<text>` `` and optionally prefixed `after #<n>:` for a fact a declared dependency has yet to make true. Every line was asserted against the checkout when the Issue was cut and asserted again against the default branch immediately before this render, so read them as checked facts, not as claims to re-verify by hand. A task whose Boundary states nothing about the code as it stands carries no premise and the heading is omitted. Distinct from §4's `**Premise:**` pins, which pin the surface files' current bytes rather than the plan's own facts.]
|
|
34
|
+
|
|
31
35
|
## 2. Context — read before doing anything
|
|
32
36
|
|
|
33
37
|
- **Tranche:** [`tranche-slug`], task [n], Issue #[N]. Branch `task/[tranche-slug]/[n]`. `Depends-on: [—|ids]`, `Conflicts-with: [—|ids]`. Confirm dispatch readiness at your own Step 0, with the command §5 names.
|