@punks/cli 3.3.6 → 4.0.1

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.
Files changed (142) hide show
  1. package/AGENTS.md +1 -1
  2. package/dist/BASELINE_CHANGELOG.md +11 -2
  3. package/dist/CHANGELOG.md +20 -0
  4. package/dist/baseline/scaffold-baseline/baseline.json +5 -5
  5. package/dist/baseline/scaffold-baseline/data/catalog/packs.json +9 -3
  6. package/dist/baseline/scaffold-baseline/data/catalog/skills.json +32 -0
  7. package/dist/baseline/scaffold-baseline/data/subagents/manifest.mjs +1 -0
  8. package/dist/baseline/scaffold-baseline/skills/agnostic/docs/docs-onboarding/SKILL.md +20 -4
  9. package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-plan/SKILL.md +14 -9
  10. package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-plan/references/backlog-sync.md +61 -29
  11. package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-plan/references/plan-schema.md +25 -6
  12. package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-spec/SKILL.md +10 -4
  13. package/dist/baseline/scaffold-baseline/skills/agnostic/planning/create-spec/references/readiness.md +4 -0
  14. package/dist/baseline/scaffold-baseline/skills/agnostic/planning/implement-spec/SKILL.md +20 -1
  15. package/dist/baseline/scaffold-baseline/skills/agnostic/planning/implement-spec/references/lifecycle.md +20 -3
  16. package/dist/baseline/scaffold-baseline/skills/agnostic/planning/wayfinder/SKILL.md +13 -36
  17. package/dist/baseline/scaffold-baseline/skills/agnostic/quality/make-tsuite/SKILL.md +57 -0
  18. package/dist/baseline/scaffold-baseline/skills/agnostic/quality/make-tsuite/agents/openai.yaml +4 -0
  19. package/dist/baseline/scaffold-baseline/skills/agnostic/quality/make-tsuite/references/audit-portfolio.md +47 -0
  20. package/dist/baseline/scaffold-baseline/skills/agnostic/quality/make-tsuite/references/implement-suite.md +40 -0
  21. package/dist/baseline/scaffold-baseline/skills/agnostic/quality/make-tsuite/references/route-api-design.md +21 -0
  22. package/dist/baseline/scaffold-baseline/skills/agnostic/quality/make-tsuite/references/user-journey-design.md +21 -0
  23. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/EXAMPLES.md +42 -26
  24. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/REFERENCE.md +80 -97
  25. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/SKILL.md +93 -96
  26. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/assets/concepts/backlog-model.md +43 -52
  27. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/assets/concepts/story-shape.md +70 -136
  28. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/references/backlog-initialization.md +88 -0
  29. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/references/business-projection.md +31 -0
  30. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/references/delivery-status.md +66 -0
  31. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/references/fog-intake.md +72 -0
  32. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/references/functional-projection.md +27 -0
  33. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/references/issue-reconciliation.md +76 -0
  34. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/references/normalization.md +105 -0
  35. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/references/project-context.md +43 -0
  36. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/references/providers/github.md +168 -0
  37. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/references/providers/linear.md +190 -0
  38. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/references/technical-projection.md +65 -0
  39. package/dist/baseline/scaffold-baseline/skills/agnostic/requirements/write-backlog/scripts/validate-task-blocker-graph.mjs +137 -0
  40. package/dist/baseline/scaffold-baseline/skills/phases/business-finder/SKILL.md +30 -0
  41. package/dist/baseline/scaffold-baseline/skills/phases/business-finder/agents/openai.yaml +2 -0
  42. package/dist/baseline/scaffold-baseline/skills/phases/delivery-phase/phases/backlog.md +10 -3
  43. package/dist/baseline/scaffold-baseline/skills/phases/delivery-phase/phases/closeout.md +12 -0
  44. package/dist/baseline/scaffold-baseline/skills/phases/delivery-phase/phases/implement.md +21 -0
  45. package/dist/baseline/scaffold-baseline/skills/phases/delivery-phase/phases/router.md +8 -0
  46. package/dist/baseline/scaffold-baseline/skills/phases/delivery-phase/references/artifact-state.md +18 -3
  47. package/dist/baseline/scaffold-baseline/skills/phases/design-phase/phases/backlog.md +9 -1
  48. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/AUTHORING-HANDOFF.md +276 -0
  49. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/SKILL.md +43 -51
  50. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/agents/openai.yaml +1 -1
  51. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/phases/adopt-business-path.md +52 -0
  52. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/phases/business-grilling.md +68 -0
  53. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/phases/ensure-fog.md +43 -0
  54. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/phases/functional-grilling.md +53 -0
  55. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/phases/handback.md +36 -0
  56. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/phases/prototype.md +40 -0
  57. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/phases/reconcile.md +52 -0
  58. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/phases/research.md +38 -0
  59. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/phases/return-target.md +42 -0
  60. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/phases/router.md +64 -0
  61. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/phases/technical-grilling.md +67 -0
  62. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/references/entrypoint-contract.md +38 -0
  63. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/references/root-routing.md +14 -27
  64. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/references/runtime-handoff.md +62 -0
  65. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/references/state-graph.md +60 -0
  66. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/scripts/finder-contract.mjs +383 -0
  67. package/dist/baseline/scaffold-baseline/skills/phases/functional-finder/SKILL.md +78 -0
  68. package/dist/baseline/scaffold-baseline/skills/phases/functional-finder/agents/openai.yaml +2 -0
  69. package/dist/baseline/scaffold-baseline/skills/phases/technical-finder/SKILL.md +74 -0
  70. package/dist/baseline/scaffold-baseline/skills/phases/technical-finder/agents/openai.yaml +2 -0
  71. package/dist/baseline/scaffold-baseline.json +5 -5
  72. package/dist/baseline/scaffold-baseline.tgz +0 -0
  73. package/dist/data/subagents/manifest.mjs +1 -0
  74. package/dist/index.js +6 -6
  75. package/dist/skills/agnostic/docs/docs-onboarding/SKILL.md +20 -4
  76. package/dist/skills/agnostic/planning/create-plan/SKILL.md +14 -9
  77. package/dist/skills/agnostic/planning/create-plan/references/backlog-sync.md +61 -29
  78. package/dist/skills/agnostic/planning/create-plan/references/plan-schema.md +25 -6
  79. package/dist/skills/agnostic/planning/create-spec/SKILL.md +10 -4
  80. package/dist/skills/agnostic/planning/create-spec/references/readiness.md +4 -0
  81. package/dist/skills/agnostic/planning/implement-spec/SKILL.md +20 -1
  82. package/dist/skills/agnostic/planning/implement-spec/references/lifecycle.md +20 -3
  83. package/dist/skills/agnostic/planning/wayfinder/SKILL.md +13 -36
  84. package/dist/skills/agnostic/quality/make-tsuite/SKILL.md +57 -0
  85. package/dist/skills/agnostic/quality/make-tsuite/agents/openai.yaml +4 -0
  86. package/dist/skills/agnostic/quality/make-tsuite/references/audit-portfolio.md +47 -0
  87. package/dist/skills/agnostic/quality/make-tsuite/references/implement-suite.md +40 -0
  88. package/dist/skills/agnostic/quality/make-tsuite/references/route-api-design.md +21 -0
  89. package/dist/skills/agnostic/quality/make-tsuite/references/user-journey-design.md +21 -0
  90. package/dist/skills/agnostic/requirements/write-backlog/EXAMPLES.md +42 -26
  91. package/dist/skills/agnostic/requirements/write-backlog/REFERENCE.md +80 -97
  92. package/dist/skills/agnostic/requirements/write-backlog/SKILL.md +93 -96
  93. package/dist/skills/agnostic/requirements/write-backlog/assets/concepts/backlog-model.md +43 -52
  94. package/dist/skills/agnostic/requirements/write-backlog/assets/concepts/story-shape.md +70 -136
  95. package/dist/skills/agnostic/requirements/write-backlog/references/backlog-initialization.md +88 -0
  96. package/dist/skills/agnostic/requirements/write-backlog/references/business-projection.md +31 -0
  97. package/dist/skills/agnostic/requirements/write-backlog/references/delivery-status.md +66 -0
  98. package/dist/skills/agnostic/requirements/write-backlog/references/fog-intake.md +72 -0
  99. package/dist/skills/agnostic/requirements/write-backlog/references/functional-projection.md +27 -0
  100. package/dist/skills/agnostic/requirements/write-backlog/references/issue-reconciliation.md +76 -0
  101. package/dist/skills/agnostic/requirements/write-backlog/references/normalization.md +105 -0
  102. package/dist/skills/agnostic/requirements/write-backlog/references/project-context.md +43 -0
  103. package/dist/skills/agnostic/requirements/write-backlog/references/providers/github.md +168 -0
  104. package/dist/skills/agnostic/requirements/write-backlog/references/providers/linear.md +190 -0
  105. package/dist/skills/agnostic/requirements/write-backlog/references/technical-projection.md +65 -0
  106. package/dist/skills/agnostic/requirements/write-backlog/scripts/validate-task-blocker-graph.mjs +135 -0
  107. package/dist/skills/phases/business-finder/SKILL.md +30 -0
  108. package/dist/skills/phases/business-finder/agents/openai.yaml +2 -0
  109. package/dist/skills/phases/delivery-phase/phases/backlog.md +10 -3
  110. package/dist/skills/phases/delivery-phase/phases/closeout.md +12 -0
  111. package/dist/skills/phases/delivery-phase/phases/implement.md +21 -0
  112. package/dist/skills/phases/delivery-phase/phases/router.md +8 -0
  113. package/dist/skills/phases/delivery-phase/references/artifact-state.md +18 -3
  114. package/dist/skills/phases/design-phase/phases/backlog.md +9 -1
  115. package/dist/skills/phases/finder-phase/AUTHORING-HANDOFF.md +276 -0
  116. package/dist/skills/phases/finder-phase/SKILL.md +43 -51
  117. package/dist/skills/phases/finder-phase/agents/openai.yaml +1 -1
  118. package/dist/skills/phases/finder-phase/phases/adopt-business-path.md +52 -0
  119. package/dist/skills/phases/finder-phase/phases/business-grilling.md +68 -0
  120. package/dist/skills/phases/finder-phase/phases/ensure-fog.md +43 -0
  121. package/dist/skills/phases/finder-phase/phases/functional-grilling.md +53 -0
  122. package/dist/skills/phases/finder-phase/phases/handback.md +36 -0
  123. package/dist/skills/phases/finder-phase/phases/prototype.md +40 -0
  124. package/dist/skills/phases/finder-phase/phases/reconcile.md +52 -0
  125. package/dist/skills/phases/finder-phase/phases/research.md +38 -0
  126. package/dist/skills/phases/finder-phase/phases/return-target.md +42 -0
  127. package/dist/skills/phases/finder-phase/phases/router.md +64 -0
  128. package/dist/skills/phases/finder-phase/phases/technical-grilling.md +67 -0
  129. package/dist/skills/phases/finder-phase/references/entrypoint-contract.md +38 -0
  130. package/dist/skills/phases/finder-phase/references/root-routing.md +14 -27
  131. package/dist/skills/phases/finder-phase/references/runtime-handoff.md +62 -0
  132. package/dist/skills/phases/finder-phase/references/state-graph.md +60 -0
  133. package/dist/skills/phases/finder-phase/scripts/finder-contract.mjs +383 -0
  134. package/dist/skills/phases/functional-finder/SKILL.md +78 -0
  135. package/dist/skills/phases/functional-finder/agents/openai.yaml +2 -0
  136. package/dist/skills/phases/technical-finder/SKILL.md +74 -0
  137. package/dist/skills/phases/technical-finder/agents/openai.yaml +2 -0
  138. package/package.json +4 -2
  139. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/references/convergence.md +0 -39
  140. package/dist/baseline/scaffold-baseline/skills/phases/finder-phase/references/frontier-lifecycle.md +0 -76
  141. package/dist/skills/phases/finder-phase/references/convergence.md +0 -39
  142. package/dist/skills/phases/finder-phase/references/frontier-lifecycle.md +0 -76
