One improvement procedure over atomic instructions

Type: reference/types/design-proposal.md · Tags: review-system, kb-maintenance

Commonplace has three ways to improve one note after review: the full improvement pass, the fix procedure for review warnings, and the simplification passes. All three do the same thing. They review the note with some operations, choose edit operations from what the review found, apply them within bounds, review again, and stop for an operator where authority requires it. They do it from the same ingredients, atomic instructions of three kinds:

  • Review operations: the gate criteria, and the full pass's method families (critique, compression, composition friction, premise decomposition, connect).
  • Edit operations: the simplification passes, and the fix strategies keyed to warning kinds.
  • Stops: strike lists, the publication approval, the hand-back dispositions.

The goal is one procedure in their place. It is flexible because it is mostly LLM instructions. It is held in shape by the infrastructure every other artifact already uses: types, schemas and commonplace-validate. Code stays only where batching needs it, in review.

Current state (as of 2026-11-16)

Adopted: catalog gates, type/collection conformance, the four compression checks, and the critique, composition-friction, premise-decomposition and compression-synthesis reports share typed results, retained observations and single-assessment fixtures under ADR 132. That bounded execution/result slice is shipped, not proposed below. The synthesis takes its findings as supplied files and keeps no current result. Connect keeps its own report.

Adopted: edit operations are typed atoms under ADR 133. Six simplification passes and the fix strategies, wrapped as one operation, declare the edit-operation type. Each runs alone through commonplace-review run edit and returns a typed edit result, retained with its exact inputs and rerunnable from a fixture. The revise workflow runs every pass through that route. This departs from the design below, which has a session agent run edit operations: a code route keeps the inputs needed to rerun one operation.

Adopted: stops record the operator's answers in one typed file under ADR 134. An answers file holds one item per decision, pending, approved, rejected or deferred, and names its question by hash; the validator checks it against the question. Two stop instructions serve a session agent with the operator: decide items for a list of proposals and approve a text for publication. The per-item edit operations read answers; the strike-list format is gone. The full pass's hand-back disposition stays on its packet route. The composition design remains unadopted.

Adopted: the composition, in a different form than proposed below, under ADR 135. One runner, commonplace-review run revise, executes a plan of edit operations; the focused, quick and full procedures differ only in how the plan is made. The full-pass workflow and the fix procedure are retired. Not adopted from the design below: procedure variants as typed instruction files, and the run as a typed directory the validator checks. The table below describes the three procedures before that change.

Adopted: a run ends at its first stop and leaves what it could not finish to a later session, under ADR 138. A revise run publishes what needs no decision, then ends with a continuation record. A later command that names the operator's answers file, or the run holding a candidate, is the approval: no answers file precedes publication, no approval is bound by a key, and no run is resumed. Step 3 of the default composition below and its three endings therefore match shipped behaviour in run-record form, and the closing statement of what the design gives up no longer marks a difference from the shipped system for approval and resumption.

The three procedures, as the operator meets them:

Full pass Fix procedure Simplification passes
Entry commonplace-review run full-pass agent follows fix review warnings (retired by ADR 135); no workflow command commonplace-review run revise with --assess or --plan
Review operations used all six method families, before editing and again at closing the gate catalog, as fresh warn and fail results, before and after none; code checks on each text
Edit operations used the packet's body edits under keep, then a copyedit the fix strategies, chosen per finding the passes a plan names, in order
Stops used hand-back dispositions; --direction for an undetermined update; exact publication approval pending items, deferred only on the operator's word; the agent edits the checkout directly, so no publication boundary per-item answers for plain-wording and abstractions; exact publication approval
Where the operator's answer is kept packet resolution fields with rationale, under resolve a full-pass disposition (retired by ADR 135); the publication approval in an answers file the rejected, pending and deferred statuses in the free-form fix report answers files with each rejection's and deferral's reason, in the run's operator record

The atomic instructions, where they live and who uses them:

