code-architecture
Installation
SKILL.md
Code architecture
Find the subsystem, the revision or branch, the requested stages and the output location in the request and the repository. Run the stages the user requests. An extract-only request stops after the model. A review runs extract, design, compare, synthesize and verify. Implement only when the user asks for code changes, under the project's coding workflow.
Terms
Each term has one meaning in every file of this skill. Do not use a synonym for a term.
- Model: the code-free account of the subsystem that extraction writes. A row is one table line with an id. A PR row records what a provider routine writes. A K row records a collapse: a combination the lenses forbid and the code permits.
- Section group: a set of model sections one agent owns at extraction, design and compare. The groups: external contracts and wrappers; states and gates; lifetimes and interrupts; identities; failures; handoffs and time; diagnostics when selected.
- Lens: an invariant with its code form, in lenses.md. Its slug is its name.
- Invariant (I), encoding (E), premise (P): the design's rows. An encoding is the code form that enforces an invariant. A premise is a design row about provider behavior the model lacks; extraction records a missing fact as unresolved, never as a premise. "design.md" names this skill's instruction file; the artifact of the same name lives in the output directory.
- Provider: the engine, framework or SDK the subsystem calls. A gate is a refusal at the only entry, before the write; a refusal after the write, or at one of several entries, is a check at runtime. lenses.md owns these two definitions.
- Design check: a comparer's result for an encoding: passes, correction (a stated value is wrong and the form stands) or defect (the form or its level is wrong). "Runtime check" is a Level value of an encoding, not a design check.
- Divergence: a place where the code differs from an encoding. Its disposition is one of finding, conditional finding, justified tradeoff, not a finding, evidence gap. Its consequence class is one of user-visible, ruling, leak, diagnostic, none.
- Handoff (H): a finding written for implementation. A lower row is a finding or correction kept on record without a handoff. A decision is a choice a handoff waits on. A default taken is a choice made on its recommendation.
- Verdict: a verifier's result for one part of a handoff: Confirmed, Refuted or Unverifiable.
- Checker:
scripts/check_artifacts.py. Only the checker checks an artifact's shape. Agents extract, design, compare, synthesize and verify.