@@ -7,8 +7,27 @@ when a retained review opened `repair_active` for in-scope non-runtime blockers.
7
7
 
8
8
  Load `implement-spec` only after this phase is selected.
9
9
 
10
+ Before naming or rewriting domain concepts, read the canonical glossary in the
11
+ routed `requirements-grill` status artifact. Preserve its canonical terms;
12
+ route proposed terminology changes through `requirements-grill` instead of
13
+ silently renaming them.
14
+
10
15
  ## Rules
11
16
 
17
+ - Read the plan's uniform `task_identity_mode`. Provider-task work preserves
18
+ one stable provider Task identity per `Tn`, the same `V*`, and native blocker
19
+ edges. Planning-only work preserves `Tn` as the execution identity,
20
+ `not_applicable` identity slots, `unprojected` relations, and its sync-skip
21
+ reason.
22
+ - For provider-task work, immediately route each directly observed work start,
23
+ blocker, pull request, merge, staging deployment, or production deployment
24
+ through `write-backlog`'s
25
+ [delivery-status.md](../../write-backlog/references/delivery-status.md) branch.
26
+ Require exact readback before advancing the Task. Planning-only work emits no
27
+ provider lifecycle mutation or readback claim.
28
+ - Merge is never deployment evidence. Merge, staging, and production remain
29
+ distinct directly observed facts. Complete a Fog only when production
30
+ evidence covers every accepted resulting Story and Task.
12
31
  - Preserve the plan's dependencies, owned paths, validation gates, and wave boundaries.
