clavix 4.12.0 → 5.0.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/README.md +69 -61
- package/dist/templates/slash-commands/_canonical/archive.md +83 -121
- package/dist/templates/slash-commands/_canonical/execute.md +32 -42
- package/dist/templates/slash-commands/_canonical/implement.md +32 -44
- package/dist/templates/slash-commands/_canonical/improve.md +13 -52
- package/dist/templates/slash-commands/_components/agent-protocols/cli-reference.md +84 -180
- package/dist/templates/slash-commands/_components/agent-protocols/error-handling.md +2 -2
- package/dist/templates/slash-commands/_components/agent-protocols/file-formats.md +41 -59
- package/dist/templates/slash-commands/_components/sections/file-saving-protocol.md +20 -27
- package/dist/templates/slash-commands/_components/troubleshooting/file-not-saved.md +4 -5
- package/package.json +2 -2
- package/dist/cli/commands/analyze.d.ts +0 -17
- package/dist/cli/commands/analyze.js +0 -133
- package/dist/cli/commands/archive.d.ts +0 -36
- package/dist/cli/commands/archive.js +0 -266
- package/dist/cli/commands/deep.d.ts +0 -17
- package/dist/cli/commands/deep.js +0 -170
- package/dist/cli/commands/execute.d.ts +0 -15
- package/dist/cli/commands/execute.js +0 -168
- package/dist/cli/commands/fast.d.ts +0 -18
- package/dist/cli/commands/fast.js +0 -219
- package/dist/cli/commands/implement.d.ts +0 -24
- package/dist/cli/commands/implement.js +0 -289
- package/dist/cli/commands/improve.d.ts +0 -32
- package/dist/cli/commands/improve.js +0 -250
- package/dist/cli/commands/list.d.ts +0 -17
- package/dist/cli/commands/list.js +0 -217
- package/dist/cli/commands/plan.d.ts +0 -21
- package/dist/cli/commands/plan.js +0 -297
- package/dist/cli/commands/prd.d.ts +0 -24
- package/dist/cli/commands/prd.js +0 -321
- package/dist/cli/commands/prompts/clear.d.ts +0 -16
- package/dist/cli/commands/prompts/clear.js +0 -222
- package/dist/cli/commands/prompts/list.d.ts +0 -8
- package/dist/cli/commands/prompts/list.js +0 -88
- package/dist/cli/commands/show.d.ts +0 -21
- package/dist/cli/commands/show.js +0 -191
- package/dist/cli/commands/start.d.ts +0 -40
- package/dist/cli/commands/start.js +0 -210
- package/dist/cli/commands/summarize.d.ts +0 -17
- package/dist/cli/commands/summarize.js +0 -196
- package/dist/cli/commands/task-complete.d.ts +0 -27
- package/dist/cli/commands/task-complete.js +0 -269
- package/dist/cli/commands/verify.d.ts +0 -28
- package/dist/cli/commands/verify.js +0 -349
- package/dist/core/archive-manager.d.ts +0 -100
- package/dist/core/archive-manager.js +0 -302
- package/dist/core/basic-checklist-generator.d.ts +0 -35
- package/dist/core/basic-checklist-generator.js +0 -344
- package/dist/core/checklist-parser.d.ts +0 -48
- package/dist/core/checklist-parser.js +0 -238
- package/dist/core/config-manager.d.ts +0 -149
- package/dist/core/config-manager.js +0 -230
- package/dist/core/conversation-analyzer.d.ts +0 -86
- package/dist/core/conversation-analyzer.js +0 -387
- package/dist/core/conversation-quality-tracker.d.ts +0 -81
- package/dist/core/conversation-quality-tracker.js +0 -195
- package/dist/core/git-manager.d.ts +0 -126
- package/dist/core/git-manager.js +0 -282
- package/dist/core/intelligence/confidence-calculator.d.ts +0 -93
- package/dist/core/intelligence/confidence-calculator.js +0 -124
- package/dist/core/intelligence/index.d.ts +0 -11
- package/dist/core/intelligence/index.js +0 -15
- package/dist/core/intelligence/intent-detector.d.ts +0 -54
- package/dist/core/intelligence/intent-detector.js +0 -723
- package/dist/core/intelligence/pattern-library.d.ts +0 -104
- package/dist/core/intelligence/pattern-library.js +0 -330
- package/dist/core/intelligence/patterns/actionability-enhancer.d.ts +0 -27
- package/dist/core/intelligence/patterns/actionability-enhancer.js +0 -192
- package/dist/core/intelligence/patterns/alternative-phrasing-generator.d.ts +0 -29
- package/dist/core/intelligence/patterns/alternative-phrasing-generator.js +0 -239
- package/dist/core/intelligence/patterns/ambiguity-detector.d.ts +0 -22
- package/dist/core/intelligence/patterns/ambiguity-detector.js +0 -196
- package/dist/core/intelligence/patterns/assumption-explicitizer.d.ts +0 -30
- package/dist/core/intelligence/patterns/assumption-explicitizer.js +0 -296
- package/dist/core/intelligence/patterns/base-pattern.d.ts +0 -192
- package/dist/core/intelligence/patterns/base-pattern.js +0 -103
- package/dist/core/intelligence/patterns/completeness-validator.d.ts +0 -27
- package/dist/core/intelligence/patterns/completeness-validator.js +0 -221
- package/dist/core/intelligence/patterns/conciseness-filter.d.ts +0 -20
- package/dist/core/intelligence/patterns/conciseness-filter.js +0 -92
- package/dist/core/intelligence/patterns/context-precision.d.ts +0 -32
- package/dist/core/intelligence/patterns/context-precision.js +0 -389
- package/dist/core/intelligence/patterns/conversation-summarizer.d.ts +0 -30
- package/dist/core/intelligence/patterns/conversation-summarizer.js +0 -277
- package/dist/core/intelligence/patterns/dependency-identifier.d.ts +0 -23
- package/dist/core/intelligence/patterns/dependency-identifier.js +0 -166
- package/dist/core/intelligence/patterns/domain-context-enricher.d.ts +0 -21
- package/dist/core/intelligence/patterns/domain-context-enricher.js +0 -198
- package/dist/core/intelligence/patterns/edge-case-identifier.d.ts +0 -30
- package/dist/core/intelligence/patterns/edge-case-identifier.js +0 -269
- package/dist/core/intelligence/patterns/error-tolerance-enhancer.d.ts +0 -22
- package/dist/core/intelligence/patterns/error-tolerance-enhancer.js +0 -179
- package/dist/core/intelligence/patterns/implicit-requirement-extractor.d.ts +0 -24
- package/dist/core/intelligence/patterns/implicit-requirement-extractor.js +0 -259
- package/dist/core/intelligence/patterns/objective-clarifier.d.ts +0 -22
- package/dist/core/intelligence/patterns/objective-clarifier.js +0 -126
- package/dist/core/intelligence/patterns/output-format-enforcer.d.ts +0 -22
- package/dist/core/intelligence/patterns/output-format-enforcer.js +0 -151
- package/dist/core/intelligence/patterns/prd-structure-enforcer.d.ts +0 -23
- package/dist/core/intelligence/patterns/prd-structure-enforcer.js +0 -183
- package/dist/core/intelligence/patterns/prerequisite-identifier.d.ts +0 -23
- package/dist/core/intelligence/patterns/prerequisite-identifier.js +0 -221
- package/dist/core/intelligence/patterns/requirement-prioritizer.d.ts +0 -24
- package/dist/core/intelligence/patterns/requirement-prioritizer.js +0 -134
- package/dist/core/intelligence/patterns/scope-definer.d.ts +0 -26
- package/dist/core/intelligence/patterns/scope-definer.js +0 -236
- package/dist/core/intelligence/patterns/step-decomposer.d.ts +0 -31
- package/dist/core/intelligence/patterns/step-decomposer.js +0 -242
- package/dist/core/intelligence/patterns/structure-organizer.d.ts +0 -31
- package/dist/core/intelligence/patterns/structure-organizer.js +0 -218
- package/dist/core/intelligence/patterns/success-criteria-enforcer.d.ts +0 -22
- package/dist/core/intelligence/patterns/success-criteria-enforcer.js +0 -165
- package/dist/core/intelligence/patterns/success-metrics-enforcer.d.ts +0 -24
- package/dist/core/intelligence/patterns/success-metrics-enforcer.js +0 -165
- package/dist/core/intelligence/patterns/technical-context-enricher.d.ts +0 -25
- package/dist/core/intelligence/patterns/technical-context-enricher.js +0 -165
- package/dist/core/intelligence/patterns/topic-coherence-analyzer.d.ts +0 -26
- package/dist/core/intelligence/patterns/topic-coherence-analyzer.js +0 -300
- package/dist/core/intelligence/patterns/user-persona-enricher.d.ts +0 -24
- package/dist/core/intelligence/patterns/user-persona-enricher.js +0 -141
- package/dist/core/intelligence/patterns/validation-checklist-creator.d.ts +0 -31
- package/dist/core/intelligence/patterns/validation-checklist-creator.js +0 -242
- package/dist/core/intelligence/quality-assessor.d.ts +0 -71
- package/dist/core/intelligence/quality-assessor.js +0 -525
- package/dist/core/intelligence/types.d.ts +0 -111
- package/dist/core/intelligence/types.js +0 -3
- package/dist/core/intelligence/universal-optimizer.d.ts +0 -91
- package/dist/core/intelligence/universal-optimizer.js +0 -399
- package/dist/core/prd-generator.d.ts +0 -76
- package/dist/core/prd-generator.js +0 -173
- package/dist/core/prompt-manager.d.ts +0 -110
- package/dist/core/prompt-manager.js +0 -274
- package/dist/core/prompt-optimizer.d.ts +0 -268
- package/dist/core/prompt-optimizer.js +0 -959
- package/dist/core/question-engine.d.ts +0 -167
- package/dist/core/question-engine.js +0 -356
- package/dist/core/session-manager.d.ts +0 -139
- package/dist/core/session-manager.js +0 -365
- package/dist/core/task-manager.d.ts +0 -211
- package/dist/core/task-manager.js +0 -981
- package/dist/core/verification-hooks.d.ts +0 -67
- package/dist/core/verification-hooks.js +0 -309
- package/dist/core/verification-manager.d.ts +0 -107
- package/dist/core/verification-manager.js +0 -415
- package/dist/index 2.js +0 -13
- package/dist/index.d 2.ts +0 -4
- package/dist/types/session.d.ts +0 -78
- package/dist/types/session.js +0 -8
- package/dist/types/verification.d.ts +0 -205
- package/dist/types/verification.js +0 -9
package/README.md
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
# Clavix
|
|
2
|
-
>
|
|
2
|
+
> Agentic-first prompt workflows. Markdown templates that teach AI agents how to optimize prompts, create PRDs, and manage implementation. Works with Claude Code, Cursor, Windsurf, and 19+ other AI coding tools.
|
|
3
3
|
|
|
4
4
|
## Table of contents
|
|
5
5
|
- [Why Clavix?](#why-clavix)
|
|
6
6
|
- [How It Works](#how-it-works)
|
|
7
|
-
- [
|
|
7
|
+
- [Supported AI Tools](#supported-ai-tools)
|
|
8
8
|
- [Quickstart](#quickstart)
|
|
9
9
|
- [Full documentation](#full-documentation)
|
|
10
10
|
|
|
@@ -12,109 +12,117 @@
|
|
|
12
12
|
|
|
13
13
|
| Version | Highlights | Details |
|
|
14
14
|
| --- | --- | --- |
|
|
15
|
-
| **
|
|
16
|
-
| **
|
|
17
|
-
| **v3.5.0** | "Providers" → "Integrations" terminology | [Changelog](CHANGELOG.md#350---2025-01-24) |
|
|
18
|
-
| **v3.4.0** | Provider categorization fixes | [Changelog](CHANGELOG.md#340---2025-11-24) |
|
|
15
|
+
| **v5.0.0** (Latest) | Agentic-first architecture - lean template delivery | [Changelog](CHANGELOG.md#500---2025-01-27) |
|
|
16
|
+
| **v4.12.0** | Final v4 release with full CLI commands | [Changelog](docs/archive/v4-changelog.md) |
|
|
19
17
|
|
|
20
|
-
**Requirements:** Node.js
|
|
18
|
+
**Requirements:** Node.js >= 18.0.0
|
|
21
19
|
|
|
22
20
|
## Why Clavix?
|
|
23
|
-
Better prompts lead to better code. Clavix analyzes what you're trying to do and applies structured optimization patterns—no framework to learn, no methodology to master. Just describe what you want, and Clavix structures it for AI consumption.
|
|
24
21
|
|
|
25
|
-
|
|
26
|
-
- **
|
|
27
|
-
- **
|
|
28
|
-
- **
|
|
29
|
-
- **
|
|
22
|
+
Better prompts lead to better code. Clavix provides **markdown templates** that teach AI agents how to:
|
|
23
|
+
- **Optimize prompts** - Transform rough ideas into structured, AI-ready prompts
|
|
24
|
+
- **Create PRDs** - Generate comprehensive requirements documents through guided questions
|
|
25
|
+
- **Plan implementations** - Break down PRDs into phased task lists
|
|
26
|
+
- **Track progress** - Manage task completion with optional git commits
|
|
27
|
+
|
|
28
|
+
**No framework to learn.** Just describe what you want, and your AI agent follows the Clavix templates to structure it properly.
|
|
30
29
|
|
|
31
30
|
Learn more in [docs/why-clavix.md](docs/why-clavix.md).
|
|
32
31
|
|
|
33
32
|
## How It Works
|
|
34
|
-
Clavix uses pattern-based analysis to:
|
|
35
|
-
- **Detect intent** - Keyword scoring and phrase detection across 11 intent categories
|
|
36
|
-
- **Assess quality** - Heuristic scoring across 6 dimensions: Clarity, Efficiency, Structure, Completeness, Actionability, Specificity
|
|
37
|
-
- **Apply patterns** - 20 optimization patterns automatically selected based on intent and quality
|
|
38
|
-
- **Generate output** - Structured prompts optimized for AI coding assistants
|
|
39
33
|
|
|
40
|
-
|
|
34
|
+
Clavix v5 follows an **agentic-first architecture**:
|
|
35
|
+
|
|
36
|
+
1. **You run `clavix init`** - Sets up `.clavix/` directory with slash command templates
|
|
37
|
+
2. **You invoke a slash command** - Like `/clavix:improve` in Claude Code or Cursor
|
|
38
|
+
3. **Your AI agent reads the template** - The markdown file contains all instructions
|
|
39
|
+
4. **The agent follows the instructions** - Using its native tools (Write, Read, Edit, etc.)
|
|
40
|
+
5. **Output is saved** - To `.clavix/outputs/` for future reference
|
|
41
41
|
|
|
42
|
-
|
|
42
|
+
**No TypeScript code executes during slash command usage.** The templates are the product - they instruct AI agents on what to do.
|
|
43
43
|
|
|
44
|
-
##
|
|
44
|
+
## Supported AI Tools
|
|
45
45
|
|
|
46
|
-
| Category |
|
|
46
|
+
| Category | Tools |
|
|
47
47
|
| --- | --- |
|
|
48
|
-
| IDE
|
|
49
|
-
| CLI agents | Claude Code
|
|
50
|
-
| Universal adapters | AGENTS.md
|
|
48
|
+
| IDE extensions | Cursor, Windsurf, Kilocode, Roocode, Cline |
|
|
49
|
+
| CLI agents | Claude Code, Droid CLI, CodeBuddy CLI, OpenCode, Gemini CLI, Qwen Code, LLXPRT, Amp, Crush CLI, Codex CLI, Augment CLI |
|
|
50
|
+
| Universal adapters | AGENTS.md, GitHub Copilot, OCTO.md, WARP.md |
|
|
51
51
|
|
|
52
|
-
|
|
52
|
+
Full list and configuration: [docs/integrations.md](docs/integrations.md)
|
|
53
53
|
|
|
54
54
|
## Quickstart
|
|
55
55
|
|
|
56
|
-
###
|
|
57
|
-
|
|
58
|
-
Most Clavix users work through AI coding assistants:
|
|
59
|
-
|
|
60
|
-
> **💡 Choosing Your Workflow:**
|
|
61
|
-
> - **Improve** – Optimize a single prompt (auto-selects depth)
|
|
62
|
-
> - **PRD** – Plan something new with guided questions
|
|
63
|
-
> - **Start** – Explore ideas conversationally
|
|
64
|
-
>
|
|
65
|
-
> See [Choosing the Right Workflow](docs/guides/choosing-workflow.md) for detailed guidance.
|
|
56
|
+
### 1. Install and Initialize
|
|
66
57
|
|
|
67
58
|
```bash
|
|
68
|
-
# 1. Initialize in your project
|
|
69
59
|
npm install -g clavix
|
|
70
60
|
clavix init
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
This creates `.clavix/` with slash command templates and injects documentation into your CLAUDE.md (or equivalent).
|
|
71
64
|
|
|
72
|
-
|
|
73
|
-
/clavix:improve "Create a login page" # Optimize a prompt
|
|
74
|
-
/clavix:prd # Full PRD workflow
|
|
75
|
-
/clavix:start # Conversational exploration
|
|
65
|
+
### 2. Use Slash Commands
|
|
76
66
|
|
|
77
|
-
|
|
78
|
-
/clavix:execute # Execute saved prompts
|
|
79
|
-
/clavix:verify # Verify implementation against checklist
|
|
67
|
+
In your AI coding assistant (Claude Code, Cursor, etc.):
|
|
80
68
|
|
|
81
|
-
|
|
82
|
-
/clavix:
|
|
83
|
-
/clavix:implement # Start implementation workflow
|
|
84
|
-
clavix task-complete <taskId> # Mark tasks done with auto-commit
|
|
69
|
+
```
|
|
70
|
+
/clavix:improve "Create a secure login page with JWT"
|
|
85
71
|
```
|
|
86
72
|
|
|
87
|
-
|
|
73
|
+
The AI agent reads the improve template and:
|
|
74
|
+
- Analyzes your prompt for quality
|
|
75
|
+
- Applies optimization patterns
|
|
76
|
+
- Saves the improved version to `.clavix/outputs/prompts/`
|
|
88
77
|
|
|
89
|
-
|
|
78
|
+
### 3. Choose Your Workflow
|
|
90
79
|
|
|
91
|
-
|
|
80
|
+
| Command | When to Use |
|
|
81
|
+
|---------|-------------|
|
|
82
|
+
| `/clavix:improve` | Optimize a single prompt (auto-selects depth) |
|
|
83
|
+
| `/clavix:prd` | Plan something new with guided questions |
|
|
84
|
+
| `/clavix:start` | Explore ideas conversationally first |
|
|
85
|
+
| `/clavix:plan` | Generate tasks from a PRD |
|
|
86
|
+
| `/clavix:implement` | Execute tasks with progress tracking |
|
|
87
|
+
| `/clavix:archive` | Archive completed projects |
|
|
92
88
|
|
|
93
|
-
|
|
89
|
+
See [Choosing the Right Workflow](docs/guides/choosing-workflow.md) for detailed guidance.
|
|
90
|
+
|
|
91
|
+
### 4. Keep Templates Updated
|
|
94
92
|
|
|
95
93
|
```bash
|
|
96
|
-
clavix
|
|
97
|
-
clavix improve "Create a login page" # Auto-selects depth
|
|
98
|
-
clavix improve --comprehensive "Complex API" # Force comprehensive
|
|
99
|
-
clavix prd
|
|
94
|
+
clavix update # After npm update clavix
|
|
100
95
|
```
|
|
101
96
|
|
|
97
|
+
## CLI Commands
|
|
98
|
+
|
|
99
|
+
Clavix v5 has only 4 CLI commands (for setup, not workflows):
|
|
100
|
+
|
|
101
|
+
| Command | Purpose |
|
|
102
|
+
|---------|---------|
|
|
103
|
+
| `clavix init` | Initialize Clavix in a project |
|
|
104
|
+
| `clavix update` | Update templates after package update |
|
|
105
|
+
| `clavix config` | Manage configuration |
|
|
106
|
+
| `clavix version` | Show version |
|
|
107
|
+
|
|
108
|
+
**All workflows** (`/clavix:improve`, `/clavix:prd`, etc.) are **slash commands** that AI agents execute by reading markdown templates.
|
|
109
|
+
|
|
102
110
|
## Full documentation
|
|
103
111
|
- Overview & navigation: [docs/README.md](docs/README.md)
|
|
104
|
-
-
|
|
105
|
-
- Providers: [docs/integrations.md](docs/integrations.md)
|
|
112
|
+
- Integrations: [docs/integrations.md](docs/integrations.md)
|
|
106
113
|
- How it works: [docs/how-it-works.md](docs/how-it-works.md)
|
|
107
114
|
- Philosophy: [docs/philosophy.md](docs/philosophy.md)
|
|
108
|
-
-
|
|
115
|
+
- v4 Architecture (archived): [docs/archive/v4-architecture.md](docs/archive/v4-architecture.md)
|
|
109
116
|
|
|
110
117
|
## Requirements
|
|
111
118
|
|
|
112
119
|
### For End Users
|
|
113
|
-
- **Node.js
|
|
120
|
+
- **Node.js >= 18.0.0**
|
|
114
121
|
- npm or yarn package manager
|
|
122
|
+
- An AI coding assistant (Claude Code, Cursor, Windsurf, etc.)
|
|
115
123
|
|
|
116
124
|
### For Contributors
|
|
117
|
-
- **Node.js
|
|
125
|
+
- **Node.js >= 18.0.0**
|
|
118
126
|
- Run tests: `npm test`
|
|
119
127
|
- Lint: `npm run lint`
|
|
120
128
|
- Build: `npm run build`
|
|
@@ -38,25 +38,25 @@ When you run `/clavix:archive`, I:
|
|
|
38
38
|
|
|
39
39
|
---
|
|
40
40
|
|
|
41
|
-
## How I Archive Projects
|
|
41
|
+
## How I Archive Projects (v5 Agentic-First)
|
|
42
42
|
|
|
43
|
-
**I
|
|
43
|
+
**I use my native tools directly - no CLI commands involved.**
|
|
44
44
|
|
|
45
|
-
### What I
|
|
45
|
+
### What I Do
|
|
46
46
|
|
|
47
|
-
| What You Want |
|
|
48
|
-
|
|
49
|
-
| Archive completed project |
|
|
50
|
-
| Archive
|
|
51
|
-
|
|
|
52
|
-
|
|
|
53
|
-
|
|
|
54
|
-
| Restore from archive | `clavix archive --restore [name]` |
|
|
47
|
+
| What You Want | How I Do It |
|
|
48
|
+
|---------------|-------------|
|
|
49
|
+
| Archive completed project | Move directory: `.clavix/outputs/<project>` → `.clavix/outputs/archive/<project>` |
|
|
50
|
+
| Archive incomplete work | Same, with your confirmation |
|
|
51
|
+
| Delete permanently | Remove directory: `rm -rf .clavix/outputs/<project>` |
|
|
52
|
+
| See what's archived | List files in `.clavix/outputs/archive/` |
|
|
53
|
+
| Restore from archive | Move back: `.clavix/outputs/archive/<project>` → `.clavix/outputs/<project>` |
|
|
55
54
|
|
|
56
55
|
### Before I Archive
|
|
57
56
|
|
|
58
57
|
I check:
|
|
59
58
|
- ✓ Projects exist in `.clavix/outputs/`
|
|
59
|
+
- ✓ Task completion status (read tasks.md)
|
|
60
60
|
- ✓ What you want to do (archive, delete, restore)
|
|
61
61
|
- ✓ Project name is correct
|
|
62
62
|
|
|
@@ -69,44 +69,27 @@ I tell you:
|
|
|
69
69
|
|
|
70
70
|
### Part B: Understanding Archive Operations
|
|
71
71
|
|
|
72
|
-
**Archive
|
|
72
|
+
**Archive Operations** (I perform these using my native tools):
|
|
73
73
|
|
|
74
|
-
1. **Interactive Archive
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
CLI behavior:
|
|
80
|
-
- Lists all PRD projects with 100% tasks completed
|
|
81
|
-
- Allows user to select which project to archive
|
|
82
|
-
- Confirms before archiving
|
|
83
|
-
- Moves the project to archive directory
|
|
74
|
+
1. **Interactive Archive**:
|
|
75
|
+
- I list all PRD projects in `.clavix/outputs/`
|
|
76
|
+
- I check which have 100% tasks completed
|
|
77
|
+
- You select which to archive
|
|
78
|
+
- I move the project to `.clavix/outputs/archive/`
|
|
84
79
|
|
|
85
80
|
2. **Archive Specific Project**:
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
CLI behavior:
|
|
91
|
-
- Checks task completion status
|
|
92
|
-
- Warns if tasks are incomplete
|
|
93
|
-
- Asks for confirmation
|
|
94
|
-
- Archives the specific project
|
|
81
|
+
- I check task completion status in `tasks.md`
|
|
82
|
+
- I warn if tasks are incomplete
|
|
83
|
+
- You confirm
|
|
84
|
+
- I move the project directory
|
|
95
85
|
|
|
96
86
|
3. **Force Archive (Incomplete Tasks)**:
|
|
97
|
-
```bash
|
|
98
|
-
clavix archive [project-name] --force
|
|
99
|
-
```
|
|
100
|
-
|
|
101
87
|
Use when:
|
|
102
88
|
- Project scope changed and some tasks are no longer relevant
|
|
103
89
|
- User wants to archive work-in-progress
|
|
104
90
|
- Tasks are incomplete but project is done
|
|
105
91
|
|
|
106
92
|
4. **Delete Project (Permanent Removal)**: **DESTRUCTIVE ACTION**
|
|
107
|
-
```bash
|
|
108
|
-
clavix archive [project-name] --delete
|
|
109
|
-
```
|
|
110
93
|
|
|
111
94
|
**WARNING**: This PERMANENTLY deletes the project. Cannot be restored.
|
|
112
95
|
|
|
@@ -124,24 +107,16 @@ I tell you:
|
|
|
124
107
|
```
|
|
125
108
|
|
|
126
109
|
**Safety confirmation required:**
|
|
127
|
-
-
|
|
128
|
-
-
|
|
129
|
-
-
|
|
130
|
-
-
|
|
110
|
+
- I show project details and task status
|
|
111
|
+
- I ask you to type project name to confirm
|
|
112
|
+
- I warn about permanent deletion
|
|
113
|
+
- I list what will be permanently deleted
|
|
131
114
|
|
|
132
115
|
5. **List Archived Projects**:
|
|
133
|
-
|
|
134
|
-
clavix archive --list
|
|
135
|
-
```
|
|
136
|
-
|
|
137
|
-
Shows all projects currently in archive with their task completion status
|
|
116
|
+
I read the contents of `.clavix/outputs/archive/` and show you all archived projects.
|
|
138
117
|
|
|
139
118
|
6. **Restore from Archive**:
|
|
140
|
-
|
|
141
|
-
clavix archive --restore [project-name]
|
|
142
|
-
```
|
|
143
|
-
|
|
144
|
-
Moves a project back from archive to active outputs
|
|
119
|
+
I move a project back: `.clavix/outputs/archive/<project>` → `.clavix/outputs/<project>`
|
|
145
120
|
|
|
146
121
|
## When to Archive
|
|
147
122
|
|
|
@@ -180,61 +155,57 @@ Optimized prompts from `/clavix:improve` are stored separately in `.clavix/outpu
|
|
|
180
155
|
|
|
181
156
|
**Prompts are NOT archived with PRD projects.**
|
|
182
157
|
|
|
183
|
-
**
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
clavix prompts clear --stale # Remove >30 day old
|
|
189
|
-
```
|
|
190
|
-
|
|
191
|
-
**Before archiving, consider cleanup:**
|
|
192
|
-
```bash
|
|
193
|
-
clavix prompts clear --executed
|
|
194
|
-
```
|
|
158
|
+
**To manage prompts:**
|
|
159
|
+
- **View all prompts**: List `.clavix/outputs/prompts/*.md` files
|
|
160
|
+
- **View a prompt**: Read `.clavix/outputs/prompts/<id>.md`
|
|
161
|
+
- **Delete executed prompts**: Remove files where frontmatter has `executed: true`
|
|
162
|
+
- **Delete stale prompts**: Remove files older than 30 days (check timestamp in frontmatter)
|
|
195
163
|
|
|
196
164
|
**Prompts lifecycle:**
|
|
197
165
|
- Independent from PRD lifecycle
|
|
198
|
-
- Managed
|
|
199
|
-
-
|
|
166
|
+
- Managed by reading/writing files directly
|
|
167
|
+
- Clean up manually when project complete
|
|
200
168
|
|
|
201
169
|
## Example Workflows
|
|
202
170
|
|
|
203
171
|
### Workflow 1: Complete Project
|
|
204
172
|
```
|
|
205
173
|
User: "I've finished implementing the user authentication feature"
|
|
206
|
-
You: "Great! Let me help you archive it."
|
|
174
|
+
You: "Great! Let me check the task status and help you archive it."
|
|
207
175
|
|
|
208
|
-
|
|
176
|
+
I read: .clavix/outputs/user-authentication-system/tasks.md
|
|
177
|
+
Result: All 15 tasks completed (100%)
|
|
209
178
|
|
|
210
|
-
|
|
211
|
-
System shows: All 15 tasks completed (100%)
|
|
212
|
-
User confirms: Yes, archive it
|
|
179
|
+
You confirm: Yes, archive it
|
|
213
180
|
|
|
214
|
-
|
|
181
|
+
I execute: mv .clavix/outputs/user-authentication-system .clavix/outputs/archive/
|
|
182
|
+
|
|
183
|
+
Result: Project archived to .clavix/outputs/archive/user-authentication-system/
|
|
215
184
|
```
|
|
216
185
|
|
|
217
186
|
### Workflow 2: Force Archive WIP
|
|
218
187
|
```
|
|
219
188
|
User: "We're pivoting, I want to archive the old API design even though tasks aren't done"
|
|
220
|
-
You: "I'll archive it
|
|
189
|
+
You: "I'll check the status and archive it if you confirm."
|
|
221
190
|
|
|
222
|
-
|
|
191
|
+
I read: .clavix/outputs/old-api-design/tasks.md
|
|
192
|
+
Result: 8 incomplete tasks
|
|
223
193
|
|
|
224
|
-
System shows: 8 incomplete tasks
|
|
225
194
|
User confirms: Yes, archive anyway
|
|
226
195
|
|
|
196
|
+
I execute: mv .clavix/outputs/old-api-design .clavix/outputs/archive/
|
|
197
|
+
|
|
227
198
|
Result: Project archived despite incomplete tasks
|
|
228
199
|
```
|
|
229
200
|
|
|
230
201
|
### Workflow 3: Restore Archived Project
|
|
231
202
|
```
|
|
232
203
|
User: "Actually, we need to revisit that authentication feature"
|
|
233
|
-
You: "I'll restore it from the archive"
|
|
204
|
+
You: "I'll restore it from the archive."
|
|
234
205
|
|
|
235
|
-
|
|
206
|
+
I execute: mv .clavix/outputs/archive/user-authentication-system .clavix/outputs/
|
|
236
207
|
|
|
237
|
-
Result: Project
|
|
208
|
+
Result: Project restored to .clavix/outputs/user-authentication-system/
|
|
238
209
|
```
|
|
239
210
|
|
|
240
211
|
### Workflow 4: Delete Failed Experiment
|
|
@@ -243,26 +214,25 @@ User: "I have a test project 'api-experiment-1' that I don't need anymore"
|
|
|
243
214
|
You: "Is this something you might reference later, or can it be permanently deleted?"
|
|
244
215
|
|
|
245
216
|
User: "It was just a quick test, no value. Delete it."
|
|
246
|
-
You: "This will permanently delete the project.
|
|
217
|
+
You: "This will permanently delete the project. Please confirm by typing the project name."
|
|
247
218
|
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
System shows:
|
|
219
|
+
I show:
|
|
251
220
|
Project: api-experiment-1
|
|
252
221
|
Tasks: 3/5 completed
|
|
253
222
|
Files: full-prd.md, quick-prd.md, tasks.md
|
|
254
223
|
|
|
255
224
|
WARNING: This action is PERMANENT and CANNOT be undone.
|
|
256
|
-
Type the project name to confirm deletion: _
|
|
257
225
|
|
|
258
226
|
User types: api-experiment-1
|
|
259
227
|
|
|
260
|
-
|
|
228
|
+
I execute: rm -rf .clavix/outputs/api-experiment-1
|
|
229
|
+
|
|
230
|
+
Result: Project permanently deleted
|
|
261
231
|
```
|
|
262
232
|
|
|
263
233
|
---
|
|
264
234
|
|
|
265
|
-
## Agent Transparency (
|
|
235
|
+
## Agent Transparency (v5.0)
|
|
266
236
|
|
|
267
237
|
### CLI Reference (Commands I Execute)
|
|
268
238
|
{{INCLUDE:agent-protocols/cli-reference.md}}
|
|
@@ -295,37 +265,37 @@ Result: Project permanently deleted from .clavix/outputs/api-experiment-1/
|
|
|
295
265
|
- Archive keeps your active projects list clean and focused
|
|
296
266
|
- Archived projects maintain all their data (nothing is deleted)
|
|
297
267
|
- Archive is searchable - you can still `grep` or find files in archive/
|
|
298
|
-
- Regular archiving
|
|
299
|
-
-
|
|
268
|
+
- Regular archiving keeps `.clavix/outputs/` organized
|
|
269
|
+
- Check `.clavix/outputs/archive/` to see what's been archived
|
|
300
270
|
|
|
301
271
|
## Troubleshooting
|
|
302
272
|
|
|
303
273
|
### Issue: No projects available to archive
|
|
304
274
|
**Cause**: No projects in `.clavix/outputs/` OR all already archived
|
|
305
275
|
|
|
306
|
-
**
|
|
307
|
-
1.
|
|
276
|
+
**How I handle it**:
|
|
277
|
+
1. Read `.clavix/outputs/` directory
|
|
308
278
|
2. If directory doesn't exist: "No PRD projects found. Create one with `/clavix:prd`"
|
|
309
|
-
3. If empty:
|
|
279
|
+
3. If empty: Check `.clavix/outputs/archive/` for archived projects
|
|
310
280
|
4. Communicate: "All projects are already archived" or "No projects exist yet"
|
|
311
281
|
|
|
312
282
|
### Issue: Trying to archive project with incomplete tasks
|
|
313
283
|
**Cause**: User wants to archive but tasks aren't 100% done
|
|
314
284
|
|
|
315
|
-
**
|
|
316
|
-
1.
|
|
285
|
+
**How I handle it**:
|
|
286
|
+
1. I read tasks.md and count incomplete tasks
|
|
317
287
|
2. Ask user: "Project has X incomplete tasks. Do you want to:
|
|
318
288
|
- Complete tasks first with `/clavix:implement`
|
|
319
|
-
- Archive anyway
|
|
289
|
+
- Archive anyway (tasks remain incomplete but archived)
|
|
320
290
|
- Cancel archival"
|
|
321
|
-
3. If user confirms
|
|
322
|
-
4. If scope changed: Explain
|
|
291
|
+
3. If user confirms: I move the directory
|
|
292
|
+
4. If scope changed: Explain force archive is appropriate
|
|
323
293
|
|
|
324
294
|
### Issue: Cannot restore archived project (name conflict)
|
|
325
295
|
**Cause**: Project with same name already exists in active outputs
|
|
326
296
|
|
|
327
|
-
**
|
|
328
|
-
1.
|
|
297
|
+
**How I handle it**:
|
|
298
|
+
1. I detect the conflict when checking the target directory
|
|
329
299
|
2. Ask user which option:
|
|
330
300
|
- Archive the active project first, then restore old one
|
|
331
301
|
- Keep both (manual rename required)
|
|
@@ -335,62 +305,54 @@ Result: Project permanently deleted from .clavix/outputs/api-experiment-1/
|
|
|
335
305
|
### Issue: Unsure whether to delete or archive
|
|
336
306
|
**Cause**: User wants to clean up but uncertain about permanence
|
|
337
307
|
|
|
338
|
-
**
|
|
308
|
+
**How I handle it**:
|
|
339
309
|
1. Use decision tree to guide user:
|
|
340
|
-
```
|
|
341
|
-
Ask user questions:
|
|
342
310
|
- "Is this a failed experiment with no learning value?"
|
|
343
311
|
- "Might you need to reference this code later?"
|
|
344
312
|
- "Are you unsure if it's valuable?"
|
|
345
|
-
```
|
|
346
313
|
2. Default recommendation: **ARCHIVE** (safer, reversible)
|
|
347
314
|
3. Only suggest DELETE for: duplicates, failed experiments, test data with zero value
|
|
348
315
|
4. Remind: "Archive is free, disk space is cheap, regret is expensive"
|
|
349
316
|
|
|
350
|
-
### Issue:
|
|
317
|
+
### Issue: File operation fails
|
|
351
318
|
**Cause**: File system permissions, missing directory, or process error
|
|
352
319
|
|
|
353
|
-
**
|
|
354
|
-
1. Check error output
|
|
320
|
+
**How I handle it**:
|
|
321
|
+
1. Check error output
|
|
355
322
|
2. Common fixes:
|
|
356
323
|
- Check `.clavix/outputs/` exists and is writable
|
|
357
324
|
- Verify project name is correct (no typos)
|
|
358
325
|
- Check if another process is accessing the files
|
|
359
|
-
3.
|
|
360
|
-
4. If persistent: Inform user to check file permissions
|
|
326
|
+
3. Retry the operation or inform user about permissions
|
|
361
327
|
|
|
362
|
-
### Issue: Accidentally deleted project
|
|
363
|
-
**Cause**: User error
|
|
328
|
+
### Issue: Accidentally deleted project
|
|
329
|
+
**Cause**: User error
|
|
364
330
|
|
|
365
|
-
**
|
|
366
|
-
1. Acknowledge: "Project was permanently deleted
|
|
331
|
+
**How I handle it**:
|
|
332
|
+
1. Acknowledge: "Project was permanently deleted"
|
|
367
333
|
2. Check recovery options:
|
|
368
334
|
- "If code was committed to git, we can recover from git history"
|
|
369
335
|
- "Check if you have local backups"
|
|
370
336
|
- "Check if IDE has local history (VS Code, JetBrains)"
|
|
371
337
|
3. Prevention: "Going forward, use ARCHIVE by default. Only DELETE when absolutely certain."
|
|
372
|
-
4. No recovery possible from Clavix itself
|
|
373
338
|
|
|
374
339
|
### Issue: Archive directory getting too large
|
|
375
340
|
**Cause**: Many archived projects accumulating
|
|
376
341
|
|
|
377
|
-
**
|
|
342
|
+
**How I handle it**:
|
|
378
343
|
1. Explain: "Archive is designed to grow - this is normal behavior"
|
|
379
|
-
2. Archived projects don't affect
|
|
380
|
-
3. If user
|
|
381
|
-
-
|
|
344
|
+
2. Archived projects don't affect workflow performance
|
|
345
|
+
3. If user concerned:
|
|
346
|
+
- List archive contents
|
|
382
347
|
- Identify ancient/irrelevant projects
|
|
383
|
-
- Delete only truly obsolete ones
|
|
348
|
+
- Delete only truly obsolete ones
|
|
384
349
|
- Or suggest external backup for very old projects
|
|
385
350
|
|
|
386
351
|
### Issue: Archived project but forgot what it was about
|
|
387
352
|
**Cause**: No naming convention or time passed
|
|
388
353
|
|
|
389
|
-
**
|
|
390
|
-
1. Read the PRD
|
|
391
|
-
```bash
|
|
392
|
-
cat .clavix/outputs/archive/[project-name]/full-prd.md
|
|
393
|
-
```
|
|
354
|
+
**How I handle it**:
|
|
355
|
+
1. Read the PRD: `.clavix/outputs/archive/[project-name]/full-prd.md`
|
|
394
356
|
2. Summarize: Problem, Goal, Features from PRD
|
|
395
357
|
3. Suggest: Better naming conventions going forward
|
|
396
358
|
- Example: `2024-01-user-auth` (date-feature format)
|