dino-spec 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 (92) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +243 -0
  3. package/bin/dino.js +3 -0
  4. package/dist/cli/index.d.ts +3 -0
  5. package/dist/cli/index.d.ts.map +1 -0
  6. package/dist/cli/index.js +114 -0
  7. package/dist/cli/index.js.map +1 -0
  8. package/dist/commands/active.d.ts +5 -0
  9. package/dist/commands/active.d.ts.map +1 -0
  10. package/dist/commands/active.js +85 -0
  11. package/dist/commands/active.js.map +1 -0
  12. package/dist/commands/archive.d.ts +9 -0
  13. package/dist/commands/archive.d.ts.map +1 -0
  14. package/dist/commands/archive.js +77 -0
  15. package/dist/commands/archive.js.map +1 -0
  16. package/dist/commands/init.d.ts +9 -0
  17. package/dist/commands/init.d.ts.map +1 -0
  18. package/dist/commands/init.js +91 -0
  19. package/dist/commands/init.js.map +1 -0
  20. package/dist/commands/list.d.ts +12 -0
  21. package/dist/commands/list.d.ts.map +1 -0
  22. package/dist/commands/list.js +169 -0
  23. package/dist/commands/list.js.map +1 -0
  24. package/dist/commands/skill.d.ts +17 -0
  25. package/dist/commands/skill.d.ts.map +1 -0
  26. package/dist/commands/skill.js +143 -0
  27. package/dist/commands/skill.js.map +1 -0
  28. package/dist/commands/status.d.ts +9 -0
  29. package/dist/commands/status.d.ts.map +1 -0
  30. package/dist/commands/status.js +96 -0
  31. package/dist/commands/status.js.map +1 -0
  32. package/dist/commands/update.d.ts +9 -0
  33. package/dist/commands/update.d.ts.map +1 -0
  34. package/dist/commands/update.js +64 -0
  35. package/dist/commands/update.js.map +1 -0
  36. package/dist/commands/view.d.ts +5 -0
  37. package/dist/commands/view.d.ts.map +1 -0
  38. package/dist/commands/view.js +177 -0
  39. package/dist/commands/view.js.map +1 -0
  40. package/dist/core/config.d.ts +51 -0
  41. package/dist/core/config.d.ts.map +1 -0
  42. package/dist/core/config.js +58 -0
  43. package/dist/core/config.js.map +1 -0
  44. package/dist/core/skills/index.d.ts +7 -0
  45. package/dist/core/skills/index.d.ts.map +1 -0
  46. package/dist/core/skills/index.js +6 -0
  47. package/dist/core/skills/index.js.map +1 -0
  48. package/dist/core/skills/loader.d.ts +34 -0
  49. package/dist/core/skills/loader.d.ts.map +1 -0
  50. package/dist/core/skills/loader.js +110 -0
  51. package/dist/core/skills/loader.js.map +1 -0
  52. package/dist/core/skills/registry.d.ts +31 -0
  53. package/dist/core/skills/registry.d.ts.map +1 -0
  54. package/dist/core/skills/registry.js +150 -0
  55. package/dist/core/skills/registry.js.map +1 -0
  56. package/dist/core/skills/types.d.ts +33 -0
  57. package/dist/core/skills/types.d.ts.map +1 -0
  58. package/dist/core/skills/types.js +5 -0
  59. package/dist/core/skills/types.js.map +1 -0
  60. package/dist/core/templates/dna-template.d.ts +5 -0
  61. package/dist/core/templates/dna-template.d.ts.map +1 -0
  62. package/dist/core/templates/dna-template.js +52 -0
  63. package/dist/core/templates/dna-template.js.map +1 -0
  64. package/dist/core/templates/index.d.ts +8 -0
  65. package/dist/core/templates/index.d.ts.map +1 -0
  66. package/dist/core/templates/index.js +8 -0
  67. package/dist/core/templates/index.js.map +1 -0
  68. package/dist/core/templates/rules-template.d.ts +5 -0
  69. package/dist/core/templates/rules-template.d.ts.map +1 -0
  70. package/dist/core/templates/rules-template.js +71 -0
  71. package/dist/core/templates/rules-template.js.map +1 -0
  72. package/dist/core/templates/skill-template.d.ts +5 -0
  73. package/dist/core/templates/skill-template.d.ts.map +1 -0
  74. package/dist/core/templates/skill-template.js +63 -0
  75. package/dist/core/templates/skill-template.js.map +1 -0
  76. package/dist/core/templates/slash-commands.d.ts +5 -0
  77. package/dist/core/templates/slash-commands.d.ts.map +1 -0
  78. package/dist/core/templates/slash-commands.js +753 -0
  79. package/dist/core/templates/slash-commands.js.map +1 -0
  80. package/dist/index.d.ts +7 -0
  81. package/dist/index.d.ts.map +1 -0
  82. package/dist/index.js +7 -0
  83. package/dist/index.js.map +1 -0
  84. package/dist/utils/ascii-art.d.ts +38 -0
  85. package/dist/utils/ascii-art.d.ts.map +1 -0
  86. package/dist/utils/ascii-art.js +66 -0
  87. package/dist/utils/ascii-art.js.map +1 -0
  88. package/dist/utils/file-system.d.ts +67 -0
  89. package/dist/utils/file-system.d.ts.map +1 -0
  90. package/dist/utils/file-system.js +177 -0
  91. package/dist/utils/file-system.js.map +1 -0
  92. package/package.json +68 -0
