context weight: free-tier prose cuts across six surfaces (~11,600 B) #101

Closed
opened 2026-08-10 14:49:01 +00:00 by john · 2 comments
Owner

~11,600 B off the eager path with no new files, no register rows, and no dependency on #1. Land these per-command, one commit per surface plus its budget re-pin — except the --tokens item, which is inherently cross-file.

Cuts

bytes where what
~2,900 tree-wide plan.md:182-189, context.md:122-144, execute.md:233-237, verify-deep.md:37-41, review-triggers.md:106-107 The --tokens provenance paragraph, duplicated five times. context.md:122 claims to state it "once, for every bracket in this plugin" — already false four ways. Move to lib/trace.mjs's header (zero token cost); each site keeps one imperative sentence. Keep everywhere: omit the flag when no figure exists, never --tokens 0, and a return carrying no figure is ROUTINE rather than a defect.
~2,050 skills/cad-land/SKILL.md:175-190, :44-49, :93-97, :115-118 Guardrails bullet 1 re-derives the git.auto_close mechanic given 50 lines above at :119-132; three deferral tails are maintainer cost-model prose. Keep: "No preselected publish default, ever. No auto-push. No auto-commit." and the "this read is NOT scoped to the GitHub arm" clause — that one stops the model skipping the read on GitLab. The compressed deferral form has in-repo precedent at skills/cad-plan-review/SKILL.md:38-39.
~1,780 execute.md:96-104, :245-253, :1-11 Lease-check placement justification (belongs beside the lease-check source); trace.jsonl gitignore/scaffold archaeology; <purpose> duplicating SKILL.md's <objective> in the same context, with lines 8-10 describing a design already removed. Keep: "a worktree executor emits no trace events of its own" — that is a rule.
~1,713 context.md:128-144, :366-370, :9-11, :13-15 Per-agent token figures and "read the three states apart"; clauses already carried by guardrails 413-421. Runtime rule is entirely in :122-127.
990 verify.md:2-11, :84-89 Purpose duplicating SKILL.md's objective clause-for-clause; the fields_version legacy paragraph, which is /cad-audit's and already lives at audit.md:71-75 and acceptance-criteria.md:181-191. Removing it also kills a live drift hazard — that five-term rule currently has four copies across two commands.
942 cad-planner-contract:167-175, cad-reviewer-contract:76-80, cad-plan-checker-contract:111-116 <success_criteria> checklists restating their own contracts item-for-item. conventions.md:141 scopes the section to workflows, and the executor, verifier and assumptions-analyzer contracts already ship without one. Cut reviewer's first — highest multiplier, shortest contract, easiest to reverse if compliance drops.
606 cad-health:107-113, :103-105 Membership-not-sort-order anti-regression note (move to a comment beside lib/branch-decision.mjs) and a v2.4.0 regression anecdote. The runtime rule is already unambiguous at :92-94 and :96-102.
439 plan.md:8-10, :329-333 Design-history contrast with a tool that is not here; a paragraph already verbatim in trace.test.mjs beside BRACKETING.
180 cad-executor-contract:44-46 Static-analysis carve-out stated in full twice (also :100-103). Cut the step-3 copy to a pointer at <deviation_rules>.

Constraints

  • weight-budgets.json pins exact bytes and undershoot fails CI as hard as overrun — every cut needs a same-commit re-pin.
  • Rationale that moves must land somewhere: a .mjs header or a design-note, both zero token cost. Rationale bound to a rule the model applies at runtime stays.
  • Check 10 (dispatch phrasing) binds plan.md:56-57, plan.md:104-107, context.md:77-78 — those sentences survive verbatim.

Risk

This is where the milestone can actually regress behaviour: roughly 9,000 B of what comes out is rationale, and this repo keeps rationale because removing it caused regressions before. Run /cad-verify on each affected command rather than bulk-editing — self-verify structurally cannot catch this.

