iikit-07-implement
Execute the implementation plan by coding each task from tasks.md — writes source files, runs tests, verifies assertion integrity, and validates output against constitutional principles. Use when ready to build a feature from a tasks.md plan, start coding against an Intent Integrity Kit implementation plan, develop from the task list, resume a partially completed implementation, or run the implement phase of the iikit workflow.
- License 许可
- MIT
- 最近更新
- 2026-10-12
- Stars
- ★ 1
- Forks
- 0
01 前言 Front Matter
- name
- iikit-07-implement
- license
- MIT
- metadata
- { "version": "1.6.4" }
- description
- Execute the implementation plan by coding each task from tasks.md — writes source files, runs tests, verifies assertion integrity, and validates output against constitutional principles. Use when ready to build a feature from a tasks.md plan, start coding against an Intent Integrity Kit implementation plan, develop from the task list, resume a partially completed implementation, or run the implement phase of the iikit workflow.
02 资源文件 34
- 参考文档references/constitution-loading.md1.5 KB
- 参考文档references/conversation-guide.md2.2 KB
- 参考文档references/formatting-guide.md3.9 KB
- 参考文档references/ignore-patterns.md1.2 KB
- 参考文档references/model-recommendations.md2.5 KB
- 参考文档references/parallel-execution.md7.8 KB
- 参考文档references/tessl-integration.md4.6 KB
- 脚本scripts/bash/check-prerequisites.sh29.2 KB
- 脚本scripts/bash/common.sh25.3 KB
- 脚本scripts/bash/generate-dashboard-safe.sh1.8 KB
- 脚本scripts/bash/next-step.sh14.3 KB
- 脚本scripts/bash/set-active-feature.sh3.2 KB
- 脚本scripts/bash/testify-tdd.sh23.7 KB
- 脚本scripts/bash/verify-step-quality.sh24.4 KB
- 脚本scripts/bash/verify-steps.sh13.1 KB
- 脚本scripts/bash/verify-test-execution.sh6.8 KB
- 脚本scripts/dashboard/public/index.html205.7 KB
- 脚本scripts/dashboard/src/analyze.js7.0 KB
- 脚本scripts/dashboard/src/board.js3.2 KB
- 脚本scripts/dashboard/src/bugs.js4.9 KB
- 脚本scripts/dashboard/src/checklist.js2.1 KB
- 脚本scripts/dashboard/src/generate-dashboard.js10.2 KB
- 脚本scripts/dashboard/src/integrity.js1.7 KB
- 脚本scripts/dashboard/src/parser.js43.5 KB
- 脚本scripts/dashboard/src/pipeline.js5.9 KB
- 脚本scripts/dashboard/src/planview.js9.4 KB
- 脚本scripts/dashboard/src/public/index.html205.1 KB
- 脚本scripts/dashboard/src/storymap.js1.4 KB
- 脚本scripts/dashboard/src/testify.js6.2 KB
- 脚本scripts/dashboard/template.js213.0 KB
- 脚本scripts/powershell/common.ps114.3 KB
- 脚本scripts/powershell/next-step.ps110.7 KB
- 脚本scripts/powershell/testify-tdd.ps122.1 KB
- 参考文档templates/plan-template.md3.3 KB
03 SKILL.md 正文
Intent Integrity Kit Implement
Execute the implementation plan by processing all tasks in tasks.md.
User Input
$ARGUMENTS
You MUST consider the user input before proceeding (if not empty).
Windows: Replace
bash …/iikit-core/scripts/bash/*.shwithpwsh …/iikit-core/scripts/powershell/*.ps1(same flags,-PascalCase).
Constitution Loading
Load constitution per constitution-loading.md (enforcement mode — extract rules, declare hard gate, validate before every file write).
Prerequisites Check
- Run:
bash .tessl/tiles/tessl-labs/intent-integrity-kit/skills/iikit-core/scripts/bash/check-prerequisites.sh --phase 07 --json - Parse for
FEATURE_DIRandAVAILABLE_DOCS. If missing tasks.md: ERROR. - If JSON contains
needs_selection: true: present thefeaturesarray as a numbered table (name and stage columns). Follow the options presentation pattern in conversation-guide.md. After user selects, run:
Then re-run the prerequisites check from step 1.bash .tessl/tiles/tessl-labs/intent-integrity-kit/skills/iikit-core/scripts/bash/set-active-feature.sh --json <selection>
Commit Strategy
Ask the user to choose a commit strategy before starting:
| Strategy | Description |
|---|---|
| A) Per-task (default) | One git commit per completed task. Clean, bisectable history mapping each commit to a task ID. |
| B) Batch | Commits per phase (Setup, Foundational, each User Story, Polish) — typically 4–6 commits. Faster; commits don't map 1:1 to task IDs. |
Default to A if user doesn't respond. Apply the chosen strategy throughout.
Pre-Implementation Validation
Bugfix detection: if every unchecked task has a T-B prefix, this is a bugfix-only run — relaxed gates below.
Standard mode: Verify artifact completeness (constitution, spec, plan, tasks, checklists), cross-artifact consistency (FR-XXX → tasks, tech stack → file paths), and checklist completion (all 100% or ask user). Report READY or BLOCKED.
Bugfix mode: Only require tasks.md (T-B tasks) and bugs.md (matching BUG-NNN). Skip spec/plan/checklist gates. BDD chain (§2.1–2.4) still applies if .feature files exist.
Dashboard
Suggest the user open the dashboard to watch implementation progress in real time:
Dashboard: file://$(pwd)/.specify/dashboard.html (resolve the path) — updates live as tasks complete
Execution Flow
1. Load Context
Read tasks.md + plan.md (standard) or tasks.md + bugs.md (bugfix). Optional: data-model.md, contracts/, research.md, quickstart.md, tests/features/.
2. TDD Support Check
If tests/features/ directory exists (contains .feature files), verify assertion integrity:
bash .tessl/tiles/tessl-labs/intent-integrity-kit/skills/iikit-core/scripts/bash/testify-tdd.sh comprehensive-check "FEATURE_DIR/tests/features" "CONSTITUTION.md"
Parse JSON response: PASS (proceed), BLOCKED (halt, show remediation), WARN (proceed with caution).
If TDD mandatory but tests/features/ missing or empty: ERROR with Run: /iikit-04-testify.
2.1 BDD Verification Chain Enforcement
When .feature files exist, apply this chain to each implementation task:
- Write step definitions in
tests/step_definitions/binding Gherkin steps to application calls. - RED phase: run BDD tests — they MUST fail. Confirms tests are meaningful.
- Write production code implementing the behavior.
- GREEN phase: run BDD tests — they MUST pass. Fix production code if they fail; never modify tests or
.featurefiles. - Verify BDD chain:
Parse JSON forbash .tessl/tiles/tessl-labs/intent-integrity-kit/skills/iikit-core/scripts/bash/verify-bdd.sh --json "FEATURE_DIR/tests/features" "FEATURE_DIR/plan.md" "FEATURE_DIR/tests/step_definitions" "<language>"steps.status(coverage) andquality.status(assertions). Both must bePASSbefore marking task complete. IfBLOCKED: fix the flagged step definitions.
2.2 Feature File Immutability
CRITICAL: .feature files MUST NOT be modified during implementation. They are generated by /iikit-04-testify and hash-locked. Only step definitions and production code may be modified. If a .feature file needs changes, re-run /iikit-04-testify.
2.3 Test Execution Enforcement
Tests MUST be run, not just written. Run immediately after writing (expect red); run again after implementing (expect green). Fix code, not tests. Never mark a test task [x] without execution output.
bash .tessl/tiles/tessl-labs/intent-integrity-kit/skills/iikit-core/scripts/bash/verify-test-execution.sh verify "FEATURE_DIR/tests/features" "$(cat test-output.log)"
Block on any status other than PASS.
2.4 Task Completion Gate
A task is NOT complete until:
verify-steps.shreturnsPASS(all steps defined)- BDD tests pass (GREEN phase confirmed)
verify-step-quality.shreturnsPASS(no empty/trivial assertions)
Do NOT mark [x] in tasks.md until all three gates pass.
3. Setup (Dependencies, Tiles, Scaffolding)
Before writing source code:
- Install dependencies from plan.md Technical Context (detect package manager, add runtime + dev deps, commit manifest + lockfile)
- Install Tessl tiles for each major dependency:
tessl search <pkg>thentessl install <tile>. Query tile docs before writing library code. See tessl-integration.md. - Scaffold project if needed. For existing directories, use force/overwrite flags. See ignore-patterns.md for gitignore patterns.
6. Parse and Execute Tasks
6.1 Task extraction: parse tasks.md for phase, completion status ([x] = skip), dependencies, [P] markers, [USn] labels. Build in-memory task graph.
6.2 Execution strategy — read parallel-execution.md BEFORE proceeding:
If tasks.md contains [P] markers, you MUST use the Task tool to dispatch parallel batches as concurrent subagents (one worker per task). Only fall back to sequential execution if the runtime has no subagent dispatch mechanism. Report mode per formatting-guide.md (Execution Mode Header).
6.3 Phase-by-phase:
- Collect eligible tasks (dependencies satisfied)
- Build parallel batches from [P] tasks with no mutual dependencies
- Dispatch — parallel: launch one
Tasktool subagent per[P]task in the batch; sequential: one at a time - Collect results, checkpoint
[x]in tasks.md per batch, then commit per chosen strategy (§6.6) - Repeat until phase complete
Cross-story parallelism: independent stories can run as parallel workstreams after Phase 2 (verify no shared file modifications).
6.4 Rules: install dependencies (§3) and Tessl tiles (§4) before writing code, query tiles before library code, tests before code if TDD, run tests after writing them, only orchestrator updates tasks.md.
6.5 Failure handling: let in-flight siblings finish, mark successes, report failures, halt phase. Constitutional violations in workers: worker stops, reports to orchestrator, treated as task failure.
6.6 Task Commits: Apply the user's chosen commit strategy.
Per-task (strategy A): After each task is marked [x], stage its changed files (git add specific files, NOT -A) and commit:
# Subject + trailers template
feat(<feature-id>): <task-id> <task description>
iikit-feature: <feature-id>
iikit-task: <task-id>
# Bugfix tasks use fix(…) instead of feat(…)
# <feature-id> = FEATURE_DIR with specs/ prefix and trailing / stripped (e.g. 001-user-auth)
# Skip if no files changed; for parallel batches commit each task individually after batch completes
Batch (strategy B): Write code continuously, mark tasks [x] as they complete, commit once per phase:
# Subject template
feat(<feature-id>): <phase-name>
# e.g. feat(001-user-auth): Phase 3 - User Story 1
# Stage all changed files for the phase at once
# Still mark each task [x] in tasks.md as it completes (for progress tracking)
For both strategies, regenerate the dashboard after commits:
bash .tessl/tiles/tessl-labs/intent-integrity-kit/skills/iikit-core/scripts/bash/generate-dashboard-safe.sh
7. Output Validation
Before writing ANY file: review against constitutional principles. On violation: STOP, explain, suggest alternative.
8. Progress Tracking
Report after each task/batch. Mark completed [x] in tasks.md. Halt on failure.
9. Post-Fix GitHub Integration (Bug Fix Tasks)
After completing bug fix tasks (tasks with T-B prefix pattern):
- Check if
FEATURE_DIR/bugs.mdexists - For each completed bug (all T-BNNN tasks for a BUG-NNN marked
[x]):- Read the
GitHub Issuefield from the bug's entry in bugs.md - If a GitHub issue is linked (e.g.,
#42):- Close via commit: include
Fixes #<number>in the last task's commit message (§6.6) - Post a comment: use
gh issue commentif available, otherwisecurlthe GitHub API (POST /repos/{owner}/{repo}/issues/{number}/comments). Comment content: root cause from bugs.md, completed fix tasks, and fix reference
- Close via commit: include
- If no GitHub issue is linked: skip silently
- Read the
10. Completion
All tasks [x], features validated against spec, test execution enforcement (§2.1) satisfied, Tessl usage reported.
Error Handling
Missing artifacts: STOP with run instructions. Constitution violations: STOP, explain, suggest alternative. Checklist incomplete: ask user. Task/parallel failure: report + halt (§6.5). Tests not run: STOP. Tests failing: fix code, re-run.
Dashboard & Next Steps
After all tasks are complete (or on halt), refresh the dashboard and compute the next step. The post-phase script handles both in a single call — it runs generate-dashboard-safe.sh to regenerate the HTML dashboard, then runs next-step.sh --phase 07 --json to determine the next workflow step based on feature completion state:
bash .tessl/tiles/tessl-labs/intent-integrity-kit/skills/iikit-core/scripts/bash/post-phase.sh --phase 07
Windows: pwsh .tessl/tiles/tessl-labs/intent-integrity-kit/skills/iikit-core/scripts/powershell/post-phase.ps1 -Phase 07
Note: implement handles its own git commits per the chosen strategy (§6.6), so post-phase is called without --commit-files.
Parse next_step from JSON:
- If
next_stepis/iikit-07-implement(feature incomplete): suggest resuming - If
next_stepis null (feature complete): congratulate, list alt_steps - Include
model_tierper model-recommendations.md
Push commits to remote if available: git push. If on a feature branch, offer to merge:
- A) Merge locally:
git checkout main && git merge <branch> - B) Create PR:
gh pr createif available, otherwise provide the GitHub URL - C) Skip: user will handle it
Implementation complete!
Next: [/clear → ] <next_step or "All tasks done!">
[- <alt_step> — <reason> (model: <tier>)]
- Dashboard: file://$(pwd)/.specify/dashboard.html
04 同仓库更多 Skills
swiss-design
Apply a Swiss International Style design system using Tailwind CSS. Use when asked to style a webpage, clean up a UI, apply a design system, make something look great, or when the user references Swiss design, grotesque fonts, Helvetica, grid systems, modernist typography, or 1960s/1950s design aesthetics. Implements IBM Plex Sans typography, stone color palette, opacity-based hierarchy, generous whitespace, and structured grid layouts.
karpathy-guidelines
Behavioral guidelines to reduce common LLM coding mistakes. Use when writing, reviewing, or refactoring code to avoid overcomplication, make surgical changes, surface assumptions, and define verifiable success criteria.
iikit-core
Initialize an IIKit (Intent Integrity Kit) project, check IIKit feature progress, select the active IIKit feature, and display the IIKit workflow command reference. Use when starting a new IIKit project, running IIKit init or setup, checking IIKit status, switching between IIKit features, looking up IIKit available commands and phases, or asking for help with the IIKit workflow.
iikit-clarify
Resolve ambiguities in any project artifact — auto-detects the most recent artifact (spec, plan, checklist, testify, tasks, or constitution), asks targeted questions with option tables, and writes answers back into the artifact's Clarifications section. Use when requirements are unclear, a plan has trade-off gaps, checklist thresholds feel wrong, test scenarios are imprecise, task dependencies seem off, or constitution principles are vague.
iikit-bugfix
Report a bug against an existing feature — creates a structured bugs.md record, generates fix tasks in tasks.md, and optionally imports from or creates GitHub issues. Use when fixing a bug, reporting a defect, importing a GitHub issue into the workflow, or triaging an error without running the full specification process.
iikit-08-taskstoissues
Convert tasks from tasks.md into GitHub Issues with labels and dependencies. Use when exporting work items to GitHub, setting up project boards, or assigning tasks to team members.