@eforge-build/eforge-plan 0.8.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.
Files changed (112) hide show
  1. package/LICENSE +190 -0
  2. package/README.md +466 -0
  3. package/dist/backlog-curation-source-provider.d.ts +62 -0
  4. package/dist/backlog-curation-source-provider.js +495 -0
  5. package/dist/index.d.ts +7 -0
  6. package/dist/index.js +589 -0
  7. package/package.json +72 -0
  8. package/prompts/eforge-plan-backlog-curation-item-audit.md +71 -0
  9. package/prompts/eforge-plan-backlog-curation-reducer.md +61 -0
  10. package/prompts/eforge-plan-planning-draft.md +125 -0
  11. package/workstation-assets/plans/assets/abnfDiagram-VRR7QNED-78B0yOEK.js +1 -0
  12. package/workstation-assets/plans/assets/arc-XmhKxjV7.js +1 -0
  13. package/workstation-assets/plans/assets/architecture-TIHT7OUA-NvwveMWr.js +1 -0
  14. package/workstation-assets/plans/assets/architectureDiagram-ZJ3FMSHR-DwWqL5gE.js +36 -0
  15. package/workstation-assets/plans/assets/array-BifhSqXX.js +1 -0
  16. package/workstation-assets/plans/assets/blockDiagram-677ZJIJ3-DKTnUbdw.js +132 -0
  17. package/workstation-assets/plans/assets/c4Diagram-LMCZKHZV-X42ysI10.js +10 -0
  18. package/workstation-assets/plans/assets/channel-D_5qxKhT.js +1 -0
  19. package/workstation-assets/plans/assets/chunk-2Q5K7J3B-C1jixKkw.js +1 -0
  20. package/workstation-assets/plans/assets/chunk-32BRIVSS-CC-cwjI2.js +1 -0
  21. package/workstation-assets/plans/assets/chunk-52WLFC77-C5jMuCNv.js +10 -0
  22. package/workstation-assets/plans/assets/chunk-5VM5RSS4-ZNzvKenW.js +15 -0
  23. package/workstation-assets/plans/assets/chunk-7BUUIJ7U-Bb538aSH.js +1 -0
  24. package/workstation-assets/plans/assets/chunk-C7G6YPKG-QJOKf7JR.js +1 -0
  25. package/workstation-assets/plans/assets/chunk-EX3LRPZG-BC6hcB7L.js +231 -0
  26. package/workstation-assets/plans/assets/chunk-FWX5IMBZ-DjGANnm8.js +2 -0
  27. package/workstation-assets/plans/assets/chunk-HOUHSVGY-CTvTF8P_.js +1 -0
  28. package/workstation-assets/plans/assets/chunk-ICXQ74PX-BnobhCjQ.js +2 -0
  29. package/workstation-assets/plans/assets/chunk-JWPE2WC7-DVXcaiue.js +1 -0
  30. package/workstation-assets/plans/assets/chunk-KEIR6QF5-Dj-OpFgW.js +161 -0
  31. package/workstation-assets/plans/assets/chunk-MOJQB5TN-Dwkjcsly.js +88 -0
  32. package/workstation-assets/plans/assets/chunk-OGEWGWER-CFMxH_hz.js +1 -0
  33. package/workstation-assets/plans/assets/chunk-PUDLZKDR-Dor57faH.js +156 -0
  34. package/workstation-assets/plans/assets/chunk-Q4XR5HBZ-D-IK7DlL.js +70 -0
  35. package/workstation-assets/plans/assets/chunk-RYQCIY6F-DpTa04be.js +1 -0
  36. package/workstation-assets/plans/assets/chunk-V7JOEXUC-CFqzUdj4.js +206 -0
  37. package/workstation-assets/plans/assets/chunk-VAUOI2AC-BbIlIF2a.js +1 -0
  38. package/workstation-assets/plans/assets/chunk-VR4S4FIN-CFMVg8B3.js +1 -0
  39. package/workstation-assets/plans/assets/chunk-WYO6CB5R-BlOpSQhB.js +125 -0
  40. package/workstation-assets/plans/assets/chunk-XXDRQBXY-BTV-IdbV.js +1 -0
  41. package/workstation-assets/plans/assets/chunk-Y2CYZVJY-DsF7k-Jl.js +1 -0
  42. package/workstation-assets/plans/assets/chunk-ZGVPDNZ5-DughZ6NH.js +62 -0
  43. package/workstation-assets/plans/assets/chunk-ZIRB5QZD-C6fEPe3t.js +32 -0
  44. package/workstation-assets/plans/assets/classDiagram-OUVF2IWQ-BDFCV_Gu.js +1 -0
  45. package/workstation-assets/plans/assets/classDiagram-v2-EOCWNBFH-BDFCV_Gu.js +1 -0
  46. package/workstation-assets/plans/assets/cose-bilkent-JH36ORCC-DBeM55MZ.js +1 -0
  47. package/workstation-assets/plans/assets/cynefin-VYW2F7L2-DNQDl6J7.js +1 -0
  48. package/workstation-assets/plans/assets/cynefinDiagram-TSTJHNR4-7rwTPI0P.js +62 -0
  49. package/workstation-assets/plans/assets/cytoscape.esm-CQFVGiJu.js +321 -0
  50. package/workstation-assets/plans/assets/dagre-VKFMJZFB-w4kYnfcE.js +4 -0
  51. package/workstation-assets/plans/assets/dagre-dpRSp0QF.js +1 -0
  52. package/workstation-assets/plans/assets/defaultLocale-C8Fc0cco.js +1 -0
  53. package/workstation-assets/plans/assets/diagram-FQU43EPY-CYlyxHIb.js +3 -0
  54. package/workstation-assets/plans/assets/diagram-G47NLZAW-BTQ2Ih7M.js +24 -0
  55. package/workstation-assets/plans/assets/diagram-NH7WQ7WH-CzVwXQzn.js +24 -0
  56. package/workstation-assets/plans/assets/diagram-OA4YK3LP-DZyMdlgd.js +30 -0
  57. package/workstation-assets/plans/assets/diagram-WEI45ONY-CPKPEidU.js +41 -0
  58. package/workstation-assets/plans/assets/dist-BN7f1r-d.js +1 -0
  59. package/workstation-assets/plans/assets/ebnfDiagram-CCIWWBDH-CedQkhiI.js +1 -0
  60. package/workstation-assets/plans/assets/erDiagram-Q63AITRT--f4SojKJ.js +85 -0
  61. package/workstation-assets/plans/assets/eventmodeling-45OFAUF4-Dmd0oPLe.js +1 -0
  62. package/workstation-assets/plans/assets/flowDiagram-23GEKE2U-Bk0_NpAg.js +1 -0
  63. package/workstation-assets/plans/assets/ganttDiagram-NO4QXBWP-BD2wDR3D.js +292 -0
  64. package/workstation-assets/plans/assets/gitGraph-TEB2WS4Q-Cu5uXxdQ.js +1 -0
  65. package/workstation-assets/plans/assets/gitGraphDiagram-IHSO6WYX-VyFjgVvS.js +106 -0
  66. package/workstation-assets/plans/assets/graphlib-DS17s2tU.js +1 -0
  67. package/workstation-assets/plans/assets/info-DKCQHKI2-BbwvhFJT.js +1 -0
  68. package/workstation-assets/plans/assets/infoDiagram-FWYZ7A6U-CtgDgw_G.js +2 -0
  69. package/workstation-assets/plans/assets/init-D6jRqBbL.js +1 -0
  70. package/workstation-assets/plans/assets/ishikawaDiagram-FXEZZL3T-4xM3fMGV.js +70 -0
  71. package/workstation-assets/plans/assets/journeyDiagram-5HDEW3XC-Bo-Wurg9.js +139 -0
  72. package/workstation-assets/plans/assets/kanban-definition-HUTT4EX6-9bumG_hJ.js +89 -0
  73. package/workstation-assets/plans/assets/katex-B7rAX3Vi.js +257 -0
  74. package/workstation-assets/plans/assets/line-BuQmF8pC.js +1 -0
  75. package/workstation-assets/plans/assets/linear-RuFdJ2n1.js +1 -0
  76. package/workstation-assets/plans/assets/map-BaFkSB1l.js +1 -0
  77. package/workstation-assets/plans/assets/mermaid-parser.core-Z7aCdDC3.js +7 -0
  78. package/workstation-assets/plans/assets/mermaid.core-7qPnBf_x.js +11 -0
  79. package/workstation-assets/plans/assets/mindmap-definition-LN4V7U3C-CzdKkzT7.js +96 -0
  80. package/workstation-assets/plans/assets/ordinal-hYBb2elL.js +1 -0
  81. package/workstation-assets/plans/assets/packet-7NZHBO7P-Bjesbb-N.js +1 -0
  82. package/workstation-assets/plans/assets/path-BWPyau1x.js +1 -0
  83. package/workstation-assets/plans/assets/pegDiagram-2B236MQR-D1f0OGd_.js +1 -0
  84. package/workstation-assets/plans/assets/pie-RZYD4A2V-BHdG1B1p.js +1 -0
  85. package/workstation-assets/plans/assets/pieDiagram-ENE6RG2P-Da5uhg-w.js +39 -0
  86. package/workstation-assets/plans/assets/quadrantDiagram-ABIIQ3AL-Cxs3S7y0.js +7 -0
  87. package/workstation-assets/plans/assets/radar-I7S5WNFK-u6N10cFf.js +1 -0
  88. package/workstation-assets/plans/assets/railroad-3IZDKUUU-BzfIqZiM.js +1 -0
  89. package/workstation-assets/plans/assets/railroad-abnf-AHOZXSZD-DGhviTe2.js +1 -0
  90. package/workstation-assets/plans/assets/railroad-ebnf-EBAXGLYW-C-Tn21vK.js +1 -0
  91. package/workstation-assets/plans/assets/railroad-peg-LSFZ7HO6-DIdilv2h.js +1 -0
  92. package/workstation-assets/plans/assets/railroadDiagram-RFXS5EU6-DNtNT7hD.js +1 -0
  93. package/workstation-assets/plans/assets/requirementDiagram-TGXJPOKE-raVb_23e.js +84 -0
  94. package/workstation-assets/plans/assets/rough.esm-CSKSodPl.js +1 -0
  95. package/workstation-assets/plans/assets/sankeyDiagram-HTMAVEWB-CeV_C-V-.js +40 -0
  96. package/workstation-assets/plans/assets/sequenceDiagram-DBY2YBRQ-COqLefWL.js +162 -0
  97. package/workstation-assets/plans/assets/sizeCapture-X5ZJPWSS-B0uUizjq.js +1 -0
  98. package/workstation-assets/plans/assets/src-YX8hbnqp.js +1 -0
  99. package/workstation-assets/plans/assets/stateDiagram-2N3HPSRC-hFzKGo6t.js +1 -0
  100. package/workstation-assets/plans/assets/stateDiagram-v2-6OUMAXLB-B0mmwSp9.js +1 -0
  101. package/workstation-assets/plans/assets/swimlanes-5IMT3BWC-8GwDMK58.js +2 -0
  102. package/workstation-assets/plans/assets/swimlanesDiagram-G3AALYLV-CZI5CzhY.js +8 -0
  103. package/workstation-assets/plans/assets/timeline-definition-FHXFAJF6-9eSt4R4I.js +120 -0
  104. package/workstation-assets/plans/assets/treeView-QDETBFTQ-D8MgMJ8g.js +1 -0
  105. package/workstation-assets/plans/assets/treemap-6X3UGDF4-CrzhEgHE.js +1 -0
  106. package/workstation-assets/plans/assets/vennDiagram-L72KCM5P-D8jY-Ckx.js +34 -0
  107. package/workstation-assets/plans/assets/wardley-OPB4EBWU-C6HBA56t.js +1 -0
  108. package/workstation-assets/plans/assets/wardleyDiagram-EHGQE667-DScKs1nw.js +78 -0
  109. package/workstation-assets/plans/assets/xychartDiagram-FW5EYKEG-CMdUL3S6.js +7 -0
  110. package/workstation-assets/plans/index.html +13 -0
  111. package/workstation-assets/plans/index.js +381 -0
  112. package/workstation-assets/plans/style.css +3 -0