@@ -0,0 +1,753 @@
1
+ /**
2
+ * Slash command templates for .claude/commands/dino/
3
+ */
4
+ export function getSlashCommandTemplates() {
5
+ return {
6
+ discover: getDiscoverTemplate(),
7
+ scout: getScoutTemplate(),
8
+ clarify: getClarifyTemplate(),
9
+ nest: getNestTemplate(),
10
+ hatch: getHatchTemplate(),
11
+ hunt: getHuntTemplate(),
12
+ fossil: getFossilTemplate(),
13
+ next: getNextTemplate(),
14
+ dna: getDnaCommandTemplate(),
15
+ skill: getSkillCommandTemplate(),
16
+ };
17
+ }
18
+ function getDiscoverTemplate() {
19
+ return `---
20
+ description: Create a new specification from user intent
21
+ argument-hint: <feature description>
22
+ ---
23
+
24
+ # /dino.discover
25
+
26
+ You are starting a new specification. Your goal is to understand the user's intent and create a clear spec.
27
+
28
+ ## User Input
29
+
30
+ \`\`\`
31
+ $ARGUMENTS
32
+ \`\`\`
33
+
34
+ ## Instructions
35
+
36
+ 1. **Read project context** (if exists):
37
+ - Read \`.dino/dna.md\` for project conventions
38
+ - Understand the tech stack and patterns
39
+
40
+ 2. **Generate spec ID**:
41
+ - Create a short, kebab-case ID (e.g., "add-user-auth", "fix-login-bug")
42
+ - Check \`.dino/specs/\` to avoid duplicates
43
+
44
+ 3. **Create specification**:
45
+ - Create \`.dino/specs/{id}/spec.md\` with this structure:
46
+
47
+ \`\`\`markdown
48
+ # {Title}
49
+
50
+ Created: {date} | Status: draft | Phase: discover
51
+
52
+ ## Goal
53
+
54
+ {1-2 sentences describing the objective}
55
+
56
+ ## Requirements
57
+
58
+ - [ ] REQ-1: {requirement}
59
+ - [ ] REQ-2: {requirement}
60
+
61
+ ## Constraints
62
+
63
+ {limitations, boundaries, non-goals}
64
+
65
+ ## Success Criteria
66
+
67
+ - [ ] {measurable outcome}
68
+
69
+ ## Notes
70
+
71
+ {additional context}
72
+ \`\`\`
73
+
74
+ 4. **Update active spec**:
75
+ - Update \`.dino/active.json\` with the new spec ID and phase
76
+
77
+ 5. **Suggest next step**:
78
+ - If requirements are clear → suggest /dino.scout
79
+ - If ambiguous → suggest /dino.clarify
80
+
81
+ ## Rules
82
+
83
+ - Do NOT create implementation plans yet
84
+ - Do NOT write any code
85
+ - Mark unclear requirements with [NEEDS CLARIFICATION]
86
+ - Maximum 3 [NEEDS CLARIFICATION] markers
87
+ - Keep requirements technology-agnostic when possible
88
+ `;
89
+ }
90
+ function getScoutTemplate() {
91
+ return `---
92
+ description: Research codebase and technical options for the active spec
93
+ argument-hint: [tech stack or focus area]
94
+ ---
95
+
96
+ # /dino.scout
97
+
98
+ You are researching the codebase and technical options for the active specification.
99
+
100
+ ## Optional Focus
101
+
102
+ \`\`\`
103
+ $ARGUMENTS
104
+ \`\`\`
105
+
106
+ ## Instructions
107
+
108
+ 1. **Load context**:
109
+ - Read \`.dino/active.json\` to get active spec
110
+ - Read \`.dino/specs/{id}/spec.md\` for requirements
111
+ - Read \`.dino/dna.md\` for project conventions
112
+
113
+ 2. **Explore codebase**:
114
+ - Find relevant existing code patterns
115
+ - Identify similar implementations
116
+ - Note reusable components or utilities
117
+
118
+ 3. **Research technical options**:
119
+ - If tech stack specified, research best practices
120
+ - Search for up-to-date documentation
121
+ - Identify dependencies needed
122
+
123
+ 4. **Create research document**:
124
+ - Create \`.dino/specs/{id}/research.md\`:
125
+
126
+ \`\`\`markdown
127
+ # Research: {spec title}
128
+
129
+ ## Existing Patterns
130
+
131
+ {relevant code found in codebase}
132
+
133
+ ## Technical Options
134
+
135
+ ### Option 1: {approach}
136
+ - Pros: {benefits}
137
+ - Cons: {drawbacks}
138
+
139
+ ### Option 2: {approach}
140
+ - Pros: {benefits}
141
+ - Cons: {drawbacks}
142
+
143
+ ## Dependencies
144
+
145
+ {new packages or tools needed}
146
+
147
+ ## Unknowns
148
+
149
+ {questions that need clarification}
150
+
151
+ ## Recommendation
152
+
153
+ {preferred approach with reasoning}
154
+ \`\`\`
155
+
156
+ 5. **Update phase**:
157
+ - Update \`.dino/active.json\` phase to "scout"
158
+
159
+ 6. **Suggest next step**:
160
+ - If unknowns exist → suggest /dino.clarify
161
+ - If clear → suggest /dino.nest
162
+
163
+ ## Rules
164
+
165
+ - Do NOT modify any existing code
166
+ - Do NOT create implementation plans yet
167
+ - Be thorough but concise
168
+ - Cite specific file paths when referencing code
169
+ `;
170
+ }
171
+ function getClarifyTemplate() {
172
+ return `---
173
+ description: Resolve ambiguity in the active specification
174
+ ---
175
+
176
+ # /dino.clarify
177
+
178
+ You are resolving ambiguity in the active specification through targeted questions.
179
+
180
+ ## Instructions
181
+
182
+ 1. **Load context**:
183
+ - Read \`.dino/active.json\` to get active spec
184
+ - Read \`.dino/specs/{id}/spec.md\` for requirements
185
+ - Read \`.dino/specs/{id}/research.md\` if exists
186
+
187
+ 2. **Identify ambiguities**:
188
+ - Find [NEEDS CLARIFICATION] markers
189
+ - Look for vague requirements
190
+ - Check for missing edge cases
191
+ - Note unclear success criteria
192
+
193
+ 3. **Ask questions using AskUserQuestion**:
194
+ - Maximum 5 questions per session
195
+ - Each question should have 2-4 options
196
+ - Always include "Other" option
197
+ - Prioritize most impactful questions first
198
+
199
+ 4. **Update specification**:
200
+ - After each answer, update spec.md immediately
201
+ - Remove [NEEDS CLARIFICATION] markers as resolved
202
+ - Add clarified details to appropriate sections
203
+
204
+ 5. **Update phase**:
205
+ - Update \`.dino/active.json\` phase to "clarify"
206
+
207
+ 6. **Suggest next step**:
208
+ - If all ambiguity resolved → suggest /dino.nest
209
+ - If more research needed → suggest /dino.scout
210
+ - If more questions → continue clarifying
211
+
212
+ ## Question Format
213
+
214
+ Use AskUserQuestion tool with this structure:
215
+ - **header**: Short category (e.g., "Auth Method", "Error Handling")
216
+ - **question**: Clear, specific question ending with ?
217
+ - **options**: 2-4 distinct choices with descriptions
218
+ - **multiSelect**: false (unless choices aren't mutually exclusive)
219
+
220
+ ## Rules
221
+
222
+ - Never guess or assume - always ask
223
+ - One question at a time when possible
224
+ - Integrate answers immediately into spec.md
225
+ - Do NOT create implementation plans yet
226
+ `;
227
+ }
228
+ function getNestTemplate() {
229
+ return `---
230
+ description: Create implementation plan for the active spec (requires Plan Mode)
231
+ ---
232
+
233
+ # /dino.nest
234
+
235
+ You are creating the implementation plan for the active specification.
236
+
237
+ **IMPORTANT**: This command requires Plan Mode. Enter Plan Mode before proceeding.
238
+
239
+ ## Instructions
240
+
241
+ 1. **Enter Plan Mode**:
242
+ - Use EnterPlanMode tool
243
+ - This is required before creating the plan
244
+
245
+ 2. **Load context**:
246
+ - Read \`.dino/active.json\` to get active spec
247
+ - Read \`.dino/specs/{id}/spec.md\` for requirements
248
+ - Read \`.dino/specs/{id}/research.md\` for technical context
249
+ - Read \`.dino/dna.md\` for project conventions
250
+
251
+ 3. **Design implementation approach**:
252
+ - Choose architecture based on research
253
+ - Define data models if needed
254
+ - Plan API contracts if applicable
255
+ - Consider testing strategy
256
+
257
+ 4. **Create plan document**:
258
+ - Create \`.dino/specs/{id}/plan.md\`:
259
+
260
+ \`\`\`markdown
261
+ # Implementation Plan: {spec title}
262
+
263
+ ## Summary
264
+
265
+ {1-2 paragraph overview of the approach}
266
+
267
+ ## Technical Decisions
268
+
269
+ - **Architecture**: {chosen approach}
270
+ - **Key Dependencies**: {libraries/tools}
271
+ - **Data Model**: {entities and relationships}
272
+
273
+ ## Implementation Phases
274
+
275
+ ### Phase 1: Foundation
276
+ {setup and infrastructure}
277
+
278
+ ### Phase 2: Core Features
279
+ {main functionality}
280
+
281
+ ### Phase 3: Integration
282
+ {connecting components}
283
+
284
+ ### Phase 4: Polish
285
+ {error handling, edge cases, documentation}
286
+
287
+ ## Testing Strategy
288
+
289
+ {how to verify the implementation}
290
+
291
+ ## Risks and Mitigations
292
+
293
+ {potential issues and how to handle them}
294
+ \`\`\`
295
+
296
+ 5. **Update phase**:
297
+ - Update \`.dino/active.json\` phase to "nest"
298
+
299
+ 6. **Exit Plan Mode**:
300
+ - Use ExitPlanMode when plan is ready for approval
301
+
302
+ 7. **After approval**:
303
+ - Suggest /dino.hatch to break into tasks
304
+
305
+ ## Rules
306
+
307
+ - Must be in Plan Mode for the entire process
308
+ - Do NOT write any code yet
309
+ - Keep plan high-level but actionable
310
+ - Maximum 4 implementation phases
311
+ `;
312
+ }
313
+ function getHatchTemplate() {
314
+ return `---
315
+ description: Break implementation plan into phased tasks
316
+ ---
317
+
318
+ # /dino.hatch
319
+
320
+ You are breaking the implementation plan into actionable, phased tasks.
321
+
322
+ **NOTE**: Requires Plan Mode if creating 5+ tasks.
323
+
324
+ ## Instructions
325
+
326
+ 1. **Check task count**:
327
+ - If plan suggests 5+ tasks → Enter Plan Mode first
328
+ - If fewer tasks → proceed directly
329
+
330
+ 2. **Load context**:
331
+ - Read \`.dino/active.json\` to get active spec
332
+ - Read \`.dino/specs/{id}/plan.md\` for implementation approach
333
+ - Read \`.dino/specs/{id}/spec.md\` for requirements
334
+
335
+ 3. **Break into tasks**:
336
+ - Maximum 8-10 tasks per phase
337
+ - Each task should be independently completable
338
+ - Include file paths in task descriptions
339
+ - Mark parallelizable tasks with [P]
340
+
341
+ 4. **Create tasks document**:
342
+ - Create \`.dino/specs/{id}/tasks.md\`:
343
+
344
+ \`\`\`markdown
345
+ # Tasks: {spec title}
346
+
347
+ ## Phase 1: Foundation
348
+
349
+ - [ ] T001 Create directory structure at src/{path}
350
+ - [ ] T002 [P] Add dependencies to package.json
351
+ - [ ] T003 [P] Create config file at src/config/{name}.ts
352
+
353
+ ## Phase 2: Core Features
354
+
355
+ - [ ] T004 Implement {feature} at src/{path}
356
+ - [ ] T005 [P] Add tests for {feature} at tests/{path}
357
+ - [ ] T006 Implement {feature 2} at src/{path}
358
+
359
+ ## Phase 3: Integration
360
+
361
+ - [ ] T007 Connect {component A} to {component B}
362
+ - [ ] T008 Add error handling
363
+
364
+ ## Phase 4: Polish
365
+
366
+ - [ ] T009 Add documentation
367
+ - [ ] T010 Final testing and cleanup
368
+
369
+ ## Execution Notes
370
+
371
+ - Complete Phase 1 before starting Phase 2
372
+ - [P] tasks within a phase can run in parallel
373
+ - Mark tasks [x] as completed immediately
374
+ \`\`\`
375
+
376
+ 5. **Validate tasks**:
377
+ - Each requirement maps to at least one task
378
+ - No task is too large (should take < 30 min)
379
+ - Dependencies between tasks are clear
380
+
381
+ 6. **Update phase**:
382
+ - Update \`.dino/active.json\` phase to "hatch"
383
+
384
+ 7. **Suggest next step**:
385
+ - Suggest /dino.hunt to start implementation
386
+
387
+ ## Task Format
388
+
389
+ \`\`\`
390
+ - [ ] T{NNN} [P?] Description with file path
391
+ \`\`\`
392
+
393
+ - \`T{NNN}\`: Sequential task ID (T001, T002, etc.)
394
+ - \`[P]\`: Optional - marks parallelizable tasks
395
+ - Description must include target file/directory path
396
+
397
+ ## Rules
398
+
399
+ - Maximum 10 tasks per phase
400
+ - Maximum 4 phases total
401
+ - Each task should be atomic and testable
402
+ - Include "run tests" as explicit tasks
403
+ `;
404
+ }
405
+ function getHuntTemplate() {
406
+ return `---
407
+ description: Implement tasks from the active specification
408
+ ---
409
+
410
+ # /dino.hunt
411
+
412
+ You are implementing tasks from the active specification. This is where code gets written!
413
+
414
+ ## Instructions
415
+
416
+ 1. **Load context**:
417
+ - Read \`.dino/active.json\` to get active spec
418
+ - Read \`.dino/specs/{id}/tasks.md\` for task list
419
+ - Read \`.dino/specs/{id}/plan.md\` for technical decisions
420
+ - Read \`.dino/specs/{id}/spec.md\` for requirements
421
+ - Read \`.dino/dna.md\` for code conventions
422
+
423
+ 2. **Find next task**:
424
+ - Look for first unchecked task: \`- [ ] T{NNN}\`
425
+ - Check phase dependencies (Phase N must complete before N+1)
426
+ - [P] tasks in same phase can run in parallel
427
+
428
+ 3. **Implement the task**:
429
+ - Write code following project conventions
430
+ - Follow the plan's technical decisions
431
+ - Include appropriate error handling
432
+ - Write tests if task specifies
433
+
434
+ 4. **Mark task complete**:
435
+ - Immediately after completing a task
436
+ - Update tasks.md: change \`- [ ]\` to \`- [x]\`
437
+ - Save the file right away
438
+
439
+ 5. **Report progress**:
440
+ - Show which task was completed
441
+ - Show remaining tasks in current phase
442
+ - Calculate overall progress percentage
443
+
444
+ 6. **Continue or complete**:
445
+ - If more tasks → continue with next task
446
+ - If current phase complete → start next phase
447
+ - If all tasks complete → suggest /dino.fossil
448
+
449
+ ## Progress Tracking
450
+
451
+ After each task, report:
452
+ \`\`\`
453
+ ✓ T003 [Completed] Create user model at src/models/user.ts
454
+
455
+ Phase 1: [████████░░] 80% (4/5 tasks)
456
+ Overall: [██████░░░░] 60% (6/10 tasks)
457
+
458
+ Next: T004 Add validation to user model
459
+ \`\`\`
460
+
461
+ ## Rules
462
+
463
+ - Complete tasks in order within each phase
464
+ - [P] tasks can be done in any order within their phase
465
+ - Mark tasks complete IMMEDIATELY after finishing
466
+ - Do not skip tasks
467
+ - Follow code conventions from .dino/dna.md
468
+ - If stuck, explain the blocker and ask for help
469
+ `;
470
+ }
471
+ function getFossilTemplate() {
472
+ return `---
473
+ description: Archive the completed specification
474
+ ---
475
+
476
+ # /dino.fossil
477
+
478
+ You are archiving a completed specification, creating a fossil record for future reference.
479
+
480
+ ## Instructions
481
+
482
+ 1. **Verify completion**:
483
+ - Read \`.dino/specs/{id}/tasks.md\`
484
+ - Check all tasks are marked \`[x]\`
485
+ - If incomplete tasks exist, warn and confirm with user
486
+
487
+ 2. **Create archive entry**:
488
+ - Generate date prefix: YYYY-MM-DD
489
+ - Move \`.dino/specs/{id}/\` to \`.dino/archive/{date}-{id}/\`
490
+
491
+ 3. **Add completion notes**:
492
+ - Create or update \`.dino/archive/{date}-{id}/COMPLETED.md\`:
493
+
494
+ \`\`\`markdown
495
+ # Completed: {spec title}
496
+
497
+ Archived: {date}
498
+ Duration: {time from created to now}
499
+
500
+ ## Summary
501
+
502
+ {brief description of what was accomplished}
503
+
504
+ ## Files Changed
505
+
506
+ {list of key files created/modified}
507
+
508
+ ## Lessons Learned
509
+
510
+ {any insights for future work}
511
+ \`\`\`
512
+
513
+ 4. **Clear active spec**:
514
+ - Update \`.dino/active.json\`:
515
+ - Set id to null
516
+ - Set phase to null
517
+
518
+ 5. **Report completion**:
519
+ - Show the fossil ASCII art
520
+ - Confirm archival location
521
+ - Show summary of completed work
522
+
523
+ 6. **Suggest next step**:
524
+ - Suggest /dino.next for feature recommendations
525
+ - Or mention user can start new spec with /dino.discover
526
+
527
+ ## Rules
528
+
529
+ - Do not archive incomplete specs without user confirmation
530
+ - Preserve all spec files in archive
531
+ - Clear active.json after archiving
532
+ `;
533
+ }
534
+ function getNextTemplate() {
535
+ return `---
536
+ description: Suggest next features or improvements
537
+ ---
538
+
539
+ # /dino.next
540
+
541
+ You are analyzing the project to suggest next steps and potential features.
542
+
543
+ ## Instructions
544
+
545
+ 1. **Analyze project state**:
546
+ - Read \`.dino/dna.md\` for project context
547
+ - List archived specs: \`.dino/archive/\`
548
+ - Check for patterns in completed work
549
+
550
+ 2. **Explore codebase**:
551
+ - Look for TODOs and FIXMEs
552
+ - Find incomplete features
553
+ - Identify technical debt
554
+ - Note missing tests
555
+
556
+ 3. **Generate suggestions**:
557
+ - Create 3-5 actionable suggestions
558
+ - Prioritize by impact and effort
559
+ - Include reasoning for each
560
+
561
+ 4. **Present options using AskUserQuestion**:
562
+ - Let user choose which to pursue
563
+ - Include "Something else" option
564
+
565
+ 5. **After selection**:
566
+ - If user picks a suggestion → run /dino.discover with that intent
567
+ - If "Something else" → ask for their idea
568
+
569
+ ## Suggestion Format
570
+
571
+ Present each suggestion as:
572
+ \`\`\`
573
+ ### {Priority} - {Title}
574
+
575
+ **What**: {brief description}
576
+ **Why**: {benefit or problem it solves}
577
+ **Effort**: {Low/Medium/High estimate}
578
+ \`\`\`
579
+
580
+ ## Rules
581
+
582
+ - Base suggestions on actual code analysis
583
+ - Don't suggest completed features
584
+ - Keep suggestions concrete and actionable
585
+ - This command is optional - user can skip to /dino.discover directly
586
+ `;
587
+ }
588
+ function getDnaCommandTemplate() {
589
+ return `---
590
+ description: Generate project-specific skills based on tech stack analysis
591
+ ---
592
+
593
+ # /dino.dna
594
+
595
+ You are analyzing the project to generate helpful Claude Code skills.
596
+
597
+ ## Instructions
598
+
599
+ 1. **Analyze project**:
600
+ - Read package.json, pyproject.toml, Cargo.toml, etc.
601
+ - Identify programming language(s)
602
+ - Find framework(s) used
603
+ - Detect testing tools
604
+ - Note linters/formatters configured
605
+
606
+ 2. **Suggest skills**:
607
+ - Based on detected tech stack
608
+ - Each skill should automate a common task
609
+ - Present options using AskUserQuestion
610
+
611
+ 3. **Skill categories**:
612
+ - **linter**: Run code quality checks after generation
613
+ - **type-check**: Run type checker (tsc, pyright, mypy)
614
+ - **test-runner**: Run tests after implementation
615
+ - **formatter**: Format code (prettier, black, rustfmt)
616
+ - **build**: Build/compile the project
617
+
618
+ 4. **Generate selected skills**:
619
+ - Create \`.claude/skills/{name}/SKILL.md\` for each
620
+ - Use this format:
621
+
622
+ \`\`\`markdown
623
+ ---
624
+ name: {skill-name}
625
+ description: {what it does}
626
+ ---
627
+
628
+ # {Skill Title}
629
+
630
+ {instructions for when and how to use this skill}
631
+
632
+ ## Triggers
633
+
634
+ - {when this skill should activate}
635
+
636
+ ## Actions
637
+
638
+ - {what the skill does}
639
+ \`\`\`
640
+
641
+ 5. **Preserve user modifications**:
642
+ - Check for existing skills
643
+ - Use DINO:CORE and DINO:USER markers
644
+ - Only update DINO:CORE sections
645
+
646
+ ## Example Skills
647
+
648
+ **linter** (TypeScript project):
649
+ \`\`\`markdown
650
+ ---
651
+ name: linter
652
+ description: Run ESLint after code generation
653
+ ---
654
+
655
+ # Linter
656
+
657
+ Run ESLint to catch errors and enforce code style after generating or modifying code.
658
+
659
+ ## Triggers
660
+
661
+ - After creating new .ts or .tsx files
662
+ - After significant code modifications
663
+
664
+ ## Actions
665
+
666
+ - Run: npx eslint --fix {files}
667
+ - Report any unfixable errors
668
+ - Suggest fixes for common issues
669
+ \`\`\`
670
+
671
+ ## Rules
672
+
673
+ - Only suggest skills relevant to detected tech stack
674
+ - Let user choose which skills to generate
675
+ - Don't overwrite user customizations
676
+ `;
677
+ }
678
+ function getSkillCommandTemplate() {
679
+ return `---
680
+ description: Create a custom skill from description
681
+ argument-hint: <skill description>
682
+ ---
683
+
684
+ # /dino.skill
685
+
686
+ You are creating a custom Claude Code skill based on user description.
687
+
688
+ ## User Input
689
+
690
+ \`\`\`
691
+ $ARGUMENTS
692
+ \`\`\`
693
+
694
+ ## Instructions
695
+
696
+ 1. **Parse intent**:
697
+ - Understand what the skill should do
698
+ - Identify triggers (when it activates)
699
+ - Define actions (what it does)
700
+
701
+ 2. **Generate skill name**:
702
+ - Create kebab-case ID from description
703
+ - Check \`.claude/skills/\` for duplicates
704
+
705
+ 3. **Create skill file**:
706
+ - Create \`.claude/skills/{name}/SKILL.md\`:
707
+
708
+ \`\`\`markdown
709
+ ---
710
+ name: {skill-name}
711
+ description: {concise description}
712
+ ---
713
+
714
+ # {Skill Title}
715
+
716
+ {detailed instructions}
717
+
718
+ ## Triggers
719
+
720
+ - {when this skill activates}
721
+
722
+ ## Actions
723
+
724
+ - {what the skill does}
725
+
726
+ <!-- DINO:USER:START -->
727
+ ## Custom Notes
728
+
729
+ {user can add notes here}
730
+ <!-- DINO:USER:END -->
731
+ \`\`\`
732
+
733
+ 4. **Confirm creation**:
734
+ - Show the created skill
735
+ - Explain how it will be used
736
+
737
+ ## Examples
738
+
739
+ Input: "run tests after I finish implementing a feature"
740
+ Creates: \`test-runner\` skill that runs project tests
741
+
742
+ Input: "check for security vulnerabilities in dependencies"
743
+ Creates: \`security-audit\` skill that runs npm audit or similar
744
+
745
+ ## Rules
746
+
747
+ - Keep skills focused on one purpose
748
+ - Include clear trigger conditions
749
+ - Use project-specific commands when possible
750
+ - Add DINO:USER markers for customization
751
+ `;
752
+ }
753
+ //# sourceMappingURL=slash-commands.js.map