implement-story
БесплатноБез исполняемых скриптовНе проверенImplements a GitHub user story from planning through PR creation, with research, codebase analysis, and structured commits.
от stacklok★ 2 366 звёзд на GitHubОб этом скилле
Implement User Story
Takes a GitHub user story issue and produces well-organized PR(s) that reliably meet the acceptance criteria.
Arguments
The user provides a GitHub issue number or URL. Example:
/implement-story #4550
/implement-story https://github.com/stacklok/toolhive/issues/4550
Phase 1: Gather Context
1.1 Read the Issue
Fetch the issue body using GitHub tools. Extract:
- User story: The "As a / I want / so that" statement
- Acceptance criteria: The checkbox list — this is the contract
- Context links: RFC links, related issues, dependencies
- Out of scope: What NOT to do
1.2 Fetch RFC Context
If the issue links to an RFC (look for THV-XXXX references or links to toolhive-rfcs):
- Clone or locate the RFC repo locally (check
../toolhive-rfcs/first) - Read the full RFC document
- Extract design decisions relevant to this story — config shapes, algorithm details, error formats, key schemas, etc.
If no RFC is linked, skip this step.
1.3 Find Related Stories
Search for sibling stories that share context with this one. These inform how to factor the code for extensibility:
# Search by keywords from the issue title
gh search issues "<keywords>" --repo stacklok/toolhive --state open --limit 10
# Search for issues linking to the same RFC
gh search issues "THV-XXXX" --repo stacklok/toolhive --limit 10
For each related story, read its acceptance criteria. Ask:
- Will a future story need to extend a type, interface, or package I'm creating?
- Should I define an interface now that a sibling story will implement later?
- Are there naming conventions or patterns I should establish that siblings will follow?
Do not implement sibling stories. Design internal interfaces so they can be extended without refactoring, but do not add config fields, CRD types, or user-facing API surface for functionality that isn't implemented in this PR. Unused config confuses users and reviewers.
1.4 Research the Codebase
Use the Explore agent or direct search to understand:
- Where does this change fit? Identify the packages, files, and functions that need modification.
- What patterns exist? Find analogous features already implemented. For example, if adding a new middleware, study how existing middleware (auth, mcp-parser, authz) is registered and wired.
- What gets generated? Identify files that are auto-generated (CRD manifests, mocks, docs) so you know what to regenerate.
- What tests exist? Find the test patterns used for similar features (table-driven tests, testcontainers, Chainsaw E2E).
Document your findings before writing any code.
Phase 2: Plan the Work
2.1 Map AC to Changes
For each acceptance criterion, identify:
- Which files need to change
- Whether it's new code or a modification
- What tests verify it (unit, integration, or E2E)
2.2 Decide PR Strategy
Evaluate the total scope against the project's PR guidelines:
- < 10 files changed (excluding tests, generated code, docs)
- < 400 lines of code changed (excluding tests, generated code, docs)
If the story fits in one PR, use a single PR. If not, split into multiple PRs following these patterns:
- Foundation first: New types, interfaces, packages
- Wiring second: Integration into existing code (middleware chain, reconciler, CRD)
- Tests alongside: Each PR includes its own tests
- Generated code with its trigger: CRD type changes +
task operator-manifests operator-generateoutput in the same PR
2.3 Present the High-Level Plan
First, show the user a high-level plan covering PR boundaries and what each PR delivers. Do NOT include commit-level details yet — get alignment on the split first.
## Implementation Plan
**Story**: #XXXX — [title]
**PRs**: [1 or N]
### PR 1: [title]
- [what this PR introduces and why]
- **AC covered**: [which acceptance criteria]
### PR 2: [title] (if needed)
- [what this PR introduces and why]
- **AC covered**: [which acceptance criteria]
Wait for user approval on the PR split. Adjust if the user has feedback.
2.4 Plan Each PR in Detail
Once the user approves the high-level split, enter plan mode for the first PR. In plan mode, explore the codebase and design commit boundaries, file changes, and test strategy. Present the detailed plan for user approval before writing code.
For subsequent PRs, enter plan mode again once CI is green for the previous PR.
Phase 3: Implement
3.1 Create a Branch
git checkout -b <user>/<short-description> main
3.2 Write Code
Implement the changes from the plan. Follow these principles:
- Match existing patterns: Don't invent new conventions. Study the codebase and follow what's there.
- Design for siblings: If related stories will extend this code, use interfaces and clear extension points. But don't build speculative abstractions — just leave the door open.
- **Tests are no
Установить implement-story в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл implement-story?
Implements a GitHub user story from planning through PR creation, with research, codebase analysis, and structured commits.
Как установить скилл implement-story?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл implement-story запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
skill-creator
Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
от Anthropicdiscernment-nudge
After you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
от Anthropicdata-consolidate
Joins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
от Anthropicinspection-to-capa
Runs the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…
от Anthropic