Kind Atom Lives at Used by
Review gate criteria, in seven bundles review-gates/ full pass, fix procedure, gate sweeps
Review compression bundle compression-bundle/ full pass, as one report; each of its four checks by its standalone compression/<check> selector, and its synthesis by compression-synthesis over supplied findings
Review type and collection conformance applicable type spec and collection contract full pass, standalone type and collection selectors
Review critique critique-note full pass, standalone critique selector
Review composition friction, with premise decomposition composition-friction-gate, premise-decomposition-gate full pass, standalone friction and premises selectors
Review connect cp-skill-connect full pass
Edit simplification passes, typed edit operations with effort, decision and preserve rules; split-out-a-treatment stays an instruction simplification-passes/ revise workflow, run edit
Edit fix strategies, keyed to finding kinds, as one typed edit operation fix strategy taxonomy fix procedure, run edit
Edit packet body edits and copyedit under keep run a full improvement pass (retired by ADR 135) full pass
Stop decide items: the operator's answer per proposal, in an answers file decide items revise workflow, run edit
Stop approve a text: the operator's word on a held candidate, given by commonplace-review publish RUN approve a text both workflow commands
Stop hand-back disposition with a packet resolve a full-pass disposition (retired by ADR 135) full pass
Stop deferred item fix review warnings (retired by ADR 135) fix procedure

Shipped constraints this proposal must respect:

  • ADR 080 keeps every claim-level change with the author. No edit operation changes a title, thesis or title-as-claim.
  • The review system asks that each operation be evaluated alone before its composition is trusted.
  • The operator-decision record is commonplace-review decisions under ADR 130. It reads what runs leave in the state tree.
  • A rejection or deferral carries the operator's reason, and a deferral its revisit condition; the validator enforces both for every answers file.
  • Directory types (ADR 111, directory artifact) are shipped and still experimental; one workflow family uses them.
  • Revise and full-pass still fix composition in Python: the assessment and plan grammar, the order of passes, the per-item stops, the method order and the closing cycle. Which passes stop for answers follows each operation's decision. Shared review and edit execution does not replace those procedures.

The problem

The same atoms are wired three ways, and the wiring is where the differences and the failures are. The full pass runs every review operation and then edits once. The fix procedure runs one kind of review operation and edits per finding, with no run record. The simplification passes run edit operations in a planned order with no review after. Nothing names the wiring, so two wirings cannot be compared on the same note.

Two of the three wirings are code. How the atoms are combined is the part that matters most and will change most, and today each change to it is a change to a Python workflow.

The design

One constraint is set, by the operator on 2026-11-13: review needs code, fixing does not. Review is many pairs over many notes with freshness, results and cost to track, a batching problem. Fixing is one note, one agent, a diff and an operator, a conversation problem. So review operations run through commonplace-review as they do now, and everything else is instruction.

The procedure has two layers. The atoms are the stable layer. The composition is the variable layer and exists as variants. Structure comes from three typed artifacts.

An atom is a typed instruction file. One review operation, edit operation or stop, with its contract: what it reads, what it may change, what it must preserve, what it returns. Review gates already have a type. Edit operations get one; the simplification passes nearly fit it already, and each fix strategy becomes a file of that type. Every remaining atom must be individually testable. The admitted review subset already has standalone execution and fixtures; the requirement below remains open for the other review, edit and stop operations. An atom can be run by itself on one note, and a review operation can be run by itself across a whole collection through the batch machinery, so that it can be calibrated before any variant relies on it: the split check on every note in kb/theory/, for instance, with its rate of proposals, its hits on known cases and an operator-judged sample. An atom that only works inside a composition, because it needs the variant's context or another atom's unrecorded output, does not meet the contract. Its inputs are therefore files, and its output is a typed result the batch run can store.

A variant is an instruction that composes atoms. It states its entry evidence, the review operations it runs, how it selects edit operations from their findings, the order, how far it re-reviews after editing, where it stops for the operator, and which checks it runs on what it produced. commonplace-validate is the default check; a cheap variant runs little more and an expensive one runs more. An agent follows the variant in a session, delegating atoms to workers where isolation matters. The operator answers in the session, and the commit is the publication. Variants are expected to change often and to coexist, each retained with the runs it was tried on.