~11,600 B off the eager path with no new files, no register rows, and no dependency on #1. Land these per-command, one commit per surface plus its budget re-pin — except the `--tokens` item, which is inherently cross-file. ## Cuts | bytes | where | what | |---|---|---| | ~2,900 tree-wide | `plan.md:182-189`, `context.md:122-144`, `execute.md:233-237`, `verify-deep.md:37-41`, `review-triggers.md:106-107` | The `--tokens` provenance paragraph, duplicated five times. `context.md:122` claims to state it "once, for every bracket in this plugin" — already false four ways. Move to `lib/trace.mjs`'s header (zero token cost); each site keeps one imperative sentence. **Keep everywhere:** omit the flag when no figure exists, never `--tokens 0`, and a return carrying no figure is ROUTINE rather than a defect. | | ~2,050 | `skills/cad-land/SKILL.md:175-190`, `:44-49`, `:93-97`, `:115-118` | Guardrails bullet 1 re-derives the `git.auto_close` mechanic given 50 lines above at `:119-132`; three deferral tails are maintainer cost-model prose. **Keep:** "No preselected publish default, ever. No auto-push. No auto-commit." and the "this read is NOT scoped to the GitHub arm" clause — that one stops the model skipping the read on GitLab. The compressed deferral form has in-repo precedent at `skills/cad-plan-review/SKILL.md:38-39`. | | ~1,780 | `execute.md:96-104`, `:245-253`, `:1-11` | Lease-check placement justification (belongs beside the lease-check source); trace.jsonl gitignore/scaffold archaeology; `<purpose>` duplicating `SKILL.md`'s `<objective>` in the same context, with lines 8-10 describing a design already removed. **Keep:** "a worktree executor emits no trace events of its own" — that is a rule. | | ~1,713 | `context.md:128-144`, `:366-370`, `:9-11`, `:13-15` | Per-agent token figures and "read the three states apart"; clauses already carried by guardrails 413-421. Runtime rule is entirely in `:122-127`. | | 990 | `verify.md:2-11`, `:84-89` | Purpose duplicating `SKILL.md`'s objective clause-for-clause; the `fields_version` legacy paragraph, which is /cad-audit's and already lives at `audit.md:71-75` and `acceptance-criteria.md:181-191`. Removing it also kills a live drift hazard — that five-term rule currently has four copies across two commands. | | 942 | `cad-planner-contract:167-175`, `cad-reviewer-contract:76-80`, `cad-plan-checker-contract:111-116` | `<success_criteria>` checklists restating their own contracts item-for-item. `conventions.md:141` scopes the section to workflows, and the executor, verifier and assumptions-analyzer contracts already ship without one. **Cut reviewer's first** — highest multiplier, shortest contract, easiest to reverse if compliance drops. | | 606 | `cad-health:107-113`, `:103-105` | Membership-not-sort-order anti-regression note (move to a comment beside `lib/branch-decision.mjs`) and a `v2.4.0` regression anecdote. The runtime rule is already unambiguous at `:92-94` and `:96-102`. | | 439 | `plan.md:8-10`, `:329-333` | Design-history contrast with a tool that is not here; a paragraph already verbatim in `trace.test.mjs` beside `BRACKETING`. | | 180 | `cad-executor-contract:44-46` | Static-analysis carve-out stated in full twice (also `:100-103`). Cut the step-3 copy to a pointer at `<deviation_rules>`. | ## Constraints - `weight-budgets.json` pins exact bytes and **undershoot fails CI as hard as overrun** — every cut needs a same-commit re-pin. - Rationale that moves must land somewhere: a `.mjs` header or a design-note, both zero token cost. Rationale bound to a rule the model applies at runtime stays. - Check 10 (dispatch phrasing) binds `plan.md:56-57`, `plan.md:104-107`, `context.md:77-78` — those sentences survive verbatim. ## Risk This is where the milestone can actually regress behaviour: roughly 9,000 B of what comes out is rationale, and this repo keeps rationale because removing it caused regressions before. Run `/cad-verify` on each affected command rather than bulk-editing — self-verify structurally cannot catch this.
john added this to the v2.6.2 milestone 2026-08-10 14:49:01 +00:00
Author
Owner

