| name | execute-task |
| description | Execute the next available implementation task from a PRD task folder. Use when Codex is asked to implement, execute, start, continue, or complete a task using tasks/prd-[feature-name]/prd.md, techspec.md, tasks.md, and individual task files, then mark the task complete after verification. |
Execute Task
Use this skill to identify the next available task, prepare the context, implement it, verify it, and mark it complete.
Required Workflow
-
Identify the task.
- Locate the relevant feature folder under
tasks/prd-[feature-name]/.
- Read
tasks.md and identify the next incomplete main task or the task explicitly requested by the user.
- Read the matching individual task file, such as
1_task.md.
-
Load task context.
- Read
prd.md, techspec.md, tasks.md, and the selected task file.
- Review dependencies on previous tasks and confirm whether prerequisite tasks are complete.
- Read applicable project rules under
.codex/rules/.
- Identify and load applicable project skills under
.codex/skills/ based on the technologies and work involved.
-
Research technical dependencies.
- Use Context7 MCP for documentation about involved languages, frameworks, libraries, APIs, and patterns when applicable.
- Prefer official documentation and existing project patterns.
-
Produce the required pre-implementation summary.
- Use
references/task-summary-template.md.
- Include task ID, task name, PRD context, Tech Spec requirements, dependencies, objectives, and risks.
-
Produce the approach plan.
- Use
references/approach-plan-template.md.
- Keep the plan concrete and ordered.
- Do not skip this step.
-
Implement the task.
- Start implementation immediately after the summary and approach plan.
- Follow the selected task file, Tech Spec, PRD, and project rules.
- Keep changes scoped to the selected task.
- Do not implement unrelated tasks or opportunistic refactors.
-
Verify the task.
- Run the relevant unit, integration, E2E, lint, typecheck, or build commands required by the task and project standards.
- If a required command cannot run, explain why and record the residual risk.
-
Mark completion.
- After implementation and verification, mark the completed task in
tasks.md.
- Update the individual task file if its checklist tracks completed subtasks.
- Report changed files, verification results, and any follow-up risks.
Hard Rules
- Do not skip reading the PRD, Tech Spec, tasks summary, and selected task file.
- Do not skip the task summary.
- Do not skip the approach plan.
- Start implementation after completing the required setup, summary, and plan.
- Use Context7 MCP for relevant technical documentation when the task involves frameworks, libraries, or APIs.
- Mark the task complete in
tasks.md only after implementation and verification.
Quality Checklist
- Next task or user-requested task was identified.
- PRD, Tech Spec,
tasks.md, and task file were reviewed.
- Applicable
.codex/rules/ and .codex/skills/ entries were checked.
- Relevant Context7 documentation was consulted when applicable.
- Task summary and approach plan were produced.
- Implementation was completed.
- Relevant verification commands were run or documented as blocked.
- Completed task was marked in
tasks.md.