prjct-cli 0.4.8 → 0.5.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 (49) hide show
  1. package/CHANGELOG.md +337 -0
  2. package/CLAUDE.md +109 -3
  3. package/README.md +228 -93
  4. package/core/agent-detector.js +55 -122
  5. package/core/agent-generator.js +516 -0
  6. package/core/command-installer.js +109 -806
  7. package/core/commands.js +5 -34
  8. package/core/editors-config.js +9 -28
  9. package/core/git-integration.js +401 -0
  10. package/package.json +10 -7
  11. package/scripts/install.sh +0 -1
  12. package/templates/agents/be.template.md +42 -0
  13. package/templates/agents/data.template.md +41 -0
  14. package/templates/agents/devops.template.md +41 -0
  15. package/templates/agents/fe.template.md +42 -0
  16. package/templates/agents/mobile.template.md +41 -0
  17. package/templates/agents/pm.template.md +84 -0
  18. package/templates/agents/qa.template.md +54 -0
  19. package/templates/agents/scribe.template.md +95 -0
  20. package/templates/agents/security.template.md +41 -0
  21. package/templates/agents/ux.template.md +49 -0
  22. package/templates/commands/analyze.md +137 -3
  23. package/templates/commands/done.md +154 -5
  24. package/templates/commands/init.md +61 -3
  25. package/templates/commands/ship.md +146 -6
  26. package/templates/commands/sync.md +220 -0
  27. package/templates/examples/natural-language-examples.md +234 -22
  28. package/core/agents/codex-agent.js +0 -256
  29. package/core/agents/terminal-agent.js +0 -465
  30. package/templates/workflows/analyze.md +0 -159
  31. package/templates/workflows/cleanup.md +0 -73
  32. package/templates/workflows/context.md +0 -72
  33. package/templates/workflows/design.md +0 -88
  34. package/templates/workflows/done.md +0 -20
  35. package/templates/workflows/fix.md +0 -201
  36. package/templates/workflows/git.md +0 -192
  37. package/templates/workflows/help.md +0 -13
  38. package/templates/workflows/idea.md +0 -22
  39. package/templates/workflows/init.md +0 -80
  40. package/templates/workflows/natural-language-handler.md +0 -183
  41. package/templates/workflows/next.md +0 -44
  42. package/templates/workflows/now.md +0 -19
  43. package/templates/workflows/progress.md +0 -113
  44. package/templates/workflows/recap.md +0 -66
  45. package/templates/workflows/roadmap.md +0 -95
  46. package/templates/workflows/ship.md +0 -18
  47. package/templates/workflows/stuck.md +0 -25
  48. package/templates/workflows/task.md +0 -109
  49. package/templates/workflows/test.md +0 -243
