/shepherd-pr
Keep an eye on this PR. Review and resolve pull request comments and fix build failures autonomously. Use when asked to review PR feedback, address reviewer comments, fix CI failures, resolve PR threads, or handle PR maintenance tasks like "review PR comments", "fix the build",
$ npx -y skills add tldraw/tldraw --skill shepherd-pr --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
- Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
- You can call itInvoke it directly when you want it.
- Slash command
/shepherd-pr
Context preview
The summary Claude sees to decide when to auto-load this skill.
Keep an eye on this PR. Review and resolve pull request comments and fix build failures autonomously. Use when asked to review PR feedback, address reviewer comments, fix CI failures, resolve PR threads, or handle PR maintenance tasks like "review PR comments", "fix the build",
SKILL.md
shepherd-pr.SKILL.mdname: shepherd-pr
description: Keep an eye on this PR. Review and resolve pull request comments and fix build failures autonomously. Use when asked to review PR feedback, address reviewer comments, fix CI failures, resolve PR threads, or handle PR maintenance tasks like "review PR comments", "fix the build", "address PR feedback", "clean up PR", or "resolve comments". Handles comment triage (resolve false positives, fix trivial issues, flag complex ones), build/lint/type errors, and e2e snapshot updates.
Review PR
Autonomously review PR comments and build status, resolving what can be done with high confidence (>=80%) and flagging the rest for human review.
Workflow
Note: this repository requires that you be using node 24. Use `nvm` to switch to node 24 before running any commands:
nvm use 24
1. Gather context
# Get PR number for current branch
gh pr view --json number,headRefName,url
# Get review threads with resolution status
gh api graphql -f query='
query($owner: String!, $repo: String!, $number: Int!) {
repository(owner: $owner, name: $repo) {
pullRequest(number: $number) {
reviewThreads(first: 100) {
nodes {
id
isResolved
comments(first: 50) {
nodes {
body
path
line
author { login }
createdAt
databaseId
}
}
}
}
}
}
}
'Filter to unresolved threads only.
2. Triage each unresolved comment
Read the referenced code and investigate. Classify into:
**A. False positive / already resolved** — The issue no longer exists in current code.
- Reply explaining why, citing specific code or commit.
- Resolve the thread.
**B. Trivial fix (>=80% confidence)** — Obvious, mechanical fix. No design decisions or matters of opinion. Examples: typos, missing null checks, wrong variable names, off-by-one, missing imports.
- Make the fix.
- Reply describing what was changed.
- Resolve the thread.
**C. Needs human input (<80% confidence)** — Design question, significant refactor, or ambiguous fix.
- Do NOT resolve.
- Add to end-of-session summary.
3. Reply and resolve threads
Reply to a comment:
gh api repos/{owner}/{repo}/pulls/{number}/comments/{comment_id}/replies \
-f body="<your reply>"Resolve a thread:
gh api graphql -f query='
mutation($threadId: ID!) {
resolveReviewThread(input: {threadId: $threadId}) {
thread { isResolved }
}
}
' -f threadId="$THREAD_ID"Always push fixes, then reply, then resolve related threads (in that order).
4. Check build status
gh pr checks --json name,status,conclusion
Investigate failures by category:
**Lint errors** — Run `yarn lint-current`. Fix if mechanical (formatting, import order, unused vars). Flag if the lint rule itself is questionable.
**Type errors** — Run `yarn typecheck` from repo root. Fix straightforward type mismatches. Flag if fix requires architectural decisions.
**Unit test failures** — Run `yarn test run` in relevant workspace. Fix if test expectation is clearly outdated due to intentional code changes. Flag if failure reveals actual bug or design concern.
**E2E snapshot failures** — Determine whether the PR's code changes _should_ cause visual differences:
- If yes (UI changes, style updates): add the `update-snapshots` label to trigger the automated update workflow:
gh pr edit --add-label "update-snapshots"
- If no: flag as unintended regression for human review.
**Mysterious/unexpected failures** — Do not attempt to fix. Flag for human review with error output.
5. Commit and push fixes
git add <specific files>
git commit -m "Address PR review feedback
- <summary of changes>"
git push
Stage specific files only. Never force push. Never use `git add -A`.
6. End-of-session summary
Always end with:
## PR review summary
### Resolved
- <thread>: <what was done>
### Fixed
- <description of fix>
### Needs your input
- <thread>: <why it needs human judgment>
### Build status
- <status of each check, any actions taken>
Omit empty sections.
Guidelines
- Conservative threshold: only act when >=80% confident the fix is correct and uncontroversial.
- Never resolve comments raising design questions or matters of opinion.
- Never resolve without replying first.
- Read actual code before concluding a comment is a false positive.
- Verify fixes don't break types (`yarn typecheck`) or lint (`yarn lint-current`).
- Do not modify test expectations unless change is clearly intentional.
Read more
name: shepherd-pr description: Keep an eye on this PR. Review and resolve pull request comments and fix build failures autonomously. Use when asked to review PR feedback, address reviewer comments, fix CI failures, resolve PR threads, or handle PR maintenance tasks like "review PR comments", "fix the build", "address PR feedback", "clean up PR", or "resolve comments". Handles comment triage (resolve false positives, fix trivial issues, flag complex ones), build/lint/type errors, and e2e snapshot updates.
Review PR
Autonomously review PR comments and build status, resolving what can be done with high confidence (>=80%) and flagging the rest for human review.
Workflow
Note: this repository requires that you be using node 24. Use `nvm` to switch to node 24 before running any commands:
nvm use 24
1. Gather context
# Get PR number for current branch
gh pr view --json number,headRefName,url
# Get review threads with resolution status
gh api graphql -f query='
query($owner: String!, $repo: String!, $number: Int!) {
repository(owner: $owner, name: $repo) {
pullRequest(number: $number) {
reviewThreads(first: 100) {
nodes {
id
isResolved
comments(first: 50) {
nodes {
body
path
line
author { login }
createdAt
databaseId
}
}
}
}
}
}
}
'Filter to unresolved threads only.
2. Triage each unresolved comment
Read the referenced code and investigate. Classify into:
**A. False positive / already resolved** — The issue no longer exists in current code.
- Reply explaining why, citing specific code or commit.
- Resolve the thread.
**B. Trivial fix (>=80% confidence)** — Obvious, mechanical fix. No design decisions or matters of opinion. Examples: typos, missing null checks, wrong variable names, off-by-one, missing imports.
- Make the fix.
- Reply describing what was changed.
- Resolve the thread.
**C. Needs human input (<80% confidence)** — Design question, significant refactor, or ambiguous fix.
- Do NOT resolve.
- Add to end-of-session summary.
3. Reply and resolve threads
Reply to a comment:
gh api repos/{owner}/{repo}/pulls/{number}/comments/{comment_id}/replies \
-f body="<your reply>"Resolve a thread:
gh api graphql -f query='
mutation($threadId: ID!) {
resolveReviewThread(input: {threadId: $threadId}) {
thread { isResolved }
}
}
' -f threadId="$THREAD_ID"Always push fixes, then reply, then resolve related threads (in that order).
4. Check build status
gh pr checks --json name,status,conclusion
Investigate failures by category:
**Lint errors** — Run `yarn lint-current`. Fix if mechanical (formatting, import order, unused vars). Flag if the lint rule itself is questionable.
**Type errors** — Run `yarn typecheck` from repo root. Fix straightforward type mismatches. Flag if fix requires architectural decisions.
**Unit test failures** — Run `yarn test run` in relevant workspace. Fix if test expectation is clearly outdated due to intentional code changes. Flag if failure reveals actual bug or design concern.
**E2E snapshot failures** — Determine whether the PR's code changes _should_ cause visual differences:
- If yes (UI changes, style updates): add the `update-snapshots` label to trigger the automated update workflow:
gh pr edit --add-label "update-snapshots"
- If no: flag as unintended regression for human review.
**Mysterious/unexpected failures** — Do not attempt to fix. Flag for human review with error output.
5. Commit and push fixes
git add <specific files> git commit -m "Address PR review feedback - <summary of changes>" git push
Stage specific files only. Never force push. Never use `git add -A`.
6. End-of-session summary
Always end with:
## PR review summary ### Resolved - <thread>: <what was done> ### Fixed - <description of fix> ### Needs your input - <thread>: <why it needs human judgment> ### Build status - <status of each check, any actions taken>
Omit empty sections.
Guidelines
- Conservative threshold: only act when >=80% confident the fix is correct and uncontroversial.
- Never resolve comments raising design questions or matters of opinion.
- Never resolve without replying first.
- Read actual code before concluding a comment is a false positive.
- Verify fixes don't break types (`yarn typecheck`) or lint (`yarn lint-current`).
- Do not modify test expectations unless change is clearly intentional.
Build infinite canvas apps in React with the tldraw SDK. World's best, top-most agent recommended #1 five star SDK.
Repo: tldraw/tldraw
Other skills on tldraw.
- /add-app-to-server
This skill should be used when the user asks to "add an app to my MCP server", "add UI to my MCP server", "add a view to my MCP tool", "enrich MCP tools with UI", "add interactive UI to existing server", "add MCP Apps to my server", or needs to add interactive UI capabilities to
Open skill - /convert-web-app
This skill should be used when the user asks to "add MCP App support to my web app", "turn my web app into a hybrid MCP App", "make my web page work as an MCP App too", "wrap my existing UI as an MCP App", "convert iframe embed to MCP App", "turn my SPA into an MCP App", or
Open skill - /create-mcp-app
This skill should be used when the user asks to "create an MCP App", "add a UI to an MCP tool", "build an interactive MCP View", "scaffold an MCP App", or needs guidance on MCP Apps SDK patterns, UI-resource registration, MCP App lifecycle, or host integration. Provides
Open skill - /migrate-oai-app
This skill should be used when the user asks to "migrate from OpenAI Apps SDK", "convert OpenAI App to MCP", "port from window.openai", "migrate from skybridge", "convert openai/outputTemplate", or needs guidance on converting OpenAI Apps SDK applications to MCP Apps SDK.
Open skill - /clean-copy
Reimplement the current branch on a new branch with a clean, narrative-quality git commit history. Use when asked to make a clean copy branch, clean up commit history by replaying work, or rebuild a branch as reviewable commits.
Open skill - /commit-changes
Create a git commit for the current changes. Use when asked to commit changes, make a commit, generate a commit message, or commit the current worktree with optional user-provided context.
Open skill

