millhouse 0.3.5 → 1.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 (75) hide show
  1. package/README.md +88 -161
  2. package/dist/analysis/issue-analyzer.d.ts +6 -1
  3. package/dist/analysis/issue-analyzer.d.ts.map +1 -1
  4. package/dist/analysis/issue-analyzer.js +45 -13
  5. package/dist/analysis/issue-analyzer.js.map +1 -1
  6. package/dist/analysis/plan-parser.d.ts +7 -1
  7. package/dist/analysis/plan-parser.d.ts.map +1 -1
  8. package/dist/analysis/plan-parser.js +98 -21
  9. package/dist/analysis/plan-parser.js.map +1 -1
  10. package/dist/cli/cleanup.d.ts +1 -1
  11. package/dist/cli/cleanup.d.ts.map +1 -1
  12. package/dist/cli/cleanup.js +25 -29
  13. package/dist/cli/cleanup.js.map +1 -1
  14. package/dist/cli/commands/init.d.ts +6 -0
  15. package/dist/cli/commands/init.d.ts.map +1 -0
  16. package/dist/cli/commands/init.js +156 -0
  17. package/dist/cli/commands/init.js.map +1 -0
  18. package/dist/cli/commands/list.d.ts +6 -0
  19. package/dist/cli/commands/list.d.ts.map +1 -0
  20. package/dist/cli/commands/list.js +111 -0
  21. package/dist/cli/commands/list.js.map +1 -0
  22. package/dist/cli/commands/load.d.ts +2 -0
  23. package/dist/cli/commands/load.d.ts.map +1 -0
  24. package/dist/cli/commands/load.js +111 -0
  25. package/dist/cli/commands/load.js.map +1 -0
  26. package/dist/cli/commands/resume.d.ts.map +1 -1
  27. package/dist/cli/commands/resume.js +29 -24
  28. package/dist/cli/commands/resume.js.map +1 -1
  29. package/dist/cli/commands/run.d.ts +2 -3
  30. package/dist/cli/commands/run.d.ts.map +1 -1
  31. package/dist/cli/commands/run.js +44 -237
  32. package/dist/cli/commands/run.js.map +1 -1
  33. package/dist/cli/commands/save.d.ts +2 -0
  34. package/dist/cli/commands/save.d.ts.map +1 -0
  35. package/dist/cli/commands/save.js +220 -0
  36. package/dist/cli/commands/save.js.map +1 -0
  37. package/dist/cli/commands/setup.js +3 -3
  38. package/dist/cli/progress-display.d.ts +10 -1
  39. package/dist/cli/progress-display.d.ts.map +1 -1
  40. package/dist/cli/progress-display.js +107 -17
  41. package/dist/cli/progress-display.js.map +1 -1
  42. package/dist/core/orchestrator.d.ts +11 -12
  43. package/dist/core/orchestrator.d.ts.map +1 -1
  44. package/dist/core/orchestrator.js +159 -113
  45. package/dist/core/orchestrator.js.map +1 -1
  46. package/dist/core/scheduler.d.ts +6 -1
  47. package/dist/core/scheduler.d.ts.map +1 -1
  48. package/dist/core/scheduler.js +48 -9
  49. package/dist/core/scheduler.js.map +1 -1
  50. package/dist/execution/claude-runner.d.ts +2 -2
  51. package/dist/execution/claude-runner.d.ts.map +1 -1
  52. package/dist/execution/claude-runner.js +1 -1
  53. package/dist/execution/claude-runner.js.map +1 -1
  54. package/dist/execution/worktree-manager.d.ts.map +1 -1
  55. package/dist/execution/worktree-manager.js +5 -6
  56. package/dist/execution/worktree-manager.js.map +1 -1
  57. package/dist/index.js +30 -29
  58. package/dist/index.js.map +1 -1
  59. package/dist/storage/json-store.d.ts +1 -0
  60. package/dist/storage/json-store.d.ts.map +1 -1
  61. package/dist/storage/json-store.js +36 -0
  62. package/dist/storage/json-store.js.map +1 -1
  63. package/dist/storage/worklist-store.d.ts +19 -0
  64. package/dist/storage/worklist-store.d.ts.map +1 -0
  65. package/dist/storage/worklist-store.js +131 -0
  66. package/dist/storage/worklist-store.js.map +1 -0
  67. package/dist/types.d.ts +39 -70
  68. package/dist/types.d.ts.map +1 -1
  69. package/dist/types.js +3 -24
  70. package/dist/types.js.map +1 -1
  71. package/package.json +3 -4
  72. package/prompts/implementation.prompt.md +34 -35
  73. package/prompts/issue-analysis.prompt.md +56 -22
  74. package/prompts/plan-analysis.prompt.md +47 -36
  75. package/commands/millhouse.md +0 -223
