Package Exports
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@emb715/cdd) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
CDD Methodology
Context-Driven Development (CDD) methodology template with Claude commands
Overview
This package provides a shareable template for initializing Context-Driven Development (CDD) workflow in your projects. It includes:
- CDD folder structure - Example work items and metadata organization
- Claude commands - Slash commands for AI-assisted development workflow
Looking for the why behind these artefacts? See the methodology overview in What is CDD and the full set of influences in Inspiration & Resources.
What's Included
📁 CDD Folder Structure
The cdd/ folder contains:
.meta/- Methodology metadata and templates- Work item folders (e.g.,
0001-phase-02-metrics-dashboard/) - Example of how to organize context-driven work
🤖 Claude Commands
The .claude/commands/ folder includes:
cdd:create-work.md→/cdd:create-work- Create new work itemscdd:plan-work.md→/cdd:plan-work- Generate implementation plans from decisionscdd:save-session.md→/cdd:save-session- Document session progresscdd:complete-work.md→/cdd:complete-work- Mark work items complete with summariescdd:list-work.md→/cdd:list-work- List and filter work items
📊 Metrics System
The .meta/metrics/ folder provides automated productivity tracking:
Purpose: Quantify the impact of CDD on session efficiency and track evidence-based development metrics.
What's Tracked:
- Context reacquisition time (minutes spent recreating context at session start)
- Session duration (total work session length)
- Task completion rate (completed vs. planned tasks)
- Evidence items (artefacts attached per requirement)
How It Works:
- Session saves capture metrics - When you run
/cdd:save-session, frontmatter inDECISIONS.mdis automatically updated with session data - Scripts aggregate data - Run
node cdd/.meta/metrics/scripts/collect-metrics.jsto generate summaries from all work items - Dashboards consume summaries - The
/cdd:list-workcommand.
Files:
metrics/README.md- Full methodology, data templates, and automation guidemetrics/AI_AUTOMATION_GUIDE.md- When AI should run metrics scriptsmetrics/WORKFLOW_EXAMPLE.md- Step-by-step example of metrics capturemetrics/scripts/collect-metrics.js- Aggregates metrics from all work itemsmetrics/scripts/lib/frontmatter.js- Programmatic frontmatter managementmetrics-summary.json- Auto-generated dashboard data (empty skeleton in template)
AI Automation:
The AI assistant automatically runs metrics collection after each /cdd:save-session to keep dashboards up-to-date.
Evidence-Based Claims:
CDD tracks real productivity data so efficiency claims stay grounded in measurement rather than assumptions. See metrics/README.md for current findings.
Usage
Initialize your first work item:
- Use
/cdd:create-workor manually create folders following the pattern - Follow the CDD workflow documented in the main README
- Use
Customize for your needs:
- Adjust the
.meta/templates - Modify Claude commands as needed
- Add project-specific workflows
- Adjust the
With AI Assistants
When asking an AI to initialize CDD in your project, you can say:
Install the CDD methodology template using npx @cdd/installerOr for manual installation:
Copy the CDD template from packages/cdd/ to set up
the workflow with cdd/ folder and .claude/commands/Directory Structure
cdd/
├── cdd/ # Work items and metadata
│ ├── .meta/ # Methodology templates and system files
│ │ ├── metrics/ # Metrics system
│ │ │ ├── README.md # Full metrics methodology
│ │ │ ├── AI_AUTOMATION_GUIDE.md # When AI runs metrics scripts
│ │ │ ├── WORKFLOW_EXAMPLE.md # Step-by-step metrics example
│ │ │ └── scripts/ # Automation scripts
│ │ │ ├── collect-metrics.js
│ │ │ ├── lib/frontmatter.js
│ │ │ └── README.md
│ │ ├── metrics-summary.json # Auto-generated metrics dashboard
│ │ └── templates/ # Document templates
│ └── NNNN-work-item/ # Example work items
└── .claude/ # Claude commands
└── commands/ # Slash commands
├── cdd:create-work.md
├── cdd:plan-work.md
├── cdd:save-session.md
├── cdd:complete-work.md
└── cdd:list-work.md🔌 Optional Extensions
CDD can be enhanced with optional extensions:
CDD-RAG: Searchable Knowledge Base
Transform your CDD workspace into a searchable knowledge base with semantic search.
Features:
- 🔍 Semantic search across all work items
- 🤖 AI-powered answers from your documentation (optional)
- 📚 Discover similar solutions from past work
- 💰 Cost-effective (~$0.0006/query with AI)
- 🔒 Privacy-first (local indexing, optional cloud AI)
Install:
npx @emb715/cdd add ragLearn more: packages/cdd-rag/README.md
License
MIT