13
32
  - Launch every currently unblocked task whose write scope is disjoint as the
14
33
  active worker wave.
@@ -38,6 +57,8 @@ Write or verify:
38
57
  - validation commands and results
39
58
  - UI Evidence links for changed user-visible surfaces, or explicit no-op reason
40
59
  - remaining blockers or follow-up debt
60
+ - exact provider readback for every observed provider-task fact; explicit
61
+ planning-only non-applicability otherwise
41
62
  - resulting state: `review_due`, `debug_active`, `focused_validation`,
42
63
  `clean_handoff`, or blocked
43
64
 
@@ -63,6 +63,14 @@ state take precedence over inferred artifact order.
63
63
  19. Route remaining docs-affecting work to [docs-ingest.md](docs-ingest.md),
64
64
  otherwise [closeout.md](closeout.md).
65
65
 
66
+ When staged Finder authority is missing, report the exact Business, Functional,
67
+ or Technical Finder invocation the human must make. Every Finder surface is
68
+ human-only; this router never invokes one implicitly.
69
+
70
+ When a linked provider Task has a newly observed work start, blocker, pull
71
+ request, merge, staging deployment, or production deployment without exact
72
+ readback, route to [implement.md](implement.md) before any later phase.
73
+
66
74
  Only an explicitly new delivery goal with materially changed accepted bounds
67
75
  creates a new lineage and resets review/repair counters. Same-goal bounds
68
76
  revision, resume, rebase, commit, retry, and handoff preserve them.
@@ -12,14 +12,21 @@ Use this reference when deciding whether a phase is complete enough to skip.
12
12
  ## Plan Complete
13
13
 
14
14
  - `PLAN.md` exists and matches the spec.
15
- - Tasks have dependencies, owned paths, validation gates, and wave boundaries.
15
+ - One uniform `task_identity_mode` applies. In `provider-task` mode every `Tn`
16
+ resolves one stable provider Task ID and URL, preserves the same `V*`, and
17
+ mirrors native blocker edges through `depends_on`. In `planning-only` mode
18
+ each `Tn` is the execution identity, provider identity slots are `not_applicable`,
19
+ relation mode is `unprojected`, a nonempty sync-skip reason is present, and
20
+ `depends_on` names plan `Tn` identities.
21
+ - Tasks have owned paths, validation gates, and wave boundaries.
16
22
  - Each wave contains every currently unblocked task with a disjoint write scope;
