CoDD Init
Initialize CoDD in the current project, then move immediately into the first scan and validation cycle so the dependency graph starts from a clean baseline.
Usage
Run this skill when a repository does not have a codd/ directory yet and you need to bootstrap CoDD with the official codd CLI entry point.
Instructions
Preflight before running
codd init:- Work from the project root where
codd/should be created. - If
codd/already exists, do not re-run init. Inspect the existing CoDD setup instead. - If the
coddcommand is not available, install the package so the console script is onPATHbefore continuing.
- Work from the project root where
Collect the required inputs:
- Project name: default to the current directory name unless the user provides a better product name.
- Primary language: choose one of
python,typescript,java, orgo. - Requirements file (optional): if the user already has a requirements document (any format —
.txt,.md,.doc), use--requirementsto import it. CoDD adds frontmatter automatically.
Choose the command:
- With existing requirements file (recommended):
codd init --project-name "<project-name>" --language <language> --requirements <path-to-requirements> --dest .
- Without requirements (user will add them later):
codd init --project-name "<project-name>" --language <language> --dest .
Run the selected
codd initcommand.Confirm the generated skeleton:
codd/codd.yamlcodd/scan/codd/reports/codd/.gitignore.codd_version
For an existing project, handle the bootstrap carefully:
- Do not assume old design docs already have CoDD frontmatter. Inspect them before the first scan.
- Prefer adding frontmatter to the documents you want CoDD to track before treating scan results as authoritative.
- Legacy annotation files under
codd/annotations/are optional and backward-compatible. Create them only if the project still uses that workflow.
Next steps immediately after init — choose greenfield or brownfield:
Greenfield (have requirements, no code yet)
- If you used
--requirements, the requirements document is already indocs/requirements/requirements.mdwith CoDD frontmatter. Skip to step 2. If you did NOT use--requirements, write a requirements document (plain text is fine) and import it into the existing project:
- If you used
codd init --project-name "<project-name>" --language "<language>" \
--requirements <path-to-requirements> --dest .
This works even when `codd/` already exists — it only imports the file and adds frontmatter.
Or manually create `docs/requirements/requirements.md` with frontmatter (`node_id` and `type: requirement`).
- Run
codd generateto auto-generate wave_config and design docs:
codd generate --wave 2 --path .
- Scan to build the dependency graph:
codd scan --path .
- Validate the graph inputs:
codd validate --path .
- If validation passes, continue the normal operating cycle:
codd scan --path .
codd impact --path .
Brownfield (have existing code, no requirements)
- Extract code structure:
codd extract
- Generate wave_config from extracted docs (
plan --initauto-detects brownfield):
codd plan --init
- Restore design docs from extracted facts (use
/codd-restoreskill or CLI):
codd restore --wave 0 --path . # Infer requirements from code
codd restore --wave 2 --path . # Reconstruct system design
- Scan and validate:
codd scan --path .
codd validate --path .
- Continue with the normal operating cycle:
codd impact --path .
- Report back with:
- Which language option was used
- Whether init created the skeleton successfully
- Which documents were prepared for the first scan
- Whether
codd validate --path .passed or which issues remain