sdd-system
Use Cautionnpx machina-cli add skill leoheart0125/sdd-skills/sdd-system --openclawSDD System
This skill is the entry point for the Compounding Engineering framework. It handles initialization, feature lifecycle management, and global status.
Core Responsibilities
- Project Initialization: Setup
.sdd/directory,project_rules.md, and Knowledge Base directories. - Feature Lifecycle: Manage features from creation through request → design → plan → impl → complete → learn.
- Global Status: Display the "Big Picture" (Current Stage + Active Feature + Velocity + Knowledge Stats).
- Coordination: Verify
.sdd/directory structure integrity (all required subdirectories andcontext.jsonexist and are well-formed).
Commands
/sdd-init [project principles]: Initialize a new Compounding Engineering project. Optional args define the project's guiding principles (e.g.,/sdd-init product should be testable, high-quality and implement by MVP never overdesign)./sdd-status: Display current project health, active stage, active feature, and recent lessons learned./sdd-nuke: (Dangerous) Reset internal state but keep learned patterns and lessons.
Initialization Logic
When /sdd-init is called:
- Check for
.sdd/directory. - Create full directory structure:
context/—context.json,project_rules.mdspec/— Feature-scoped spec subdirectoriesplan/— Feature-scoped plan subdirectoriesfeatures/— Feature snapshot archive (spec + plan per feature)knowledge/index.json— Lightweight knowledge index (initialize as{ "patterns": {}, "lessons": {} })knowledge/patterns/— Reusable design/code patternsknowledge/lessons/— Lessons learned from past workdata/,logs/,temp/
- Generate initial
context.jsonfrom template (includescurrent_stage,current_feature,feature_counter: "001", etc.). JSON Writing Rule: All string values MUST have special characters properly escaped (\",\\,\n,\t, control chars). Validate JSON is well-formed before writing to disk. - Generate initial
project_rules.mdtemplate. - If user provided args: Incorporate them as the "General Principles" section in
project_rules.md. These principles guide all downstream design and implementation decisions. - Report: "Project initialized. Ready for
/sdd-request."
Feature Lifecycle
Each feature follows this lifecycle, tracked via context.json.current_stage:
init → request → request-complete → design → design-complete → plan → plan-complete → impl → impl-complete
Starting a Feature
Executed by
sdd-request-engine— seesdd-request-engine/SKILL.mdStep 2 for the canonical implementation.
- User provides feature name/intent via
/sdd-request. sdd-request-enginereadscontext.json.feature_counter, generates the feature ID, creates directories, and setscurrent_stageto"request".
Completing a Feature
- All tasks in
tasks.jsonreach"done"or"verified"status. /sdd-impl-finishtriggers mandatory knowledge extraction (reads.sdd/logs/session.mdfor cross-session history).- MOVE (not copy)
.sdd/spec/<feature-id>/and.sdd/plan/<feature-id>/into.sdd/features/<feature-id>/. - Move feature ID from
current_featuretocompleted_features. - Reset
current_stageto"init"andcurrent_featuretonull. - Clear
.sdd/logs/session.md.
Status Display
When /sdd-status is called, display:
- Active Feature:
context.json.current_feature(or "None") - Current Stage:
context.json.current_stage - Completed Features: Count of
context.json.completed_features - Knowledge Stats: Number of patterns in
knowledge/patterns/, lessons inknowledge/lessons/ - Active Patterns:
context.json.active_patterns - Applied Lessons:
context.json.applied_lessons
Integration
- Consumes:
sdd-knowledge-base(for status and knowledge stats). - Directs: Users to
/sdd-designor/sdd-planbased oncurrent_stage.
Source
git clone https://github.com/leoheart0125/sdd-skills/blob/main/skills/sdd-system/SKILL.mdView on GitHub Overview
SDD System is the entry point of the Compounding Engineering framework. It initializes projects, manages feature lifecycles from creation to learn, and presents a global status view including current stage, active feature, velocity, and knowledge stats. It also validates the .sdd/ directory structure to maintain project coherence.
How This Skill Works
On /sdd-init, it creates the .sdd/ directory with a full structure (context/, spec/, plan/, features/, knowledge/index.json, knowledge/patterns/, knowledge/lessons/, data/, logs/, temp/) and generates context.json and project_rules.md. The system tracks state in context.json (current_stage, current_feature, feature_counter) and enforces the feature lifecycle (init → request → request-complete → design → design-complete → plan → plan-complete → impl → impl-complete). Commands like /sdd-status and /sdd-nuke operate against this state, and completed features are moved into .sdd/features with proper state resets.
When to Use It
- Starting a new Compounding Engineering project with a clear framework and governance
- Tracking a feature from initial request through design, planning, implementation, and learnings
- Monitoring project health, progress, and knowledge stats via the global status
- Verifying the integrity of the .sdd/ directory structure and context.json consistency
- Resetting internal state carefully when needed, while preserving learned patterns and lessons
Quick Start
- Step 1: /sdd-init [optional principles] to initialize the project and create the .sdd/ structure
- Step 2: Use /sdd-request to introduce a new feature and drive it through the lifecycle
- Step 3: Periodically run /sdd-status to monitor current_stage, active feature, and lessons learned
Best Practices
- Run /sdd-init with optional general principles to seed the project_rules.md for downstream decisions
- Keep context.json well-formed and ensure feature_counter increments correctly for new features
- Regularly check /sdd-status to surface current_stage, active feature, and lessons learned
- Avoid using /sdd-nuke in production unless you intend to reset state and preserve history
- Organize knowledge by maintaining patterns and lessons under knowledge/ for reusability
Example Use Cases
- Kick off a new project: user runs /sdd-init and adds guiding principles, triggering directory creation and context.json setup
- Propose a feature with /sdd-request, which the sdd-request-engine converts into a new feature in the lifecycle
- Complete design and plan phases, then run /sdd-impl-finish to extract knowledge and move spec/plan into features
- Review project health via /sdd-status to see current stage, active feature, and knowledge stats
- Safely reset internal state with /sdd-nuke after saving lessons to ensure lessons and patterns persist