17
23
  one-task waves are justified by dependencies or ownership.
18
24
 
19
25
  ## Backlog Projection Complete
20
26
 
21
- - Projection evidence names the immutable spec URL, provider destination,
22
- epic/story ids and URLs, and verified observed state.
27
+ - Projection evidence names the immutable spec URL, provider destination, exact
28
+ Epic and Story identities, provider Task IDs and URLs, same `V*`, native
29
+ blocker edges, and verified observed state.
23
30
  - Evidence matches the current spec; otherwise the projection is stale.
24
31
 
25
32
  ## Implementation Complete
@@ -27,6 +34,11 @@ Use this reference when deciding whether a phase is complete enough to skip.
27
34
  - Plan tasks are complete or explicitly deferred.
28
35
  - Implementation notes or equivalent evidence describe changed files, validation,
29
36
  blockers, and debt.
37
+ - Exact `write-backlog` delivery-status readback exists for each directly
38
+ observed work start, blocker, pull request, merge, staging deployment, or
39
+ production deployment. Merge is never deployment evidence.
40
+ - Fog completion exists only when production evidence covers every accepted
41
+ resulting Story and Task.
30
42
 
31
43
  ## Review Complete
32
44
 
@@ -53,3 +65,6 @@ Use this reference when deciding whether a phase is complete enough to skip.
53
65
 
54
66
  - Final report names what ran, what was skipped, validation evidence, docs
55
67
  outcome, stack state when relevant, and remaining blockers.
68
+ - The final path-limited commit includes review and docs-ingest changes while
69
+ preserving unrelated dirty user files. Required release classification and
70
+ exact-tree provider proof match that final tree.
@@ -2,6 +2,11 @@
2
2
 
3
3
  Convert approved design artifacts into backlog work.
4
4
 
5
+ Before naming or rewriting domain concepts, read the canonical glossary in the
6
+ routed `requirements-grill` status artifact. Preserve its canonical terms;
7
+ route proposed terminology changes through `requirements-grill` instead of
8
+ silently renaming them.
9
+
5
10
  ## Prerequisite
6
11
 
7
12
  An authoritative agent-ready `SPEC.md` at a verified stable blob URL that includes or links at least one fresh approved artifact set with its artifact contract.
@@ -10,7 +15,10 @@ An authoritative agent-ready `SPEC.md` at a verified stable blob URL that includ
10
15
 
11
16
  1. Verify the spec is authoritative and agent-ready, then verify approved artifact links, durable asset links, scope, constraints, and acceptance checks.
12
17
  2. Use `repo-asset-management` for backlog attachments first and repo-provider fallback when backlog attachments are unavailable or unsuitable.
13
- 3. Activate `write-backlog` from this phase only.
18
+ 3. Require the exact existing Story and accepted Technical resolution. Activate
19
+ only `write-backlog`'s technical-projection branch to enrich that Story and
20
+ project its provider Tasks. Missing staged Finder authority returns the
21
+ explicit human Finder invocation needed; this phase never starts Finder.
14
22
  4. Include only accepted product and design constraints, acceptance context, and artifact links in backlog bodies.
15
23
  5. Record created or updated backlog ids and preserve the `spec -> backlog -> delivery` handoff.
16
24
 
