dev-implementation
GitHub指导AI执行代码实现(Phase 5)及检查实施结果(Phase 7),遵循TDD原则,同步更新文档与代码,确保实现与设计一致。
Trigger Scenarios
Install
npx skills add codeaholicguy/ai-devkit --skill dev-implementation -g -y
SKILL.md
Frontmatter
{
"name": "dev-implementation",
"description": "AI DevKit · Implementation phase guidance for executing feature plans and checking implementation against design. Use when the user wants to implement planned tasks, update implementation docs, verify code matches design, or run dev-lifecycle phases 5 and 7."
}
Dev Implementation
Run implementation work for configured AI docs features. Before changing docs or code, propose the concrete plan for this phase and wait for user approval unless the user already approved the exact phase plan.
Phase Contract
- Run
npx ai-devkit@latest lintbefore phase work. - If working on a named feature, run
npx ai-devkit@latest lint --feature <name>. - Read requirements, design, planning, implementation, and testing docs before changes.
- Use the
tddskill while executing implementation tasks: write a failing test before production code, then make it pass. - Apply the
verifyskill before completing tasks or making implementation alignment claims. - Keep testing and implementation docs in lockstep with code. Do not defer all doc updates to final verification.
- If parent
dev-lifecycleestablished usable task tracing, emit phase, progress, next-step, blocker, and evidence events pertask.
Execute Plan
Use for Phase 5.
- Run
npx ai-devkit@latest lint --feature <name>and work through the planning doc path it validates. If manual path resolution is unavoidable, first resolve.ai-devkit.jsonpaths.docs, falling back todocs/ai. - Gather context: feature name, planning doc path, supporting docs, current branch, and current diff.
- Parse task lists and build an ordered queue by section.
- Present the task queue with status:
todo,in-progress,done,blocked. - For each task, show context, suggest relevant docs, and outline sub-steps from the design doc when useful.
- If task tracing is available, record current task progress and immediate next action per
task. - Reuse before writing: grep for existing utilities/functions before adding new ones. Reuse only if it fits cleanly.
- Subtract before adding: delete dead paths, redundant guards, stale tests, and one-caller wrappers when they are in task scope.
- Handle breaking changes carefully: update all in-repo callers atomically and delete the old internal API; for external/public/cross-service callers, add a new function and deprecate the old one.
- Model the domain when implementation friction repeats: replace synchronized flags, branch growth, or duplicated shape assumptions with the smallest domain structure that removes them.
- Generate a markdown tracking snippet after each status change.
- After each task, update the testing doc with completed scenarios, newly discovered scenarios, and invalidated scenarios. Update the implementation doc with changed files, decisions, design deviations, and edge cases handled.
- After each section, ask if new tasks were discovered.
- Summarize completed, in-progress, blocked, skipped, new tasks, task-tracing events emitted or why tracing was unavailable, and doc deltas.
Next: after completing any task, run dev-planning Phase 6. When all tasks are done, run Check Implementation, then dev-testing and dev-review.
Check Implementation
Use for Phase 7.
- Compare implementation against the configured design and requirements docs validated by
npx ai-devkit@latest lint --feature <name>. - Gather context: feature description, modified files, relevant design/requirements docs, constraints.
- Summarize design: key decisions, components, interfaces, data flows.
- Review file by file: verify design intent, note deviations, flag logic gaps, edge cases, security issues, and missing tests or doc updates.
- Treat repeated implementation friction as a redesign signal, not another patch, and return to design when the model no longer fits.
- Finalize the implementation doc. Verify it captures what shipped, fill gaps, and record follow-ups.
- Summarize alignment status, deviations with severity, missing pieces, concerns, and next steps.
Next: dev-testing, then dev-review. If major deviations exist, return to dev-design if design is wrong or Execute Plan if implementation is wrong.
Version History
-
c1f5930
Current 2026-08-27 13:23
优化设计与重构相关的指导说明
- d4caf56 2026-07-05 15:22