package/CHANGELOG.md CHANGED
@@ -7,6 +7,148 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ### Fixed
11
+ - **Corrected Claude Subscription Messaging** - Clarified honest pricing throughout
12
+ - Updated `website/src/pages/Changelog.tsx`:
13
+ - Changed "Claude Code is 100% free" → "Works with whatever Claude subscription you have (free tier or Pro)"
14
+ - Added clarity: "No extra costs or tokens required - just install and use with your existing Claude access"
15
+ - Updated `website/src/components/FAQ.tsx`:
16
+ - Replaced misleading "100% free" claims with accurate subscription info
17
+ - Emphasized "no extra setup", "no token management", "no API keys to configure"
18
+ - Updated `README.md`:
19
+ - Changed "100% free" → "works with free tier or Pro"
20
+ - Added clarity about zero additional costs beyond existing Claude subscription
21
+ - Explained Claude has free tier but isn't completely free
22
+ - **Editor Installation**: Removed multi-editor references (Cursor, Windsurf, Codex) - now shows Claude-only installation
23
+ - **Natural Language Section**: Renamed to "p. Trigger - Zero Memorization" and updated all examples to show p. prefix
24
+ - **Alignment**: All examples now consistently show "p. I want..." format
25
+ - **Data Storage**: Fixed inconsistent paths - changed `.prjct/` → `~/.prjct-cli/projects/{id}/` for accuracy
26
+ - **Team Workflow**: Updated to reflect global architecture with local data and shared config
27
+ - **FAQ Sections**: Both quick and detailed FAQs now aligned with global architecture
28
+ - **Why This Matters**: Being honest about costs builds trust - prjct-cli doesn't require extra payments, but Claude itself has subscription tiers
29
+
30
+ - **Fixed TypeScript Errors** - Removed unused imports across website components
31
+ - Fixed `website/src/pages/Changelog.tsx`: Added missing `MessageSquare` import
32
+ - Fixed `website/src/components/Features.tsx`: Removed unused `Cpu` import
33
+ - Fixed `website/src/pages/Commands.tsx`: Removed unused `Cpu`, `Wind` imports
34
+ - Fixed `website/src/components/WindsurfExtension.tsx`: Removed unused `Zap`, `ChevronRight` imports
35
+ - Fixed `website/src/components/WindsurfPreview.tsx`: Removed unused `ArrowRight`, `GitBranch`, `PlayCircle`, `Layers`, `ChevronRight` imports
36
+ - Website now compiles without TypeScript errors
37
+
38
+ ### Changed
39
+ - **Website Alignment with p. Trigger** - ALL website components now show p. trigger correctly
40
+ - Updated `website/src/components/Features.tsx`:
41
+ - Changed "p. Trigger" description to show multiple examples
42
+ - '"p. I\'m done" → /p:done | "p. start building auth" → /p:now | "p. ship this" → /p:ship'
43
+ - Updated `website/src/components/ClaudeSuperpowers.tsx`:
44
+ - Changed "Natural Language" → "p. Trigger - Zero Memorization"
45
+ - All examples now show p. prefix: "p. I'm done", "p. start building auth", "p. ship this feature"
46
+ - Updated `website/src/pages/Commands.tsx`:
47
+ - Natural language examples now include p. trigger
48
+ - "p. I want to start building the login page", "p. I'm done", "p. ship this feature"
49
+ - Updated `website/src/pages/docs/QuickStart.tsx`:
50
+ - Changed examples to use p. trigger
51
+ - "p. I'm done" when finished, "p. ship this feature" to celebrate
52
+
53
+ - **Copy Simplification for Creators** - Made all text stupidly simple to understand
54
+ - Updated `README.md` to speak to creators and small teams, not just developers:
55
+ - Changed "indie hackers" → "solo creators and founders"
56
+ - Changed "developer momentum" → "track progress, not meetings"
57
+ - Simplified technical jargon:
58
+ - "Git validation" → "Checks your actual code changes"
59
+ - "MCP Integration" → "AI tools that help you code"
60
+ - "Dynamic AI Agents" → "Smart AI helpers"
61
+ - Made benefits easier to understand for non-technical creators
62
+ - Updated `website/src/components/InteractiveTerminal.tsx` examples:
63
+ - "implement user authentication" → "build login feature"
64
+ - "JWT token not validating" → "login not working"
65
+ - "API rate limiting" → "prevent spam requests"
66
+ - "Design notification architecture" → "Design how notifications will work"
67
+ - "Setup WebSocket server" → "Setup real-time messaging"
68
+ - Added explanatory comments to `website/src/lib/utils.ts`:
69
+ - Simple explanation of what `cn()` function does
70
+ - Real-world examples for creators
71
+
72
+ ### Added
73
+ - **p. Trigger System** - Zero memorization interface for prjct context
74
+ - Simple prefix `p.` signals prjct context (e.g., "p. analiza esto")
75
+ - Works in any language: English, Spanish, German, etc.
76
+ - Auto-validates `.prjct/prjct.config.json` before execution
77
+ - Context-aware: Only works in prjct directories
78
+ - Provides friendly error when not in prjct project
79
+ - Implemented via CLAUDE.md instructions (no SDK needed)
80
+ - Zero API keys, zero additional costs
81
+
82
+ - **Natural Language Context Validation** - Conversational responses when context is missing
83
+ - Automatic context validation before command execution
84
+ - Friendly guidance instead of technical errors
85
+ - Multi-language intent detection (English, Spanish, etc.)
86
+ - Works natively in Claude Code and Claude Desktop
87
+
88
+ ### Changed
89
+ - **Natural Language System** - Enhanced with p. trigger and context validation
90
+ - Updated `CLAUDE.md` with complete p. trigger detection logic
91
+ - Added context validation examples and patterns
92
+ - Implemented semantic intent understanding (Claude's native LLM capability)
93
+ - Updated `templates/commands/done.md` with context validation docs
94
+ - Updated `templates/examples/natural-language-examples.md`:
95
+ - Added Example 11: p. Trigger (zero memorization)
96
+ - Added Example 12: p. Trigger multi-language
97
+ - Added Example 13: p. Trigger without project
98
+ - Added Example 14: All three ways work (p. | /p: | natural)
99
+ - Added examples for missing context scenarios (Example 2b, 3b)
100
+ - Updated implementation notes (no SDK approach)
101
+ - Created `docs/p-trigger.md` - Complete p. trigger documentation
102
+
103
+ - **Website Alignment** - Updated all components to show p. trigger as primary interface
104
+ - `website/src/components/Hero.tsx`:
105
+ - Updated p. Trigger feature description
106
+ - Changed badge to "Built for Claude Code - Claude Desktop"
107
+ - Restored Windsurf Extension CTA with scroll-to-section functionality
108
+ - Added Sparkles and ArrowRight animated icons
109
+ - `website/src/components/Features.tsx`:
110
+ - Updated p. Trigger feature to show natural language first
111
+ - `website/src/components/CommandGuide.tsx`:
112
+ - Added p. trigger examples to all 6 scenarios (preferred option)
113
+ - Updated Quick Decision Matrix to show p. trigger format
114
+ - All examples now follow: `"p. [natural language]"` → `/p:command` pattern
115
+ - Demonstrates zero memorization approach throughout
116
+
117
+ - **Windsurf Extension Preview Section** - Added complete Windsurf extension roadmap to homepage
118
+ - `website/src/components/WindsurfExtension.tsx`:
119
+ - Full section with hero, features grid, timeline, and early access form
120
+ - Development timeline (Oct 2025 - Feb 2026)
121
+ - 4 key features: Real-time Metrics, Focus Mode, Velocity Tracking, Smart Notifications
122
+ - Progress bar showing 10% completion (validation phase)
123
+ - Scroll target for Hero CTA (`.windsurf-extension-section`)
124
+ - `website/src/components/WindsurfPreview.tsx`:
125
+ - Interactive mockup of Windsurf extension UI
126
+ - Kanban-style roadmap with drag & drop
127
+ - AI Task Generator and PRJCT Control Center
128
+ - Project Rules management interface
129
+ - `website/src/components/EarlyAccessForm.tsx`:
130
+ - GitHub issue-based waitlist signup
131
+ - Animated with framer-motion
132
+ - Purple/blue gradient theme
133
+ - `website/src/pages/Home.tsx`:
134
+ - Added WindsurfExtension between Features and ClaudeSuperpowers
135
+ - Maintains page flow and user journey
136
+
137
+ ### Fixed
138
+ - **🐛 Natural Language Context Bug** - Fixed error messages when context is missing
139
+ - Before: "⏺ No hay tarea activa en este momento..." (technical error)
140
+ - After: "✨ You're not working on anything right now! Want to start something?" (conversational)
141
+ - Affects ALL commands: /p:done, /p:ship, /p:stuck, /p:idea, /p:now
142
+ - Claude automatically validates and provides friendly guidance
143
+
144
+ ### Technical Implementation
145
+ - **Zero External Dependencies** - All functionality via CLAUDE.md
146
+ - No SDK required (initially considered but removed)
147
+ - Uses Claude Code's native session (zero API keys)
148
+ - Simple file reads for context validation
149
+ - Works identically in Claude Code and Claude Desktop
150
+ - No additional costs for users
151
+
10
152
  ### Coming Soon
11
153
  - **Windows Compatibility** - Native Windows support
12
154
  - PowerShell and CMD command execution
@@ -15,6 +157,201 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
15
157
  - Cross-platform file operations
16
158
  - Windows Terminal integration
17
159
 
160
+ ## [0.5.0] - 2025-10-02
161
+
162
+ ### 🚨 BREAKING CHANGES
163
+
164
+ - **100% Claude-Focused Architecture** - Removed support for all non-Claude environments
165
+ - ❌ **Removed**: OpenAI Codex support
166
+ - ❌ **Removed**: Cursor AI support
167
+ - ❌ **Removed**: Windsurf/Codeium support
168
+ - ✅ **Supported**: Claude Code (primary)
169
+ - ✅ **Supported**: Claude Desktop (secondary)
170
+
171
+ - **Simplified Installation** - Now installs only to `~/.claude/`
172
+ - Single editor detection (Claude only)
173
+ - Removed multi-editor selection workflow
174
+ - Removed editor-specific adapters and formatters
175
+
176
+ - **Deleted Files**:
177
+ - `core/agents/codex-agent.js` - OpenAI Codex adapter
178
+ - `core/agents/terminal-agent.js` - Terminal fallback
179
+ - `AGENTS.md` - Legacy Codex configuration
180
+ - `templates/workflows/` - Windsurf workflow templates
181
+
182
+ - **Rewritten Modules** (breaking API changes):
183
+ - `command-installer.js` - Now Claude-only (208 lines, was 800+)
184
+ - `editors-config.js` - Simplified to single editor (160 lines, was 205)
185
+ - `agent-detector.js` - Claude detection only (183 lines, was 250)
186
+
187
+ ### 🚀 Why This Change? (Built for Claude - Ship Fast, No BS)
188
+
189
+ **prjct-cli is now a developer momentum tool, NOT a project management tool.**
190
+
191
+ **The Philosophy:**
192
+ - Ship fast, stay focused, no BS
193
+ - For indie hackers and small teams (2-5 devs)
194
+ - No Jira, no ceremonies, no bureaucracy
195
+ - Just `/p:now` → work → `/p:done` → `/p:ship` → celebrate
196
+
197
+ **By focusing 100% on Claude, we unlocked superpowers:**
198
+
199
+ 1. **🤖 Dynamic AI Agents**
200
+ - Auto-generated specialists (PM, Frontend, Backend, UX, QA, Scribe, Security, DevOps, Mobile, Data)
201
+ - Context-aware activation based on your project stack
202
+ - Impossible to build with multi-platform support
203
+
204
+ 2. **🔗 Native MCP Integration**
205
+ - Context7 - Automatic library documentation
206
+ - Sequential - Deep reasoning for complex problems
207
+ - Magic - UI component generation from patterns
208
+ - Playwright - Browser automation and E2E testing
209
+ - MCP is Claude-native, can't replicate elsewhere
210
+
211
+ 3. **✅ Git Validation**
212
+ - Last commit as source of truth
213
+ - Validates completed work against actual changes
214
+ - Prevents empty task completions
215
+ - Requires tight Claude integration
216
+
217
+ 4. **💬 Natural Language**
218
+ - Talk naturally in any language, no command memorization
219
+ - "I'm done" → `/p:done`, "ship this" → `/p:ship`
220
+ - Leverages Claude's language understanding
221
+
222
+ 5. **⚡ Technical Benefits**
223
+ - **50-60% less code** (800+ lines → 228 lines in command-installer alone)
224
+ - Faster features and bug fixes
225
+ - Proper testing of everything we support
226
+ - Honest compatibility (only claim what works)
227
+
228
+ **Migration Path:**
229
+ - **Using Claude?** → `npm update -g prjct-cli` (you're all set!)
230
+ - **Using Cursor/Windsurf/Codex?** → Switch to Claude Code (free) or stay on v0.4.10
231
+ - **See [MIGRATION.md](MIGRATION.md) for complete upgrade guide**
232
+
233
+ **This isn't a limitation - it's a strategic decision that makes prjct-cli better for developers who ship fast.**
234
+
235
+ ### Added
236
+ - **Dynamic AI Agent System** - Automatic generation of specialized AI agents based on project stack
237
+ - **GitIntegration Module** (`core/git-integration.js`)
238
+ - Repository validation and state tracking
239
+ - Last commit as source of truth for validation
240
+ - Working directory status monitoring
241
+ - User claim validation against commit history
242
+ - Comprehensive git statistics and reporting
243
+
244
+ - **AgentGenerator Module** (`core/agent-generator.js`)
245
+ - Dynamic agent creation based on project analysis
246
+ - Project-specific context injection into agent templates
247
+ - Intelligent conditional agent detection
248
+ - Agent update and synchronization capabilities
249
+ - Support for both base and conditional agents
250
+
251
+ - **Base AI Agents** (Always Generated)
252
+ - PM (Project Manager) - Task coordination and breakdown
253
+ - FE (Frontend Engineer) - UI/UX, React, components, state management
254
+ - BE (Backend Engineer) - APIs, database, SOLID principles
255
+ - UX (UX Designer) - User experience, accessibility, design systems
256
+ - QA (QA Engineer) - Testing strategy and automation
257
+ - Scribe (Documentation) - Technical writing and changelog management
258
+
259
+ - **Conditional AI Agents** (Generated Based on Project Stack)
260
+ - DevOps - Docker, CI/CD, infrastructure (when Docker/CI/CD detected)
261
+ - Security - OWASP, threat modeling (when web app or auth detected)
262
+ - Mobile - React Native, Flutter (when mobile frameworks detected)
263
+ - Data - ML, data pipelines (when ML libraries detected)
264
+
265
+ - **Scribe Agent Workflows**
266
+ - Automatic documentation on `/p:done` completion
267
+ - Feature documentation on `/p:ship` deployment
268
+ - Git-based change detection for documentation scope
269
+ - User confirmation workflow before saving documentation
270
+ - Task docs saved to `analysis/task-docs/`
271
+ - Feature docs saved to `analysis/feature-docs/`
272
+
273
+ - **Enhanced `/p:analyze` Command**
274
+ - Git repository integration and validation
275
+ - Last commit information and statistics
276
+ - Working directory status tracking
277
+ - Validation baseline for user claims
278
+ - Conditional agent detection based on stack
279
+ - Comprehensive project analysis report with git stats
280
+ - Agent recommendation system
281
+
282
+ - **Enhanced `/p:init` Command**
283
+ - Automatic agent generation after project analysis
284
+ - Git-integrated analysis workflow
285
+ - Project-specific agent context injection
286
+ - Smart agent selection based on detected stack
287
+ - Agents stored in `~/.claude/agents/` directory
288
+
289
+ - **New `/p:sync` Command**
290
+ - Re-analyze project for stack changes
291
+ - Update existing agents with new project context
292
+ - Add newly required agents based on stack evolution
293
+ - Remove obsolete agents with user confirmation
294
+ - Comprehensive sync reporting and logging
295
+
296
+ ### Changed
297
+ - **Agent Architecture** - 100% Claude-focused (Claude Code + Claude Desktop)
298
+ - Agents stored in `~/.claude/agents/` directory
299
+ - Markdown format with YAML frontmatter (Claude native)
300
+ - Project-specific naming: `p_agent_[type].md`
301
+ - Dynamic context injection from project analysis
302
+ - Limited expertise per agent (focused specialization)
303
+
304
+ ### Technical Details
305
+ - **10 Agent Templates** in `templates/agents/`
306
+ - 6 base templates (always generated)
307
+ - 4 conditional templates (stack-dependent)
308
+ - Each template includes project context placeholders
309
+ - Specialized tools and color coding per agent type
310
+ - Defined expertise boundaries and trigger keywords
311
+
312
+ - **Git Integration Features**
313
+ - Commit validation and claim verification
314
+ - Working directory change tracking
315
+ - Unverified work identification
316
+ - Comprehensive git statistics
317
+ - Multi-contributor support
318
+
319
+ ## [0.4.10] - 2025-10-02
320
+
321
+ ### Changed
322
+ - **Agent Workflow Initialization** - `prjct init` now properly initializes AI agent workflows
323
+ - When existing codebase detected, prompts user to run `/p:analyze`
324
+ - Enables AI agents to follow complete analysis workflow
325
+ - Provides proper workflow context for comprehensive project analysis
326
+ - Replaced silent programmatic analysis with workflow-driven approach
327
+
328
+ ### Fixed
329
+ - **Analysis Workflow** - AI agents now receive proper instructions during project initialization
330
+ - Removed silent `analyze()` call that bypassed agent workflows
331
+ - Agent workflows now activate when user runs `/p:analyze` command
332
+ - Ensures agents follow complete analysis instructions from workflow templates
333
+
334
+ ## [0.4.9] - 2025-10-02
335
+
336
+ ### Added
337
+ - **Editor Uninstallation** - `prjct start` now allows removing editors
338
+ - Interactive checkbox selection shows currently installed editors
339
+ - Uncheck an editor to remove all prjct commands from it
340
+ - Automatically cleans up `~/.prjct-cli/config/installed-editors.json`
341
+ - User has full control over which editors have prjct commands
342
+
343
+ ### Changed
344
+ - **`prjct start` Never Blocks** - Removed "already set up" error
345
+ - Can run `prjct start` anytime to reconfigure editors
346
+ - Shows beautiful ASCII art every time
347
+ - User decides which editors to keep/remove
348
+
349
+ ### Fixed
350
+ - **Interactive Prompts** - Better UX for editor selection
351
+ - Pre-selects currently installed editors
352
+ - Clear message: "Select AI editors (uncheck to remove)"
353
+ - Allows selecting 0 editors (removes all)
354
+
18
355
  ## [0.4.8] - 2025-10-02
19
356
 
20
357
  ### Added
package/CLAUDE.md CHANGED
@@ -46,6 +46,35 @@ The system operates as an AI Assistant Enhancement Framework using:
46
46
 
47
47
  **prjct-cli includes a conversational interface** - users can talk naturally instead of memorizing commands!
48
48
 
49
+ ### p. Trigger Detection
50
+
51
+ **NEW: Simple prefix trigger** - Users can start messages with `p.` to signal prjct context:
52
+
53
+ **How it works:**
54
+ 1. User starts message with `p.` → You check if `.prjct/prjct.config.json` exists
55
+ 2. If exists → Detect intent from rest of message → Execute appropriate `/p:*` command
56
+ 3. If not exists → Respond: "No prjct project here. Run /p:init first."
57
+
58
+ **Examples:**
59
+ ```
60
+ "p. analiza todo este documento" → Detect "analysis" intent → /p:analyze
61
+ "p. estoy listo para shipear" → Detect "ship" intent → /p:ship
62
+ "p. muéstrame progreso semanal" → Detect "progress" intent → /p:progress week
63
+ "p. empiezo con auth" → Detect "start task" intent → /p:now "auth"
64
+ "p. terminé" → Detect "done" intent → /p:done
65
+ ```
66
+
67
+ **Why this is useful:**
68
+ - ✅ **Zero memorization** - No need to remember `/p:*` commands
69
+ - ✅ **Multi-project** - Only works in prjct directories
70
+ - ✅ **Natural** - "p. [what you want]" is intuitive
71
+ - ✅ **Any language** - Works in English, Spanish, etc.
72
+
73
+ **Detection priority:**
74
+ 1. Check for `p.` prefix first
75
+ 2. Then check for `/p:*` slash command
76
+ 3. Finally check for natural language without prefix
77
+
49
78
  ### Semantic Intent Detection
50
79
 
51
80
  As an LLM, you understand context and intent naturally. When users describe what they want to do, **map their intent to the appropriate command** based on semantic understanding, not pattern matching.
@@ -101,11 +130,11 @@ What's next?
101
130
  Or use: /p:now | /p:ship | /p:idea
102
131
  ```
103
132
 
104
- ## Implementation for Claude Code
133
+ ## Implementation for Claude Code & Desktop
105
134
 
106
135
  ### How to Handle Natural Language
107
136
 
108
- When you receive a message from the user:
137
+ When you receive a message from the user, follow these steps to provide the natural language experience:
109
138
 
110
139
  **Step 1: Check if it's a direct command**
111
140
  ```javascript
@@ -142,7 +171,46 @@ if (intent.command) {
142
171
  }
143
172
  ```
144
173
 
145
- **Step 3: Provide conversational response**
174
+ **Step 3: Validate context before execution**
175
+ ```javascript
176
+ // Before executing commands, check prerequisites:
177
+
178
+ // For /p:done:
179
+ if (command === 'done') {
180
+ const nowContent = await Read('core/now.md')
181
+ if (!nowContent || nowContent.trim() === '') {
182
+ return conversationalResponse(`
183
+ ✨ You're not working on anything right now!
184
+
185
+ Want to start something?
186
+ • Tell me what you want to build
187
+ • Say "show me what's next"
188
+ • Or use: /p:now | /p:next
189
+
190
+ Let's ship something!`)
191
+ }
192
+ }
193
+
194
+ // For /p:ship:
195
+ if (command === 'ship') {
196
+ const nowContent = await Read('core/now.md')
197
+ const shippedContent = await Read('progress/shipped.md')
198
+ if ((!nowContent || nowContent.trim() === '') &&
199
+ (!shippedContent || shippedContent.trim() === '')) {
200
+ return conversationalResponse(`
201
+ 🚀 Nothing to ship yet!
202
+
203
+ First, let's build something:
204
+ • Tell me what feature you want to create
205
+ • Say "start building [feature]"
206
+ • Or use: /p:now "feature name"
207
+
208
+ Then we'll celebrate when you ship it!`)
209
+ }
210
+ }
211
+ ```
212
+
213
+ **Step 4: Provide conversational response**
146
214
  ```javascript
147
215
  // Always suggest natural next steps
148
216
  ✅ [What you did]
@@ -178,6 +246,43 @@ When you're done:
178
246
  Need help? Say "I'm stuck" or use /p:stuck
179
247
  ```
180
248
 
249
+ ### Context Validation Examples
250
+
251
+ **Missing Active Task:**
252
+
253
+ User: "done"
254
+ You check: `core/now.md` is empty
255
+ Your response:
256
+ ```
257
+ ✨ You're not working on anything right now!
258
+
259
+ Want to start something?
260
+ • Tell me what you want to build
261
+ • Say "show me what's next"
262
+ • Or use: /p:now | /p:next
263
+
264
+ Let's ship something!
265
+ ```
266
+
267
+ **Valid Context:**
268
+
269
+ User: "I'm done"
270
+ You check: `core/now.md` has content ✅
271
+ Your response:
272
+ ```
273
+ 💬 I understood: "task completion"
274
+ ⚡ Executing: /p:done
275
+
276
+ ✅ Task complete: building authentication (2h 15m)
277
+
278
+ What's next?
279
+ • "start next task" → Begin working
280
+ • "ship this feature" → Track & celebrate
281
+ • "add new idea" → Brainstorm
282
+
283
+ Or use: /p:now | /p:ship | /p:idea
284
+ ```
285
+
181
286
  ### Key Principles
182
287
 
183
288
  1. **Trust your understanding** - You're an LLM, not a regex parser
@@ -185,6 +290,7 @@ Need help? Say "I'm stuck" or use /p:stuck
185
290
  3. **Variations are fine** - Users can express intent in infinite ways
186
291
  4. **Show transparency** - Always say what you understood and what you'll execute
187
292
  5. **Be conversational** - Guide users naturally toward next actions
293
+ 6. **Validate context** - Check prerequisites before executing commands
188
294
 
189
295
  ## Command System for Claude Code
190
296