@@ -0,0 +1,276 @@
1
+ # Finder Graph Authoring Handoff
2
+
3
+ Mode: Convert the former chart/work lifecycle into the accepted Fog-child graph.
4
+
5
+ ## Obligation Map
6
+
7
+ | Obligation | Mandatory | Survives interruption | Evidence artifact | Owner | Audit criterion |
8
+ | -------------------------- | --------- | --------------------- | ----------------------------------------------- | ------------------ | ------------------------------------------------------- |
9
+ | Explicit human invocation | yes | yes | both `SKILL.md` files and OpenAI metadata | engine and wrapper | invocation flags agree |
10
+ | One exact Fog | yes | yes | durable wiki identity, provider readback | ensure gate | create/resume cardinality is one |
11
+ | One Business child | yes | yes | child identity and Stage readback | Business gate | ambiguity produces zero writes |
12
+ | Deterministic resume | yes | yes | router, runtime handoff, provider snapshot | router | one route from current evidence |
13
+ | Business decision depth | yes | yes | immutable resolution pointer | Business gate | atomic grill settles placement without technical policy |
14
+ | Support cycles | yes | yes | Research/Prototype child and immutable evidence | support gates | support returns to its named grilling child |
15
+ | Provider mutation boundary | yes | yes | semantic intent plus exact readback | reconciliation | all physical writes route through `write-backlog` |
16
+ | Exact target return | yes | yes | `target_depth_reached` handoff | return gate | chosen depth returns without Fog completion |
17
+
18
+ Survivor artifacts: stable wiki/provider Fog identities, exact child identities,
19
+ immutable resolution pointers, provider snapshots/readbacks, support evidence,
20
+ checkpoints, blockers, target depth, and terminal state.
21
+
22
+ ## Phase: qualify
23
+
24
+ Status: complete
25
+
26
+ Scope: Finder engine and Business wrapper conversion.
27
+
28
+ Artifacts: obligation map and survivor list above.
29
+
30
+ Validation: The engine is multi-step, resumable, cyclic, and repairable, so the
31
+ graph is mandatory. Only the three audience wrappers qualify for direct
32
+ composition because each supplies one target/profile call into the graph and
33
+ owns no resumable action.
34
+
35
+ Domain state: All T2 obligations have an owner, evidence artifact, and audit
36
+ criterion.
37
+
38
+ Next suggested route: `model-state.md`
39
+
40
+ Blockers: none
41
+
42
+ Resume identity: canonical source tree at current working revision
43
+
44
+ ## State Model
45
+
46
+ | State | Scope | Entry guard | Exit guard | Next |
47
+ | ----------------- | -------------------- | ---------------------------------- | ---------------------------- | ---------------------------------------- |
48
+ | Fog absent | invocation | no exact readback | one exact Fog read back | Business or handback |
49
+ | Business active | one Fog | Business evidence missing/invalid | accepted pointer plus intent | support, reconcile, checkpoint, handback |
50
+ | Support active | named grilling child | precise support unknown | immutable report or verdict | reconcile or handback |
51
+ | Stage accepted | one stage | immutable evidence exists | exact projection readback | target return or next depth |
52
+ | Functional active | one Story intent | target includes Functional | accepted pointer plus intent | support, reconcile, handback |
53
+ | Technical active | one Story | target is Technical | accepted pointer plus intent | support, reconcile, handback |
54
+ | Target reached | invocation | all target evidence/readback fresh | durable return written | terminal return |
55
+ | Human steering | conflict | admissible evidence cannot resolve | `$handback` guard passes | terminal or router re-entry |
56
+
57
+ Graph forms: baseline depth path, target-depth branches, Research/Prototype
58
+ cycles, accepted-stage reuse skips, structural approval checkpoint, blocked
59
+ readback exit, and terminal handback are represented. Current evidence carries
60
+ freshness, scope, identity, and validity guards.
61
+
62
+ ## Phase: model-state
63
+
64
+ Status: complete
65
+
66
+ Scope: Runtime evidence states and topology.
67
+
68
+ Artifacts: `references/state-graph.md`, router precedence, state table above.
69
+
70
+ Validation: Every obligation reaches an evidence-backed state; every gate can
71
+ reach `human_steering_required`; target return remains distinct from Fog
72
+ completion.
73
+
74
+ Domain state: No conversational-progress state is authoritative.
75
+
76
+ Next suggested route: `define-authority.md`
77
+
78
+ Blockers: none
79
+
80
+ Resume identity: exact Fog wiki/provider identity when available
81
+
82
+ ## Phase: define-authority
83
+
84
+ Status: complete
85
+
86
+ Scope: Evidence admissibility and route tie-breaks.
87
+
88
+ Artifacts: `references/state-graph.md#evidence-authority` and
89
+ `phases/router.md#route-precedence`.
90
+
91
+ Validation: Current direct evidence outranks fresh workflow-native artifacts,
92
+ which outrank the committed runtime handoff and suggested route. Human steering,
93
+ identity conflict, Fog ensure, scope checkpoint, support, stage work,
94
+ reconciliation, and target return have one declared precedence order. Stale,
95
+ invalid, ambiguous, or out-of-scope evidence satisfies no positive gate.
96
+
97
+ Domain state: All known overlaps resolve to one route; conflicting accepted
98
+ identity routes to zero-write handback.
99
+
100
+ Next suggested route: `write-router.md`
101
+
102
+ Blockers: none
103
+
104
+ Resume identity: current provider snapshot plus runtime handoff
105
+
106
+ ## Phase: write-router
107
+
108
+ Status: complete
109
+
110
+ Scope: Finder bootstrap and runtime route selection.
111
+
112
+ Artifacts: `SKILL.md`, `phases/router.md`, and
113
+ `scripts/finder-contract.mjs`.
114
+
115
+ Validation: Root contains bootstrap/pointers only. Router recomputes on cold
116
+ resume, returns one gate/checkpoint/blocked/terminal outcome, names only flat
117
+ phase files, and preserves the handback terminal. Human-only metadata remains
118
+ unchanged.
119
+
120
+ Domain state: Eleven required route classes plus identity-conflict variants are
121
+ covered by the route fixture.
122
+
123
+ Next suggested route: `write-phases.md`
124
+
125
+ Blockers: none
126
+
127
+ Resume identity: current target depth and Fog snapshot
128
+
129
+ ## Phase: write-phases
130
+
131
+ Status: complete
132
+
133
+ Scope: Ten flat executable Finder gates.
134
+
135
+ Artifacts: `phases/ensure-fog.md`, `adopt-business-path.md`, `business-grilling.md`,
136
+ `functional-grilling.md`, `technical-grilling.md`, `research.md`,
137
+ `prototype.md`, `reconcile.md`, `return-target.md`, and `handback.md`.
138
+
139
+ Validation: Every gate declares entry guard, inputs, bounded action, invariants,
140
+ completion evidence, exits, and durable handoff. Narrow executors return to the
141
+ owning gate for reconciliation. Handback invokes `$handback` and persists only
142
+ its declared terminal or guard-passed re-entry.
143
+
144
+ Domain state: No executable gate body remains in root or references.
145
+
146
+ Next suggested route: `define-handoffs.md`
147
+
148
+ Blockers: none
149
+
150
+ Resume identity: gate outcome plus exact evidence identities
151
+
152
+ ## Phase: define-handoffs
153
+
154
+ Status: complete
155
+
156
+ Scope: Runtime persistence and discovery.
157
+
158
+ Artifacts: `references/runtime-handoff.md` plus every gate's durable-handoff
159
+ section.
160
+
161
+ Validation: The schema preserves phase, status, scope, artifacts, validation,
162
+ Finder state, optional UI evidence, suggestion, blockers, and resume identity.
163
+ The durable wiki Fog identity discovers the record before provider creation;
164
+ stable provider identity joins it after readback. Every declared exit writes a
165
+ checkpoint, blocker, skip, target return, or human-steering outcome.
166
+
167
+ Domain state: Suggestions remain advisory and current evidence can supersede
168
+ them. The handoff retains only exact identities/pointers and irreducible route
169
+ state.
170
+
171
+ Next suggested route: `verify-disclosure.md`
172
+
173
+ Blockers: none
174
+
175
+ Resume identity: durable wiki Fog identity
176
+
177
+ ## Phase: verify-disclosure
178
+
179
+ Status: complete
180
+
181
+ Scope: Bootstrap-to-gate context trace.
182
+
183
+ Artifacts: Root pointers, router links, flat phase files, and three shared
184
+ runtime references.
185
+
186
+ Validation: Business trace loads `business-finder/SKILL.md` -> Finder bootstrap
187
+ -> entrypoint contract and router -> exactly `business-grilling.md`; sibling
188
+ gates remain unloaded. Every root/router pointer resolves. References contain
189
+ state, handoff, and entry contracts only. No old chart/work pointer remains.
190
+
191
+ Domain state: Branch-specific execution stays behind the selected gate pointer.
192
+
193
+ Next suggested route: `test-routes.md`
194
+
195
+ Blockers: none
196
+
197
+ Resume identity: current target artifact set
198
+
199
+ ## Phase: router (2026-08-27 repair)
200
+
201
+ Status: complete
202
+
203
+ Scope: Technical Task graph completion evidence.
204
+
205
+ Artifacts: Current Finder router, contract, runtime handoff, writer validator,
206
+ and fresh PR review evidence.
207
+
208
+ Validation: Direct-child Task collection rejected valid cross-Epic blockers and
209
+ could not prove future-milestone rejection. Current artifacts therefore made
210
+ `test-routes` stale while prior authority, gates, and disclosure remained
211
+ consistent.
212
+
213
+ Domain state: Selected `test-routes.md`; no provider mutation or wider topology
214
+ change was authorized.
215
+
216
+ Next suggested route: `test-routes.md`
217
+
218
+ Blockers: none
219
+
220
+ Resume identity: exact upstream source revision and current PR review threads
221
+
222
+ ## Phase: test-routes
223
+
224
+ Status: complete
225
+
226
+ Scope: Runtime route matrix.
227
+
228
+ Artifacts: `tests/fixtures/finder-phase-routes.json`,
229
+ `scripts/finder-contract.mjs`, and `tests/finder-phase-graph.contract.test.mjs`.
230
+
231
+ Validation: Predictions and derivations match for baseline Fog ensure, Business
232
+ branch, Research executor cycle, reconciliation repair, structural checkpoint,
233
+ handback terminal, cold resume, stale/invalid/out-of-scope evidence,
234
+ contradictory suggestion, and premature completion rejection. The planned
235
+ checkpoint remains distinct from human steering. The out-of-scope case first
236
+ failed as target return, then was repaired to reject inadmissible evidence. The
237
+ 2026-08-27 repair adds RED/GREEN cases proving the exact `write-backlog`
238
+ full-reachable validator result rejects a future-iteration edge and accepts a
239
+ same-or-earlier-milestone blocker whose target belongs to another Epic.
240
+
241
+ Domain state: Route fixture contains expected route before the executable
242
+ contract derives it. Technical target return now requires the successful writer
243
+ validator result, its complete Task/edge coverage, exact milestone-order
244
+ readback, and matching provider snapshot.
245
+
246
+ Next suggested route: `audit.md`
247
+
248
+ Blockers: none
249
+
250
+ Resume identity: route fixture and current script revision
251
+
252
+ ## Phase: audit
253
+
254
+ Status: complete
255
+
256
+ Scope: Terminal graph-authoring audit.
257
+
258
+ Artifacts: Finder engine, Business wrapper, runtime references, route contract,
259
+ fixtures, and focused contract tests.
260
+
261
+ Validation: All mandatory obligations, route precedence, cold resume, pointers,
262
+ gate exits, handoffs, target-depth return, and human-steering authority guard
263
+ pass. The 2026-08-27 repair passes `node --test tests/*.test.mjs` at 212/212 and
264
+ `git diff --check`. No separate skill validator exists in this canonical
265
+ repository.
266
+
267
+ Domain state: Audit complete. The no-op pass removed the old chart/work map,
268
+ Fog-graduation rules, placement classification, and duplicate convergence
269
+ reference. Remaining instructions change cardinality, evidence, routing,
270
+ presentation, mutation-boundary, or terminal behavior.
271
+
272
+ Next suggested route: audit-complete terminal
273
+
274
+ Blockers: none
275
+
276
+ Resume identity: current canonical source working revision
@@ -1,55 +1,47 @@
1
1
  ---
