jell-utils 0.1.0 → 0.2.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.
- package/.claude/commands/tm/add-dependency.md +58 -0
- package/.claude/commands/tm/add-subtask.md +79 -0
- package/.claude/commands/tm/add-task.md +81 -0
- package/.claude/commands/tm/analyze-complexity.md +124 -0
- package/.claude/commands/tm/analyze-project.md +100 -0
- package/.claude/commands/tm/auto-implement-tasks.md +100 -0
- package/.claude/commands/tm/command-pipeline.md +80 -0
- package/.claude/commands/tm/complexity-report.md +120 -0
- package/.claude/commands/tm/convert-task-to-subtask.md +74 -0
- package/.claude/commands/tm/expand-all-tasks.md +52 -0
- package/.claude/commands/tm/expand-task.md +52 -0
- package/.claude/commands/tm/fix-dependencies.md +82 -0
- package/.claude/commands/tm/help.md +101 -0
- package/.claude/commands/tm/init-project-quick.md +49 -0
- package/.claude/commands/tm/init-project.md +53 -0
- package/.claude/commands/tm/install-taskmaster.md +118 -0
- package/.claude/commands/tm/learn.md +106 -0
- package/.claude/commands/tm/list-tasks-by-status.md +42 -0
- package/.claude/commands/tm/list-tasks-with-subtasks.md +30 -0
- package/.claude/commands/tm/list-tasks.md +46 -0
- package/.claude/commands/tm/next-task.md +69 -0
- package/.claude/commands/tm/parse-prd-with-research.md +51 -0
- package/.claude/commands/tm/parse-prd.md +52 -0
- package/.claude/commands/tm/project-status.md +67 -0
- package/.claude/commands/tm/quick-install-taskmaster.md +23 -0
- package/.claude/commands/tm/remove-all-subtasks.md +94 -0
- package/.claude/commands/tm/remove-dependency.md +65 -0
- package/.claude/commands/tm/remove-subtask.md +87 -0
- package/.claude/commands/tm/remove-subtasks.md +89 -0
- package/.claude/commands/tm/remove-task.md +110 -0
- package/.claude/commands/tm/setup-models.md +52 -0
- package/.claude/commands/tm/show-task.md +85 -0
- package/.claude/commands/tm/smart-workflow.md +58 -0
- package/.claude/commands/tm/sync-readme.md +120 -0
- package/.claude/commands/tm/tm-main.md +147 -0
- package/.claude/commands/tm/to-cancelled.md +58 -0
- package/.claude/commands/tm/to-deferred.md +50 -0
- package/.claude/commands/tm/to-done.md +47 -0
- package/.claude/commands/tm/to-in-progress.md +39 -0
- package/.claude/commands/tm/to-pending.md +35 -0
- package/.claude/commands/tm/to-review.md +43 -0
- package/.claude/commands/tm/update-single-task.md +122 -0
- package/.claude/commands/tm/update-task.md +75 -0
- package/.claude/commands/tm/update-tasks-from-id.md +111 -0
- package/.claude/commands/tm/validate-dependencies.md +72 -0
- package/.claude/commands/tm/view-models.md +52 -0
- package/.claude/settings.local.json +17 -3
- package/.cursor/commands/tm/add-dependency.md +55 -0
- package/.cursor/commands/tm/add-subtask.md +76 -0
- package/.cursor/commands/tm/add-task.md +78 -0
- package/.cursor/commands/tm/analyze-complexity.md +121 -0
- package/.cursor/commands/tm/analyze-project.md +97 -0
- package/.cursor/commands/tm/auto-implement-tasks.md +97 -0
- package/.cursor/commands/tm/command-pipeline.md +77 -0
- package/.cursor/commands/tm/complexity-report.md +117 -0
- package/.cursor/commands/tm/convert-task-to-subtask.md +71 -0
- package/.cursor/commands/tm/expand-all-tasks.md +51 -0
- package/.cursor/commands/tm/expand-task.md +49 -0
- package/.cursor/commands/tm/fix-dependencies.md +81 -0
- package/.cursor/commands/tm/help.md +98 -0
- package/.cursor/commands/tm/init-project-quick.md +46 -0
- package/.cursor/commands/tm/init-project.md +50 -0
- package/.cursor/commands/tm/install-taskmaster.md +117 -0
- package/.cursor/commands/tm/learn.md +103 -0
- package/.cursor/commands/tm/list-tasks-by-status.md +39 -0
- package/.cursor/commands/tm/list-tasks-with-subtasks.md +29 -0
- package/.cursor/commands/tm/list-tasks.md +43 -0
- package/.cursor/commands/tm/next-task.md +66 -0
- package/.cursor/commands/tm/parse-prd-with-research.md +48 -0
- package/.cursor/commands/tm/parse-prd.md +49 -0
- package/.cursor/commands/tm/project-status.md +64 -0
- package/.cursor/commands/tm/quick-install-taskmaster.md +22 -0
- package/.cursor/commands/tm/remove-all-subtasks.md +93 -0
- package/.cursor/commands/tm/remove-dependency.md +62 -0
- package/.cursor/commands/tm/remove-subtask.md +84 -0
- package/.cursor/commands/tm/remove-subtasks.md +86 -0
- package/.cursor/commands/tm/remove-task.md +107 -0
- package/.cursor/commands/tm/setup-models.md +51 -0
- package/.cursor/commands/tm/show-task.md +82 -0
- package/.cursor/commands/tm/smart-workflow.md +55 -0
- package/.cursor/commands/tm/sync-readme.md +117 -0
- package/.cursor/commands/tm/tm-main.md +146 -0
- package/.cursor/commands/tm/to-cancelled.md +55 -0
- package/.cursor/commands/tm/to-deferred.md +47 -0
- package/.cursor/commands/tm/to-done.md +44 -0
- package/.cursor/commands/tm/to-in-progress.md +36 -0
- package/.cursor/commands/tm/to-pending.md +32 -0
- package/.cursor/commands/tm/to-review.md +40 -0
- package/.cursor/commands/tm/update-single-task.md +119 -0
- package/.cursor/commands/tm/update-task.md +72 -0
- package/.cursor/commands/tm/update-tasks-from-id.md +108 -0
- package/.cursor/commands/tm/validate-dependencies.md +71 -0
- package/.cursor/commands/tm/view-models.md +51 -0
- package/.cursor/mcp.json +20 -0
- package/.cursor/rules/cursor_rules.mdc +53 -0
- package/.cursor/rules/self_improve.mdc +72 -0
- package/.cursor/rules/taskmaster/dev_workflow.mdc +424 -0
- package/.cursor/rules/taskmaster/taskmaster.mdc +573 -0
- package/.env.example +12 -0
- package/.gemini/commands/tm/add-dependency.toml +58 -0
- package/.gemini/commands/tm/add-subtask.toml +79 -0
- package/.gemini/commands/tm/add-task.toml +81 -0
- package/.gemini/commands/tm/analyze-complexity.toml +124 -0
- package/.gemini/commands/tm/analyze-project.toml +100 -0
- package/.gemini/commands/tm/auto-implement-tasks.toml +100 -0
- package/.gemini/commands/tm/command-pipeline.toml +80 -0
- package/.gemini/commands/tm/complexity-report.toml +120 -0
- package/.gemini/commands/tm/convert-task-to-subtask.toml +74 -0
- package/.gemini/commands/tm/expand-all-tasks.toml +54 -0
- package/.gemini/commands/tm/expand-task.toml +52 -0
- package/.gemini/commands/tm/fix-dependencies.toml +84 -0
- package/.gemini/commands/tm/help.toml +101 -0
- package/.gemini/commands/tm/init-project-quick.toml +49 -0
- package/.gemini/commands/tm/init-project.toml +53 -0
- package/.gemini/commands/tm/install-taskmaster.toml +120 -0
- package/.gemini/commands/tm/learn.toml +106 -0
- package/.gemini/commands/tm/list-tasks-by-status.toml +42 -0
- package/.gemini/commands/tm/list-tasks-with-subtasks.toml +32 -0
- package/.gemini/commands/tm/list-tasks.toml +46 -0
- package/.gemini/commands/tm/next-task.toml +69 -0
- package/.gemini/commands/tm/parse-prd-with-research.toml +51 -0
- package/.gemini/commands/tm/parse-prd.toml +52 -0
- package/.gemini/commands/tm/project-status.toml +67 -0
- package/.gemini/commands/tm/quick-install-taskmaster.toml +25 -0
- package/.gemini/commands/tm/remove-all-subtasks.toml +96 -0
- package/.gemini/commands/tm/remove-dependency.toml +65 -0
- package/.gemini/commands/tm/remove-subtask.toml +87 -0
- package/.gemini/commands/tm/remove-subtasks.toml +89 -0
- package/.gemini/commands/tm/remove-task.toml +110 -0
- package/.gemini/commands/tm/setup-models.toml +54 -0
- package/.gemini/commands/tm/show-task.toml +85 -0
- package/.gemini/commands/tm/smart-workflow.toml +58 -0
- package/.gemini/commands/tm/sync-readme.toml +120 -0
- package/.gemini/commands/tm/tm-main.toml +149 -0
- package/.gemini/commands/tm/to-cancelled.toml +58 -0
- package/.gemini/commands/tm/to-deferred.toml +50 -0
- package/.gemini/commands/tm/to-done.toml +47 -0
- package/.gemini/commands/tm/to-in-progress.toml +39 -0
- package/.gemini/commands/tm/to-pending.toml +35 -0
- package/.gemini/commands/tm/to-review.toml +43 -0
- package/.gemini/commands/tm/update-single-task.toml +122 -0
- package/.gemini/commands/tm/update-task.toml +75 -0
- package/.gemini/commands/tm/update-tasks-from-id.toml +111 -0
- package/.gemini/commands/tm/validate-dependencies.toml +74 -0
- package/.gemini/commands/tm/view-models.toml +54 -0
- package/.gemini/settings.json +20 -0
- package/.mcp.json +15 -0
- package/.taskmaster/CLAUDE.md +435 -0
- package/.taskmaster/config.json +44 -0
- package/.taskmaster/docs/prd.txt +584 -0
- package/.taskmaster/state.json +6 -0
- package/.taskmaster/tasks/tasks.json +304 -0
- package/.taskmaster/templates/example_prd.txt +47 -0
- package/.taskmaster/templates/example_prd_rpg.txt +511 -0
- package/CLAUDE.md +4 -138
- package/README.md +551 -0
- package/coverage/clover.xml +134 -22
- package/coverage/coverage-final.json +1 -1
- package/coverage/lcov-report/index.html +21 -21
- package/coverage/lcov-report/index.js.html +854 -29
- package/coverage/lcov.info +246 -39
- package/internal-docs/CLAUDE.md +139 -0
- package/internal-docs/NPM_DEPLOYMENT_GUIDE.md +203 -0
- package/internal-docs/OBSIDIAN_PROJECT_PROMPT.md +302 -0
- package/lib/index.d.ts +88 -0
- package/lib/index.js +275 -0
- package/package.json +11 -3
- /package/{DEPLOYMENT.md → internal-docs/DEPLOYMENT.md} +0 -0
- /package/{TEST_RESULTS.md → internal-docs/TEST_RESULTS.md} +0 -0
- /package/{TEST_SIMULATION.md → internal-docs/TEST_SIMULATION.md} +0 -0
|
@@ -0,0 +1,511 @@
|
|
|
1
|
+
<rpg-method>
|
|
2
|
+
# Repository Planning Graph (RPG) Method - PRD Template
|
|
3
|
+
|
|
4
|
+
This template teaches you (AI or human) how to create structured, dependency-aware PRDs using the RPG methodology from Microsoft Research. The key insight: separate WHAT (functional) from HOW (structural), then connect them with explicit dependencies.
|
|
5
|
+
|
|
6
|
+
## Core Principles
|
|
7
|
+
|
|
8
|
+
1. **Dual-Semantics**: Think functional (capabilities) AND structural (code organization) separately, then map them
|
|
9
|
+
2. **Explicit Dependencies**: Never assume - always state what depends on what
|
|
10
|
+
3. **Topological Order**: Build foundation first, then layers on top
|
|
11
|
+
4. **Progressive Refinement**: Start broad, refine iteratively
|
|
12
|
+
|
|
13
|
+
## How to Use This Template
|
|
14
|
+
|
|
15
|
+
- Follow the instructions in each `<instruction>` block
|
|
16
|
+
- Look at `<example>` blocks to see good vs bad patterns
|
|
17
|
+
- Fill in the content sections with your project details
|
|
18
|
+
- The AI reading this will learn the RPG method by following along
|
|
19
|
+
- Task Master will parse the resulting PRD into dependency-aware tasks
|
|
20
|
+
|
|
21
|
+
## Recommended Tools for Creating PRDs
|
|
22
|
+
|
|
23
|
+
When using this template to **create** a PRD (not parse it), use **code-context-aware AI assistants** for best results:
|
|
24
|
+
|
|
25
|
+
**Why?** The AI needs to understand your existing codebase to make good architectural decisions about modules, dependencies, and integration points.
|
|
26
|
+
|
|
27
|
+
**Recommended tools:**
|
|
28
|
+
- **Claude Code** (claude-code CLI) - Best for structured reasoning and large contexts
|
|
29
|
+
- **Cursor/Windsurf** - IDE integration with full codebase context
|
|
30
|
+
- **Gemini CLI** (gemini-cli) - Massive context window for large codebases
|
|
31
|
+
- **Codex/Grok CLI** - Strong code generation with context awareness
|
|
32
|
+
|
|
33
|
+
**Note:** Once your PRD is created, `task-master parse-prd` works with any configured AI model - it just needs to read the PRD text itself, not your codebase.
|
|
34
|
+
</rpg-method>
|
|
35
|
+
|
|
36
|
+
---
|
|
37
|
+
|
|
38
|
+
<overview>
|
|
39
|
+
<instruction>
|
|
40
|
+
Start with the problem, not the solution. Be specific about:
|
|
41
|
+
- What pain point exists?
|
|
42
|
+
- Who experiences it?
|
|
43
|
+
- Why existing solutions don't work?
|
|
44
|
+
- What success looks like (measurable outcomes)?
|
|
45
|
+
|
|
46
|
+
Keep this section focused - don't jump into implementation details yet.
|
|
47
|
+
</instruction>
|
|
48
|
+
|
|
49
|
+
## Problem Statement
|
|
50
|
+
[Describe the core problem. Be concrete about user pain points.]
|
|
51
|
+
|
|
52
|
+
## Target Users
|
|
53
|
+
[Define personas, their workflows, and what they're trying to achieve.]
|
|
54
|
+
|
|
55
|
+
## Success Metrics
|
|
56
|
+
[Quantifiable outcomes. Examples: "80% task completion via autopilot", "< 5% manual intervention rate"]
|
|
57
|
+
|
|
58
|
+
</overview>
|
|
59
|
+
|
|
60
|
+
---
|
|
61
|
+
|
|
62
|
+
<functional-decomposition>
|
|
63
|
+
<instruction>
|
|
64
|
+
Now think about CAPABILITIES (what the system DOES), not code structure yet.
|
|
65
|
+
|
|
66
|
+
Step 1: Identify high-level capability domains
|
|
67
|
+
- Think: "What major things does this system do?"
|
|
68
|
+
- Examples: Data Management, Core Processing, Presentation Layer
|
|
69
|
+
|
|
70
|
+
Step 2: For each capability, enumerate specific features
|
|
71
|
+
- Use explore-exploit strategy:
|
|
72
|
+
* Exploit: What features are REQUIRED for core value?
|
|
73
|
+
* Explore: What features make this domain COMPLETE?
|
|
74
|
+
|
|
75
|
+
Step 3: For each feature, define:
|
|
76
|
+
- Description: What it does in one sentence
|
|
77
|
+
- Inputs: What data/context it needs
|
|
78
|
+
- Outputs: What it produces/returns
|
|
79
|
+
- Behavior: Key logic or transformations
|
|
80
|
+
|
|
81
|
+
<example type="good">
|
|
82
|
+
Capability: Data Validation
|
|
83
|
+
Feature: Schema validation
|
|
84
|
+
- Description: Validate JSON payloads against defined schemas
|
|
85
|
+
- Inputs: JSON object, schema definition
|
|
86
|
+
- Outputs: Validation result (pass/fail) + error details
|
|
87
|
+
- Behavior: Iterate fields, check types, enforce constraints
|
|
88
|
+
|
|
89
|
+
Feature: Business rule validation
|
|
90
|
+
- Description: Apply domain-specific validation rules
|
|
91
|
+
- Inputs: Validated data object, rule set
|
|
92
|
+
- Outputs: Boolean + list of violated rules
|
|
93
|
+
- Behavior: Execute rules sequentially, short-circuit on failure
|
|
94
|
+
</example>
|
|
95
|
+
|
|
96
|
+
<example type="bad">
|
|
97
|
+
Capability: validation.js
|
|
98
|
+
(Problem: This is a FILE, not a CAPABILITY. Mixing structure into functional thinking.)
|
|
99
|
+
|
|
100
|
+
Capability: Validation
|
|
101
|
+
Feature: Make sure data is good
|
|
102
|
+
(Problem: Too vague. No inputs/outputs. Not actionable.)
|
|
103
|
+
</example>
|
|
104
|
+
</instruction>
|
|
105
|
+
|
|
106
|
+
## Capability Tree
|
|
107
|
+
|
|
108
|
+
### Capability: [Name]
|
|
109
|
+
[Brief description of what this capability domain covers]
|
|
110
|
+
|
|
111
|
+
#### Feature: [Name]
|
|
112
|
+
- **Description**: [One sentence]
|
|
113
|
+
- **Inputs**: [What it needs]
|
|
114
|
+
- **Outputs**: [What it produces]
|
|
115
|
+
- **Behavior**: [Key logic]
|
|
116
|
+
|
|
117
|
+
#### Feature: [Name]
|
|
118
|
+
- **Description**:
|
|
119
|
+
- **Inputs**:
|
|
120
|
+
- **Outputs**:
|
|
121
|
+
- **Behavior**:
|
|
122
|
+
|
|
123
|
+
### Capability: [Name]
|
|
124
|
+
...
|
|
125
|
+
|
|
126
|
+
</functional-decomposition>
|
|
127
|
+
|
|
128
|
+
---
|
|
129
|
+
|
|
130
|
+
<structural-decomposition>
|
|
131
|
+
<instruction>
|
|
132
|
+
NOW think about code organization. Map capabilities to actual file/folder structure.
|
|
133
|
+
|
|
134
|
+
Rules:
|
|
135
|
+
1. Each capability maps to a module (folder or file)
|
|
136
|
+
2. Features within a capability map to functions/classes
|
|
137
|
+
3. Use clear module boundaries - each module has ONE responsibility
|
|
138
|
+
4. Define what each module exports (public interface)
|
|
139
|
+
|
|
140
|
+
The goal: Create a clear mapping between "what it does" (functional) and "where it lives" (structural).
|
|
141
|
+
|
|
142
|
+
<example type="good">
|
|
143
|
+
Capability: Data Validation
|
|
144
|
+
→ Maps to: src/validation/
|
|
145
|
+
├── schema-validator.js (Schema validation feature)
|
|
146
|
+
├── rule-validator.js (Business rule validation feature)
|
|
147
|
+
└── index.js (Public exports)
|
|
148
|
+
|
|
149
|
+
Exports:
|
|
150
|
+
- validateSchema(data, schema)
|
|
151
|
+
- validateRules(data, rules)
|
|
152
|
+
</example>
|
|
153
|
+
|
|
154
|
+
<example type="bad">
|
|
155
|
+
Capability: Data Validation
|
|
156
|
+
→ Maps to: src/utils.js
|
|
157
|
+
(Problem: "utils" is not a clear module boundary. Where do I find validation logic?)
|
|
158
|
+
|
|
159
|
+
Capability: Data Validation
|
|
160
|
+
→ Maps to: src/validation/everything.js
|
|
161
|
+
(Problem: One giant file. Features should map to separate files for maintainability.)
|
|
162
|
+
</example>
|
|
163
|
+
</instruction>
|
|
164
|
+
|
|
165
|
+
## Repository Structure
|
|
166
|
+
|
|
167
|
+
```
|
|
168
|
+
project-root/
|
|
169
|
+
├── src/
|
|
170
|
+
│ ├── [module-name]/ # Maps to: [Capability Name]
|
|
171
|
+
│ │ ├── [file].js # Maps to: [Feature Name]
|
|
172
|
+
│ │ └── index.js # Public exports
|
|
173
|
+
│ └── [module-name]/
|
|
174
|
+
├── tests/
|
|
175
|
+
└── docs/
|
|
176
|
+
```
|
|
177
|
+
|
|
178
|
+
## Module Definitions
|
|
179
|
+
|
|
180
|
+
### Module: [Name]
|
|
181
|
+
- **Maps to capability**: [Capability from functional decomposition]
|
|
182
|
+
- **Responsibility**: [Single clear purpose]
|
|
183
|
+
- **File structure**:
|
|
184
|
+
```
|
|
185
|
+
module-name/
|
|
186
|
+
├── feature1.js
|
|
187
|
+
├── feature2.js
|
|
188
|
+
└── index.js
|
|
189
|
+
```
|
|
190
|
+
- **Exports**:
|
|
191
|
+
- `functionName()` - [what it does]
|
|
192
|
+
- `ClassName` - [what it does]
|
|
193
|
+
|
|
194
|
+
</structural-decomposition>
|
|
195
|
+
|
|
196
|
+
---
|
|
197
|
+
|
|
198
|
+
<dependency-graph>
|
|
199
|
+
<instruction>
|
|
200
|
+
This is THE CRITICAL SECTION for Task Master parsing.
|
|
201
|
+
|
|
202
|
+
Define explicit dependencies between modules. This creates the topological order for task execution.
|
|
203
|
+
|
|
204
|
+
Rules:
|
|
205
|
+
1. List modules in dependency order (foundation first)
|
|
206
|
+
2. For each module, state what it depends on
|
|
207
|
+
3. Foundation modules should have NO dependencies
|
|
208
|
+
4. Every non-foundation module should depend on at least one other module
|
|
209
|
+
5. Think: "What must EXIST before I can build this module?"
|
|
210
|
+
|
|
211
|
+
<example type="good">
|
|
212
|
+
Foundation Layer (no dependencies):
|
|
213
|
+
- error-handling: No dependencies
|
|
214
|
+
- config-manager: No dependencies
|
|
215
|
+
- base-types: No dependencies
|
|
216
|
+
|
|
217
|
+
Data Layer:
|
|
218
|
+
- schema-validator: Depends on [base-types, error-handling]
|
|
219
|
+
- data-ingestion: Depends on [schema-validator, config-manager]
|
|
220
|
+
|
|
221
|
+
Core Layer:
|
|
222
|
+
- algorithm-engine: Depends on [base-types, error-handling]
|
|
223
|
+
- pipeline-orchestrator: Depends on [algorithm-engine, data-ingestion]
|
|
224
|
+
</example>
|
|
225
|
+
|
|
226
|
+
<example type="bad">
|
|
227
|
+
- validation: Depends on API
|
|
228
|
+
- API: Depends on validation
|
|
229
|
+
(Problem: Circular dependency. This will cause build/runtime issues.)
|
|
230
|
+
|
|
231
|
+
- user-auth: Depends on everything
|
|
232
|
+
(Problem: Too many dependencies. Should be more focused.)
|
|
233
|
+
</example>
|
|
234
|
+
</instruction>
|
|
235
|
+
|
|
236
|
+
## Dependency Chain
|
|
237
|
+
|
|
238
|
+
### Foundation Layer (Phase 0)
|
|
239
|
+
No dependencies - these are built first.
|
|
240
|
+
|
|
241
|
+
- **[Module Name]**: [What it provides]
|
|
242
|
+
- **[Module Name]**: [What it provides]
|
|
243
|
+
|
|
244
|
+
### [Layer Name] (Phase 1)
|
|
245
|
+
- **[Module Name]**: Depends on [[module-from-phase-0], [module-from-phase-0]]
|
|
246
|
+
- **[Module Name]**: Depends on [[module-from-phase-0]]
|
|
247
|
+
|
|
248
|
+
### [Layer Name] (Phase 2)
|
|
249
|
+
- **[Module Name]**: Depends on [[module-from-phase-1], [module-from-foundation]]
|
|
250
|
+
|
|
251
|
+
[Continue building up layers...]
|
|
252
|
+
|
|
253
|
+
</dependency-graph>
|
|
254
|
+
|
|
255
|
+
---
|
|
256
|
+
|
|
257
|
+
<implementation-roadmap>
|
|
258
|
+
<instruction>
|
|
259
|
+
Turn the dependency graph into concrete development phases.
|
|
260
|
+
|
|
261
|
+
Each phase should:
|
|
262
|
+
1. Have clear entry criteria (what must exist before starting)
|
|
263
|
+
2. Contain tasks that can be parallelized (no inter-dependencies within phase)
|
|
264
|
+
3. Have clear exit criteria (how do we know phase is complete?)
|
|
265
|
+
4. Build toward something USABLE (not just infrastructure)
|
|
266
|
+
|
|
267
|
+
Phase ordering follows topological sort of dependency graph.
|
|
268
|
+
|
|
269
|
+
<example type="good">
|
|
270
|
+
Phase 0: Foundation
|
|
271
|
+
Entry: Clean repository
|
|
272
|
+
Tasks:
|
|
273
|
+
- Implement error handling utilities
|
|
274
|
+
- Create base type definitions
|
|
275
|
+
- Setup configuration system
|
|
276
|
+
Exit: Other modules can import foundation without errors
|
|
277
|
+
|
|
278
|
+
Phase 1: Data Layer
|
|
279
|
+
Entry: Phase 0 complete
|
|
280
|
+
Tasks:
|
|
281
|
+
- Implement schema validator (uses: base types, error handling)
|
|
282
|
+
- Build data ingestion pipeline (uses: validator, config)
|
|
283
|
+
Exit: End-to-end data flow from input to validated output
|
|
284
|
+
</example>
|
|
285
|
+
|
|
286
|
+
<example type="bad">
|
|
287
|
+
Phase 1: Build Everything
|
|
288
|
+
Tasks:
|
|
289
|
+
- API
|
|
290
|
+
- Database
|
|
291
|
+
- UI
|
|
292
|
+
- Tests
|
|
293
|
+
(Problem: No clear focus. Too broad. Dependencies not considered.)
|
|
294
|
+
</example>
|
|
295
|
+
</instruction>
|
|
296
|
+
|
|
297
|
+
## Development Phases
|
|
298
|
+
|
|
299
|
+
### Phase 0: [Foundation Name]
|
|
300
|
+
**Goal**: [What foundational capability this establishes]
|
|
301
|
+
|
|
302
|
+
**Entry Criteria**: [What must be true before starting]
|
|
303
|
+
|
|
304
|
+
**Tasks**:
|
|
305
|
+
- [ ] [Task name] (depends on: [none or list])
|
|
306
|
+
- Acceptance criteria: [How we know it's done]
|
|
307
|
+
- Test strategy: [What tests prove it works]
|
|
308
|
+
|
|
309
|
+
- [ ] [Task name] (depends on: [none or list])
|
|
310
|
+
|
|
311
|
+
**Exit Criteria**: [Observable outcome that proves phase complete]
|
|
312
|
+
|
|
313
|
+
**Delivers**: [What can users/developers do after this phase?]
|
|
314
|
+
|
|
315
|
+
---
|
|
316
|
+
|
|
317
|
+
### Phase 1: [Layer Name]
|
|
318
|
+
**Goal**:
|
|
319
|
+
|
|
320
|
+
**Entry Criteria**: Phase 0 complete
|
|
321
|
+
|
|
322
|
+
**Tasks**:
|
|
323
|
+
- [ ] [Task name] (depends on: [[tasks-from-phase-0]])
|
|
324
|
+
- [ ] [Task name] (depends on: [[tasks-from-phase-0]])
|
|
325
|
+
|
|
326
|
+
**Exit Criteria**:
|
|
327
|
+
|
|
328
|
+
**Delivers**:
|
|
329
|
+
|
|
330
|
+
---
|
|
331
|
+
|
|
332
|
+
[Continue with more phases...]
|
|
333
|
+
|
|
334
|
+
</implementation-roadmap>
|
|
335
|
+
|
|
336
|
+
---
|
|
337
|
+
|
|
338
|
+
<test-strategy>
|
|
339
|
+
<instruction>
|
|
340
|
+
Define how testing will be integrated throughout development (TDD approach).
|
|
341
|
+
|
|
342
|
+
Specify:
|
|
343
|
+
1. Test pyramid ratios (unit vs integration vs e2e)
|
|
344
|
+
2. Coverage requirements
|
|
345
|
+
3. Critical test scenarios
|
|
346
|
+
4. Test generation guidelines for Surgical Test Generator
|
|
347
|
+
|
|
348
|
+
This section guides the AI when generating tests during the RED phase of TDD.
|
|
349
|
+
|
|
350
|
+
<example type="good">
|
|
351
|
+
Critical Test Scenarios for Data Validation module:
|
|
352
|
+
- Happy path: Valid data passes all checks
|
|
353
|
+
- Edge cases: Empty strings, null values, boundary numbers
|
|
354
|
+
- Error cases: Invalid types, missing required fields
|
|
355
|
+
- Integration: Validator works with ingestion pipeline
|
|
356
|
+
</example>
|
|
357
|
+
</instruction>
|
|
358
|
+
|
|
359
|
+
## Test Pyramid
|
|
360
|
+
|
|
361
|
+
```
|
|
362
|
+
/\
|
|
363
|
+
/E2E\ ← [X]% (End-to-end, slow, comprehensive)
|
|
364
|
+
/------\
|
|
365
|
+
/Integration\ ← [Y]% (Module interactions)
|
|
366
|
+
/------------\
|
|
367
|
+
/ Unit Tests \ ← [Z]% (Fast, isolated, deterministic)
|
|
368
|
+
/----------------\
|
|
369
|
+
```
|
|
370
|
+
|
|
371
|
+
## Coverage Requirements
|
|
372
|
+
- Line coverage: [X]% minimum
|
|
373
|
+
- Branch coverage: [X]% minimum
|
|
374
|
+
- Function coverage: [X]% minimum
|
|
375
|
+
- Statement coverage: [X]% minimum
|
|
376
|
+
|
|
377
|
+
## Critical Test Scenarios
|
|
378
|
+
|
|
379
|
+
### [Module/Feature Name]
|
|
380
|
+
**Happy path**:
|
|
381
|
+
- [Scenario description]
|
|
382
|
+
- Expected: [What should happen]
|
|
383
|
+
|
|
384
|
+
**Edge cases**:
|
|
385
|
+
- [Scenario description]
|
|
386
|
+
- Expected: [What should happen]
|
|
387
|
+
|
|
388
|
+
**Error cases**:
|
|
389
|
+
- [Scenario description]
|
|
390
|
+
- Expected: [How system handles failure]
|
|
391
|
+
|
|
392
|
+
**Integration points**:
|
|
393
|
+
- [What interactions to test]
|
|
394
|
+
- Expected: [End-to-end behavior]
|
|
395
|
+
|
|
396
|
+
## Test Generation Guidelines
|
|
397
|
+
[Specific instructions for Surgical Test Generator about what to focus on, what patterns to follow, project-specific test conventions]
|
|
398
|
+
|
|
399
|
+
</test-strategy>
|
|
400
|
+
|
|
401
|
+
---
|
|
402
|
+
|
|
403
|
+
<architecture>
|
|
404
|
+
<instruction>
|
|
405
|
+
Describe technical architecture, data models, and key design decisions.
|
|
406
|
+
|
|
407
|
+
Keep this section AFTER functional/structural decomposition - implementation details come after understanding structure.
|
|
408
|
+
</instruction>
|
|
409
|
+
|
|
410
|
+
## System Components
|
|
411
|
+
[Major architectural pieces and their responsibilities]
|
|
412
|
+
|
|
413
|
+
## Data Models
|
|
414
|
+
[Core data structures, schemas, database design]
|
|
415
|
+
|
|
416
|
+
## Technology Stack
|
|
417
|
+
[Languages, frameworks, key libraries]
|
|
418
|
+
|
|
419
|
+
**Decision: [Technology/Pattern]**
|
|
420
|
+
- **Rationale**: [Why chosen]
|
|
421
|
+
- **Trade-offs**: [What we're giving up]
|
|
422
|
+
- **Alternatives considered**: [What else we looked at]
|
|
423
|
+
|
|
424
|
+
</architecture>
|
|
425
|
+
|
|
426
|
+
---
|
|
427
|
+
|
|
428
|
+
<risks>
|
|
429
|
+
<instruction>
|
|
430
|
+
Identify risks that could derail development and how to mitigate them.
|
|
431
|
+
|
|
432
|
+
Categories:
|
|
433
|
+
- Technical risks (complexity, unknowns)
|
|
434
|
+
- Dependency risks (blocking issues)
|
|
435
|
+
- Scope risks (creep, underestimation)
|
|
436
|
+
</instruction>
|
|
437
|
+
|
|
438
|
+
## Technical Risks
|
|
439
|
+
**Risk**: [Description]
|
|
440
|
+
- **Impact**: [High/Medium/Low - effect on project]
|
|
441
|
+
- **Likelihood**: [High/Medium/Low]
|
|
442
|
+
- **Mitigation**: [How to address]
|
|
443
|
+
- **Fallback**: [Plan B if mitigation fails]
|
|
444
|
+
|
|
445
|
+
## Dependency Risks
|
|
446
|
+
[External dependencies, blocking issues]
|
|
447
|
+
|
|
448
|
+
## Scope Risks
|
|
449
|
+
[Scope creep, underestimation, unclear requirements]
|
|
450
|
+
|
|
451
|
+
</risks>
|
|
452
|
+
|
|
453
|
+
---
|
|
454
|
+
|
|
455
|
+
<appendix>
|
|
456
|
+
## References
|
|
457
|
+
[Papers, documentation, similar systems]
|
|
458
|
+
|
|
459
|
+
## Glossary
|
|
460
|
+
[Domain-specific terms]
|
|
461
|
+
|
|
462
|
+
## Open Questions
|
|
463
|
+
[Things to resolve during development]
|
|
464
|
+
</appendix>
|
|
465
|
+
|
|
466
|
+
---
|
|
467
|
+
|
|
468
|
+
<task-master-integration>
|
|
469
|
+
# How Task Master Uses This PRD
|
|
470
|
+
|
|
471
|
+
When you run `task-master parse-prd <file>.txt`, the parser:
|
|
472
|
+
|
|
473
|
+
1. **Extracts capabilities** → Main tasks
|
|
474
|
+
- Each `### Capability:` becomes a top-level task
|
|
475
|
+
|
|
476
|
+
2. **Extracts features** → Subtasks
|
|
477
|
+
- Each `#### Feature:` becomes a subtask under its capability
|
|
478
|
+
|
|
479
|
+
3. **Parses dependencies** → Task dependencies
|
|
480
|
+
- `Depends on: [X, Y]` sets task.dependencies = ["X", "Y"]
|
|
481
|
+
|
|
482
|
+
4. **Orders by phases** → Task priorities
|
|
483
|
+
- Phase 0 tasks = highest priority
|
|
484
|
+
- Phase N tasks = lower priority, properly sequenced
|
|
485
|
+
|
|
486
|
+
5. **Uses test strategy** → Test generation context
|
|
487
|
+
- Feeds test scenarios to Surgical Test Generator during implementation
|
|
488
|
+
|
|
489
|
+
**Result**: A dependency-aware task graph that can be executed in topological order.
|
|
490
|
+
|
|
491
|
+
## Why RPG Structure Matters
|
|
492
|
+
|
|
493
|
+
Traditional flat PRDs lead to:
|
|
494
|
+
- ❌ Unclear task dependencies
|
|
495
|
+
- ❌ Arbitrary task ordering
|
|
496
|
+
- ❌ Circular dependencies discovered late
|
|
497
|
+
- ❌ Poorly scoped tasks
|
|
498
|
+
|
|
499
|
+
RPG-structured PRDs provide:
|
|
500
|
+
- ✅ Explicit dependency chains
|
|
501
|
+
- ✅ Topological execution order
|
|
502
|
+
- ✅ Clear module boundaries
|
|
503
|
+
- ✅ Validated task graph before implementation
|
|
504
|
+
|
|
505
|
+
## Tips for Best Results
|
|
506
|
+
|
|
507
|
+
1. **Spend time on dependency graph** - This is the most valuable section for Task Master
|
|
508
|
+
2. **Keep features atomic** - Each feature should be independently testable
|
|
509
|
+
3. **Progressive refinement** - Start broad, use `task-master expand` to break down complex tasks
|
|
510
|
+
4. **Use research mode** - `task-master parse-prd --research` leverages AI for better task generation
|
|
511
|
+
</task-master-integration>
|
package/CLAUDE.md
CHANGED
|
@@ -1,139 +1,5 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Claude Code Instructions
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
This is a TypeScript utility library (`jell-utils`) containing utility functions primarily focused on:
|
|
8
|
-
- Korean text processing and detection
|
|
9
|
-
- Date/time manipulation and formatting
|
|
10
|
-
- String transformations (camelCase, snake_case, title case)
|
|
11
|
-
- HTML/text parsing and cleaning
|
|
12
|
-
- Array comparison utilities
|
|
13
|
-
- iOS device detection
|
|
14
|
-
|
|
15
|
-
The library is designed for both browser and Node.js environments, with compiled output in CommonJS format.
|
|
16
|
-
|
|
17
|
-
## Development Commands
|
|
18
|
-
|
|
19
|
-
### Build & Compilation
|
|
20
|
-
```bash
|
|
21
|
-
# Build TypeScript to JavaScript (outputs to lib/ directory)
|
|
22
|
-
yarn build
|
|
23
|
-
# or
|
|
24
|
-
npm run build
|
|
25
|
-
```
|
|
26
|
-
|
|
27
|
-
### Testing
|
|
28
|
-
```bash
|
|
29
|
-
# Run all tests using Jest
|
|
30
|
-
yarn test
|
|
31
|
-
# or
|
|
32
|
-
npm test
|
|
33
|
-
|
|
34
|
-
# Test files are in __tests__/ directory
|
|
35
|
-
# Tests are written for TypeScript but run against compiled JS in lib/
|
|
36
|
-
```
|
|
37
|
-
|
|
38
|
-
### Code Quality
|
|
39
|
-
```bash
|
|
40
|
-
# Lint TypeScript files
|
|
41
|
-
yarn lint
|
|
42
|
-
# or
|
|
43
|
-
npm run lint
|
|
44
|
-
|
|
45
|
-
# Auto-fix linting issues
|
|
46
|
-
yarn lint:fix
|
|
47
|
-
# or
|
|
48
|
-
npm run lint:fix
|
|
49
|
-
|
|
50
|
-
# Format code with Prettier
|
|
51
|
-
yarn format
|
|
52
|
-
# or
|
|
53
|
-
npm run format
|
|
54
|
-
```
|
|
55
|
-
|
|
56
|
-
### Publishing Workflow
|
|
57
|
-
```bash
|
|
58
|
-
# Pre-publish checks (runs test, lint, and lint:fix)
|
|
59
|
-
yarn prepublishOnly
|
|
60
|
-
|
|
61
|
-
# Version management (includes linting and formatting)
|
|
62
|
-
yarn preversion # lint check
|
|
63
|
-
yarn version # format and git add
|
|
64
|
-
yarn postversion # git push with tags
|
|
65
|
-
```
|
|
66
|
-
|
|
67
|
-
## Architecture & Structure
|
|
68
|
-
|
|
69
|
-
### Core Module Structure
|
|
70
|
-
- **Source**: `src/index.ts` - Single file containing all utility functions as a default export object
|
|
71
|
-
- **Compiled Output**: `lib/index.js` + `lib/index.d.ts` - ES5 CommonJS with TypeScript declarations
|
|
72
|
-
- **Tests**: `__tests__/korean.test.ts` - Jest tests importing from compiled lib directory
|
|
73
|
-
|
|
74
|
-
### Key Design Patterns
|
|
75
|
-
- **Single Object Export**: All utilities are methods on a single `util` object
|
|
76
|
-
- **Pure Functions**: All utility functions are stateless and side-effect free (except `clearTag` which uses DOM)
|
|
77
|
-
- **Defensive Programming**: Functions include type checking and fallback values
|
|
78
|
-
- **Browser Compatibility**: Uses DOM APIs for `clearTag` and `navigator` for `isiOS`
|
|
79
|
-
|
|
80
|
-
### Function Categories
|
|
81
|
-
|
|
82
|
-
1. **Korean Text Processing**:
|
|
83
|
-
- `isKorean()` - Detects Korean characters using Unicode ranges
|
|
84
|
-
|
|
85
|
-
2. **Date/Time Utilities**:
|
|
86
|
-
- `getNowDate()` - Current datetime in local timezone
|
|
87
|
-
- `getKoreanDate()` - Korean date format ("월일" format)
|
|
88
|
-
- `formatDate()` - yyyy-mm-dd formatting
|
|
89
|
-
- `calDDay()` - D-day calculator
|
|
90
|
-
- `parseTime()` - Parse time strings to milliseconds
|
|
91
|
-
|
|
92
|
-
3. **String Transformations**:
|
|
93
|
-
- `toCamelCase()` - Convert to camelCase
|
|
94
|
-
- `toSnakeCase()` - Convert to snake_case
|
|
95
|
-
- `toTitleCase()` - Convert to Title Case with space handling
|
|
96
|
-
- `replaceBetween()` - Replace substring at specific indices
|
|
97
|
-
|
|
98
|
-
4. **HTML/Text Processing**:
|
|
99
|
-
- `parseTag()` - Decode HTML entities (< to <)
|
|
100
|
-
- `toText()` - Convert <br> tags to newlines
|
|
101
|
-
- `toHtml()` - Convert newlines to <br> tags
|
|
102
|
-
- `clearTag()` - Remove HTML tags (browser only)
|
|
103
|
-
|
|
104
|
-
5. **Data Utilities**:
|
|
105
|
-
- `clone()` - Shallow object cloning
|
|
106
|
-
- `equalArrays()` - Array comparison
|
|
107
|
-
- `parseNumber()` - Safe number parsing with defaults
|
|
108
|
-
|
|
109
|
-
6. **Browser Detection**:
|
|
110
|
-
- `isiOS()` - Detect iOS devices via user agent
|
|
111
|
-
|
|
112
|
-
## Development Notes
|
|
113
|
-
|
|
114
|
-
### Build Process
|
|
115
|
-
- TypeScript compiles to ES5 for broad compatibility
|
|
116
|
-
- Outputs both JavaScript and TypeScript declaration files
|
|
117
|
-
- Uses strict TypeScript configuration with proper module resolution
|
|
118
|
-
|
|
119
|
-
### Testing Strategy
|
|
120
|
-
- Tests run against compiled JavaScript in `lib/` directory, not source TypeScript
|
|
121
|
-
- Jest configuration supports both .ts and .js files
|
|
122
|
-
- Tests focus on core functionality rather than edge cases
|
|
123
|
-
|
|
124
|
-
### Type Safety Considerations
|
|
125
|
-
- Uses `Record<string, unknown>` for generic object types
|
|
126
|
-
- TODO comment indicates need to improve object typing
|
|
127
|
-
- Functions include runtime type checking for safety
|
|
128
|
-
|
|
129
|
-
### Browser Dependencies
|
|
130
|
-
- `clearTag()` function requires DOM environment (uses `document.createElement`)
|
|
131
|
-
- `isiOS()` function requires browser environment (uses `navigator.userAgent`)
|
|
132
|
-
- Other functions are environment-agnostic
|
|
133
|
-
|
|
134
|
-
When adding new utilities:
|
|
135
|
-
1. Add to the main util object in `src/index.ts`
|
|
136
|
-
2. Follow existing patterns for type safety and error handling
|
|
137
|
-
3. Add comprehensive JSDoc documentation
|
|
138
|
-
4. Write tests in `__tests__/` directory
|
|
139
|
-
5. Test against compiled output, not source
|
|
3
|
+
## Task Master AI Instructions
|
|
4
|
+
**Import Task Master's development workflow commands and guidelines, treat as if import is in the main CLAUDE.md file.**
|
|
5
|
+
@./.taskmaster/CLAUDE.md
|