implement-step
What it does
Section titled “What it does”Takes a step number and implementation details, writes the code, validates the build, creates a git commit, and records provenance. This is the tool the AI calls most frequently — once per feature or change.
| Parameter | Type | Required | Description |
|---|---|---|---|
projectPath | string | No | Path to the project directory |
stepNumber | number | Yes | Which step from the plan to implement |
files | object | Yes | Map of file paths to file contents |
description | string | No | Human-readable description of the change |
What it does internally
Section titled “What it does internally”- Reads the current project state and plan
- Writes the provided files to disk
- Runs the build to validate (via
npm run build) - If the build succeeds, creates a git commit
- Updates the plan state to mark the step as complete
- Records provenance (which prompt/step created which files)
- If the build fails, the tool returns the build errors (parsed by
debug-buildlogic) and does not commit. - The AI is expected to fix build errors and retry.
- Each successful step is a git commit, so
undo-last-changecan revert it cleanly.