2
2
  name: finder-phase
3
- description: Route loose oversized foggy work before requirements or delivery. Use when an idea is too large for one agent session, wrapped in fog, or needs backlog-native frontier shaping before requirements-phase.
3
+ description: Run the shared human-driven Finder engine at an explicit target depth.
4
+ disable-model-invocation: true
4
5
  ---
5
6
 
6
- # Finder Phase
7
-
8
- Harness phase wrapper for backlog-native frontier routing.
9
-
10
- Use this before `requirements-phase` when the work is too big or foggy to grill
11
- directly. Compose the lean `wayfinder` primitive and preserve a resumable map.
12
-
13
- ## Core Loop
14
-
15
- 1. Choose a destination and mode. In **chart mode**, repair the map and sharpen
16
- fog. In **work mode**, claim and execute exactly one frontier ticket.
17
- 2. Read the backlog root plus any resumable ticket and immutable evidence links.
18
- If provider state is unavailable, use docs as temporary evidence and say so.
19
- 3. Use `wayfinder` to compute the frontier and select one route.
20
- 4. In chart mode, use `write-backlog` only when provider mutation is in scope.
21
- In work mode, produce a claim and use `write-backlog` for its physical
22
- provider mutation before dispatching one bounded child flow.
23
- 5. Reconcile the child result semantically, repair invalidated scope, recompute
24
- the frontier, and use `$show-me` to present that frontier before returning
25
- the next route or completion state. The visual explains the living map; the
26
- backlog root remains authoritative.
27
-
28
- ## Always-Needed Rules
29
-
30
- - The backlog root is the living map; do not create a separate map issue.
31
- - `fog` is not delivery-eligible and is not a `SPEC.md` anchor.
32
- - A `fog` item records a frontier or uncertainty description. Once Finder can
33
- derive a precise question, graduate it into `grilling`, `research`, or
34
- `prototype`; the question belongs to that concrete item, not the fog intake.
35
- - Frontier tickets are open, unblocked, and unclaimed. Dependencies and claims
36
- use provider-native relations and assignment/state.
37
- - Child flows return immutable resolution pointers. Finder produces semantic
38
- claim/resolution outputs; `write-backlog` owns their provider writes. The phase does not infer a
39
- product decision from research or impersonate the human in grilling or
40
- prototyping.
41
- - `finder-phase` owns frontier lifecycle and root routing; `write-backlog` owns provider materialization.
42
-
43
- ## References
44
-
45
- - Frontier lifecycle: [references/frontier-lifecycle.md](references/frontier-lifecycle.md)
46
- - Convergence and resumption: [references/convergence.md](references/convergence.md)
47
- - Root routing: [references/root-routing.md](references/root-routing.md)
48
- - Backlog taxonomy and provider materialization: use the `write-backlog` skill.
49
-
50
- ## Completion Criteria
51
-
52
- - The frontier is represented as backlog-root state or as a temporary evidence-backed handoff when provider state is unavailable.
53
- - The destination, current mode, frontier, claims, and next route are explicit.
54
- - Any backlog writes were delegated to `write-backlog`.
55
- - The final handoff names the next skill or phase and any unresolved blocker.
7
+ # Finder Engine
8
+
9
+ One durable graph creates or resumes one Fog and advances it to the human's
10
+ chosen decision depth. The three Finder wrappers compose this engine directly;
11
+ they do not own lifecycle state.
12
+
13
+ ## Bootstrap
14
+
15
+ 1. Read [the direct-composition contract](references/entrypoint-contract.md).
16
+ 2. Read [the state and route model](references/state-graph.md) before deriving
17
+ any state.
18
+ 3. Read [the runtime handoff schema](references/runtime-handoff.md) before
19
+ discovering or updating a Finder handoff.
20
+ 4. Reconstruct current state from fresh Fog, child, relation, provider-object,
21
+ immutable-evidence, and runtime-handoff reads.
22
+ 5. Read [the Finder router](phases/router.md) on every entry and cold resume.
23
+ 6. Load exactly one gate selected by the router, or return its one checkpoint,
24
+ blocked, or terminal outcome.
25
+ 7. After the gate writes its durable handoff, stop or re-enter this bootstrap.
26
+
27
+ The router is the sole route authority. Gate files own executable work.
28
+ `write-backlog` is the sole provider mutation authority.
29
+
30
+ ## Gates
31
+
32
+ - [Ensure Fog](phases/ensure-fog.md)
33
+ - [Adopt exact Business path](phases/adopt-business-path.md)
34
+ - [Business grilling](phases/business-grilling.md)
35
+ - [Functional grilling](phases/functional-grilling.md)
36
+ - [Technical grilling](phases/technical-grilling.md)
37
+ - [Research support](phases/research.md)
38
+ - [Prototype support](phases/prototype.md)
39
+ - [Reconcile stage](phases/reconcile.md)
40
+ - [Return target depth](phases/return-target.md)
41
+ - [Human steering](phases/handback.md)
42
+
43
+ ## Runtime References
44
+
45
+ - [State and route model](references/state-graph.md)
46
+ - [Runtime handoff](references/runtime-handoff.md)
47
+ - [Root routing boundary](references/root-routing.md)
@@ -1,2 +1,2 @@
1
1
  policy:
