@punks/cli 5.2.0 → 5.2.2
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/README.md +2 -2
- package/dist/BASELINE_CHANGELOG.md +46 -1
- package/dist/CHANGELOG.md +37 -0
- package/dist/baseline/scaffold-baseline/baseline.json +15 -5
- package/dist/baseline/scaffold-baseline/data/catalog/packs.json +2 -0
- package/dist/baseline/scaffold-baseline/data/catalog/skills.json +16 -0
- package/dist/baseline/scaffold-baseline/data/hooks/format-edited-file.mjs +459 -318
- package/dist/baseline/scaffold-baseline/data/scripts/commit-gate-runner.d.ts +1 -0
- package/dist/baseline/scaffold-baseline/data/scripts/commit-gate-runner.mjs +98 -27
- package/dist/baseline/scaffold-baseline/data/scripts/commit-gate-runner.test.ts +156 -8
- package/dist/baseline/scaffold-baseline/data/scripts/managed-lint-runner.d.mts +55 -0
- package/dist/baseline/scaffold-baseline/data/scripts/managed-lint-runner.mjs +329 -0
- package/dist/baseline/scaffold-baseline/data/scripts/managed-lint-runner.test.ts +864 -0
- package/dist/baseline/scaffold-baseline/data/scripts/managed-lint.d.mts +97 -0
- package/dist/baseline/scaffold-baseline/data/scripts/managed-lint.mjs +658 -0
- package/dist/baseline/scaffold-baseline/data/scripts/managed-lint.test.ts +614 -0
- package/dist/baseline/scaffold-baseline/skills/agnostic/cli/hi-cli/SKILL.md +2 -0
- package/dist/baseline/scaffold-baseline/skills/agnostic/cli/hi-cli/references/commands.md +8 -9
- package/dist/baseline/scaffold-baseline/skills/agnostic/cli/hi-cli/references/managed-lint.md +165 -0
- package/dist/baseline/scaffold-baseline/skills/agnostic/cli/hi-cli/references/post-command-flow.md +28 -24
- package/dist/baseline/scaffold-baseline/skills/agnostic/cli/hi-cli/references/wiki-structure.md +16 -0
- package/dist/baseline/scaffold-baseline/skills/agnostic/docs/docs-onboarding/SKILL.md +21 -16
- package/dist/baseline/scaffold-baseline/skills/agnostic/docs/docs-onboarding/agents/openai.yaml +1 -1
- package/dist/baseline/scaffold-baseline/skills/agnostic/docs/docs-onboarding/references/artifact-contract.md +16 -4
- package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-architecture/SKILL.md +65 -0
- package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-architecture/assets/ARCHITECTURE-TEMPLATE.md +119 -0
- package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-architecture/references/artifact-contract.md +200 -0
- package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-plan/SKILL.md +11 -3
- package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-plan/references/architecture-convergence.md +19 -4
- package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-plan/references/plan-schema.md +17 -3
- package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-spec/SKILL.md +38 -20
- package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-spec/assets/SPEC-TEMPLATE.md +11 -0
- package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-spec/references/readiness.md +40 -0
- package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-spec/references/spec-quality-bar.md +8 -0
- package/dist/baseline/scaffold-baseline/skills/agnostic/planning/implement-spec/SKILL.md +4 -2
- package/dist/baseline/scaffold-baseline/skills/agnostic/planning/implement-spec/references/architecture-conformance.md +10 -6
- package/dist/baseline/scaffold-baseline/skills/agnostic/planning/implement-spec/references/lifecycle.md +23 -10
- package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/brainstorm/SKILL.md +22 -0
- package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/requirements-grill/SKILL.md +2 -1
- package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/requirements-grill/references/artifact-output.md +3 -2
- package/dist/baseline/scaffold-baseline/skills/phases/delivery-phase/SKILL.md +6 -3
- package/dist/baseline/scaffold-baseline/skills/phases/delivery-phase/phases/plan.md +4 -2
- package/dist/baseline/scaffold-baseline/skills/phases/delivery-phase/phases/review.md +5 -1
- package/dist/baseline/scaffold-baseline/skills/phases/delivery-phase/phases/router.md +15 -9
- package/dist/baseline/scaffold-baseline/skills/phases/delivery-phase/phases/spec.md +13 -26
- package/dist/baseline/scaffold-baseline/skills/phases/delivery-phase/references/artifact-state.md +39 -1
- package/dist/baseline/scaffold-baseline/skills/phases/requirements-phase/SKILL.md +31 -14
- package/dist/baseline/scaffold-baseline/skills/phases/review-phase/phases/prepare-review.md +12 -4
- package/dist/baseline/scaffold-baseline.json +5 -5
- package/dist/baseline/scaffold-baseline.tgz +0 -0
- package/dist/data/hooks/format-edited-file.d.mts +5 -0
- package/dist/data/hooks/format-edited-file.mjs +282 -333
- package/dist/data/scripts/commit-gate-runner.mjs +98 -27
- package/dist/data/scripts/managed-lint-runner.d.mts +55 -0
- package/dist/data/scripts/managed-lint-runner.mjs +329 -0
- package/dist/data/scripts/managed-lint.d.mts +97 -0
- package/dist/data/scripts/managed-lint.mjs +658 -0
- package/dist/index.js +86 -1184
- package/dist/skills/agnostic/cli/hi-cli/SKILL.md +2 -0
- package/dist/skills/agnostic/cli/hi-cli/references/commands.md +8 -9
- package/dist/skills/agnostic/cli/hi-cli/references/managed-lint.md +165 -0
- package/dist/skills/agnostic/cli/hi-cli/references/post-command-flow.md +15 -11
- package/dist/skills/agnostic/cli/hi-cli/references/wiki-structure.md +16 -0
- package/dist/skills/agnostic/docs/docs-onboarding/SKILL.md +21 -16
- package/dist/skills/agnostic/docs/docs-onboarding/agents/openai.yaml +1 -1
- package/dist/skills/agnostic/docs/docs-onboarding/references/artifact-contract.md +16 -4
- package/dist/skills/agnostic/planning/create-architecture/SKILL.md +65 -0
- package/dist/skills/agnostic/planning/create-architecture/assets/ARCHITECTURE-TEMPLATE.md +119 -0
- package/dist/skills/agnostic/planning/create-architecture/references/artifact-contract.md +200 -0
- package/dist/skills/agnostic/planning/create-plan/SKILL.md +11 -3
- package/dist/skills/agnostic/planning/create-plan/references/architecture-convergence.md +19 -4
- package/dist/skills/agnostic/planning/create-plan/references/plan-schema.md +17 -3
- package/dist/skills/agnostic/planning/create-spec/SKILL.md +38 -20
- package/dist/skills/agnostic/planning/create-spec/assets/SPEC-TEMPLATE.md +11 -0
- package/dist/skills/agnostic/planning/create-spec/references/readiness.md +40 -0
- package/dist/skills/agnostic/planning/create-spec/references/spec-quality-bar.md +8 -0
- package/dist/skills/agnostic/planning/implement-spec/SKILL.md +4 -2
- package/dist/skills/agnostic/planning/implement-spec/references/architecture-conformance.md +10 -6
- package/dist/skills/agnostic/planning/implement-spec/references/lifecycle.md +23 -10
- package/dist/skills/agnostic/requirements/brainstorm/SKILL.md +22 -0
- package/dist/skills/agnostic/requirements/requirements-grill/SKILL.md +2 -1
- package/dist/skills/agnostic/requirements/requirements-grill/references/artifact-output.md +3 -2
- package/dist/skills/phases/delivery-phase/SKILL.md +6 -3
- package/dist/skills/phases/delivery-phase/phases/plan.md +4 -2
- package/dist/skills/phases/delivery-phase/phases/review.md +5 -1
- package/dist/skills/phases/delivery-phase/phases/router.md +15 -9
- package/dist/skills/phases/delivery-phase/phases/spec.md +13 -26
- package/dist/skills/phases/delivery-phase/references/artifact-state.md +39 -1
- package/dist/skills/phases/requirements-phase/SKILL.md +31 -14
- package/dist/skills/phases/review-phase/phases/prepare-review.md +12 -4
- package/package.json +3 -2
|
@@ -8,7 +8,7 @@ Execution uses plan-derived tasks and parent-owned Task Gates. Read
|
|
|
8
8
|
[parallel.md](parallel.md) for Execution Frontier and Active Write Scope rules;
|
|
9
9
|
shared lifecycle rules remain here.
|
|
10
10
|
|
|
11
|
-
## 1. Require
|
|
11
|
+
## 1. Require the current agent-ready Architecture/SPEC pair
|
|
12
12
|
|
|
13
13
|
Execution must stay grounded in the first matching spec folder:
|
|
14
14
|
|
|
@@ -18,13 +18,17 @@ Execution must stay grounded in the first matching spec folder:
|
|
|
18
18
|
|
|
19
19
|
Required files:
|
|
20
20
|
|
|
21
|
+
- `ARCHITECTURE.md`
|
|
21
22
|
- `SPEC.md`
|
|
22
23
|
- `PLAN.md`
|
|
23
24
|
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
25
|
+
Before any execution or resumed repair, apply the
|
|
26
|
+
**Architecture/SPEC Pair Complete** gate in the installed `delivery-phase`
|
|
27
|
+
skill's `references/artifact-state.md`,
|
|
28
|
+
including direct invocation, existing work and `local` plans. Missing, stale or
|
|
29
|
+
conflicting proof routes the exact gap to Requirements Phase /
|
|
30
|
+
`requirements-grill`. Require the plan to reference that same retained pair.
|
|
31
|
+
Compiler readiness needs no separate spec review or approval state.
|
|
28
32
|
|
|
29
33
|
If `PLAN.md` is missing, stop and use `create-plan`. Do not auto-generate plans from this skill.
|
|
30
34
|
|
|
@@ -34,7 +38,7 @@ Accept either:
|
|
|
34
38
|
|
|
35
39
|
- a domain plus spec folder name
|
|
36
40
|
- a full spec folder path
|
|
37
|
-
- a direct `SPEC.md` or `PLAN.md` path
|
|
41
|
+
- a direct `ARCHITECTURE.md`, `SPEC.md` or `PLAN.md` path
|
|
38
42
|
|
|
39
43
|
Normalize to the containing spec folder before doing any work.
|
|
40
44
|
|
|
@@ -43,10 +47,19 @@ Normalize to the containing spec folder before doing any work.
|
|
|
43
47
|
Read, in this order:
|
|
44
48
|
|
|
45
49
|
1. `apps/wiki/AGENTS.md`
|
|
46
|
-
2. `<resolved-spec-folder>/
|
|
47
|
-
3. `<resolved-spec-folder>/
|
|
48
|
-
4. `<resolved-spec-folder>/
|
|
49
|
-
5.
|
|
50
|
+
2. `<resolved-spec-folder>/ARCHITECTURE.md`
|
|
51
|
+
3. `<resolved-spec-folder>/SPEC.md`
|
|
52
|
+
4. `<resolved-spec-folder>/PLAN.md`
|
|
53
|
+
5. `<resolved-spec-folder>/IMPLEMENTATION-NOTES.md` if present
|
|
54
|
+
6. `docs/reference/tech-debt/<domain>/<spec>.md` if present
|
|
55
|
+
|
|
56
|
+
Carry the pair's exact retained source identities and required architecture
|
|
57
|
+
decision selectors, mapped spec codes and source Q evidence in worker Context Pointers, Read Dependencies and Relevant
|
|
58
|
+
Input Sets. Recheck them before dependent dispatch, Task Gates and finalization.
|
|
59
|
+
Refresh changed sources through existing freshness gates; preserve unaffected
|
|
60
|
+
proof and historical review lineage. Missing plan pointers return to
|
|
61
|
+
`create-plan`; missing or conflicting accepted design returns to Requirements
|
|
62
|
+
Phase / `requirements-grill`.
|
|
50
63
|
|
|
51
64
|
When `PLAN.md` declares architecture applicability as `architecture-bearing`,
|
|
52
65
|
also read [architecture-conformance.md](architecture-conformance.md) before
|
|
@@ -15,6 +15,9 @@ description: Brainstorm a bounded system from the operating agent’s perspectiv
|
|
|
15
15
|
legible to an agent. Trace intake, state, control, feedback, recovery, and
|
|
16
16
|
handoff through that tower. Account for each applicable surface with
|
|
17
17
|
evidence, or record why it does not apply.
|
|
18
|
+
For software flows, apply Flow failure lenses below. Account for each lens
|
|
19
|
+
with grounded findings, an explicit unknown, or a reason it does not apply.
|
|
20
|
+
Surface material gaps as candidate decisions within the accepted scope.
|
|
18
21
|
3. Derive the smallest changes that make the system agent-intuitive (clear
|
|
19
22
|
meaning), agent-ergonomic (efficient control), and agent-accretive (reusable
|
|
20
23
|
verified knowledge benefiting later runs). For each candidate, state
|
|
@@ -26,3 +29,22 @@ description: Brainstorm a bounded system from the operating agent’s perspectiv
|
|
|
26
29
|
4. Return evidence-grounded observations and unresolved decisions. Completion
|
|
27
30
|
requires every observation to trace to evidence or an explicit unknown.
|
|
28
31
|
Observations remain candidates until the caller accepts them.
|
|
32
|
+
|
|
33
|
+
### Flow failure lenses
|
|
34
|
+
|
|
35
|
+
Approach the problem through an end-to-end control-flow, state-consistency and failure-recovery lens. Examine:
|
|
36
|
+
|
|
37
|
+
1. Entry points and path convergence: where can this behavior start? Do equivalent actions reach the same rules, or take divergent/bypass paths?
|
|
38
|
+
2. Critical execution paths: what must happen, in which order? Where does execution branch, wait, delegate or continue asynchronously?
|
|
39
|
+
3. State ownership and authority: what state changes, who owns it, who may change it, and which representation is authoritative?
|
|
40
|
+
4. Transaction and side-effect boundaries: what commits together? Which effects occur outside that boundary? What intermediate states can become visible?
|
|
41
|
+
5. Concurrency and stale state: what if two actors run this simultaneously, or state changes between validation and execution?
|
|
42
|
+
6. Idempotency and retries: what happens when a request is repeated, execution resumes, or an acknowledgement is lost after success?
|
|
43
|
+
7. Partial failure and recovery: what remains after failure at each boundary? Can we safely retry, reconcile, compensate or roll back?
|
|
44
|
+
8. Execution lifetime and durability: what survives a disconnect, cancellation or process crash? Who owns unfinished work?
|
|
45
|
+
9. Lifecycle and dependency transitions: what happens during creation, update, replacement and removal? What still depends on the old state?
|
|
46
|
+
10. Completion and observability: what proves the requested outcome occurred? Can an operator distinguish accepted, applied, running, failed and partially complete?
|
|
47
|
+
|
|
48
|
+
Use these lenses to surface missing architectural decisions before treating the flow as understood. Ground concerns in the actual system; propose mechanisms only for supported risks.
|
|
49
|
+
|
|
50
|
+
Completion: each applicable lens is covered by evidence or an explicit unknown; non-applicable lenses have a reason. Each material gap is recorded as a candidate decision, with its evidence or unknown and the guarantee at stake.
|
|
@@ -35,7 +35,8 @@ Both workflows can happen in one long session, but keep the responsibilities dis
|
|
|
35
35
|
- Give `$domain-modeling` the active status glossary before the first question. Invoke it whenever a round changes terminology, relationships, or domain decisions, and persist its accepted results through `artifact-output` before continuing.
|
|
36
36
|
- Inspect relevant routed learning artifacts before grilling requirements that depend on known behavior, prior bugs, project conventions, or domain facts.
|
|
37
37
|
- Before `$grilling` constructs the first frontier, identify every active code- or architecture-bearing branch and complete the technical grounding in `grilling-flow`. Ground each branch in current code evidence, then ask code-grounded questions about its applicable topology, dependency direction and injection, seams, boundaries, persistence, and module shape. Each technical question states the observed constraint and the code consequence of the decision. Persist accepted design in the grill artifacts; keep `GLOSSARY.md` glossary-only.
|
|
38
|
-
- After technical grounding, complete `$brainstorm` before the first frontier. Add its unresolved decisions to the design tree; treat all output as candidate material until accepted.
|
|
38
|
+
- After technical grounding, complete `$brainstorm` before the first frontier. Add its unresolved decisions to the design tree; treat all output as candidate material until accepted.
|
|
39
|
+
- **Response-set checkpoint:** After every `$grilling` response set, including an incomplete frontier response, record supplied answers through `artifact-output`, then invoke `$brainstorm` against updated decisions and evidence before computing and persisting the next frontier or requesting closure. Recheck its applicable lenses, reusing still-valid evidence and tracing changed decisions through affected paths and dependent branches. Add newly exposed uncertainties and decisions to the existing technical grounding record and design tree. The review is complete when every new material finding is resolved, queued, or explicitly parked/deferred; queued findings remain open under the existing branch and grill closure rules. Preserve stable question IDs and accepted decisions; surface contradictions as explicit questions.
|
|
39
40
|
- Prefer conservative defaults once enough context exists.
|
|
40
41
|
- If the user authorizes auto-pinning defaults, record obvious remaining defaults without needless extra questions.
|
|
41
42
|
- Treat parked branches as preserved knowledge, not deleted scope.
|
|
@@ -128,8 +128,9 @@ After each response set:
|
|
|
128
128
|
1. Process every supplied answer separately against its stable question id.
|
|
129
129
|
2. Add answered decisions to the log and mark those ids `answered` in status.
|
|
130
130
|
3. Leave omitted questions `unanswered`; do not infer an answer or drop them from status.
|
|
131
|
-
4.
|
|
132
|
-
5.
|
|
131
|
+
4. Complete the [response-set checkpoint](../SKILL.md#core-behavior).
|
|
132
|
+
5. Compute the next frontier and persist the updated status, including the frontier and branch dashboard, before continuing.
|
|
133
|
+
6. When the frontier is empty, set confirmation to `pending`; set it to `confirmed` only after the user explicitly confirms shared understanding.
|
|
133
134
|
|
|
134
135
|
## Status File Contract
|
|
135
136
|
|
|
@@ -11,7 +11,7 @@ disable-model-invocation: true
|
|
|
11
11
|
`delivery-phase` is a reusable phase router.
|
|
12
12
|
|
|
13
13
|
1. Read [phases/router.md](phases/router.md).
|
|
14
|
-
2. Inspect only enough issue, spec, plan, notes, diff, retained review, durable
|
|
14
|
+
2. Inspect only enough issue, architecture, spec, plan, notes, diff, retained review, durable
|
|
15
15
|
handoff, validation, and docs state to choose the current gate.
|
|
16
16
|
3. If approved artifact links or UI Evidence links are present, carry them as routing evidence.
|
|
17
17
|
4. Load exactly one phase file from `phases/`.
|
|
@@ -29,7 +29,7 @@ Within accepted bounds, full delivery grants its selected inner steps the author
|
|
|
29
29
|
## Phase Files
|
|
30
30
|
|
|
31
31
|
- [phases/router.md](phases/router.md): choose the next phase from artifacts and evidence.
|
|
32
|
-
- [phases/spec.md](phases/spec.md):
|
|
32
|
+
- [phases/spec.md](phases/spec.md): route missing or stale Architecture/SPEC proof to Requirements Phase.
|
|
33
33
|
- [phases/backlog.md](phases/backlog.md): verify or project the agent-ready spec into delivery backlog items.
|
|
34
34
|
- [phases/plan.md](phases/plan.md): create or repair the execution-ready plan.
|
|
35
35
|
- [phases/implement.md](phases/implement.md): execute the accepted plan.
|
|
@@ -43,7 +43,10 @@ Within accepted bounds, full delivery grants its selected inner steps the author
|
|
|
43
43
|
## Router Rules
|
|
44
44
|
|
|
45
45
|
- Read `router.md` and its continuity contract before selecting exactly one phase.
|
|
46
|
-
-
|
|
46
|
+
- Require the [Architecture/SPEC pair](references/artifact-state.md#architecturespec-pair-complete)
|
|
47
|
+
before dependent dispatch in every entry mode, including local and resumed
|
|
48
|
+
delivery. Reuse fresh matching authority; activate child skills only from
|
|
49
|
+
their selected phase.
|
|
47
50
|
- Full Delivery continues within accepted bounds. Other modes emit one common
|
|
48
51
|
Phase Result and stop at their requested boundary.
|
|
49
52
|
- [references/context-continuity.md](references/context-continuity.md) owns
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Plan Phase
|
|
2
2
|
|
|
3
|
-
Use this phase when a matching
|
|
3
|
+
Use this phase when a matching Architecture/SPEC pair exists but no execution-ready `PLAN.md`
|
|
4
4
|
exists, or the plan is stale, vague, or missing validation gates.
|
|
5
5
|
|
|
6
6
|
## Delegate
|
|
@@ -9,7 +9,9 @@ Load `create-plan` only after this phase is selected.
|
|
|
9
9
|
|
|
10
10
|
## Checks Before Delegating
|
|
11
11
|
|
|
12
|
-
- Verify the
|
|
12
|
+
- Verify the [Architecture/SPEC pair](../references/artifact-state.md#architecturespec-pair-complete)
|
|
13
|
+
still matches the requested goal. Carry both retained source identities and
|
|
14
|
+
decision selectors into plan Context Pointers and task Read Dependencies.
|
|
13
15
|
- Preserve tracker hierarchy and every child-story or sub-issue requirement.
|
|
14
16
|
- Require dependencies, Active Write Scopes, Read Dependencies, Shared Runtime
|
|
15
17
|
Resources, Relevant Input Set identities, validation gates, review routing and
|
|
@@ -6,7 +6,11 @@ current snapshot.
|
|
|
6
6
|
|
|
7
7
|
## Prepare Review
|
|
8
8
|
|
|
9
|
-
1.
|
|
9
|
+
1. Recheck the [Architecture/SPEC pair](../references/artifact-state.md#architecturespec-pair-complete)
|
|
10
|
+
before review or retained-state resume. Carry the exact architecture identity
|
|
11
|
+
and required decision selectors as governing review sources alongside Spec
|
|
12
|
+
and plan, including in the frozen Review Packet.
|
|
13
|
+
Require implementation, applicable task checks and Task Gates, Verification,
|
|
10
14
|
parent shared-summary reconciliation, Architecture Checkpoints and final
|
|
11
15
|
acceptance evidence. Missing or stale proof returns the exact owning gate;
|
|
12
16
|
it cannot enter Code Review. Review consumes Verification evidence while
|
|
@@ -8,10 +8,16 @@ Choose one next phase from current durable authority.
|
|
|
8
8
|
2. Preserve terminal `human_steering_required` until current user direction
|
|
9
9
|
resolves the required decision. New boundary evidence selects
|
|
10
10
|
[human-steering.md](human-steering.md).
|
|
11
|
-
3.
|
|
11
|
+
3. Before any dependent dispatch, require the
|
|
12
|
+
[Architecture/SPEC Pair Complete gate](../references/artifact-state.md#architecturespec-pair-complete)
|
|
13
|
+
for every delivery, including existing, resumed and local work. Missing,
|
|
14
|
+
stale or conflicting architecture/spec proof routes the exact gap to
|
|
15
|
+
Requirements Phase / `requirements-grill` before review, repair, debug,
|
|
16
|
+
implementation or closeout can resume. Preserve review lineage and counts.
|
|
17
|
+
4. For failed tasks or repair evidence, apply
|
|
12
18
|
[failure continuity](../references/failure-continuity.md). Independent eligible
|
|
13
19
|
work continues through the implementation owner's gates.
|
|
14
|
-
|
|
20
|
+
5. Recover review lineage, valid completed ordinals and durable active repair
|
|
15
21
|
state separately from current evidence freshness. Review due, retention pending,
|
|
16
22
|
unrouted findings, or budget decisions select [review.md](review.md), the sole
|
|
17
23
|
delivery review-transition authority. It validates bounds and target before
|
|
@@ -21,21 +27,21 @@ Choose one next phase from current durable authority.
|
|
|
21
27
|
Route legacy `focused_validation` to its recorded implementation/debugging
|
|
22
28
|
owner and `clean_handoff` to remaining docs or closeout after checking proof.
|
|
23
29
|
Reuse recorded run IDs and debt keys; a resume cannot consume them twice.
|
|
24
|
-
|
|
30
|
+
6. Before planning, require the pair's agent-ready `SPEC.md` with verified remote
|
|
25
31
|
retention and its current Write Backlog result through the
|
|
26
|
-
[
|
|
32
|
+
[Backlog Projection Complete gate](../references/artifact-state.md#backlog-projection-complete).
|
|
27
33
|
Missing, stale or contradictory required proof routes the exact gap to
|
|
28
|
-
Requirements Phase before planning. It owns Requirements Grill, Create
|
|
29
|
-
and Write Backlog. Valid current proof proceeds without a new approval gate;
|
|
34
|
+
Requirements Phase before planning. It owns Requirements Grill, Create Architecture,
|
|
35
|
+
Create Spec and Write Backlog. Valid current proof proceeds without a new approval gate;
|
|
30
36
|
optional Finder context is passed only when supplied, never manufactured.
|
|
31
|
-
|
|
37
|
+
7. A missing or stale execution plan selects [plan.md](plan.md). Incomplete plan
|
|
32
38
|
work, invalidated implementation evidence or an observed provider lifecycle
|
|
33
39
|
fact lacking exact readback selects [implement.md](implement.md).
|
|
34
|
-
|
|
40
|
+
8. Completed implementation needing Code Review selects [review.md](review.md).
|
|
35
41
|
Accepted repair follows that same transition authority's Focused Repair
|
|
36
42
|
Validation and risk-triggered second-pass rules. Passing ordinary focused
|
|
37
43
|
checks proceed without automatically reopening Code Review.
|
|
38
|
-
|
|
44
|
+
9. Remaining docs-affecting work selects [docs-ingest.md](docs-ingest.md), otherwise
|
|
39
45
|
[closeout.md](closeout.md). A fresh completed closeout needs no repeated mutation.
|
|
40
46
|
|
|
41
47
|
Read only the selected phase. Each exit emits the common Phase Result. Full
|
|
@@ -1,36 +1,23 @@
|
|
|
1
1
|
# Spec Phase
|
|
2
2
|
|
|
3
|
-
Use this phase when
|
|
4
|
-
|
|
3
|
+
Use this phase when the required Architecture/SPEC pair is missing, stale or
|
|
4
|
+
conflicting. Apply the
|
|
5
|
+
[Architecture/SPEC Pair Complete gate](../references/artifact-state.md#architecturespec-pair-complete).
|
|
5
6
|
|
|
6
7
|
## Delegate
|
|
7
8
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
-
|
|
13
|
-
- Reuse existing spec artifacts when they match the requested scope.
|
|
14
|
-
- Treat child stories, sub-issues, acceptance criteria, constraints, and non-goals as required input, not loose references.
|
|
15
|
-
- If requirements are unsettled, return the compiler's `spec-not-ready` result
|
|
16
|
-
and route each named gap upstream instead of interviewing here.
|
|
9
|
+
Return the bounded goal, exact artifact/decision gap and current source pointers
|
|
10
|
+
to Requirements Phase. It owns `requirements-grill -> create-architecture ->
|
|
11
|
+
create-spec -> write-backlog`. Pass optional Finder context only when supplied.
|
|
12
|
+
Reuse matching current retained artifacts; unsettled decisions return to
|
|
13
|
+
`requirements-grill` before either compiler runs.
|
|
17
14
|
|
|
18
15
|
## Completion State
|
|
19
16
|
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
- `readiness: agent-ready`
|
|
24
|
-
- `spec-written`
|
|
25
|
-
- verify the retained ref contains the spec commit
|
|
26
|
-
- construct and verify a stable blob URL before backlog
|
|
27
|
-
- source issue/tracker/spec folder
|
|
28
|
-
|
|
29
|
-
Then stop or re-enter `delivery-phase` for routing.
|
|
30
|
-
|
|
31
|
-
This completion state satisfies the downstream spec gate. Do not add a spec
|
|
32
|
-
review or approval stop unless the user explicitly requested a HITL checkpoint.
|
|
17
|
+
Verify the retained Architecture/SPEC pair and its exact identities, verified
|
|
18
|
+
immutable blob URLs and source selectors. Backlog projection must name that
|
|
19
|
+
spec identity. Compiler readiness needs no additional approval gate.
|
|
33
20
|
|
|
34
21
|
Emit the [common Phase Result](../references/context-continuity.md#common-phase-result)
|
|
35
|
-
with pointers to
|
|
36
|
-
otherwise stop at the requested boundary.
|
|
22
|
+
with pointers to the resulting proof or exact gap. Continue only in Full
|
|
23
|
+
Delivery; otherwise stop at the requested boundary.
|
|
@@ -2,6 +2,43 @@
|
|
|
2
2
|
|
|
3
3
|
Use this reference when deciding whether a phase is complete enough to skip.
|
|
4
4
|
|
|
5
|
+
## Architecture/SPEC Pair Complete
|
|
6
|
+
|
|
7
|
+
Require this pair for every delivery, including fresh, existing, resumed and
|
|
8
|
+
local work, before planning, implementation, review, repair, debugging, docs or
|
|
9
|
+
closeout dispatch. `architecture_applicability` controls plan convergence detail,
|
|
10
|
+
never whether `ARCHITECTURE.md` is required.
|
|
11
|
+
|
|
12
|
+
- The sibling `ARCHITECTURE.md` satisfies the
|
|
13
|
+
artifact contract in the installed `create-architecture` skill's
|
|
14
|
+
`references/artifact-contract.md`
|
|
15
|
+
with `status: compiled` and `readiness: agent-ready`; `SPEC.md` satisfies
|
|
16
|
+
**Spec Complete** below. Both name the same capability and current accepted
|
|
17
|
+
grill decisions.
|
|
18
|
+
- Verify retained commit/ref, immutable blob URL and matching bytes for each
|
|
19
|
+
artifact. The spec's `Architecture Source` and `links` identify that exact
|
|
20
|
+
retained architecture, not a mutable path or a different revision.
|
|
21
|
+
- Resolve architecture source identities and decision selectors against current
|
|
22
|
+
grill status/log, glossary and required evidence. Use existing
|
|
23
|
+
[Context Pointers and freshness rules](context-continuity.md), not timestamps.
|
|
24
|
+
Spec requirements, outcomes and acceptance criteria remain authoritative;
|
|
25
|
+
accepted design constraints come from the architecture companion and are
|
|
26
|
+
incorporated in the spec. Neither silently overrides the other.
|
|
27
|
+
- Verify complete **Spec traceability** under that architecture contract: every
|
|
28
|
+
current `OUT-###` / `AC-###` resolves to stable architecture selectors (or its
|
|
29
|
+
justified no-structural-counterpart entry) and exact source Q/log-entry evidence
|
|
30
|
+
anchors. Check the real codes, selectors, anchors and spec backlinks against
|
|
31
|
+
the retained pair and current decisions. Pending, dangling, stale, unsupported
|
|
32
|
+
or incomplete mapping blocks dispatch; route the exact gap to Requirements.
|
|
33
|
+
- Carry both source identities and required decision selectors in the action's
|
|
34
|
+
Context Pointers. Changed inputs invalidate affected dependent proof; keep
|
|
35
|
+
historical review lineage, report identities and completed ordinals intact.
|
|
36
|
+
- A missing, stale, conflicting or unreconstructable pair blocks its dependent
|
|
37
|
+
action and routes the exact artifact, selector and missing proof to
|
|
38
|
+
Requirements Phase / `requirements-grill`. Recompile architecture before spec
|
|
39
|
+
when accepted decisions change. Legacy/local artifacts have no exemption;
|
|
40
|
+
matching current proof adds no human approval gate.
|
|
41
|
+
|
|
5
42
|
## Spec Complete
|
|
6
43
|
|
|
7
44
|
- A matching agent-ready `SPEC.md` has `readiness: agent-ready`; its scope is
|
|
@@ -17,7 +54,8 @@ Use this reference when deciding whether a phase is complete enough to skip.
|
|
|
17
54
|
|
|
18
55
|
## Plan Complete
|
|
19
56
|
|
|
20
|
-
- `PLAN.md` exists and matches the
|
|
57
|
+
- `PLAN.md` exists and matches the current Architecture/SPEC pair, carrying
|
|
58
|
+
both source identities and required decision selectors through Context Pointers.
|
|
21
59
|
- One uniform `task_identity_mode` applies. In `provider-task` mode every `Tn`
|
|
22
60
|
resolves one stable provider Task ID and URL, preserves the same `V*`, and
|
|
23
61
|
mirrors native blocker edges through `depends_on`. In `planning-only` mode
|
|
@@ -7,11 +7,12 @@ disable-model-invocation: true
|
|
|
7
7
|
# Requirements Phase
|
|
8
8
|
|
|
9
9
|
Requirements Phase is independently invocable. It is the only orchestration
|
|
10
|
-
route for `requirements-grill -> create-spec -> write-backlog`.
|
|
10
|
+
route for `requirements-grill -> create-architecture -> create-spec -> write-backlog`.
|
|
11
11
|
|
|
12
12
|
## Inputs
|
|
13
13
|
|
|
14
|
-
- Direct bounded requirements input
|
|
14
|
+
- Direct bounded requirements input, including any narrower caller-supplied
|
|
15
|
+
provider projection boundary. This route creates no Fog or Finder
|
|
15
16
|
artifact and no Grilling provider item implicitly.
|
|
16
17
|
- Optional Finder context, only when the caller supplies a Fog, Finder child,
|
|
17
18
|
Research child, Prototype child, or durable Finder handoff. Resolve the exact
|
|
@@ -32,24 +33,40 @@ workflow or a Finder lifecycle owner.
|
|
|
32
33
|
interview. Research recommendations are evidence, not decisions. Complete
|
|
33
34
|
this step when every material branch is accepted or explicitly parked.
|
|
34
35
|
4. When the user confirms shared understanding and the remaining branches are
|
|
35
|
-
closed or explicitly parked, invoke `create-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
result
|
|
43
|
-
|
|
36
|
+
closed or explicitly parked, invoke `create-architecture` with the current
|
|
37
|
+
grill status and log. Require its
|
|
38
|
+
artifact contract in the installed `create-architecture` skill's
|
|
39
|
+
`references/artifact-contract.md`:
|
|
40
|
+
sibling `ARCHITECTURE.md`, `status: compiled`, `readiness: agent-ready`, exact
|
|
41
|
+
source identities and accepted details, and verified retained blob URL.
|
|
42
|
+
Architecture compilation precedes `SPEC.md` and requires no spec input.
|
|
43
|
+
An `architecture-not-ready` result returns each exact gap to its upstream
|
|
44
|
+
owner; unresolved decisions return to `requirements-grill`.
|
|
45
|
+
5. After `architecture-written`, invoke `create-spec` with that exact retained
|
|
46
|
+
architecture and the same confirmed sources. Create Spec assigns real outcome
|
|
47
|
+
and criterion codes, completes the architecture's canonical Spec traceability
|
|
48
|
+
mapping, and retains the enriched architecture before binding its final
|
|
49
|
+
immutable identity in the spec. This metadata amendment accepts no new design.
|
|
50
|
+
The compiler preserves source question anchors and unchanged codes/selectors.
|
|
51
|
+
This order applies to every delivery, including existing, resumed and local
|
|
52
|
+
work; reuse only current, matching retained artifacts with complete mapping.
|
|
53
|
+
6. Require `create-spec` to verify both retained artifact URLs and the spec's
|
|
54
|
+
reference to the enriched architecture, then push or explicitly retain the
|
|
55
|
+
spec commit before `write-backlog` can run. Pending or unresolved mappings and
|
|
56
|
+
local-only artifacts return the compiler's atomic `spec-not-ready` result.
|
|
57
|
+
7. Honor the caller's accepted provider projection boundary; missing authority
|
|
58
|
+
returns a blocked backlog delta while retaining the compiled pair.
|
|
59
|
+
After `spec-written`, pass the verified stable blob URL and current provider
|
|
44
60
|
evidence to `write-backlog`. Write Backlog derives the Stories, Tasks, and
|
|
45
61
|
blocker graph supported by the accepted result. With no prior Finder
|
|
46
62
|
projection, it may reuse, enrich, or create the accepted placement through
|
|
47
63
|
Product Area, Initiative, and Epic before placing those delivery items. Each
|
|
48
64
|
Story is a shippable product outcome. Each Task is atomic, independently
|
|
49
65
|
ownable, and understandable from its Story and stable specification.
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
residual delta. The result is ready for
|
|
66
|
+
8. Return one stable Requirements result naming the retained architecture and
|
|
67
|
+
specification, their exact identities and verified stable blob URLs, plus the
|
|
68
|
+
Write Backlog result and exact residual delta. The result is ready for
|
|
69
|
+
`delivery-phase` and `create-plan`.
|
|
53
70
|
|
|
54
71
|
## Boundary
|
|
55
72
|
|
|
@@ -12,7 +12,7 @@ and no valid later-state evidence already owns the run.
|
|
|
12
12
|
- accepted-bounds identity, scope, and primitive evidence
|
|
13
13
|
- delivery Git/diff or standalone artifact target primitives
|
|
14
14
|
- governing Spec, Standards, scoped guidance, named-skill, plan, and
|
|
15
|
-
implementation-note sources
|
|
15
|
+
implementation-note sources; retained Architecture for delivery mode
|
|
16
16
|
- delivery-goal identity and retained-report candidates for delivery mode
|
|
17
17
|
- caller evidence needed to explain a retry, failure, or current route
|
|
18
18
|
|
|
@@ -29,7 +29,14 @@ reconciles retained-pass recovery, and owns the exit evidence.
|
|
|
29
29
|
1. Validate accepted bounds and normalize the smallest-certain supported target
|
|
30
30
|
before reading or evaluating any delivery review counter. Unsupported target
|
|
31
31
|
or invalid bounds evidence is terminal even when a delivery counter is 2 or a preserved legacy 3.
|
|
32
|
-
2.
|
|
32
|
+
2. For delivery mode, verify the
|
|
33
|
+
[Architecture/SPEC pair](../../delivery-phase/references/artifact-state.md#architecturespec-pair-complete)
|
|
34
|
+
before review preparation continues. Missing, stale or conflicting proof returns
|
|
35
|
+
`review_context_blocked` with the exact gap for Requirements Phase /
|
|
36
|
+
`requirements-grill`, preserving lineage and completed ordinals. Include the
|
|
37
|
+
architecture's exact retained identity and required decision selectors in
|
|
38
|
+
governing sources and Review Packet facts; use existing source-set hashing.
|
|
39
|
+
Recompute the accepted-bounds hash, normalized target, inclusive scope,
|
|
33
40
|
snapshot hash, governing source paths and blob hashes, and source-set hash
|
|
34
41
|
from primitive current evidence.
|
|
35
42
|
3. Derive delivery lineage only from stable delivery-goal identity. Derive
|
|
@@ -67,8 +74,9 @@ reconciles retained-pass recovery, and owns the exit evidence.
|
|
|
67
74
|
`recovered review_count + 1` and derive `review_run_id` from lineage and that
|
|
68
75
|
ordinal. In standalone mode derive `review_run_id` from lineage and
|
|
69
76
|
`snapshot12`.
|
|
70
|
-
6. Freeze the [Review Packet](../references/review-packet.md), including
|
|
71
|
-
plan, skill guidance, Verification
|
|
77
|
+
6. Freeze the [Review Packet](../references/review-packet.md), including
|
|
78
|
+
Architecture for delivery mode, Spec, plan, skill guidance, Verification
|
|
79
|
+
evidence and relevant dependency pointers.
|
|
72
80
|
Assemble complete `review_running` predecessor evidence. Preparation ends
|
|
73
81
|
before any review lens, validation command, report write, retention action,
|
|
74
82
|
counter projection, or repair routing.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@punks/cli",
|
|
3
|
-
"version": "5.2.
|
|
3
|
+
"version": "5.2.2",
|
|
4
4
|
"description": "Harness Intelligence scaffolding CLI",
|
|
5
5
|
"homepage": "https://github.com/wearedevpunks/harness-intelligence/tree/main/apps/cli#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
"test": "vitest run --config vitest.config.ts --maxWorkers=1",
|
|
41
41
|
"test:parallel": "vitest run --config vitest.config.ts --fileParallelism --maxWorkers=2",
|
|
42
42
|
"ui:catalog": "bun ./scripts/run-renderer-catalog.mjs",
|
|
43
|
-
"lint": "
|
|
43
|
+
"lint": "node \"../../.agents/scripts/managed-lint-runner.mjs\" --scope \"apps/cli\"",
|
|
44
44
|
"format": "oxfmt --check src scripts package.json tsconfig.json vitest*.ts",
|
|
45
45
|
"format:check": "oxfmt --check src scripts package.json tsconfig.json vitest*.ts",
|
|
46
46
|
"check": "bun run lint && bun run format",
|
|
@@ -67,6 +67,7 @@
|
|
|
67
67
|
"@typescript-eslint/utils": "8.22.0",
|
|
68
68
|
"effect": "catalog:",
|
|
69
69
|
"eslint": "9.39.5",
|
|
70
|
+
"eslint-plugin-react-you-might-not-need-an-effect": "latest",
|
|
70
71
|
"oxfmt": "0.66.0",
|
|
71
72
|
"oxlint": "1.80.0",
|
|
72
73
|
"oxlint-tsgolint": "7.0.2001",
|