Agent skill
pr-implement
Fork-based PR implementation with isolation check. Runs isolation check before starting work. Triggers: "implement PR", "implement contribution", "fork implementation", "code the PR".
Install this agent skill to your Project
npx add-skill https://github.com/boshu2/agentops/tree/main/skills/pr-implement
Metadata
Additional technical details for this skill
- tier
- contribute
- author
- AI Platform Team
- version
- 1.0.0
- internal
- NO
SKILL.md
PR Implement Skill
Fork-based implementation for open source contributions with mandatory isolation check.
Overview
Execute a contribution plan with fork isolation. Ensures PRs are clean and focused by running isolation checks before and during implementation.
Input: Plan artifact from $pr-plan or repo URL
When to Use:
- Implementing a planned OSS contribution
- Need isolation enforcement for clean PRs
- After completing
$pr-plan
When NOT to Use:
- Internal project work (use
$implement) - Haven't planned yet (run
$pr-planfirst)
Workflow
-1. Prior Work Check -> BLOCKING: Check for competing PRs
0. Input Discovery -> Find plan artifact or repo
1. Fork Setup -> Ensure fork exists and is current
2. Worktree Creation -> Create isolated worktree
3. Isolation Pre-Check -> BLOCK if mixed concerns
4. Implementation -> Execute plan
5. Isolation Post-Check -> BLOCK if scope creep
6. Commit Preparation -> Stage with proper commit type
7. Handoff -> Ready for $pr-prep
Phase -1: Prior Work Check (BLOCKING)
# Search for open PRs on this topic
gh pr list -R <owner/repo> --state open --search "<topic>" --limit 10
# Check target issue status
gh issue view <issue-number> -R <repo> --json state,assignees
| Finding | Action |
|---|---|
| Open PR exists | Coordinate or wait |
| Issue assigned | Coordinate or find alternative |
| No competing work | Proceed |
Phase 3: Isolation Pre-Check (BLOCKING)
# Commit type analysis
git log --oneline main..HEAD | sed 's/^[^ ]* //' | grep -oE '^[a-z]+(\([^)]+\))?:' | sort -u
# File theme analysis
git diff --name-only main..HEAD | cut -d'/' -f1-2 | sort -u
| Check | Pass Criteria |
|---|---|
| Single commit type | 0 or 1 prefix |
| Thematic files | All match plan scope |
| Branch fresh | Based on recent main |
DO NOT PROCEED IF PRE-CHECK FAILS.
Phase 4: Implementation
Guidelines
| Guideline | Why |
|---|---|
| Single concern | Each commit = one logical change |
| Match conventions | Follow project style exactly |
| Test incrementally | Run tests after each change |
Commit Convention
git commit -m "type(scope): brief description
Longer explanation if needed.
Related: #issue-number"
Phase 5: Isolation Post-Check (BLOCKING)
# Commit type analysis
git log --oneline main..HEAD | sed 's/^[^ ]* //' | grep -oE '^[a-z]+(\([^)]+\))?:' | sort -u
# Summary stats
git diff --stat main..HEAD
| Check | Pass Criteria |
|---|---|
| Single commit type | All commits share same prefix |
| Thematic files | All files relate to PR scope |
| Atomic scope | Can explain in one sentence |
Phase 7: Handoff
Implementation complete. Isolation checks passed.
Branch: origin/$BRANCH_NAME
Commits: N commits, +X/-Y lines
Next step: $pr-prep
Anti-Patterns
| DON'T | DO INSTEAD |
|---|---|
| Skip isolation pre-check | Run Phase 3 FIRST |
| Skip isolation post-check | Run Phase 5 before push |
| Mix concerns in commits | One type prefix per PR |
| Implement without plan | Run $pr-plan first |
Examples
Implement From Contribution Plan
User says: "Implement this external PR plan with isolation checks."
What happens:
- Run pre-checks for branch and scope isolation.
- Implement only in planned files/areas.
- Run post-checks and prepare handoff for PR prep.
Enforce Single-Concern Commit Set
User says: "Make sure this branch is still single-purpose before I prep the PR."
What happens:
- Inspect commit/file patterns against stated scope.
- Flag mixed concerns and suggest extraction steps.
- Produce a clean handoff to
$pr-prep.
Troubleshooting
| Problem | Cause | Solution |
|---|---|---|
| Isolation check fails | Unrelated changes on branch | Move unrelated edits to separate branch/PR |
| Commits mix concerns | Implementation drifted from plan | Re-split commits by concern and revalidate |
| Scope keeps expanding | Weak boundaries in plan | Re-anchor to Out of Scope and stop additional changes |
| Hard to hand off | Missing summary/test context | Add concise change summary and verification notes |
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
swarm
Spawn isolated Codex sub-agents for parallel task execution using the current runtime primitives. Triggers: "swarm", "spawn agents", "parallel work", "run in parallel", "parallel execution".
council
Multi-perspective review for Codex using the current sub-agent runtime. Triggers: "council", "get consensus", "multi-model review", "multi-perspective review", "council validate", "council brainstorm", "council research".
openai-docs
Use when the user asks how to build with OpenAI products or APIs and needs up-to-date official documentation with citations (for example: Codex, Responses API, Chat Completions, Apps SDK, Agents SDK, Realtime, model capabilities or limits); prioritize OpenAI docs MCP tools and restrict any fallback browsing to official OpenAI domains.
crank
Hands-free epic execution for Codex using wave-based sub-agents and lead-side validation. Triggers: "crank", "run epic", "execute epic", "run all tasks", "hands-free execution", "crank it".
pr-retro
Learn from PR outcomes. Analyzes accept/reject patterns and updates contribution lessons. Triggers: "pr retro", "learn from PR", "PR outcome", "why was PR rejected", "analyze PR feedback".
ratchet
Brownian Ratchet progress gates for RPI workflow. Check, record, verify. Triggers: "check gate", "verify progress", "ratchet status".
Didn't find tool you were looking for?