forge-cc 0.1.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 (105) hide show
  1. package/.forge.json +5 -0
  2. package/AGENTS.md +42 -0
  3. package/README.md +283 -0
  4. package/dist/cli.d.ts +2 -0
  5. package/dist/cli.js +148 -0
  6. package/dist/cli.js.map +1 -0
  7. package/dist/config/loader.d.ts +2 -0
  8. package/dist/config/loader.js +44 -0
  9. package/dist/config/loader.js.map +1 -0
  10. package/dist/config/schema.d.ts +57 -0
  11. package/dist/config/schema.js +15 -0
  12. package/dist/config/schema.js.map +1 -0
  13. package/dist/gates/index.d.ts +11 -0
  14. package/dist/gates/index.js +106 -0
  15. package/dist/gates/index.js.map +1 -0
  16. package/dist/gates/lint-gate.d.ts +2 -0
  17. package/dist/gates/lint-gate.js +66 -0
  18. package/dist/gates/lint-gate.js.map +1 -0
  19. package/dist/gates/prd-gate.d.ts +7 -0
  20. package/dist/gates/prd-gate.js +193 -0
  21. package/dist/gates/prd-gate.js.map +1 -0
  22. package/dist/gates/runtime-gate.d.ts +5 -0
  23. package/dist/gates/runtime-gate.js +99 -0
  24. package/dist/gates/runtime-gate.js.map +1 -0
  25. package/dist/gates/tests-gate.d.ts +2 -0
  26. package/dist/gates/tests-gate.js +116 -0
  27. package/dist/gates/tests-gate.js.map +1 -0
  28. package/dist/gates/types-gate.d.ts +2 -0
  29. package/dist/gates/types-gate.js +59 -0
  30. package/dist/gates/types-gate.js.map +1 -0
  31. package/dist/gates/visual-gate.d.ts +6 -0
  32. package/dist/gates/visual-gate.js +118 -0
  33. package/dist/gates/visual-gate.js.map +1 -0
  34. package/dist/go/auto-chain.d.ts +107 -0
  35. package/dist/go/auto-chain.js +303 -0
  36. package/dist/go/auto-chain.js.map +1 -0
  37. package/dist/go/executor.d.ts +130 -0
  38. package/dist/go/executor.js +409 -0
  39. package/dist/go/executor.js.map +1 -0
  40. package/dist/go/finalize.d.ts +58 -0
  41. package/dist/go/finalize.js +200 -0
  42. package/dist/go/finalize.js.map +1 -0
  43. package/dist/go/linear-sync.d.ts +75 -0
  44. package/dist/go/linear-sync.js +239 -0
  45. package/dist/go/linear-sync.js.map +1 -0
  46. package/dist/go/verify-loop.d.ts +47 -0
  47. package/dist/go/verify-loop.js +172 -0
  48. package/dist/go/verify-loop.js.map +1 -0
  49. package/dist/hooks/pre-commit.d.ts +5 -0
  50. package/dist/hooks/pre-commit.js +69 -0
  51. package/dist/hooks/pre-commit.js.map +1 -0
  52. package/dist/linear/client.d.ts +108 -0
  53. package/dist/linear/client.js +388 -0
  54. package/dist/linear/client.js.map +1 -0
  55. package/dist/linear/issues.d.ts +20 -0
  56. package/dist/linear/issues.js +39 -0
  57. package/dist/linear/issues.js.map +1 -0
  58. package/dist/linear/milestones.d.ts +11 -0
  59. package/dist/linear/milestones.js +32 -0
  60. package/dist/linear/milestones.js.map +1 -0
  61. package/dist/linear/projects.d.ts +16 -0
  62. package/dist/linear/projects.js +50 -0
  63. package/dist/linear/projects.js.map +1 -0
  64. package/dist/reporter/human.d.ts +2 -0
  65. package/dist/reporter/human.js +63 -0
  66. package/dist/reporter/human.js.map +1 -0
  67. package/dist/reporter/json.d.ts +2 -0
  68. package/dist/reporter/json.js +4 -0
  69. package/dist/reporter/json.js.map +1 -0
  70. package/dist/server.d.ts +2 -0
  71. package/dist/server.js +109 -0
  72. package/dist/server.js.map +1 -0
  73. package/dist/spec/generator.d.ts +14 -0
  74. package/dist/spec/generator.js +206 -0
  75. package/dist/spec/generator.js.map +1 -0
  76. package/dist/spec/interview.d.ts +104 -0
  77. package/dist/spec/interview.js +342 -0
  78. package/dist/spec/interview.js.map +1 -0
  79. package/dist/spec/linear-sync.d.ts +48 -0
  80. package/dist/spec/linear-sync.js +125 -0
  81. package/dist/spec/linear-sync.js.map +1 -0
  82. package/dist/spec/scanner.d.ts +45 -0
  83. package/dist/spec/scanner.js +473 -0
  84. package/dist/spec/scanner.js.map +1 -0
  85. package/dist/spec/templates.d.ts +345 -0
  86. package/dist/spec/templates.js +86 -0
  87. package/dist/spec/templates.js.map +1 -0
  88. package/dist/state/reader.d.ts +29 -0
  89. package/dist/state/reader.js +116 -0
  90. package/dist/state/reader.js.map +1 -0
  91. package/dist/state/writer.d.ts +60 -0
  92. package/dist/state/writer.js +222 -0
  93. package/dist/state/writer.js.map +1 -0
  94. package/dist/types.d.ts +64 -0
  95. package/dist/types.js +2 -0
  96. package/dist/types.js.map +1 -0
  97. package/dist/utils/browser.d.ts +10 -0
  98. package/dist/utils/browser.js +89 -0
  99. package/dist/utils/browser.js.map +1 -0
  100. package/hooks/pre-commit-verify.js +103 -0
  101. package/package.json +68 -0
  102. package/skills/README.md +33 -0
  103. package/skills/forge-go.md +332 -0
  104. package/skills/forge-spec.md +251 -0
  105. package/skills/forge-triage.md +133 -0
