Agent skill
si
Execute structured TDD implementation following task documents. Use when starting, continuing, or resuming implementation of a task from tasks/ directory. Also handles addressing code review feedback.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/si-alexandrbasis-wythm-claude-workflo
SKILL.md
Start Implementation Command
PRIMARY OBJECTIVE
Implement features systematically with comprehensive tracking on feature branches.
Three modes of operation:
- Start — Begin implementation from scratch
- Continue — Resume in-progress implementation
- Address CR — Apply code review feedback
Before any work, determine which mode applies by reviewing the task document status and git history.
CONSTRAINTS
- Follow existing task document in
tasks/directory - Git writes require explicit user permission:
- Do NOT create commits, push branches, open PRs, merge, rebase, or otherwise modify git state unless the user explicitly approves it.
WORKFLOW STEPS
STEP 1: Task Validation
-
Ask user: "Which task to implement? Provide task name or path." If it was not provided
- List tasks in
tasks/if unclear
- List tasks in
-
Validate document:
- Confirm the task exists (either a single
.mdfile OR atasks/task-YYYY-MM-DD-slug/directory). - Confirm scope is unambiguous:
- Clear acceptance criteria
- Clear "done" definition (what must be true for completion)
- Confirm task status is appropriate (e.g., "Ready for Implementation" vs "Draft") and ask before proceeding if unclear.
- Confirm Linear issue exists and is referenced (ID/link).
- Confirm there is an implementation plan (even if small): impacted components + test plan.
- Confirm the task exists (either a single
STEP 2: Setup
Note: Skip this step when continuing implementation or addressing Code Review Results
Status Updates
- Update task status to "In Progress" with timestamp
- Create feature branch (name must follow repo convention):
feature/wyt-[ID]-[slug] - Update task document with branch name
- Permission gate: If any git operation is required (branch creation, commit, push), ask for explicit approval first.
STEP 3: Implementation
Parallelization (optional)
If you believe part of the work can be done safely in parallel, use the parallelization skill:
.claude/skills/parallelization/SKILL.md
Sequential Mode
Before Each Step:
- Announce: "Starting Step [N]: [Description]"
- Review requirements: Acceptance criteria, tests, artifacts
During Implementation (TDD Approach):
- Follow agreed Test Plan: Implement tests based on the Test Plan approved during task creation (Gate 2)
- TDD Red-Green-Refactor Cycle: Follow strict Test-Driven Development:
- RED: Write failing tests first according to approved test plan
- GREEN: Write minimal code to make tests pass
- REFACTOR: Clean up code while keeping tests green
- Implement tests by approved categories:
- Business Logic Tests: As/if defined in approved test plan
- State Transition Tests: As/if defined in approved test plan
- Error Handling Tests: As/if defined in approved test plan
- Integration Tests: As/if defined in approved test plan
- User Interaction Tests: As/if defined in approved test plan
- Testing tools:
- Prefer silent scripts in AI-agent mode (backend):
npm run test:silent,npm run test:unit:silent,npm run test:integration:silent,npm run test:e2e:silent - Local runs are fine with
npm run testwhen you need full output npm run test:ciwhen the Postgres-backed integration suite is requirednpm run test:db:start|migrate|stopscripts to spin up and tear down the Supabase-compatible test DB
- Prefer silent scripts in AI-agent mode (backend):
- TDD Verification: All tests from approved plan must pass before proceeding to next step
After Each Step:
-
Update the task document (REQUIRED - not just chat output):
- Mark the step checkbox as complete:
- [ ]→- [x] - Add Changelog entry describing what was done
- Update Tests field with command run + result
- If tests are defined in the Test Plan section, mark those checkboxes too
- Parallel mode note: when using parallel workers, workers should not edit shared task docs; apply/merge worker outputs first, then update the task doc once to avoid conflicts.
Example of updating a step in the task doc:
markdown- [x] Sub-step 3.1: Update CreateSessionUseCase logic - **Tests**: Test Suite 3 - PASS - **Changelog**: Injected WordGroupService, added validateGroupHasSufficientWords() method - Mark the step checkbox as complete:
-
Commit changes (permission gate):
- If the user has not explicitly approved git writes: ask for permission before any
gitcommand. - If approved and the step is complete: use conventional commits (optionally include scope) and include an issue reference when applicable:
git add [files] && git commit -m "feat|fix|refactor: [step summary]" -m "Refs: WYT-123"
- If the user has not explicitly approved git writes: ask for permission before any
Error Recovery
- Tests fail: Fix the failing code, re-run tests. Do NOT skip or delete failing tests.
- Quality gate fails: Read the Quality Gate Report, address each failure, re-run.
- Task document incomplete: Ask user to clarify missing criteria before proceeding.
STEP 4: Completion
Final Verification
- Run quality gates via agent:
- Use Task tool with subagent_type: "automated-quality-gate"
- Provide
task_path(absolute path totasks/task-YYYY-MM-DD-slug/) and currentbranch - Agent runs format/lint/types/tests/build and writes a Quality Gate Report in the task directory
Finalize Task Document
- Update status to "Ready for Review" with timestamp
- Verify all checkboxes are accurate
- Add implementation summary
STEP 5: Prepare for Code Review
-
Permission gate (required):
- Creating a PR and pushing branches requires explicit user approval for git writes.
- If approval is not given, stop and ask for permission before proceeding.
-
Validate task documentation:
- Use Task tool with subagent_type: "task-pm-validator"
- Provide the exact task document path (e.g.,
tasks/task-2025-01-15-feature-name.md)
-
Create PR + sync Linear (single path):
- Use Task tool with subagent_type: "create-pr-agent"
- Provide the exact task document path (e.g.,
tasks/task-2025-01-15-feature-name.md) - This agent handles PR creation and updates the task document with PR links. For Linear updates use the
cc-linearskill (.claude/skills/cc-linear/SKILL.md).
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?