@@ -1,223 +0,0 @@
1
- # Millhouse
2
-
3
- Orchestrate parallel Claude Code instances to implement work items.
4
-
5
- ## Usage
6
-
7
- Parse $ARGUMENTS to determine the subcommand:
8
-
9
- - `/millhouse plan [plan-file]` - Refine a plan for millhouse execution
10
- - `/millhouse issues [plan-file]` - Create GitHub issues from a plan
11
-
12
- ---
13
-
14
- ## /millhouse plan
15
-
16
- Refine and improve a plan to make it suitable for millhouse execution. This should be fast and unattended - don't ask clarifying questions, just improve the plan.
17
-
18
- ### Context
19
-
20
- Millhouse executes work items in **parallel using separate Claude Code instances**, each running **unattended in its own context window**. This means:
21
-
22
- - Each work item is a fresh start with no memory of previous work
23
- - Work items must be completely self-contained
24
- - Nothing can be assumed or left implicit
25
-
26
- ### Instructions
27
-
28
- 1. Read the plan from the file path argument. If no file given, look for plan.md or ask for the filename only.
29
- 2. Analyze the plan and rewrite it following the guidelines below
30
- 3. Save the improved plan to the same file (overwrite), or `plan.md` if it was a new plan
31
- 4. **Do not ask questions about features, scope, or implementation details** - work with what's given
32
- 5. **Do not suggest additions** - only restructure and clarify what's already in the plan
33
-
34
- ### Plan Improvement Guidelines
35
-
36
- Transform the plan to be millhouse-ready:
37
-
38
- **1. Separate work items clearly**
39
- - Each work item should be a distinct section
40
- - Work items will run in separate contexts, stage by stage
41
- - Make boundaries between items obvious
42
-
43
- **2. Split into appropriately-sized tasks**
44
- - Break large tasks into smaller sub-tasks where necessary
45
- - Each task should be small enough to complete in one go, unattended
46
- - A task that's "create an entire application" is too big
47
- - A task that's "create a function that adds two numbers" might be too small (unless it's a dependency)
48
-
49
- **3. Make each task self-contained**
50
- - Include ALL context needed to implement the task
51
- - Specify exact file paths to create or modify
52
- - Include function signatures, types, interfaces
53
- - Don't assume knowledge from other tasks
54
-
55
- **4. Add thorough acceptance criteria**
56
- - How do we know this task is done?
57
- - What commands verify it works? (e.g., `npm test`, `go build`)
58
- - What should the output look like?
59
- - What edge cases should be handled?
60
-
61
- **5. Add testing instructions**
62
- - Specific test commands to run
63
- - Expected results
64
- - How to verify integration with other components
65
-
66
- **6. Make dependencies explicit**
67
- - Which tasks must complete before this one can start?
68
- - What does this task need from its dependencies? (files, exports, etc.)
69
- - Use clear language like "This requires the math utilities from task 1"
70
-
71
- ### Important: Be Non-Interactive
72
-
73
- - **Don't ask** if the user wants to add features, tests, or documentation
74
- - **Don't suggest** expanding scope or adding "nice to haves"
75
- - **Just restructure** the existing plan into millhouse-ready format
76
- - If something is ambiguous, make a reasonable assumption and note it in the task
77
-
78
- ### Example Transformation
79
-
80
- **Before (too vague):**
81
- ```markdown
82
- # My App
83
- - Build a calculator
84
- - Add tests
85
- ```
86
-
87
- **After (millhouse-ready):**
88
- ```markdown
89
- # Calculator App
90
-
91
- ## 1. Initialize TypeScript Project
92
- Create the project structure with TypeScript configuration.
93
-
94
- ### Implementation
95
- - Create `package.json` with name "calculator", typescript and vitest as dev dependencies
96
- - Create `tsconfig.json` with strict mode, ES2020 target, NodeNext module resolution
97
- - Create `src/` directory
98
-
99
- ### Testing
100
- Run `npm install` and `npx tsc --noEmit` - should complete without errors.
101
-
102
- ### Acceptance Criteria
103
- - [ ] `package.json` exists with correct dependencies
104
- - [ ] `tsconfig.json` exists with strict mode enabled
105
- - [ ] `src/` directory exists
106
- - [ ] `npm install && npx tsc --noEmit` succeeds
107
-
108
- ## 2. Create Math Utilities
109
- Create basic arithmetic functions used by the calculator.
110
-
111
- **Depends on task 1** - needs the TypeScript project structure.
112
-
113
- ### Implementation
114
- Create `src/math.ts` with:
115
- - `add(a: number, b: number): number` - returns sum
116
- - `subtract(a: number, b: number): number` - returns difference
117
- - `multiply(a: number, b: number): number` - returns product
118
- - `divide(a: number, b: number): number` - returns quotient, throws on division by zero
119
-
120
- ### Testing
121
- Create `src/math.test.ts` with vitest tests for all functions including edge cases.
122
- Run `npx vitest run` - all tests should pass.
123
-
124
- ### Acceptance Criteria
125
- - [ ] `src/math.ts` exports all four functions
126
- - [ ] `src/math.test.ts` has tests for each function
127
- - [ ] Tests cover division by zero error case
128
- - [ ] `npx vitest run` passes all tests
129
- ```
130
-
131
- ---
132
-
133
- ## /millhouse issues
134
-
135
- Convert a plan into GitHub issues formatted for Millhouse.
136
-
137
- ### Critical Context
138
-
139
- These issues will be implemented by Claude Code instances running **unattended in separate context windows**. Each issue is a fresh start with no memory of previous conversations. This means:
140
-
141
- - Every issue must be completely self-contained
142
- - All relevant context, requirements, and constraints must be explicitly stated
143
- - Nothing can be assumed or left implicit
144
-
145
- ### Instructions
146
-
147
- 1. Read the plan from the file path argument, or ask the user to describe it
148
- 2. Break it into discrete, implementable issues
149
- 3. For each issue, identify dependencies on other issues
150
- 4. Create issues in order using `gh issue create`, starting with issues that have no dependencies
151
- 5. Use the actual issue numbers returned by GitHub for dependency references
152
- 6. After creating all issues, create an **index issue** that lists them all (see below)
153
-
154
- ### Issue Content Requirements
155
-
156
- Each issue MUST include:
157
-
158
- **Implementation Details**
159
- - Specific file paths to create or modify
160
- - Function signatures, types, or interfaces expected
161
- - Any specific libraries or patterns to use
162
-
163
- **Testing & Verification**
164
- - How to verify the implementation works
165
- - Specific test commands to run (e.g., `npm test`, `npm run build`)
166
- - Expected output or behavior
167
-
168
- **Acceptance Criteria**
169
- - Clear, checkable criteria for when the issue is "done"
170
- - Edge cases to handle
171
- - Error conditions to consider
172
-
173
- **Dependencies**
174
- - `**Depends on #N**` if it depends on another issue
175
- - What specifically it needs from that dependency (files, exports, etc.)
176
-
177
- ### Example Issue Body
178
-
179
- ```markdown
180
- Create `src/utils/math.ts` with basic arithmetic functions.
181
-
182
- ## Implementation
183
- - Export functions: `add(a: number, b: number): number` and `multiply(a: number, b: number): number`
184
- - Use ES module syntax (export, not module.exports)
185
- - No external dependencies
186
-
187
- ## Testing
188
- Run `npx tsc --noEmit` to verify no type errors.
189
-
190
- ## Acceptance Criteria
191
- - [ ] File exists at `src/utils/math.ts`
192
- - [ ] Both functions are exported
193
- - [ ] TypeScript compiles without errors
194
- ```
195
-
196
- ### Index Issue
197
-
198
- After creating all implementation issues, create a final **index issue** that serves as an overview. Title it something like "Implement [feature name]" and include:
199
-
200
- - A one-line summary of the overall goal
201
- - A list of all created issues with their numbers and a brief description
202
- - The command to run: `millhouse run issues <index-number>`
203
-
204
- Example:
205
-
206
- ```markdown
207
- Implement a calculator library with math utilities.
208
-
209
- ## Issues
210
-
211
- - #1 Create math utilities (`src/utils/math.ts`)
212
- - #2 Create string helpers (`src/utils/string.ts`)
213
- - #3 Create calculator class (`src/calculator.ts`)
214
- - #4 Create main entry point (`src/index.ts`)
215
-
216
- ## Run
217
-
218
- \`\`\`bash
219
- millhouse run issues <this-issue-number>
220
- \`\`\`
221
- ```
222
-
223
- The index issue should **not** include detailed dependency information—Millhouse will discover dependencies from the individual issues.