2
- allow_implicit_invocation: true
2
+ allow_implicit_invocation: false
@@ -0,0 +1,52 @@
1
+ # Adopt Business Path Gate
2
+
3
+ ## Entry guard
4
+
5
+ Functional or Technical depth starts with no accepted Business child, exact
6
+ provider readback for one Product Area -> Initiative -> Epic path, and the
7
+ human's explicit `reuse-unchanged` decision.
8
+
9
+ ## Inputs
10
+
11
+ Exact Fog identity, exact hierarchy identities and readback, accepted
12
+ no-scope-change decision, current direct Business children, and wrapper
13
+ presentation profile.
14
+
15
+ ## Bounded action
16
+
17
+ 1. Read every direct Business child. Reuse one exact child or, when none
18
+ exists, allocate one durable Business child wiki identity and send its shell
19
+ ensure intent to `$write-backlog`. Require exact readback before adoption.
20
+ 2. Use `$show-me` to confirm the exact existing hierarchy and unchanged
21
+ business scope recorded by the human.
22
+ 3. Persist an immutable accepted Business resolution that names the exact path
23
+ identities and the `reuse-unchanged` decision. This gate runs no Business
24
+ grill.
25
+ 4. Emit the semantic Business projection intent for exact readback. The intent
26
+ binds the Fog and Business child to the existing path; it creates no new
27
+ Product Area, Initiative, or Epic.
28
+
29
+ ## Invariants
30
+
31
+ The exact path is evidence, not an implicit decision. This gate runs only after
32
+ the human accepts unchanged scope. Ambiguous or duplicate Business children,
33
+ hierarchy identities, or provider readbacks produce zero writes and route to
34
+ human steering. The immutable resolution and projection readback remain
35
+ mandatory before Functional progression.
36
+
37
+ ## Completion evidence
38
+
39
+ Exact Business child identity, immutable accepted resolution pointer, exact
40
+ Product Area -> Initiative -> Epic identities, explicit `reuse-unchanged`
41
+ decision, and semantic projection intent.
42
+
43
+ ## Declared exits
44
+
45
+ - `business_accepted` -> reconciliation.
46
+ - `human_steering_required` -> handback.
47
+ - `blocked` -> stop with missing evidence.
48
+
49
+ ## Durable handoff
50
+
51
+ Persist the Business child identity, immutable resolution pointer, exact path
52
+ readback, unchanged-scope decision, projection intent, and exit.
@@ -0,0 +1,68 @@
1
+ # Business Grilling Gate
2
+
3
+ ## Entry guard
4
+
5
+ One exact Fog exists and its Business grilling evidence is missing or invalid.
6
+
7
+ ## Inputs
8
+
9
+ Fog snapshot; project wiki; existing Product Areas, Initiatives, Epics, and
10
+ milestones; accepted project language; wrapper presentation profile.
11
+
12
+ ## Bounded action
13
+
14
+ 1. Read all direct Business-stage children before ensuring one. Resume reuses
15
+ the exact child and its durable wiki/provider identities.
16
+ 2. When none exists, allocate and persist one durable Business grilling-child
17
+ wiki identity. Authorize its child shell by the exact Fog identity, Stage
18
+ `Business`, and singleton cardinality key. Send that child-shell ensure
19
+ intent to `$write-backlog` and require exact readback before grilling. This
20
+ ensure does not require accepted grilling evidence. Ambiguity or duplicate
21
+ child identity produces zero writes and routes to human steering.
22
+ 3. Read the relevant existing Product Areas, Initiatives, Epics, milestones,
23
+ and their stable identities before proposing structure.
24
+ 4. Use `$show-me` to visualize all relevant existing Product Areas, Initiatives,
25
+ Epics, and milestones together with the proposed impact. If the request
26
+ crosses a Product Area or Initiative boundary, show the split and stop at
27
+ `scope-expansion-checkpoint` for an explicit split-or-proceed choice.
28
+ 5. Activate atomic `$grilling` on the ensured Business child. Use `$wait-what`
29
+ language whenever the request, project term, outcome, boundary, or proposed
30
+ placement does not land: pause, repitch plainly in project language, and ask
31
+ again.
32
+ 6. Settle why the request matters, target user or stakeholder, intended product
33
+ outcome, boundaries/non-goals, durable constraints, and the exact existing
34
+ or proposed Product Area -> Initiative -> Epic path.
35
+ 7. Prefer stable-identity reuse and enrichment. A new Product Area, Initiative,
36
+ or Epic is a scope-expansion proposal, never a title-only default. Existing
37
+ Product Areas and Initiatives may be changed after the required structural
38
+ preview and approval. Never duplicate an Initiative.
39
+ 8. Persist the immutable accepted resolution for that child. Only then emit one
40
+ semantic Business projection intent for reconciliation.
41
+
42
+ ## Invariants
43
+
44
+ This gate uses `$grilling`, not `$requirements-grill`. It asks no implementation
45
+ architecture questions. Fog stays lateral and records every object enriched or
46
+ proposed. Creating the child shell does not require accepted grilling evidence.
47
+ Resume reuses the exact child; ambiguity or duplicate identity produces zero
48
+ writes and routes to human steering.
49
+
50
+ ## Completion evidence
51
+
52
+ Exactly one Business child, accepted immutable resolution pointer, stable
53
+ resolved hierarchy identities or approved proposals, and one semantic
54
+ projection intent.
55
+
56
+ ## Declared exits
57
+
58
+ - `business_accepted` -> reconciliation.
59
+ - `support_required` -> Research or Prototype through router re-entry.
60
+ - `scope-expansion-checkpoint` -> persist the exact decision and stop.
61
+ - `human_steering_required` -> handback.
62
+ - `blocked` -> stop with missing evidence.
63
+
64
+ ## Durable handoff
65
+
66
+ Persist durable child wiki/provider identities before the grill, then its
67
+ accepted evidence pointer, support relations, hierarchy identities, decision
68
+ checkpoints, projection intent, and exit.