一键导入
canon-architecture
Use when you need a governed Canon architecture run to record decisions, tradeoffs, and risk-gated approvals.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Use when you need a governed Canon architecture run to record decisions, tradeoffs, and risk-gated approvals.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Use when you need a governed Canon review of a real diff or pull-request range instead of a loose chat summary.
Use when a repository does not have Canon runtime state yet and you need to initialize .canon before any governed workflow.
Use when you need a governed Canon policy-shaping run to shape a new or modified policy with mandatory impact evaluation.
Use when you need a governed backlog run that decomposes bounded upstream decisions into delivery epics and slices.
Use when you need a governed change run in a live codebase where invariants and existing behavior matter.
Use when you need a governed domain-language packet that stabilizes the shared vocabulary of a product area before downstream design or change work.
| name | canon-architecture |
| description | Use when you need a governed Canon architecture run to record decisions, tradeoffs, and risk-gated approvals. |
available-nowdefault visibility: discoverable-standardStart a real Canon architecture run from your AI assistant without making the user memorize the raw CLI.
$canon-change.RISKZONESYSTEM_CONTEXTOptional:
OWNER when the user wants to override Git-derived ownership explicitlycanon is on PATH. If missing, point to the install guide..canon/ exists. If missing, point to $canon-init.SYSTEM_CONTEXT is present before invoking Canon.SYSTEM_CONTEXT explicitly with guided fixed choices new or existing; do not infer it from the mode label.canon-input/ as read-only source material. Do not rewrite, normalize, append to, or otherwise modify the user's input files during preflight, clarification, generation, critique, or summary.canon-input/architecture.md or canon-input/architecture/ as the canonical authored-input locations for this mode.--input-text instead of materializing a repo file automatically.--input from the active editor file, open tabs, recent .canon/ artifacts, or any other path under .canon/.OWNER is optional. If omitted, Canon should try repository-local or global Git identity before asking for explicit owner input.canon inspect risk-zone --mode architecture --input <INPUT_PATH> to infer a provisional pair, explain the Canon rationale and confidence, and ask the user to confirm or override before invoking Canon.low confidence, present it as provisional and invite override rather than treating it as final.low-impact, bounded-impact, or systemic-impact.green, yellow, or red.canon run --mode architecture --system-context <SYSTEM_CONTEXT> --risk <RISK> --zone <ZONE> [--owner <OWNER>] (--input <INPUT_PATH> | --input-text <INPUT_TEXT>)canon publish <RUN_ID> writes the normal packet under tech-docs/architecture/decisions/... and one durable ADR under tech-docs/adr/ADR-XXXX-<slug>.md by default.--to can relocate the visible packet copy, but the ADR registry stays fixed under tech-docs/adr/.## Missing Authored Body or other honesty markers, preserve those signals instead of glossing over them in chat..canon/runs/<RUN_ID>/artifacts/architecture/working-brief.md while keeping canon-input/ read-only.continue, refine, or same run, supplies a RUN_ID, or chooses Canon's explicit continuation path.$canon-status for the compact summary and canon inspect refinement --run <RUN_ID> when the user needs the working-brief path, clarification records, readiness delta, or lineage.## Decision, ## Constraints, ## Evaluation Criteria,
## Decision Drivers, ## Options Considered, ## Pros, ## Cons,
## Recommendation, and ## Why Not The Others before invoking Canon.
The renderer preserves those authored bodies in
architecture-decisions.md and tradeoff-matrix.md instead of replacing
them with generic prose.architecture-decisions.md emits an ADR-like ## Consequences section.
New briefs should author ## Consequences directly. Canon still accepts the
legacy ## Risks heading as a backward-compatible input alias and renders it
as ## Consequences in the emitted decision artifact.## Working Assumptions and ## Unresolved Questions. Canon carries those
sections into readiness-assessment.md and uses them to say directly when
architecture is still conditional or should reroute to an earlier mode.## Bounded Contexts,
## Context Relationships, ## Integration Seams,
## Anti-Corruption Candidates, ## Ownership Boundaries, and
## Shared Invariants before invoking Canon. The renderer preserves these
section bodies verbatim in context-map.md.## System Context, ## Containers, and ## Components before invoking
Canon. The renderer preserves these section bodies verbatim in
system-context.md, container-view.md, and component-view.md.## Missing Authored Body block that names the missing canonical
heading. Treat that block as a structured prompt to revise the authored
brief and rerun, not as Canon-generated content.## Options, ## Recommended Option, ## Rejected Alternatives,
## C4 - System Context, ## Container View, ## Component View,
## Context Map, or ## Contexts are NOT recognized. The H2 must match the
canonical heading exactly; otherwise the missing-body block is emitted.defaults/templates/canon-input/architecture.md
shows the expected shape; the worked example at
tech-docs/examples/canon-input/architecture-state-management.md shows a
bounded-but-realistic packet.Author the packet as an architect writing a combined C4 plus ADR decision packet for reviewers and downstream implementers.
After preflight succeeds and the real Canon run exists, the assistant is responsible for turning the architecture packet from templated stubs into a grounded, reviewable artifact set.
canon-input/architecture/, treat the directory as one authored packet and read it recursively before generation..canon/artifacts/<RUN_ID>/architecture/ exists and the packet stays attached to a real run id.canon-input/ as read-only source material. Do not rewrite, normalize, append to, or otherwise modify the user's input files during preflight, clarification, generation, critique, or summary..canon/artifacts/<RUN_ID>/architecture/..canon/artifacts/<RUN_ID>/architecture/.When the authored input is structurally present but materially ambiguous on points that would force the assistant to invent content, ask targeted clarification questions before generation rather than papering over the gap. Ask only when the ambiguity could change the structural decision, the tradeoff analysis, or the correct earlier mode. Do not interrogate generic load, traffic, or user-count details unless they would materially change the architecture recommendation or reroute.
and, or, or comma-separated sub-questions.Each question must follow this shape:
- Question: <one-sentence question>
- Affects: <artifact or section it changes>
- Why it matters: <one short line on what changes if unanswered>
- Context: <≤2 lines from authored input, or `no input coverage`>
- Options:
a) <concrete option>
b) <concrete option>
c) <concrete option>
d) Other (free-form)
- Default if skipped: <explicit default>
- Status: Required | Optional
Question line as the main prompt and surface Why it matters and Context as secondary or tooltip text rather than dumping the full block inline.readiness-assessment.md, and record that carry-forward in
provenance.Write .canon/artifacts/<RUN_ID>/architecture/ai-provenance.md describing how
the packet was produced. It must include:
readiness-assessment.md.Clarification Loop section with: number of questions presented, number of Required questions answered, number of Required questions left unresolved, number of Optional questions answered or deferred, and the number of substantive clarifications that drove material changes per artifact section..canon/artifacts/... paths when Canon emitted them$canon-status, $canon-inspect-artifacts, and $canon-inspect-evidence.canon/artifacts/<RUN_ID>/architecture/ and .canon/artifacts/<RUN_ID>/architecture/ai-provenance.md, never back into canon-input/.canon/ is missing, point to $canon-init.--owner <OWNER> explicitly or tell the user to configure git user.name and git user.email.SYSTEM_CONTEXT, use guided fixed choices with the exact allowed values new and existing.RISK, use guided fixed choices with the exact allowed values low-impact, bounded-impact, and systemic-impact.ZONE, use guided fixed choices with the exact allowed values green, yellow, and red.--input-text content and do not restate already valid ownership metadata.AwaitingApproval, surface the exact target Canon produced, typically gate:risk, and do not imply the run is complete.canon-input/, stop, restore the file from the user's last saved version, and report the rollback before continuing.$canon-inspect-artifacts first.$canon-inspect-artifacts as drill-down.$canon-inspect-evidence when the user needs lineage, critique rationale, or approval context behind the packet.$canon-approve only after the user has reviewed the packet or explicitly wants to record approval.$canon-status first and use $canon-resume only if Canon still leaves the run incomplete.$canon-status$canon-inspect-artifacts$canon-inspect-evidence$canon-approve$canon-resume