opencode-codeops 1.4.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/CHANGELOG.md +179 -0
- package/LICENSE +21 -0
- package/README.md +171 -0
- package/_shared/auto-design.md +129 -0
- package/_shared/layout-convention.md +198 -0
- package/_shared/quality-profile.md +134 -0
- package/_shared/recommendation-hardening.md +166 -0
- package/_shared/scope-expansion-control.md +176 -0
- package/_shared/spec-first-ordering.md +79 -0
- package/_shared/zero-ambiguity-gate.md +311 -0
- package/agent-templates/codebase-scout.md +17 -0
- package/agent-templates/concurrency-auditor.md +5 -0
- package/agent-templates/design-challenger.md +26 -0
- package/agent-templates/financial-integrity-auditor.md +5 -0
- package/agent-templates/perf-auditor.md +23 -0
- package/agent-templates/phase-reviewer.md +54 -0
- package/agent-templates/plan-task-executor-opus.md +46 -0
- package/agent-templates/plan-task-executor.md +43 -0
- package/agent-templates/preflight-auditor.md +45 -0
- package/agent-templates/security-auditor.md +42 -0
- package/agent-templates/semantics-reviewer.md +5 -0
- package/agent-templates/spec-test-author.md +29 -0
- package/agents/concurrency-auditor.md +15 -0
- package/agents/correctness-reviewer.md +66 -0
- package/agents/demanding-executor.md +58 -0
- package/agents/design-challenger.md +38 -0
- package/agents/executor.md +55 -0
- package/agents/explorer.md +29 -0
- package/agents/financial-integrity-auditor.md +15 -0
- package/agents/performance-auditor.md +35 -0
- package/agents/preflight-auditor.md +57 -0
- package/agents/security-auditor.md +54 -0
- package/agents/semantics-reviewer.md +15 -0
- package/agents/spec-test-author.md +41 -0
- package/bin/codeops-worktree +244 -0
- package/bin/index.mjs +106 -0
- package/bin/install-agents.mjs +453 -0
- package/bin/install-skills.mjs +466 -0
- package/bin/lib/opencode-install.mjs +185 -0
- package/install.sh +55 -0
- package/package.json +73 -0
- package/plugin/index.ts +181 -0
- package/references/domains/compiler-and-language.md +28 -0
- package/references/domains/data-and-migration.md +22 -0
- package/references/domains/distributed-and-concurrent.md +26 -0
- package/references/domains/financial-system.md +28 -0
- package/references/domains/selection.md +19 -0
- package/references/domains/web-application.md +23 -0
- package/schemas/codeops-config.schema.json +56 -0
- package/scripts/check-version.mjs +163 -0
- package/scripts/codeops-migrate.sh +355 -0
- package/scripts/codeops-roadmap-compact.sh +232 -0
- package/scripts/codeops-roadmap-sync.sh +275 -0
- package/scripts/codeops_outcomes.py +155 -0
- package/scripts/codeops_plan.py +239 -0
- package/scripts/codeops_plan_migrate.py +318 -0
- package/scripts/codeops_worktree_snapshot.py +99 -0
- package/scripts/install_agents.py +288 -0
- package/scripts/release.mjs +533 -0
- package/skills/analyze-project/SKILL.md +28 -0
- package/skills/clean-comments/SKILL.md +22 -0
- package/skills/exec-plan/SKILL.md +267 -0
- package/skills/exec-plan/commit-modes.md +113 -0
- package/skills/exec-plan/execution-protocol.md +471 -0
- package/skills/git-commit/SKILL.md +35 -0
- package/skills/github-issues/SKILL.md +38 -0
- package/skills/grill-me/SKILL.md +342 -0
- package/skills/make-plan/SKILL.md +282 -0
- package/skills/make-plan/quality-checklist.md +96 -0
- package/skills/make-plan/templates.md +535 -0
- package/skills/make-plan/zero-ambiguity-gate.md +19 -0
- package/skills/make-requirements/SKILL.md +268 -0
- package/skills/make-requirements/discovery-phases.md +255 -0
- package/skills/make-requirements/review-and-add.md +73 -0
- package/skills/make-requirements/templates.md +296 -0
- package/skills/make-requirements/zero-ambiguity-gate.md +18 -0
- package/skills/outcome-review/SKILL.md +34 -0
- package/skills/preflight/SKILL.md +310 -0
- package/skills/preflight/dimensions.md +181 -0
- package/skills/preflight/report-format.md +300 -0
- package/skills/retro-requirements/SKILL.md +218 -0
- package/skills/retro-requirements/confidence-classification.md +45 -0
- package/skills/retro-requirements/phases.md +609 -0
- package/skills/retro-requirements/triage-gate.md +135 -0
- package/skills/roadmap/SKILL.md +381 -0
- package/skills/roadmap/stage-hooks.md +80 -0
- package/skills/roadmap/template.md +200 -0
- package/skills/setup-codeops/SKILL.md +94 -0
- package/skills/setup-codeops/migration.md +106 -0
- package/skills/setup-codeops/scaffold.md +99 -0
- package/skills/setup-routing/SKILL.md +102 -0
- package/skills/setup-routing/routing.md +44 -0
- package/skills/techdocs/SKILL.md +199 -0
- package/skills/techdocs/authoring-and-update.md +178 -0
- package/skills/techdocs/templates.md +655 -0
- package/skills/techdocs/vitepress-setup.md +143 -0
- package/skills/upgrade-plan/SKILL.md +75 -0
- package/skills/upgrade-plan/content-quality-gate.md +35 -0
- package/skills/upgrade-plan/upgrade-checklists.md +107 -0
- package/standards/coding-standards-full.md +124 -0
- package/standards/coding-standards.md +64 -0
- package/standards/output-style.md +17 -0
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
# Phase 3 β Quality Checklist
|
|
2
|
+
|
|
3
|
+
Run this before finalizing the plan documents. The **Specification-First Testing**, **Security-First**, **Zero-Ambiguity**, and **Execution Plan Completeness** blocks are NON-NEGOTIABLE.
|
|
4
|
+
|
|
5
|
+
## β
Completeness
|
|
6
|
+
- [ ] All requirements captured
|
|
7
|
+
- [ ] All affected components identified
|
|
8
|
+
- [ ] All scope decisions documented
|
|
9
|
+
- [ ] All dependencies mapped
|
|
10
|
+
- [ ] Every planned item traces to the confirmed scope baseline or a user-kept `SE-*` entry
|
|
11
|
+
- [ ] Strict scope contains no optional suggestions; exploration proposals remain non-executable
|
|
12
|
+
until the user chooses `Keep`
|
|
13
|
+
- [ ] The planned solution passes the coding standards' **minimum-sufficient design** rule
|
|
14
|
+
- [ ] The plan states the smallest viable design; every larger material support surface is removed
|
|
15
|
+
or has an explicitly user-approved `Technical (complexity escalation)` AR entry
|
|
16
|
+
- [ ] No complexity escalation relies on silence, generic recommendation acceptance,
|
|
17
|
+
`--auto-design`, a finding ruling, or permission to apply fixes as approval
|
|
18
|
+
|
|
19
|
+
## β
Granularity
|
|
20
|
+
- [ ] Each task is one reviewable change: 1-3 files, ~50-150 lines, immediately testable
|
|
21
|
+
- [ ] Anything touching >=6 files, 200+ lines, or 3+ concerns is SPLIT into multiple tasks
|
|
22
|
+
- [ ] Each task has clear deliverables
|
|
23
|
+
- [ ] Each task is independently testable
|
|
24
|
+
|
|
25
|
+
## β
Dependencies
|
|
26
|
+
- [ ] Phase dependencies documented
|
|
27
|
+
- [ ] Task dependencies documented
|
|
28
|
+
- [ ] No circular dependencies
|
|
29
|
+
- [ ] Dependency order is logical
|
|
30
|
+
|
|
31
|
+
## β
Testing
|
|
32
|
+
- [ ] Every component has test requirements
|
|
33
|
+
- [ ] E2E tests are planned when feasible and applicable; otherwise the plan records `N/A` with a
|
|
34
|
+
concrete reason and does not create a new harness only to satisfy the template
|
|
35
|
+
- [ ] Test coverage goals defined
|
|
36
|
+
|
|
37
|
+
## β
Specification-First Testing β π¨ NON-NEGOTIABLE
|
|
38
|
+
- [ ] `07-testing-strategy.md` contains the `π¨ Specification Test Cases` section with concrete ST-cases
|
|
39
|
+
- [ ] Every ST-case has concrete input β expected output pairs (not just test names/descriptions)
|
|
40
|
+
- [ ] Every ST-case traces to a requirement, spec document, RFC, or AR entry
|
|
41
|
+
- [ ] ST-case expectations are derived from specification documents, NOT from imagined implementation behavior
|
|
42
|
+
- [ ] `99-execution-plan.md` follows the three-phase task ordering: spec tests β implementation β impl tests
|
|
43
|
+
- [ ] Spec test tasks reference ST-cases from `07-testing-strategy.md`
|
|
44
|
+
- [ ] Spec test and impl test files use separate naming conventions (`*.spec.test.*` and `*.impl.test.*`)
|
|
45
|
+
- [ ] A red-phase verification task exists in the execution plan (verify spec tests fail before implementation)
|
|
46
|
+
|
|
47
|
+
## β
No Dead Code
|
|
48
|
+
- [ ] No unused parameters (except interface contracts, overrides, and framework-required signatures)
|
|
49
|
+
- [ ] No unused functions, classes, or modules
|
|
50
|
+
- [ ] No unreachable code or commented-out blocks
|
|
51
|
+
- [ ] Language-specific dead code tooling enabled (if available)
|
|
52
|
+
|
|
53
|
+
## β
Security-First β π¨ NON-NEGOTIABLE
|
|
54
|
+
- [ ] All user input validated and sanitized server-side
|
|
55
|
+
- [ ] Injection prevention addressed (SQL, XSS, command injection, path traversal)
|
|
56
|
+
- [ ] Authentication & authorization properly designed
|
|
57
|
+
- [ ] Rate limiting planned for public and authentication endpoints
|
|
58
|
+
- [ ] No hardcoded secrets or credentials β secrets management strategy defined
|
|
59
|
+
- [ ] Sensitive data encrypted at rest and in transit
|
|
60
|
+
- [ ] Error responses expose no internal details (no stack traces, no DB schemas)
|
|
61
|
+
- [ ] Existing or required infrastructure is hardened (non-root containers, minimal base images,
|
|
62
|
+
no secrets in images/CI); projects with no infrastructure change record `N/A` rather than
|
|
63
|
+
inventing one
|
|
64
|
+
- [ ] Security test cases included in the testing strategy
|
|
65
|
+
|
|
66
|
+
## β
Zero-Ambiguity (per Phase 1C) β π¨ NON-NEGOTIABLE
|
|
67
|
+
- [ ] Ambiguity Register (`00-ambiguity-register.md`) exists and is saved to disk
|
|
68
|
+
- [ ] Every register entry has Status = `β
Resolved` with an explicit user decision or a
|
|
69
|
+
complete auto-design delegated record, or a complete, explicitly user-approved `βΈ Deferred`
|
|
70
|
+
record
|
|
71
|
+
- [ ] Every deferred decision is absent from executable plan content; deferred extra machinery is
|
|
72
|
+
absent from the plan
|
|
73
|
+
- [ ] All decisions in plan documents have AR # back-references (only exceptions: universally obvious facts + zero-semantic-impact formatting)
|
|
74
|
+
- [ ] No plan document contains AI-assumed defaults, inferred behaviors, or guessed specifications
|
|
75
|
+
- [ ] Surface-during-authoring rule was followed β new ambiguities were added to the register and
|
|
76
|
+
resolved by the user or, when active and eligible, under the auto-design policy
|
|
77
|
+
- [ ] Scope expansion was never disguised as ambiguity resolution or delegated to auto-design
|
|
78
|
+
|
|
79
|
+
## β
Execution Plan Completeness β π¨ NON-NEGOTIABLE
|
|
80
|
+
- [ ] Every phase section carries its tasks as a checkbox list (`- [ ] N.N.N β¦` with target file)
|
|
81
|
+
- [ ] Every task appears exactly once document-wide β no consolidated restatement anywhere
|
|
82
|
+
- [ ] The execution-rule callout (single-source marks, two-stage `[~]`/`[x]`, progress-header update, resume rule) is present under Implementation Phases
|
|
83
|
+
- [ ] Task numbering is consistent across phase sections and the phase table
|
|
84
|
+
|
|
85
|
+
## β
Reference, Don't Restate β π¨ NON-NEGOTIABLE
|
|
86
|
+
- [ ] Every citation (ST-#, 03-doc Β§, AR-#) resolves to an existing anchor/entry
|
|
87
|
+
- [ ] No document restates content owned by another (spot-check 3 facts: each has a single owner)
|
|
88
|
+
- [ ] RD-based plans use the thin delta `01-requirements.md`; standalone plans use the full form
|
|
89
|
+
- [ ] No audit/traceability table duplicates AR or ST rows (citations only)
|
|
90
|
+
|
|
91
|
+
## β
Format
|
|
92
|
+
- [ ] All documents follow the templates
|
|
93
|
+
- [ ] Tables are properly formatted
|
|
94
|
+
- [ ] Task numbers follow the convention (Phase.Session.Task)
|
|
95
|
+
- [ ] Checkboxes included for tracking
|
|
96
|
+
- [ ] `00-index.md` and `99-execution-plan.md` are stamped with `> **CodeOps Artifact Schema**: 1`
|
|
@@ -0,0 +1,535 @@
|
|
|
1
|
+
# Plan Document Templates
|
|
2
|
+
|
|
3
|
+
Read this when writing the Phase 2 documents. Create files in `plans/<feature-name>/`. Stamp `00-index.md` and `99-execution-plan.md` with `> **CodeOps Artifact Schema**: 1`. Every `[Date]` / `[YYYY-MM-DD HH:MM]` placeholder is filled from `date '+%Y-%m-%d %H:%M'` β never an invented timestamp.
|
|
4
|
+
|
|
5
|
+
Folder layout:
|
|
6
|
+
|
|
7
|
+
```
|
|
8
|
+
plans/<feature-name>/
|
|
9
|
+
βββ 00-ambiguity-register.md # see zero-ambiguity-gate.md for this file's template
|
|
10
|
+
βββ 00-index.md
|
|
11
|
+
βββ 01-requirements.md
|
|
12
|
+
βββ 02-current-state.md
|
|
13
|
+
βββ 03-XX-<component>.md # one or more, per component
|
|
14
|
+
βββ 07-testing-strategy.md
|
|
15
|
+
βββ 99-execution-plan.md
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
## Reference, don't restate (NON-NEGOTIABLE)
|
|
21
|
+
|
|
22
|
+
Every behavioral fact, decision, or specification lives in exactly ONE owning document:
|
|
23
|
+
|
|
24
|
+
| Fact type | Owning doc |
|
|
25
|
+
|-----------|-----------|
|
|
26
|
+
| Requirement / scope decision | the RD (when the plan implements one), else `01-requirements.md` |
|
|
27
|
+
| Original goal and smallest viable design | `00-index.md` |
|
|
28
|
+
| Design / architecture / signatures / error handling | the governing `03-XX` doc |
|
|
29
|
+
| Expected test behavior (inputβoutput) | `07-testing-strategy.md` (ST-cases) |
|
|
30
|
+
| Resolved ambiguity | `00-ambiguity-register.md` (AR entries) |
|
|
31
|
+
|
|
32
|
+
Every other document CITES the owner β `ST-4..ST-7`, `03-01 Β§Parsing`, `AR-12` β with at most a
|
|
33
|
+
**one-line gloss** for readability. Prohibited: copying acceptance detail into execution tasks,
|
|
34
|
+
re-deriving an RD inside plan documents, and **audit/traceability tables that restate AR or ST
|
|
35
|
+
content** (cite the numbers; the register/strategy doc IS the table). Execution-plan task lines
|
|
36
|
+
name the action + target file + citations; the executor reads the owning doc (or is handed the
|
|
37
|
+
excerpt at dispatch time β excerpting for a handoff packet is not restatement).
|
|
38
|
+
|
|
39
|
+
---
|
|
40
|
+
|
|
41
|
+
## 00-index.md β Index and Overview
|
|
42
|
+
|
|
43
|
+
```markdown
|
|
44
|
+
# [Feature Name] Implementation Plan
|
|
45
|
+
|
|
46
|
+
> **Feature**: [Brief description]
|
|
47
|
+
> **Status**: Planning Complete
|
|
48
|
+
> **Created**: [Date]
|
|
49
|
+
> **Implements**: RD-NN, RD-NN (one or more RD identifiers; feature-qualify in nested layout)
|
|
50
|
+
> **CodeOps Artifact Schema**: 1
|
|
51
|
+
|
|
52
|
+
## Overview
|
|
53
|
+
|
|
54
|
+
[2-3 paragraph description of what this feature does and why it's needed]
|
|
55
|
+
|
|
56
|
+
## Minimum-Sufficient Baseline
|
|
57
|
+
|
|
58
|
+
**Original goal:** [The requested outcome in one or two sentences]
|
|
59
|
+
**Smallest viable design:** [The direct solution and existing patterns it reuses]
|
|
60
|
+
**Excluded machinery:** [Only larger support surfaces actually considered, or `None`]
|
|
61
|
+
**Approved complexity:** [AR references, or `None`]
|
|
62
|
+
|
|
63
|
+
## Document Index
|
|
64
|
+
|
|
65
|
+
| # | Document | Description |
|
|
66
|
+
| --- | ---------------------------------------------- | ------------------------------------------- |
|
|
67
|
+
| AR | [Ambiguity Register](00-ambiguity-register.md) | Zero-Ambiguity Gate decisions (audit trail) |
|
|
68
|
+
| 00 | [Index](00-index.md) | This document β overview and navigation |
|
|
69
|
+
| 01 | [Requirements](01-requirements.md) | Feature requirements and scope |
|
|
70
|
+
| 02 | [Current State](02-current-state.md) | Analysis of current implementation |
|
|
71
|
+
| 03 | [Component Name](03-component.md) | Technical specification |
|
|
72
|
+
| ... | ... | ... |
|
|
73
|
+
| 07 | [Testing Strategy](07-testing-strategy.md) | Test cases and verification |
|
|
74
|
+
| 99 | [Execution Plan](99-execution-plan.md) | Phases, sessions, and task checklist |
|
|
75
|
+
|
|
76
|
+
## Quick Reference
|
|
77
|
+
|
|
78
|
+
### Usage Examples
|
|
79
|
+
|
|
80
|
+
[Code examples showing the feature in use]
|
|
81
|
+
|
|
82
|
+
### Key Decisions
|
|
83
|
+
|
|
84
|
+
| Decision | Outcome |
|
|
85
|
+
| ------------ | --------- |
|
|
86
|
+
| [Decision 1] | [Outcome] |
|
|
87
|
+
|
|
88
|
+
## Related Files
|
|
89
|
+
|
|
90
|
+
[List of key files that will be created or modified]
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
---
|
|
94
|
+
|
|
95
|
+
## 01-requirements.md β Requirements and Scope
|
|
96
|
+
|
|
97
|
+
Two variants β pick by whether the plan implements an RD (per "Reference, don't restate").
|
|
98
|
+
|
|
99
|
+
### RD-based plans β thin delta form
|
|
100
|
+
|
|
101
|
+
When the plan implements an RD, the RD is the OWNING requirements doc and `01-requirements.md`
|
|
102
|
+
is a delta view only β never a restatement:
|
|
103
|
+
|
|
104
|
+
```markdown
|
|
105
|
+
# Requirements: [Feature Name]
|
|
106
|
+
|
|
107
|
+
> **Document**: 01-requirements.md
|
|
108
|
+
> **Parent**: [Index](00-index.md)
|
|
109
|
+
> **Source**: [RD-XX](../../requirements/RD-XX-feature-name.md) β the OWNING requirements doc
|
|
110
|
+
|
|
111
|
+
## Scope of this plan (delta view)
|
|
112
|
+
|
|
113
|
+
### In this plan
|
|
114
|
+
- RD-XX R1, R3βR5 [one-line gloss each]
|
|
115
|
+
|
|
116
|
+
### Deferred / out of this plan
|
|
117
|
+
- RD-XX R2 [why]
|
|
118
|
+
|
|
119
|
+
## Plan-local decisions
|
|
120
|
+
|
|
121
|
+
| Decision | Chosen | AR Ref |
|
|
122
|
+
| -------- | ------ | ------ |
|
|
123
|
+
| [Only decisions NOT already in the RD] | [Outcome] | AR #X |
|
|
124
|
+
|
|
125
|
+
## Acceptance Criteria
|
|
126
|
+
|
|
127
|
+
[Only plan-local criteria; the RD owns its own acceptance criteria]
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
### Standalone plans β full form
|
|
131
|
+
|
|
132
|
+
With no RD upstream, `01-requirements.md` IS the owning requirements doc:
|
|
133
|
+
|
|
134
|
+
```markdown
|
|
135
|
+
# Requirements: [Feature Name]
|
|
136
|
+
|
|
137
|
+
> **Document**: 01-requirements.md
|
|
138
|
+
> **Parent**: [Index](00-index.md)
|
|
139
|
+
|
|
140
|
+
## Feature Overview
|
|
141
|
+
|
|
142
|
+
[Detailed description of the feature]
|
|
143
|
+
|
|
144
|
+
## Functional Requirements
|
|
145
|
+
|
|
146
|
+
### Must Have
|
|
147
|
+
- [ ] Requirement 1
|
|
148
|
+
|
|
149
|
+
### Should Have
|
|
150
|
+
- [ ] Requirement 1
|
|
151
|
+
|
|
152
|
+
### Won't Have (Out of Scope)
|
|
153
|
+
- Exclusion 1
|
|
154
|
+
|
|
155
|
+
## Technical Requirements
|
|
156
|
+
|
|
157
|
+
### Performance
|
|
158
|
+
- [Performance requirements]
|
|
159
|
+
|
|
160
|
+
### Compatibility
|
|
161
|
+
- [Compatibility requirements]
|
|
162
|
+
|
|
163
|
+
### Security
|
|
164
|
+
- [Security requirements]
|
|
165
|
+
|
|
166
|
+
## Scope Decisions
|
|
167
|
+
|
|
168
|
+
| Decision | Options Considered | Chosen | Rationale | AR Ref |
|
|
169
|
+
| ---------- | ------------------ | ------ | --------- | ------ |
|
|
170
|
+
| [Decision] | A, B, C | B | [Why] | AR #X |
|
|
171
|
+
|
|
172
|
+
> **Traceability:** Every scope decision must reference the Ambiguity Register entry (AR #) that resolved it. See `00-ambiguity-register.md`.
|
|
173
|
+
|
|
174
|
+
## Acceptance Criteria
|
|
175
|
+
|
|
176
|
+
1. [ ] Criterion 1
|
|
177
|
+
2. [ ] All tests pass
|
|
178
|
+
3. [ ] Documentation updated
|
|
179
|
+
```
|
|
180
|
+
|
|
181
|
+
---
|
|
182
|
+
|
|
183
|
+
## 02-current-state.md β Current State Analysis
|
|
184
|
+
|
|
185
|
+
```markdown
|
|
186
|
+
# Current State: [Feature Name]
|
|
187
|
+
|
|
188
|
+
> **Document**: 02-current-state.md
|
|
189
|
+
> **Parent**: [Index](00-index.md)
|
|
190
|
+
|
|
191
|
+
## Existing Implementation
|
|
192
|
+
|
|
193
|
+
### What Exists
|
|
194
|
+
[Description of current relevant code]
|
|
195
|
+
|
|
196
|
+
### Relevant Files
|
|
197
|
+
|
|
198
|
+
| File | Purpose | Changes Needed |
|
|
199
|
+
| -------------- | --------- | -------------- |
|
|
200
|
+
| `path/to/file` | [Purpose] | [Changes] |
|
|
201
|
+
|
|
202
|
+
### Code Analysis
|
|
203
|
+
[Key code snippets and analysis]
|
|
204
|
+
|
|
205
|
+
## Gaps Identified
|
|
206
|
+
|
|
207
|
+
### Gap 1: [Name]
|
|
208
|
+
**Current Behavior:** [What happens now]
|
|
209
|
+
**Required Behavior:** [What should happen]
|
|
210
|
+
**Fix Required:** [What needs to change]
|
|
211
|
+
|
|
212
|
+
## Dependencies
|
|
213
|
+
|
|
214
|
+
### Internal Dependencies
|
|
215
|
+
- [List internal dependencies]
|
|
216
|
+
|
|
217
|
+
### External Dependencies
|
|
218
|
+
- [List external dependencies]
|
|
219
|
+
|
|
220
|
+
## Risks and Concerns
|
|
221
|
+
|
|
222
|
+
| Risk | Likelihood | Impact | Mitigation |
|
|
223
|
+
| ------ | ------------ | ------------ | ---------- |
|
|
224
|
+
| [Risk] | High/Med/Low | High/Med/Low | [Strategy] |
|
|
225
|
+
```
|
|
226
|
+
|
|
227
|
+
---
|
|
228
|
+
|
|
229
|
+
## 03-XX-[component].md β Component Technical Specification
|
|
230
|
+
|
|
231
|
+
```markdown
|
|
232
|
+
# [Component Name]: [Feature Name]
|
|
233
|
+
|
|
234
|
+
> **Document**: 03-[component].md
|
|
235
|
+
> **Parent**: [Index](00-index.md)
|
|
236
|
+
|
|
237
|
+
## Overview
|
|
238
|
+
[What this component does and why]
|
|
239
|
+
|
|
240
|
+
## Architecture
|
|
241
|
+
|
|
242
|
+
### Current Architecture
|
|
243
|
+
[Describe current state]
|
|
244
|
+
|
|
245
|
+
### Proposed Changes
|
|
246
|
+
[Describe what changes]
|
|
247
|
+
|
|
248
|
+
## Implementation Details
|
|
249
|
+
|
|
250
|
+
### New Types/Interfaces
|
|
251
|
+
[Type definitions β use the project's language]
|
|
252
|
+
|
|
253
|
+
### New Functions/Methods
|
|
254
|
+
[Function signatures with documentation]
|
|
255
|
+
|
|
256
|
+
### Integration Points
|
|
257
|
+
[How this connects to other components]
|
|
258
|
+
|
|
259
|
+
## Code Examples
|
|
260
|
+
|
|
261
|
+
### Example 1: [Name]
|
|
262
|
+
[Code example]
|
|
263
|
+
|
|
264
|
+
## Error Handling
|
|
265
|
+
|
|
266
|
+
| Error Case | Handling Strategy | AR Ref |
|
|
267
|
+
| ---------- | ----------------- | ------ |
|
|
268
|
+
| [Error] | [Strategy] | AR #X |
|
|
269
|
+
|
|
270
|
+
> **Traceability:** Every error-handling strategy and design choice must reference the Ambiguity Register entry (AR #) that resolved it. See `00-ambiguity-register.md`. Only exceptions: universally obvious facts and zero-semantic-impact formatting.
|
|
271
|
+
|
|
272
|
+
## Testing Requirements
|
|
273
|
+
- Unit tests for [specific functionality]
|
|
274
|
+
- Integration tests for [interactions]
|
|
275
|
+
```
|
|
276
|
+
|
|
277
|
+
**Component document sizing:** one `03-XX-[component].md` per major component, or split into `03-XX-[component]-[sub].md` per sub-component. Keep each document manageable to author (aim well under ~30K tokens to write).
|
|
278
|
+
|
|
279
|
+
---
|
|
280
|
+
|
|
281
|
+
## 07-testing-strategy.md β Testing Strategy
|
|
282
|
+
|
|
283
|
+
```markdown
|
|
284
|
+
# Testing Strategy: [Feature Name]
|
|
285
|
+
|
|
286
|
+
> **Document**: 07-testing-strategy.md
|
|
287
|
+
> **Parent**: [Index](00-index.md)
|
|
288
|
+
|
|
289
|
+
## Testing Overview
|
|
290
|
+
|
|
291
|
+
### Coverage Goals
|
|
292
|
+
|
|
293
|
+
| Code type | Target |
|
|
294
|
+
| --------- | ------ |
|
|
295
|
+
| Core business logic | 90% |
|
|
296
|
+
| Supporting modules / services | 80% |
|
|
297
|
+
| UI / glue / configuration | 60% |
|
|
298
|
+
|
|
299
|
+
- Test names state behavior: `should [expected behavior] when [condition]`.
|
|
300
|
+
- Integration tests cover key workflows when applicable. E2E tests cover complete feature behavior
|
|
301
|
+
when feasible; otherwise record `N/A` and the concrete reason instead of building a new harness.
|
|
302
|
+
- Adjust targets per project in `01-requirements.md` (an AR-referenced decision) β never
|
|
303
|
+
silently.
|
|
304
|
+
|
|
305
|
+
## π¨ Specification Test Cases (MANDATORY β NON-NEGOTIABLE)
|
|
306
|
+
|
|
307
|
+
> These test cases are derived EXCLUSIVELY from requirements (`01-requirements.md`),
|
|
308
|
+
> component specs (`03-XX-*.md`), API contracts, RFCs, and the Ambiguity Register
|
|
309
|
+
> (`00-ambiguity-register.md`). They define expected behavior BEFORE any implementation exists.
|
|
310
|
+
>
|
|
311
|
+
> **IMMUTABLE ORACLE RULE:** Do NOT modify these expectations to match the implementation.
|
|
312
|
+
> If the implementation does not match a spec test case, the implementation is wrong β not the test.
|
|
313
|
+
>
|
|
314
|
+
> **Every spec test case MUST include a source reference** tracing it to the requirement,
|
|
315
|
+
> spec document, or AR entry that defines the expected behavior.
|
|
316
|
+
>
|
|
317
|
+
> The `Source` column lives **in this plan document** β it is not a code comment. When the
|
|
318
|
+
> executor turns an ST-case into a `.spec.test` file, the test's in-code traceability comment
|
|
319
|
+
> quotes the behavior in **plain language** (e.g. `// password must be at least 8 characters`),
|
|
320
|
+
> **never** the `Source` cell's `ST-`/`Req`/`AR #` id or a `requirements/` path β per the
|
|
321
|
+
> standards' Documentation ban (the planning folder is ephemeral; the test must stand alone).
|
|
322
|
+
|
|
323
|
+
### [Component/Feature 1]
|
|
324
|
+
|
|
325
|
+
| # | Input / Scenario | Expected Output / Behavior | Source |
|
|
326
|
+
|------|----------------------------|----------------------------------------|-------------------|
|
|
327
|
+
| ST-1 | [Concrete input or action] | [Concrete expected output or behavior] | [Req X.X / AR #X] |
|
|
328
|
+
| ST-2 | [Concrete input or action] | [Concrete expected output or behavior] | [Req X.X / AR #X] |
|
|
329
|
+
| ST-3 | [Error/edge scenario] | [Expected error type and message] | [Req X.X / AR #X] |
|
|
330
|
+
|
|
331
|
+
> **β οΈ AUTHORING RULE:** Derive expectations from the specification documents above. Do NOT
|
|
332
|
+
> imagine or infer what the implementation will produce. If the expected output cannot be
|
|
333
|
+
> determined from the spec, that is an ambiguity β add it to the Ambiguity Register and
|
|
334
|
+
> resolve it with the user before defining the test case.
|
|
335
|
+
>
|
|
336
|
+
> In a repo with an active quality profile these ST-case rows are excerpted **verbatim** into
|
|
337
|
+
> the spec-test-author agent's packet β excerpting is packeting, not restatement, so keep each
|
|
338
|
+
> row self-contained.
|
|
339
|
+
|
|
340
|
+
## Test Categories
|
|
341
|
+
|
|
342
|
+
### Specification Tests (from ST-cases above)
|
|
343
|
+
> Written BEFORE implementation. Filed as `[feature].spec.test.[ext]`.
|
|
344
|
+
|
|
345
|
+
| Test File | ST Cases Covered | Component |
|
|
346
|
+
| --------------------------- | ---------------- | ------------- |
|
|
347
|
+
| `[feature].spec.test.[ext]` | ST-1, ST-2, ST-3 | [Component 1] |
|
|
348
|
+
|
|
349
|
+
### Implementation Tests (edge cases, internals)
|
|
350
|
+
> Written AFTER implementation. Filed as `[feature].impl.test.[ext]`.
|
|
351
|
+
|
|
352
|
+
| Test File | Description | Priority |
|
|
353
|
+
| --------------------------- | ------------------------------------------------- | ------------ |
|
|
354
|
+
| `[feature].impl.test.[ext]` | [Edge cases, boundary conditions, internal logic] | High/Med/Low |
|
|
355
|
+
|
|
356
|
+
### Integration Tests
|
|
357
|
+
|
|
358
|
+
| Test | Components | Description |
|
|
359
|
+
| ----------- | ------------ | ------------- |
|
|
360
|
+
| [Test name] | [Components] | [Description] |
|
|
361
|
+
|
|
362
|
+
### End-to-End Tests
|
|
363
|
+
|
|
364
|
+
| Scenario | Steps | Expected Result |
|
|
365
|
+
| ---------- | ------- | --------------- |
|
|
366
|
+
| [Scenario] | [Steps] | [Result] |
|
|
367
|
+
|
|
368
|
+
## Test Data
|
|
369
|
+
|
|
370
|
+
### Fixtures Needed
|
|
371
|
+
[List test fixtures]
|
|
372
|
+
|
|
373
|
+
### Mock Requirements
|
|
374
|
+
[List any mocks needed β prefer real objects when possible]
|
|
375
|
+
|
|
376
|
+
## Verification Checklist
|
|
377
|
+
- [ ] All specification test cases (ST-*) defined with concrete input/output pairs
|
|
378
|
+
- [ ] Every ST case traces to a requirement, spec doc, or AR entry
|
|
379
|
+
- [ ] Specification tests written BEFORE implementation
|
|
380
|
+
- [ ] Specification tests verified to FAIL before implementation (red phase)
|
|
381
|
+
- [ ] All specification tests pass after implementation (green phase)
|
|
382
|
+
- [ ] Implementation tests written for edge cases and internals
|
|
383
|
+
- [ ] All unit / integration / E2E tests pass
|
|
384
|
+
- [ ] No regressions in existing tests
|
|
385
|
+
- [ ] Test coverage meets goals
|
|
386
|
+
```
|
|
387
|
+
|
|
388
|
+
---
|
|
389
|
+
|
|
390
|
+
## 99-execution-plan.md β Execution Plan
|
|
391
|
+
|
|
392
|
+
Every execution plan MUST follow this template, MUST carry each phase's tasks as a single
|
|
393
|
+
checkbox list (the plan's **single source of truth** for progress β a task line appears exactly
|
|
394
|
+
once in the document), and MUST structure feature phases with the specification-first ordering
|
|
395
|
+
(see the next section).
|
|
396
|
+
|
|
397
|
+
````markdown
|
|
398
|
+
# Execution Plan: [Feature Name]
|
|
399
|
+
|
|
400
|
+
> **Document**: 99-execution-plan.md
|
|
401
|
+
> **Parent**: [Index](00-index.md)
|
|
402
|
+
> **Last Updated**: [YYYY-MM-DD HH:MM]
|
|
403
|
+
> **Progress**: 0/X tasks (0%)
|
|
404
|
+
> **CodeOps Artifact Schema**: 1
|
|
405
|
+
|
|
406
|
+
## Overview
|
|
407
|
+
|
|
408
|
+
[Brief description of the feature implementation]
|
|
409
|
+
|
|
410
|
+
**π¨ Update this document after EACH completed task!**
|
|
411
|
+
|
|
412
|
+
---
|
|
413
|
+
|
|
414
|
+
## Implementation Phases
|
|
415
|
+
|
|
416
|
+
| Phase | Title | Tasks |
|
|
417
|
+
| ----- | -------------- | ----- |
|
|
418
|
+
| 1 | [Phase 1 Name] | X |
|
|
419
|
+
| 2 | [Phase 2 Name] | X |
|
|
420
|
+
|
|
421
|
+
**Total: X tasks across Y phases** (no fabricated hour estimates β scope is bounded by the
|
|
422
|
+
task-size criteria in [quality-checklist.md](quality-checklist.md))
|
|
423
|
+
|
|
424
|
+
> **β οΈ EXECUTION RULE β APPLIES TO EVERY AGENT EXECUTING THIS PLAN:**
|
|
425
|
+
>
|
|
426
|
+
> The task checkboxes in the phase sections below are the **single source of truth** for
|
|
427
|
+
> progress. Every task line appears exactly once in this document. The executing agent MUST:
|
|
428
|
+
>
|
|
429
|
+
> 1. **On implementation:** mark the task `[~]` with a timestamp β
|
|
430
|
+
> `- [~] 1.1.1 Task description β³ (implemented: YYYY-MM-DD HH:MM)`
|
|
431
|
+
> 2. **On verify pass:** promote it to `[x]` β
|
|
432
|
+
> `- [x] 1.1.1 Task description β
(completed: YYYY-MM-DD HH:MM)`
|
|
433
|
+
> 3. **Update the Progress header** (`> **Progress**: X/Y tasks (Z%)`) and the Last Updated
|
|
434
|
+
> stamp after EVERY task β never batch updates. Only `[x]` counts as complete.
|
|
435
|
+
> 4. **Resume** by scanning the phase sections top-to-bottom: the first `[~]` task is resumed
|
|
436
|
+
> first, else the first `[ ]` task.
|
|
437
|
+
> 5. **On blocker:** mark the task `[!]` and append `Blocked: <short reason>` on the same line.
|
|
438
|
+
> The plan lifecycle is `Ready`, `Executing`, `Done`, or `Blocked`, derived from these markers.
|
|
439
|
+
>
|
|
440
|
+
> Timestamps come from `date '+%Y-%m-%d %H:%M'` β never invented. Failure to keep the marks
|
|
441
|
+
> current means progress is invisible after crashes, context resets, or session handoffs.
|
|
442
|
+
|
|
443
|
+
---
|
|
444
|
+
|
|
445
|
+
## Phase 1: [Phase Name]
|
|
446
|
+
|
|
447
|
+
> **Phase baseline tree**: _(recorded by the exec-plan skill from a temporary-index snapshot of
|
|
448
|
+
> committed, staged, unstaged, and untracked phase-start state)_
|
|
449
|
+
> **Lenses**: [add-on lenses β include this line only when the target repo carries a quality
|
|
450
|
+
> profile; informational: activation stays profile-driven]
|
|
451
|
+
|
|
452
|
+
### Step 1.1: [Step Objective]
|
|
453
|
+
|
|
454
|
+
**Reference**: [Governing 03-doc Β§section] Β· [AR #s]
|
|
455
|
+
**Objective**: [What this step achieves]
|
|
456
|
+
|
|
457
|
+
- [ ] 1.1.1 [spec-author] Write specification tests from the 07 ST-cases β `[feature].spec.test.[ext]`
|
|
458
|
+
- [ ] 1.1.2 [Task description] β `path/to/file`
|
|
459
|
+
|
|
460
|
+
> Mark spec-test tasks with `[spec-author]`: in a repo with an active quality profile, the
|
|
461
|
+
> exec-plan skill dispatches the spec-test-author agent for them (packet per
|
|
462
|
+
> `_shared/quality-profile.md`); without a profile the marker is inert and the session writes
|
|
463
|
+
> the tests itself.
|
|
464
|
+
|
|
465
|
+
**Deliverables**:
|
|
466
|
+
- [ ] Deliverable 1
|
|
467
|
+
- [ ] All verification passing
|
|
468
|
+
|
|
469
|
+
**Verify**: [Project's verify command from AGENTS.md / detected conventions]
|
|
470
|
+
|
|
471
|
+
---
|
|
472
|
+
|
|
473
|
+
## Dependencies
|
|
474
|
+
|
|
475
|
+
```
|
|
476
|
+
Phase 1
|
|
477
|
+
β
|
|
478
|
+
Phase 2
|
|
479
|
+
β
|
|
480
|
+
...
|
|
481
|
+
```
|
|
482
|
+
|
|
483
|
+
---
|
|
484
|
+
|
|
485
|
+
## Success Criteria
|
|
486
|
+
|
|
487
|
+
**Feature is complete when:**
|
|
488
|
+
|
|
489
|
+
1. β
All phases completed
|
|
490
|
+
2. β
All verification passing (project's verify command)
|
|
491
|
+
3. β
No warnings/errors
|
|
492
|
+
4. β
No dead code β no unused parameters, functions, classes, or modules
|
|
493
|
+
5. β
Security hardened β input validation, injection prevention, auth, rate limiting, data protection
|
|
494
|
+
6. β
Documentation updated
|
|
495
|
+
7. β
Code reviewed (if applicable)
|
|
496
|
+
8. β
Post-completion project re-analysis (handled by the exec-plan skill)
|
|
497
|
+
````
|
|
498
|
+
|
|
499
|
+
> Detailed session-by-session execution mechanics (commit modes, real-time progress updates, post-completion re-analysis) belong to the **exec-plan skill**, not here.
|
|
500
|
+
|
|
501
|
+
---
|
|
502
|
+
|
|
503
|
+
## Specification-First Task Ordering (NON-NEGOTIABLE)
|
|
504
|
+
|
|
505
|
+
Every feature implementation phase in `99-execution-plan.md` MUST follow the three-step
|
|
506
|
+
specification-first ordering β `spec tests β red phase β implement β green phase β impl tests β
|
|
507
|
+
verify` β defined ONCE in **[../../_shared/spec-first-ordering.md](../../_shared/spec-first-ordering.md)**.
|
|
508
|
+
Read it before authoring the execution plan; it carries the full step structure, the compressed
|
|
509
|
+
small-feature form, the prohibited/required lists, and the immutable-oracle rule. Generated plans
|
|
510
|
+
must reference `07-testing-strategy.md` ST-cases in spec-test tasks and include a distinct
|
|
511
|
+
red-phase verification task.
|
|
512
|
+
|
|
513
|
+
---
|
|
514
|
+
|
|
515
|
+
## Adapting to Project Type
|
|
516
|
+
|
|
517
|
+
Adapt the component documents to the project type:
|
|
518
|
+
|
|
519
|
+
| Project Type | Typical Components |
|
|
520
|
+
| ------------------ | ---------------------------------------------- |
|
|
521
|
+
| **Web App** | Frontend, Backend, API, Database, Auth |
|
|
522
|
+
| **API / Backend** | Endpoints, Services, Data Models, Validation |
|
|
523
|
+
| **Library / SDK** | Core, Utils, Types, Public API |
|
|
524
|
+
| **CLI Tool** | Commands, Arguments, Output, Config |
|
|
525
|
+
| **UI Components** | Component, Styles, Hooks, Stories, Tests |
|
|
526
|
+
| **Mobile App** | UI, State, Services, Navigation |
|
|
527
|
+
| **Compiler** | Lexer, Parser, Analyzer, Generator |
|
|
528
|
+
| **Microservices** | Services, Events, Data, Integration |
|
|
529
|
+
| **Infrastructure** | Docker, Nginx, CI/CD, Deployment Scripts |
|
|
530
|
+
| **Database** | Schema/Migration, Repository, Service, Tests |
|
|
531
|
+
| **Bug Fix** | Root cause analysis, Fix, Regression test |
|
|
532
|
+
| **Refactoring** | Current state, New structure, Migration, Tests |
|
|
533
|
+
|
|
534
|
+
These are analysis lenses, not a required document count. Combine concerns when one clear,
|
|
535
|
+
reviewable component specification can own them.
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Phase 1C: Zero-Ambiguity Gate β caller preamble (make-plan)
|
|
2
|
+
|
|
3
|
+
> **CodeOps Artifact Schema**: 1
|
|
4
|
+
|
|
5
|
+
The gate itself is defined ONCE in **[../../_shared/zero-ambiguity-gate.md](../../_shared/zero-ambiguity-gate.md)**
|
|
6
|
+
β read it now, before Phase 2. This preamble only binds it to make-plan:
|
|
7
|
+
|
|
8
|
+
- **Phase**: 1C β fires after Phase 1 discovery, before any plan document except the incrementally
|
|
9
|
+
persisted register is written.
|
|
10
|
+
- **Blocked artifacts while closed**: every file in the plan folder except the incrementally
|
|
11
|
+
persisted register itself β `00-index.md`, `01-requirements.md`, `02-current-state.md`, all
|
|
12
|
+
`03-XX` specs, `07-testing-strategy.md`, `99-execution-plan.md`.
|
|
13
|
+
- **Register location**: `<plan folder>/00-ambiguity-register.md` (resolve the folder per
|
|
14
|
+
`_shared/layout-convention.md`).
|
|
15
|
+
- **Plan-specific scan notes**: pay extra attention to *Naming & terminology* (file/dir/class/
|
|
16
|
+
function/API names the plan will create) and *Technical unknowns* (architecture choices the
|
|
17
|
+
execution plan will commit to).
|
|
18
|
+
- Items pre-resolved by a grill-me session import as resolved/deferred rows and are not
|
|
19
|
+
re-confirmed; only new rows need the user's confirmation (shared gate, rule 3).
|