A run is a typed directory. Each run of a variant leaves one directory in the state tree, a directory artifact whose type declares its roles: a report that carries the run's identity and ending, the findings the variant read, the edit chain, and the operator's answers with their reasons. The start text and the candidate are not members, because a directory member must be a Markdown file of one declared type: the start text is a commit and a hash, the candidate is the note in the working tree, and intermediate texts are stored by hash beside the members. commonplace-validate on the directory checks that the required members exist, that they name the same note and start text, and that the answers satisfy their schema, such as a reason on every strike, rejection and deferral. This is where strictness lives. The rules are schema and layout, so tightening or loosening one is an edit to a type, not to a workflow. The schemas are part of what is being designed and will change with the variants.

An output is filed by what it is about, never by who asked for it. The two kinds of operation differ here. A review operation is a function of the note's text, so its result goes to the shared result store, keyed by note and atom, at the same path whether a standalone batch or an improvement run produced it; the run names itself in the result as provenance. The run's findings member cites the results it acted on, with their hashes, and does not hold them. An edit operation is a function of a text chain: its output is a candidate that means something only relative to the text it was given. It always lives in a run. Running one edit operation alone is therefore not a special case with its own directory but a run of a one-atom variant, which is also how an edit operation is unit-tested.

The record follows from the run type. Decisions key to the atom, never to the variant, so evidence about an atom survives recomposition, and the variant's name on the run says which composition produced it. The decisions command reads the answers member of each run and should be thin enough that a schema revision is not a code change.

The default composition

The default composition checks higher-order concerns before lower-order editing. Purdue OWL's writing guidance supplies a conditional precedent: thesis or focus, audience and purpose, organization, and development take priority over sentence structure and grammar. It permits interleaving and recommends surface-first repair when errors prevent readers from reaching the thesis. This is a writing-practice precedent, not evidence that this agent workflow improves outcomes.

This proposal rests on the argument that unresolved revision choices put dependent polish at risk of rework: a later decision may discard earlier edits. A higher-order concern is one whose resolution may discard work on another concern: changing the claim, boundary, existence, placement, or argument structure may invalidate dependent wording. Structural organization is therefore not grouped with local transitions as uniformly lower-order “flow.” This dependency criterion differs from ordering by the number of viable options; a claim can have many viable revisions while much prose depends on it. Extending the writing-practice hierarchy to existence and placement is a Commonplace design choice.

The run starts from an existing note, not an empty design space. Early checking asks whether its claim or structure warrants reopening; it does not require redesign before polishing. If those commitments stand, dependent edits can proceed. For a choice that does need reopening, early checking does not require premature commitment. A variant may use bounded diagnostic rewriting to make the argument readable or produce evidence needed for a choice, without applying those drafts to the note. The default still checks before applying edits and stops on a strong proposal. Detecting a problem does not authorize its repair; claim changes remain with the author. The simplification passes' depth order supplies a local precedent for sequencing edits, not proof of the wider dependency rationale.

  1. Check higher-order concerns first. Some review operations can propose a change to what the note is: a split, a merge, a rehome, a rejection, a different claim. These checks always run before any edit is applied to the note. The expected result, in most runs, is that they propose nothing and the run goes on. That rarity is a working assumption the design rests on, not a measured fact: the higher-order check evaluation workshop exists to test it and to keep the check calibrated, and it is expected to stay open, since the check will be recalibrated many times as wordings, models and the collection change. If the check proves to propose often, the default composition is what has to change. A proposal carries a force:
  2. Strong: the run stops there and puts the proposal before the operator. Lower-order edits are not run, because they would be spent on text that may not survive.
  3. Weak: the change might be beneficial but the note stands as it is. The run records the proposal as a pending item and goes on to the edits.
  4. Otherwise apply what is automated. Edit operations that need no operator decision run and are applied, up to the exceptions their atoms name. They normally run first among the edits, since nothing waits on them.
  5. Save the rest for the operator. Edits that need a decision are not applied and do not block step 2. They are written to the run's answers member as pending items, each with its context, and the run ends with some changes applied and some pending.