package/package.json ADDED
@@ -0,0 +1,72 @@
1
+ {
2
+ "name": "@eforge-build/eforge-plan",
3
+ "version": "0.8.0",
4
+ "description": "First-party eforge planning extension with backlog, session-plan, recommendation, and workstation contributions.",
5
+ "license": "Apache-2.0",
6
+ "type": "module",
7
+ "exports": {
8
+ ".": {
9
+ "types": "./dist/index.d.ts",
10
+ "import": "./dist/index.js"
11
+ },
12
+ "./package.json": "./package.json"
13
+ },
14
+ "types": "./dist/index.d.ts",
15
+ "files": [
16
+ "dist/",
17
+ "prompts/",
18
+ "workstation-assets/",
19
+ "README.md",
20
+ "LICENSE"
21
+ ],
22
+ "engines": {
23
+ "node": ">=22"
24
+ },
25
+ "publishConfig": {
26
+ "access": "public"
27
+ },
28
+ "repository": {
29
+ "type": "git",
30
+ "url": "git+https://github.com/eforge-build/eforge.git"
31
+ },
32
+ "homepage": "https://eforge.build",
33
+ "keywords": [
34
+ "eforge",
35
+ "extension",
36
+ "planning",
37
+ "backlog",
38
+ "workstation"
39
+ ],
40
+ "dependencies": {
41
+ "@sinclair/typebox": "0.34.50",
42
+ "yaml": "^2.9.0",
43
+ "@eforge-build/extension-sdk": "0.8.0",
44
+ "@eforge-build/client": "0.8.0",
45
+ "@eforge-build/input": "0.8.0"
46
+ },
47
+ "devDependencies": {
48
+ "@types/node": "^26.1.1",
49
+ "tsup": "^8.5.1",
50
+ "typescript": "^6.0.3",
51
+ "@eforge-build/eforge-plan-workstation": "0.0.0"
52
+ },
53
+ "author": "Schaake Solutions LLC",
54
+ "eforge": {
55
+ "extension": {
56
+ "name": "eforge-plan",
57
+ "entrypoint": "./dist/index.js",
58
+ "capabilities": [
59
+ {
60
+ "name": "eforge.plan.planning-workstation",
61
+ "version": "1.0.0"
62
+ }
63
+ ]
64
+ }
65
+ },
66
+ "scripts": {
67
+ "build": "pnpm run build:workstation && pnpm run build:runtime",
68
+ "build:runtime": "tsup",
69
+ "build:workstation": "pnpm --dir workstation-src/plans build",
70
+ "type-check": "tsc --noEmit"
71
+ }
72
+ }
@@ -0,0 +1,71 @@
1
+ # eforge-plan Backlog Curation Item Audit
2
+
3
+ You are auditing exactly one validated backlog item for map/reduce backlog curation. Your job is to determine the item's current truth by inspecting the repository with read-only tools.
4
+
5
+ You may use read-only repository tools such as file reads, directory/file discovery, text search, and read-only git inspection. Do not write files, edit files, run mutating commands, install dependencies, start servers, or use network access. Your only accepted final output channel is the submission tool.
6
+
7
+ ## Identity
8
+
9
+ - Target item id: {{itemId}}
10
+ - Source fingerprint: {{sourceFingerprint}}
11
+ - Packet SHA-256: {{packetSha256}}
12
+ - Prompt version: {{promptVersion}}
13
+ - {{runtimeIdentityInstruction}}
14
+
15
+ ```json
16
+ {{runtimeIdentityJson}}
17
+ ```
18
+
19
+ ## Packet JSON
20
+
21
+ The packet is a bounded work order, not the entire evidence universe. Use it for item metadata, acceptance criteria/section summaries, dependency facts, historical navigation hints, recommendation signals, and precondition hashes. Historical hints are search leads only and have `closureAuthority: false`.
22
+
23
+ ```json
24
+ {{packetJson}}
25
+ ```
26
+
27
+ ## Progress reporting
28
+
29
+ You MAY call `{{progressTool}}` for telemetry-only progress. Progress never replaces the final submission.
30
+
31
+ ## Audit rules
32
+
33
+ - Audit only the target item id shown above. Do not infer facts from any other backlog item except when dependency facts are directly relevant.
34
+ - Inspect current source directly. Search for item ids, title terms, command/action/route/component names, changed paths or PR hints from historical hints, and likely product-surface entry points.
35
+ - Current source is the authority for shipped, superseded, partial, still-needed, and stale/invalid conclusions. Historical git/PR/lifecycle hints may guide where to look but are not standalone closure authority.
36
+ - Treat shipped as proven only when current source shows both implementation/replacement logic and user/product-surface wiring, or when the item is explicitly docs/config-only and the relevant committed docs/config surface is present.
37
+ - Treat superseded as proven only when current source or current docs show a replacement/current direction that makes the original item obsolete.
38
+ - Treat partial as useful: cite what exists and summarize what remains.
39
+ - Treat still-needed as useful when you checked likely locations and did not find implementation.
40
+ - Use needs-input only for true product/user decisions, not for missing source evidence.
41
+ - Do not include raw evidence dumps, raw item bodies, or unrelated context in your output.
42
+ - Keep the finding compact. Include only source citations and checked paths that explain the verdict.
43
+ - Preserve `itemId`, `sourceFingerprint`, `bodySha256`, `packetSha256`, and `promptVersion` exactly.
44
+ - If the server provided runtime identity above, do not include `runtimeIdentity`; the runner injects the authoritative runtime identity. If it is `null`, include a valid `runtimeIdentity` in the submission.
45
+
46
+ ## Output contract
47
+
48
+ You MUST call `{{submitTool}}` exactly once with a compact finding matching the shared `BacklogCurationMapReduceFinding` shape:
49
+
50
+ - `schemaVersion`: `1`
51
+ - `itemId`: `{{itemId}}`
52
+ - `sourceFingerprint`: `{{sourceFingerprint}}`
53
+ - `packetSha256`: `{{packetSha256}}`
54
+ - `bodySha256`: copy exactly from the packet
55
+ - `promptVersion`: `{{promptVersion}}`
56
+ - `disposition`: one of `change`, `recheck`, `skip`, or `needs-input`
57
+ - `verdict`: one of `shipped`, `superseded`, `partial`, `still-needed`, `stale-invalid`, `needs-product-input`, or `skip`
58
+ - `closureEvidenceRoles`: include `implementation` or `replacement` plus `product-surface` when proposing `shipped` or `superseded`; include `supporting` for tests/docs/config evidence.
59
+ - `checkedPaths`: compact list of source paths inspected and why they mattered.
60
+ - `summary` and `rationale`: concise, no raw evidence dump
61
+ - `citations`: current-source citations from files you inspected. For shipped/superseded, include at least one implementation/replacement citation and one product-surface citation unless the item is explicitly docs/config-only.
62
+ - `recommendationSignals` and `diagnostics`: bounded arrays only
63
+
64
+ Disposition guidance:
65
+
66
+ - `shipped` or `superseded` verdicts should usually use `disposition: "change"` so the reducer can propose a status update.
67
+ - `partial`, `still-needed`, or `stale-invalid` should use `change` when concrete backlog text/metadata should change, otherwise `recheck`.
68
+ - `needs-product-input` should use `needs-input`.
69
+ - `skip` should be exceptional.
70
+
71
+ Submit exactly once. Do not finish with prose. The submission tool is the only accepted output channel.
@@ -0,0 +1,61 @@
1
+ # eforge-plan Backlog Curation Reducer
2
+
3
+ You are reducing capped backlog-curation map outcomes into the existing eforge-plan planning draft result shape. Do not use repository, filesystem, shell, network, or mutation tools. Use only the reducer input JSON and any validation errors shown here.
4
+
5
+ ## Requested output sections
6
+
7
+ {{requestedOutputSections}}
8
+
9
+ ## Reducer input JSON
10
+
11
+ This input is capped and contains global summaries, dependency/recommendation summaries, diagnostics, and compact per-item outcomes. Item findings may include source-backed verdicts produced by read-only item agents. It intentionally excludes raw backlog packets, raw item bodies, raw `gitDelta`, and raw `fullImplementationAudit` evidence.
12
+
13
+ ```json
14
+ {{reducerInputJson}}
15
+ ```
16
+
17
+ ## Prior validation errors for this repair attempt
18
+
19
+ If this array is non-empty, repair the previous submission by addressing each bounded validation error. Do not ask for raw packets or raw evidence.
20
+
21
+ ```json
22
+ {{validationErrors}}
23
+ ```
24
+
25
+ ## Progress reporting
26
+
27
+ You MAY call `{{progressTool}}` for telemetry-only progress. Progress never replaces the final submission.
28
+
29
+ ## Output contract
30
+
31
+ You MUST call `{{submitTool}}` exactly once with a JSON payload matching this existing planning draft result schema:
32
+
33
+ ```yaml
34
+ {{resultSchema}}
35
+ ```
36
+
37
+ The payload MUST include:
38
+
39
+ 1. `summary` — concise curation summary.
40
+ 2. `assumptionsOpenQuestions` — bounded assumptions/open questions; use an empty array only when there are truly none.
41
+ 3. A ready result with `backlogCurationDraft`, `recommendations`, or both when the capped outcomes support it; otherwise emit the top-level `decision: "needs-input"` shape with non-empty `clarificationQuestions` and `rationale`.
42
+
43
+ ## Reduction rules
44
+
45
+ - Preserve the reducer input `sourceFingerprint` exactly in any `backlogCurationDraft`.
46
+ - Engine emits, consumers apply: do not claim that backlog records were written, updated, shipped, or persisted.
47
+ - Item audit findings are source-backed verdicts. Convert them into structured patches when the finding contains a safe rationale and current-source citations.
48
+ - For `verdict: "shipped"`, create an item change setting `metadata.status: "shipped"` when citations/roles show implementation plus product-surface wiring, or when the finding explains the item is explicitly docs/config-only and cites that current surface.
49
+ - For `verdict: "superseded"`, create an item change setting `metadata.status: "superseded"` when citations/roles show replacement/current direction plus product-surface or docs/config authority.
50
+ - Closed-status item changes must include durable evidence strings beginning with `Shipped evidence: current source — ` or `Superseded evidence: current source — `. Include role labels in those evidence strings, e.g. `implementation: path`, `replacement: path`, and `product-surface: path`, so apply-time validation can verify both roles.
51
+ - For `partial`, `still-needed`, or `stale-invalid`, prefer concrete open-item curation/recommendations over generic no-op rechecks.
52
+ - Use `noOpRechecks` only when the finding says no backlog mutation is warranted after source inspection.
53
+ - Historical hints and recommendation summaries may guide recommendations but are not standalone closure authority.
54
+ - If reducer input diagnostics include `code: "reducer-input-protected-terminal-omitted"`, do not submit a normal complete/apply-ready curation that silently ignores them. Either emit top-level `decision: "needs-input"` split guidance that names every omitted item id and verdict from those diagnostics, or include `backlogCurationDraft.needsInput` rows that name every omitted item id and verdict from those diagnostics.
55
+ - Protected terminal omission handling must be fully named. Do not use aggregate/unnamed split guidance for omitted shipped or superseded candidates.
56
+ - Keep `skipped` exceptional. Use `needsInput` only for true product/user decisions that cannot be resolved from supplied summaries and findings, plus the named protected-terminal omission diagnostics above.
57
+ - Recommendations must target the prospective post-curation backlog state. Do not recommend closed items or epics. Items whose current or same-draft prospective status is `active` belong only in `activeWork`; do not place active items in ready candidates, next sequence, safe-parallel groups, or blocked-chain target lanes.
58
+ - `blockedChains[].blockedBy` accepts only known open backlog item ids. Do not put product-decision placeholders, questions, labels, or synthetic ids there; put those in `rationale`, `rationaleAndAssumptions`, `assumptionsOpenQuestions`, or draft `needsInput` instead.
59
+ - Do not include raw evidence, raw item bodies, raw packets, raw `gitDelta`, or raw `fullImplementationAudit` text in the submission.
60
+
61
+ Submit exactly once. Do not finish with prose. The submission tool is the only accepted output channel.
@@ -0,0 +1,125 @@
1
+ # eforge-plan Planning Draft Task
2
+
3
+ You are drafting planning content for the first-party `eforge-plan` workstation. This is a daemon-owned, single-shot task. Do not use or request mutation-capable tools.
4
+
5
+ ## Task inputs
6
+
7
+ - Planning goal (the request to plan for, not a title): {{topic}}
8
+ - Session: {{session}}
9
+ - Planning type: {{planningType}}
10
+ - Planning depth: {{planningDepth}}
11
+ - Requested output sections: {{requestedOutputSections}}
12
+ - sessionPlanCreationReadiness:
13
+
14
+ ```json
15
+ {{sessionPlanCreationReadiness}}
16
+ ```
17
+
18
+ ## Source text
19
+
20
+ {{sourceText}}
21
+
22
+ ## Existing session plan
23
+
24
+ {{existingSessionPlan}}
25
+
26
+ ## Progress reporting
27
+
28
+ You MAY call `{{progressTool}}` before or after drafting each major session-plan section to report telemetry-only progress. Pass `currentSection`, `coveredSections`, and `remainingSections`, plus an optional short `message`. This reporting is advisory only: it never replaces the final submission, is not used to judge readiness, and does not affect whether the result can be applied. Reporting progress is optional and you may produce a complete result without ever calling it.
29
+
30
+ ## Optional Mermaid diagrams
31
+
32
+ You MAY include fenced `mermaid` diagrams only when a diagram would clarify flows, dependencies, architecture, or sequencing. Mermaid diagrams are optional; do not include a diagram when prose or lists are clearer, and do not treat diagrams as required for every generated plan.
33
+
34
+ ## Output contract
35
+
36
+ You MUST call `{{submitTool}}` exactly once with a JSON payload matching this schema:
37
+
38
+ ```yaml
39
+ {{resultSchema}}
40
+ ```
41
+
42
+ The payload MUST include:
43
+
44
+ 1. `summary` — concise human-readable summary of the proposed planning draft. For session-plan creation drafts, this becomes the persisted `## Executive Summary`; make it useful for fast scope review and sign-off without reading every readiness section. Specifically cover changed surfaces, intended direction, out-of-scope boundaries, and validation/build confidence.
45
+ 2. `assumptionsOpenQuestions` — an array of assumptions or open questions. Use an empty array only when there are truly none.
46
+ 3. Exactly one of the following result shapes:
47
+ - **A ready result** when you can produce the requested output. Include at least one applicable output section:
48
+ - `recommendations` for generated backlog recommendation model updates.
49
+ - `backlogCurationDraft` for structured backlog curation patches the extension may validate and apply later.
50
+ - `handoffDraft` or `handoffDrafts` for draft promotion selections the user may apply.
51
+ - `planDrafts` for eforge plan-file draft content.
52
+ - `sessionPlanPatch` for updates to an existing session plan.
53
+ - `planRevisionTurn` for an answer-only or patch-bearing revision turn against an existing session plan.
54
+ - When `sessionPlanCreationDraft` is requested, set `decision: "ready"` and include a `sessionPlanCreationDraft` object carrying `session`, `topic`, `planningType`, `planningDepth`, and one or more generated `sections`. `topic` MUST be a concise, human-readable plan title — a short noun phrase naming the work (for example, `Annotation-driven plan revisions`). Do NOT copy the planning goal verbatim and do NOT begin it with `Draft a session plan for`. `planningType` must be one of `bugfix`, `feature`, `refactor`, `architecture`, `docs`, `maintenance`, `unknown`; `planningDepth` must be one of `quick`, `focused`, `deep`. Optionally include `profile` (one of `errand`, `excursion`, `expedition`) and `agentProfile` (a string) when the appropriate planning profile or agent profile is known. Use `sessionPlanCreationDraft.sections[].dimension` and `skippedDimensions[].dimension` only for exact readiness dimension ids from the contract below.
55
+ - **A needs-input result** when you cannot produce a ready requested output. Set `decision: "needs-input"`, include a non-empty `clarificationQuestions` array of structured questions, and a `rationale` explaining what is blocking a ready draft. Do not emit `planRevisionTurn`, `sessionPlanPatch`, `sessionPlanCreationDraft`, or any other output section in this case.
56
+
57
+ ## Session-plan creation draft readiness guidance
58
+
59
+ When the requested output sections include `sessionPlanCreationDraft`:
60
+
61
+ - Read the `sessionPlanCreationReadiness` JSON. If `resolved` exists, copy `resolved.planningType` and `resolved.planningDepth` into the draft and use exactly `resolved.requiredDimensions` as the required readiness ids. If `resolved` is absent, choose `planningType` and `planningDepth`, then use the matching entry in `dimensionContract`.
62
+ - For `sections[].dimension` and `skippedDimensions[].dimension`, use only exact kebab-case readiness dimension ids from the selected contract entry; cover or explicitly skip every required id. A skip must include a non-empty reason.
63
+ - Do not submit display-heading aliases as dimension ids. Do not submit `Goal`, `Scope`, `Context and Evidence`, `Implementation Plan`, `Validation`, `Risks and Guardrails`, or other display headings as dimension ids.
64
+ - If a ready draft cannot be produced using the exact ids, emit `needs-input` rather than submitting a not-ready creation draft.
65
+
66
+ ## Plan revision turn guidance
67
+
68
+ When the requested output sections include `planRevisionTurn`:
69
+
70
+ - Emit `planRevisionTurn` for bounded revision-session responses against the provided existing session plan.
71
+ - Always copy the provided `basePlanFingerprint` exactly. If section hashes are provided, copy the relevant `baseSectionHashes` values exactly for sections you discuss or propose changing.
72
+ - Use `assistantMessage` for the user-facing answer. Answer-only turns are valid: include `noPatchReason` when you are explaining, answering a question, or declining to propose edits.
73
+ - For patch-bearing turns, include `proposedPatch.sections` entries with the target `dimension`, replacement `content`, and an optional `rationale`. Use structured edits only for sections you are proposing to change.
74
+ - Use `proposedPatch.metadata.openQuestions` for open questions that can be carried with the proposal, and `proposedPatch.skippedDimensions` for dimensions you intentionally did not revise.
75
+ - If a safe revision cannot be drafted without more user input, emit the top-level `needs-input` result instead of `planRevisionTurn`.
76
+ - Do not claim that the session plan was modified, applied, saved, or persisted. This task only drafts an answer or structured proposal; the extension applies validated changes later.
77
+
78
+ ## Backlog curation guidance
79
+
80
+ When the requested output sections include `backlogCurationDraft` in this generic single-shot task:
81
+
82
+ - Preserve the provided `sourceFingerprint` exactly in the draft.
83
+ - Emit structured `itemChanges`, `epicChanges`, `noOpRechecks`, `skipped`, and `needsInput` arrays. Use empty arrays when a category has no entries.
84
+ - Every material entry in `itemChanges` and `epicChanges` must include a non-empty `rationale` explaining why the patch is safe and necessary.
85
+ - Prefer `noOpRechecks: []`. Do not emit no-op rechecks just to prove every unchanged record was analyzed.
86
+ - Emit a `noOpRechecks` entry only when the record is actually due for review (`stale_after` is before the source `generatedAt` date) or lacks freshness metadata, and the rationale adds useful freshness context. Keep these entries rare and focused.
87
+ - For materially unchanged records that are already fresh, omit them from the draft entirely.
88
+ - Treat `skipped` as exceptional, not normal: use it only for corrupt records, unavailable required source/context, or tooling failures that prevent review. For records that were investigated and should remain open without mutation, omit them from the draft and summarize the coverage instead. Use `needsInput` only for true product decisions that cannot be resolved from source, backlog context, or recommendation strategy.
89
+ - Do not claim that backlog records were written or updated. This task only drafts structured output; the extension applies validated patches later.
90
+ - Do not mark work shipped, superseded, or stale without durable evidence text in the relevant patch.
91
+ - Treat `source.gitDelta.affectedItemCandidates` as deterministic range-aware context from the baseline git-delta scan. Use it to understand affected open items, matched signals, commit hashes, PR numbers, branch hints, changed paths, and bounded excerpts; do not invent evidence or infer a closed status from an affected candidate alone.
92
+ - In `scanMode: "full-implementation-audit"`, this is an agentic source-first curation pass. Current source remains the closure authority for `shipped` and `superseded`, but ambiguous precomputed evidence is a lead to resolve, not a reason to skip. Use the full supplied item body, current-source excerpts, git/PR/lifecycle/session navigation hints, dependency details, roadmap context, and recommendation strategy to produce a complete ready-to-apply draft.
93
+ - In source-first mode, closed-status patches must still be backed by current-source evidence from `source.fullImplementationAudit.sourceFirstResults` / `closureCandidates`; git history, PR metadata, lifecycle traces, branch hints, changed paths, and session-plan traces are navigation hints that help interpret source, not standalone closure authority.
94
+ - Source-first shipped-status patches must cite a strong `source-shipped` result when one is supplied and evidence text must start exactly with `Shipped evidence: current source — ...`.
95
+ - Source-first superseded-status patches must cite a strong `source-superseded` result when one is supplied and evidence text must start exactly with `Superseded evidence: current source — ...`.
96
+ - If source-first evidence is partial, first decide whether the item can be updated forward instead of skipped: clarify remaining work in the item body, fix stale metadata, adjust priority/dependencies/tags, move it to the appropriate open status, or include it in recommendations as follow-up work. Keep items open when closure is not proven, but make the draft actionable.
97
+ - Source-first evidence should include compact current-source citations for both core implementation/replacement and product-surface wiring (export, route/action registry, command registration, UI surface, provider registry, or package entrypoint) before proposing a closed status. If wiring is missing, keep the item open and patch the backlog record or recommendations toward the missing wiring work rather than emitting a generic skip.
98
+ - Epic changes are allowed when they can be justified from backlog/item-level source-first findings, dependency state, roadmap context, or recommendation strategy. Do not emit epic skipped rows merely because source-first preview metadata is item-scoped.
99
+ - Use `needsInput` only when a user/product decision is genuinely required after this investigation. Use `skipped` only for exceptional review failures such as corrupt records or missing required context.
100
+ - Do not claim exhaustive validation unless the supplied source-first caps, diagnostics, and current-source citations explicitly support that wording.
101
+ - `source.shippedEvidenceCandidates` may include compact lifecycle/git/PR historical navigation hints. In source-first curation these hints can guide investigation and recommendations, but they must not be used as standalone closed-status authority.
102
+ - `source.shippedEvidenceCandidates[].evidenceSource` is one of `lifecycle`, `git-history`, `pr-history`, or `combined`.
103
+ - Evidence entries for lifecycle-derived shipped patches must start exactly with `Shipped evidence: lifecycle trace — ...`.
104
+ - Evidence entries for strong git/PR-inferred shipped patches must start exactly with `Shipped evidence: inferred from git/PR history — ...`.
105
+ - Evidence entries for lifecycle-derived superseded patches must start exactly with `Superseded evidence: lifecycle trace — ...`.
106
+ - Evidence entries for strong git/PR-inferred superseded patches must start exactly with `Superseded evidence: inferred from git/PR history — ...`.
107
+ - Ambiguous shipped candidates are not enough for a shipped-status patch; route them to `needsInput` or `skipped` with evidence text that starts exactly with `Ambiguous shipped candidate: needs input — ...`.
108
+ - Ambiguous superseded candidates are not enough for a superseded-status patch; route them to `needsInput` or `skipped` with evidence text that starts exactly with `Ambiguous superseded candidate: needs input — ...`.
109
+ - Never convert ambiguous shipped or ambiguous superseded evidence into a closed-status patch, and never substitute a shipped prefix for superseded evidence or a superseded prefix for shipped evidence.
110
+
111
+ ## Recommendation guidance
112
+
113
+ When emitting `recommendations`:
114
+
115
+ - Generate recommendations against the prospective post-curation backlog state: apply the status changes you propose in `backlogCurationDraft` mentally before choosing recommendation targets.
116
+ - Recommendation target fields may reference only open item/epic ids. Treat closed dependencies as satisfied historical context, not active recommendation targets.
117
+ - Specifically, `activeWork`, `readyCandidates`, `recommendedNextSequence`, `safeParallelizableGroups.itemIds`, `safeParallelizableGroups.epicIds`, `blockedChains.itemIds`, and `blockedChains.blockedBy` may reference only open targets.
118
+ - Same-draft recommendation exclusion: when your `backlogCurationDraft` proposes closing an item or epic (for example with `metadata.status: "shipped"`), do not include that item or epic id anywhere in generated recommendation target arrays in the same result.
119
+ - Generate recommendations against the prospective post-curation backlog state, not the pre-curation state. If the same result includes a `backlogCurationDraft`, first mentally apply its recommendation-relevant metadata changes, then place recommendation targets.
120
+ - Same-draft active items belong only in `activeWork`; do not also list them in `readyCandidates`, `recommendedNextSequence`, `safeParallelizableGroups.itemIds`, or `blockedChains.itemIds`.
121
+ - Same-draft planned or candidate items belong in ready/next/group lanes when recommended. Do not place draft-planned or draft-candidate items in `activeWork` unless lifecycle evidence in the source shows they are already active, queued, building, or PR-open.
122
+ - Place items that your same draft proposes as `active` only in `activeWork`, not in ready/next/group/blocking target lanes.
123
+ - Place items that your same draft proposes as `planned` or `candidate` in `readyCandidates`, `recommendedNextSequence`, `safeParallelizableGroups.itemIds`, or appropriate blocking context rather than `activeWork`.
124
+
125
+ Submit exactly once. Do not finish with prose. The submission tool is the only accepted output channel.
@@ -0,0 +1 @@
1
+ import{m as e,t}from"./mermaid-parser.core-Z7aCdDC3.js";import{n}from"./chunk-Y2CYZVJY-DsF7k-Jl.js";import{m as r}from"./src-YX8hbnqp.js";import"./chunk-WYO6CB5R-BlOpSQhB.js";import"./chunk-VAUOI2AC-BbIlIF2a.js";import{n as i,r as a,t as o}from"./chunk-MOJQB5TN-Dwkjcsly.js";import{t as s}from"./chunk-JWPE2WC7-DVXcaiue.js";var c=e().RailroadAbnf.parser.LangiumParser,l=n(e=>{let t=e.alternatives.map(u);return t.length===1?t[0]:{type:`choice`,alternatives:t}},`transformAlternation`),u=n(e=>{let t=e.elements.map(f);return t.length===1?t[0]:{type:`sequence`,elements:t}},`transformConcatenation`),d=n(e=>{if(e.includes(`*`)){let[t,n]=e.split(`*`);return{min:t?parseInt(t,10):0,max:n?parseInt(n,10):1/0}}let t=parseInt(e,10);return{min:t,max:t}},`parseRepeat`),f=n(e=>{let t=p(e.primary);if(!e.repeat)return t;let{min:n,max:r}=d(e.repeat);return n===0&&r===1?{type:`optional`,element:t}:{type:`repetition`,element:t,min:n,max:r}},`transformElement`),p=n(e=>{switch(e.$type){case`AbnfStringLiteral`:return{type:`terminal`,value:e.value};case`AbnfNumVal`:return{type:`terminal`,value:e.value};case`AbnfRuleName`:return{type:`nonterminal`,name:e.name};case`AbnfGroup`:return l(e.element);case`AbnfOptionalGroup`:return{type:`optional`,element:l(e.element)};default:throw Error(`Unsupported ABNF primary node: ${e.$type}`)}},`transformPrimary`),m=n(e=>({name:e.name,definition:l(e.definition)}),`transformRule`),h=n(e=>{s(e,o),e.title&&o.setTitle(e.title),e.rules.map(e=>o.addRule(m(e)))},`populateDb`),g={parser:{parse:n(e=>{o.clear(),r.debug(`[ABNF Parser] Starting Langium parse`);let n=c.parse(e);if(n.lexerErrors.length>0||n.parserErrors.length>0)throw new t(n);let i=n.value;r.debug(`[ABNF Parser] Parsed rules:`,i.rules.length),h(i),r.debug(`[ABNF Parser] Parse complete`)},`parse`),parser:{yy:o}},db:o,renderer:a,styles:i};export{g as diagram};
@@ -0,0 +1 @@
1
+ import{n as e,t}from"./path-BWPyau1x.js";import{a as n,c as r,d as i,f as a,i as o,l as s,m as c,n as l,o as u,p as d,r as f,u as p}from"./dist-BN7f1r-d.js";function m(e){return e.innerRadius}function h(e){return e.outerRadius}function g(e){return e.startAngle}function _(e){return e.endAngle}function v(e){return e&&e.padAngle}function y(e,t,n,r,i,a,o,s){var c=n-e,l=r-t,u=o-i,d=s-a,f=d*c-u*l;if(!(f*f<1e-12))return f=(u*(t-a)-d*(e-i))/f,[e+f*c,t+f*l]}function b(e,t,n,r,i,a,o){var c=e-n,l=t-r,u=(o?a:-a)/d(c*c+l*l),f=u*l,p=-u*c,m=e+f,h=t+p,g=n+f,_=r+p,v=(m+g)/2,y=(h+_)/2,b=g-m,x=_-h,S=b*b+x*x,C=i-a,w=m*_-g*h,T=(x<0?-1:1)*d(s(0,C*C*S-w*w)),E=(w*x-b*T)/S,D=(-w*b-x*T)/S,O=(w*x+b*T)/S,k=(-w*b+x*T)/S,A=E-v,j=D-y,M=O-v,N=k-y;return A*A+j*j>M*M+N*N&&(E=O,D=k),{cx:E,cy:D,x01:-f,y01:-p,x11:E*(i/C-1),y11:D*(i/C-1)}}function x(){var s=m,x=h,S=e(0),C=null,w=g,T=_,E=v,D=null,O=t(k);function k(){var e,t,m=+s.apply(this,arguments),h=+x.apply(this,arguments),g=w.apply(this,arguments)-r,_=T.apply(this,arguments)-r,v=l(_-g),k=_>g;if(D||=e=O(),h<m&&(t=h,h=m,m=t),!(h>1e-12))D.moveTo(0,0);else if(v>c-1e-12)D.moveTo(h*u(g),h*a(g)),D.arc(0,0,h,g,_,!k),m>1e-12&&(D.moveTo(m*u(_),m*a(_)),D.arc(0,0,m,_,g,k));else{var A=g,j=_,M=g,N=_,P=v,F=v,I=E.apply(this,arguments)/2,L=I>1e-12&&(C?+C.apply(this,arguments):d(m*m+h*h)),R=p(l(h-m)/2,+S.apply(this,arguments)),z=R,B=R,V,H;if(L>1e-12){var U=o(L/m*a(I)),W=o(L/h*a(I));(P-=U*2)>1e-12?(U*=k?1:-1,M+=U,N-=U):(P=0,M=N=(g+_)/2),(F-=W*2)>1e-12?(W*=k?1:-1,A+=W,j-=W):(F=0,A=j=(g+_)/2)}var G=h*u(A),K=h*a(A),q=m*u(N),J=m*a(N);if(R>1e-12){var Y=h*u(j),X=h*a(j),Z=m*u(M),Q=m*a(M),$;if(v<i)if($=y(G,K,Z,Q,Y,X,q,J)){var ee=G-$[0],te=K-$[1],ne=Y-$[0],re=X-$[1],ie=1/a(f((ee*ne+te*re)/(d(ee*ee+te*te)*d(ne*ne+re*re)))/2),ae=d($[0]*$[0]+$[1]*$[1]);z=p(R,(m-ae)/(ie-1)),B=p(R,(h-ae)/(ie+1))}else z=B=0}F>1e-12?B>1e-12?(V=b(Z,Q,G,K,h,B,k),H=b(Y,X,q,J,h,B,k),D.moveTo(V.cx+V.x01,V.cy+V.y01),B<R?D.arc(V.cx,V.cy,B,n(V.y01,V.x01),n(H.y01,H.x01),!k):(D.arc(V.cx,V.cy,B,n(V.y01,V.x01),n(V.y11,V.x11),!k),D.arc(0,0,h,n(V.cy+V.y11,V.cx+V.x11),n(H.cy+H.y11,H.cx+H.x11),!k),D.arc(H.cx,H.cy,B,n(H.y11,H.x11),n(H.y01,H.x01),!k))):(D.moveTo(G,K),D.arc(0,0,h,A,j,!k)):D.moveTo(G,K),!(m>1e-12)||!(P>1e-12)?D.lineTo(q,J):z>1e-12?(V=b(q,J,Y,X,m,-z,k),H=b(G,K,Z,Q,m,-z,k),D.lineTo(V.cx+V.x01,V.cy+V.y01),z<R?D.arc(V.cx,V.cy,z,n(V.y01,V.x01),n(H.y01,H.x01),!k):(D.arc(V.cx,V.cy,z,n(V.y01,V.x01),n(V.y11,V.x11),!k),D.arc(0,0,m,n(V.cy+V.y11,V.cx+V.x11),n(H.cy+H.y11,H.cx+H.x11),k),D.arc(H.cx,H.cy,z,n(H.y11,H.x11),n(H.y01,H.x01),!k))):D.arc(0,0,m,N,M,k)}if(D.closePath(),e)return D=null,e+``||null}return k.centroid=function(){var e=(+s.apply(this,arguments)+ +x.apply(this,arguments))/2,t=(+w.apply(this,arguments)+ +T.apply(this,arguments))/2-i/2;return[u(t)*e,a(t)*e]},k.innerRadius=function(t){return arguments.length?(s=typeof t==`function`?t:e(+t),k):s},k.outerRadius=function(t){return arguments.length?(x=typeof t==`function`?t:e(+t),k):x},k.cornerRadius=function(t){return arguments.length?(S=typeof t==`function`?t:e(+t),k):S},k.padRadius=function(t){return arguments.length?(C=t==null?null:typeof t==`function`?t:e(+t),k):C},k.startAngle=function(t){return arguments.length?(w=typeof t==`function`?t:e(+t),k):w},k.endAngle=function(t){return arguments.length?(T=typeof t==`function`?t:e(+t),k):T},k.padAngle=function(t){return arguments.length?(E=typeof t==`function`?t:e(+t),k):E},k.context=function(e){return arguments.length?(D=e??null,k):D},k}export{x as t};
@@ -0,0 +1 @@
1
+ import"./chunk-KEIR6QF5-Dj-OpFgW.js";import{M as e}from"./mermaid-parser.core-Z7aCdDC3.js";export{e as createArchitectureServices};