Re-measured against the current tree (post-2.7.0 + the retune branch). Six of the nine rows are already shipped:

  • ~2,900 --tokens provenance: DONE. Lives in lib/trace.mjs's header; every site keeps one imperative sentence.
  • ~1,780 execute.md: DONE. Purpose block rewritten to four non-duplicating lines, lease-check justification and trace.jsonl archaeology gone.
  • ~1,713 context.md: DONE. No per-agent token figures, no 'read the three states apart'.
  • 990 verify.md: DONE. Purpose is two terse lines, fields_version legacy paragraph gone.
  • 606 cad-health: DONE. Membership note and the v2.4.0 anecdote are gone.
  • 439 plan.md: DONE. Design-history contrast and the BRACKETING duplicate paragraph are gone.

Still outstanding, ~1,700 B of the original ~11,600:

  1. cad-land guardrails (was ~2,050, now less): the three deferral tails are gone, but git.auto_close still appears 12 times in the SKILL and the guardrails still re-derive the mechanic stated in the step body. Needs a fresh hand-measure; the keeps from the original scope stand (no-preselected-default block, the not-scoped-to-GitHub clause).
  2. plan-checker contract still carries its success_criteria checklist (~350 B); planner and reviewer lost theirs already.
  3. executor contract still states the static-analysis carve-out in full twice (:40 and :107, ~180 B); the step copy should become a pointer.

Scope is now small enough to ride any branch that touches those three files.

Re-measured against the current tree (post-2.7.0 + the retune branch). Six of the nine rows are already shipped: - ~2,900 --tokens provenance: DONE. Lives in lib/trace.mjs's header; every site keeps one imperative sentence. - ~1,780 execute.md: DONE. Purpose block rewritten to four non-duplicating lines, lease-check justification and trace.jsonl archaeology gone. - ~1,713 context.md: DONE. No per-agent token figures, no 'read the three states apart'. - 990 verify.md: DONE. Purpose is two terse lines, fields_version legacy paragraph gone. - 606 cad-health: DONE. Membership note and the v2.4.0 anecdote are gone. - 439 plan.md: DONE. Design-history contrast and the BRACKETING duplicate paragraph are gone. Still outstanding, ~1,700 B of the original ~11,600: 1. cad-land guardrails (was ~2,050, now less): the three deferral tails are gone, but git.auto_close still appears 12 times in the SKILL and the guardrails still re-derive the mechanic stated in the step body. Needs a fresh hand-measure; the keeps from the original scope stand (no-preselected-default block, the not-scoped-to-GitHub clause). 2. plan-checker contract still carries its success_criteria checklist (~350 B); planner and reviewer lost theirs already. 3. executor contract still states the static-analysis carve-out in full twice (:40 and :107, ~180 B); the step copy should become a pointer. Scope is now small enough to ride any branch that touches those three files.
john modified the milestone from v2.6.2 to v3.1.0 2026-08-12 16:37:08 +00:00
Author
Owner

Correction to the re-measure above: the plan-checker contract's success_criteria checklist is NOT outstanding - CTW-03's own row keeps it deliberately, asserted by prose-agreement.test.mjs:69-95 as the DFC-03 fix. The live remnant is the cad-land guardrails re-derivation and the executor contract's doubled static-analysis carve-out, now tracked as CTW-06 in the v3.1.0 requirements.

Correction to the re-measure above: the plan-checker contract's success_criteria checklist is NOT outstanding - CTW-03's own row keeps it deliberately, asserted by prose-agreement.test.mjs:69-95 as the DFC-03 fix. The live remnant is the cad-land guardrails re-derivation and the executor contract's doubled static-analysis carve-out, now tracked as CTW-06 in the v3.1.0 requirements.
john closed this issue 2026-08-13 15:32:18 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: crenshawdev/cadence-archived#101
No description provided.