So a run has three ordinary endings: stopped on a strong proposal with nothing edited, fully applied, or partly applied with pending items, which may include a weak proposal. A later session resolves the pending items by the same present, ask and record step, and the decisions command lists what is still pending per note. Which edit operations count as automated is the grade question, which the second proposal owns; a variant only needs each atom to say which of the two it is today.

What this gives up is stated plainly. Code no longer refuses a text that changed the title or H1; that becomes a diff the agent reads and the operator sees. Approvals are no longer bound to exact text with later edits detected, and a stopped run does not resume without paying again; both become the session itself.

Options

A. Run as a directory type. As described above: roles for report, findings, edit chain and answers, validated as one unit. A workshop draft gives the layout and what validation can and cannot check. Operativity: the variant's agent writes the members; commonplace-validate and the decisions command consume them. Force against: directory types are experimental, and a second workflow will find their rough edges.

B. Run as one typed file. A single run report whose frontmatter holds the decision list, schema-checked like the full-pass packet; the texts stay in git. Operativity: the same two consumers. Force against: one file cannot check that its parts agree with each other or that a member is missing, and the candidate and findings are then recoverable only from the session and the commit.

The retired code is the same under both: the revise workflow and the full pass's editor, packet, closing cycle and repair, each retired only when a variant has run its cases on retained examples. The six method families stay as review operations.

Candidate selection (2026-11-13): A, with B as the fallback if the directory-type machinery costs more than the run structure is worth. No decision is taken here.

Free choices

  • How many notes a one-atom variant can be run over at once, since the batch machinery today runs review operations only.
  • The comparison protocol for different wordings: admitted reviews already retain observations behind the replaceable current result, but selection, labels and interpretation of calibration trials remain open.
  • The edit-operation type's fields, and whether fix strategies and method families are rewritten to their types or wrapped.
  • Whether a variant has a type of its own, so the validator can check that every atom it names exists.
  • Whether the run type keeps four member types or folds the findings and the edit chain into the report.
  • The answers schema: its fields, and which decisions require a reason.
  • Where variants and atoms live under kb/instructions/, and how a variant is named and retired.
  • Which review operations are the higher-order checks, and how each states the force of what it proposes. They always run first, so their cost is paid on every run; the full pass's method families cost far more than a gate sweep, which argues for a small dedicated check over the whole method suite.
  • What makes a proposal strong: the check's own judgment, a stated criterion such as the note having no claim its neighbours do not own, or the operator's threshold recorded from earlier answers.
  • Whether pending items expire when the note's text changes under them, as review results go stale.
  • Which checks a variant names beyond commonplace-validate.
  • The interface for operator answers. A session in which the agent presents each item in context, asks, and records the answer is the candidate; resolve a strike list is that step for one stop.

Adoption criteria

  • The higher-order check: the build does not wait on it. The procedure is built on the assumption that higher-order proposals are rare, and the standing higher-order check evaluation workshop reports when the assumption fails.
  • First build: the operator commissions the run type, the edit-operation type and the first variant. The fix case is the candidate first variant, since the fix procedure is the one with no run record today. Its first run on a note with fresh warnings is the first retained example.
  • Retirement of an editing path: a variant has run that path's cases on retained examples and the operator accepts the results.
  • Fallback to option B: the first run type needs validator changes that the run structure does not justify.

What to do with the runs once they exist, which authority each atom carries and what evidence may move it toward automation, is a separate proposal: authority grades and learning from operator decisions.


Relevant Notes:

  • Authority grades and learning from operator decisions — enables: the run records this procedure leaves are the evidence that proposal grades and learns from
  • Review architecture — part-of: the review workflows that keep running the review operations
  • Run a full improvement pass on one note (retired by ADR 135) — procedure: the variant that runs every review operation
  • Fix system (retired by ADR 135) — procedure: the variant that edits per finding, and the candidate first case
  • Simplification passes — procedure: the variant that runs edit operations from a plan, and the smallest example of a composition separated from its atoms
  • ADR 111 — decided-by: directory types and their layouts, which the run type would use
  • ADR 127 — decided-by: review as workflows over result files, the part that stays in code
  • ADR 130 — decided-by: the operator-decision record that reads what runs leave