@@ -0,0 +1,133 @@
1
+ # /forge:triage — Brain Dump to Linear Projects
2
+
3
+ Turn sticky notes, rambling thoughts, and unstructured ideas into organized Linear projects. Paste anything — bullet points, paragraphs, stream of consciousness — and this skill extracts distinct projects, deduplicates against your existing Linear backlog, and creates them after your confirmation.
4
+
5
+ ## Instructions
6
+
7
+ Follow these steps exactly. Do not skip confirmation.
8
+
9
+ ### Step 1 — Collect Input
10
+
11
+ If the user has already provided text (ideas, notes, brain dump) in the same message as invoking this skill, use that as input. Otherwise, prompt:
12
+
13
+ > Paste your ideas, sticky notes, or brain dump below. Any format works — bullet points, paragraphs, stream of consciousness. I'll extract the projects from whatever you give me.
14
+
15
+ Wait for the user's input before continuing. Do not proceed with an empty input.
16
+
17
+ If the input is extremely short or vague (fewer than 5 words with no actionable idea), ask:
18
+
19
+ > That's a bit thin. Can you expand on what you're thinking? Even a sentence or two per idea helps me create better project descriptions.
20
+
21
+ ### Step 2 — Extract Projects
22
+
23
+ Parse the input to identify distinct project ideas. For each idea, determine:
24
+
25
+ - **Name**: Short, descriptive project name (2-5 words, title case)
26
+ - **Description**: 1-2 sentence summary capturing the core intent
27
+ - **Priority**: High / Medium / Low based on urgency signals in the text (words like "urgent", "ASAP", "critical", "soon" = High; "eventually", "someday", "nice to have" = Low; everything else = Medium)
28
+
29
+ Rules for extraction:
30
+ - Group related ideas into a single project. If someone mentions "mobile app redesign" and "fix the mobile nav", that is one project, not two.
31
+ - If an idea is extremely vague (e.g., "maybe something with AI"), still extract it but flag it for clarification in Step 4.
32
+ - For a single idea, create one project. For 10+ ideas, create as many projects as are genuinely distinct — do not artificially limit or pad.
33
+ - Do not invent projects that were not in the input. Only extract what is there.
34
+
35
+ ### Step 3 — Deduplicate Against Linear
36
+
37
+ Fetch existing projects from Linear:
38
+
39
+ ```
40
+ Use mcp__linear__list_projects to get all existing projects.
41
+ ```
42
+
43
+ For each extracted project, compare its name and description against existing projects. A project is a potential duplicate if:
44
+ - The name is very similar (e.g., "Mobile Redesign" vs "Mobile App Redesign")
45
+ - The description covers the same scope
46
+
47
+ Mark duplicates with status `DUPLICATE` and reference the existing project name. Mark new projects with status `NEW`.
48
+
49
+ If `mcp__linear__list_projects` fails (auth issue, Linear not configured), warn the user:
50
+
51
+ > Could not connect to Linear to check for duplicates. Make sure your Linear MCP tools are configured. I'll proceed without dedup — you can review for duplicates manually.
52
+
53
+ Then skip dedup and mark all projects as `NEW`.
54
+
55
+ ### Step 4 — Present for Confirmation
56
+
57
+ Show the user a formatted list:
58
+
59
+ ```
60
+ ## Extracted Projects (N total)
61
+
62
+ 1. **Project Name** — Description
63
+ Priority: High | Status: NEW
64
+
65
+ 2. **Project Name** — Description
66
+ Priority: Medium | Status: DUPLICATE of "Existing Project Name"
67
+
68
+ 3. **Project Name** — Description
69
+ Priority: Low | Status: NEW | NOTE: This idea was vague — confirm or clarify?
70
+ ```
71
+
72
+ Then ask:
73
+
74
+ > Review the list above. You can:
75
+ > - **Confirm all** — I'll create the NEW ones in Linear
76
+ > - **Remove items** — tell me which numbers to skip (e.g., "remove 2, 5")
77
+ > - **Edit items** — tell me what to change (e.g., "rename 3 to X" or "change 1 priority to Low")
78
+ > - **Clarify** — expand on any flagged vague ideas
79
+ >
80
+ > What would you like to do?
81
+
82
+ Wait for the user's response. Apply any edits, removals, or clarifications. If the user says "confirm" or similar affirmative, proceed to Step 5. If they make changes, show the updated list and confirm again.
83
+
84
+ ### Step 5 — Create in Linear
85
+
86
+ First, get the team ID (you only need to do this once):
87
+
88
+ ```
89
+ Use mcp__linear__list_teams to get available teams.
90
+ ```
91
+
92
+ If there is only one team, use it automatically. If there are multiple teams, ask the user which team to use.
93
+
94
+ For each confirmed NEW project (skip items marked DUPLICATE that the user did not override):
95
+
96
+ ```
97
+ Use mcp__linear__create_project with:
98
+ - name: the project name
99
+ - description: the project description
100
+ - state: "backlog"
101
+ ```
102
+
103
+ If a project creation fails, report the error and continue with the remaining projects. Do not abort the entire batch for a single failure.
104
+
105
+ After all projects are created, print a summary:
106
+
107
+ ```
108
+ ## Created N projects in Linear
109
+
110
+ - **Project Name** — created successfully
111
+ - **Project Name** — created successfully
112
+ - **Project Name** — FAILED: [error message]
113
+
114
+ Skipped M duplicates.
115
+ ```
116
+
117
+ ### Step 6 — Suggest Next Steps
118
+
119
+ After creation, print:
120
+
121
+ > **Next steps:**
122
+ > - Run `/forge:spec` on any of these projects to create a detailed PRD with milestones
123
+ > - Run `/forge:triage` again to add more ideas
124
+ > - Open Linear to review and organize your new projects
125
+
126
+ ## Edge Cases
127
+
128
+ - **Empty input**: Prompt the user to provide input. Do not create empty projects.
129
+ - **Single idea**: Create one project. The workflow still applies (confirm before creating).
130
+ - **10+ ideas**: Process all of them. Group aggressively to avoid near-duplicates.
131
+ - **All duplicates**: Report that all ideas already exist in Linear. Suggest reviewing existing projects.
132
+ - **Linear auth fails**: Warn the user, skip dedup, but still attempt creation. If creation also fails, provide manual instructions.
133
+ - **Vague ideas**: Extract them with a clarification flag. Let the user decide whether to keep, clarify, or remove.