pr-explainer
O que ela faz
Esta skill cria uma página web local que explica um pull request em linguagem simples. Ela cobre o que mudou, por que isso importa, como funciona e como foi testado, sem despejar o diff completo.
Quando usar
- ✓Quando você quer que os revisores entendam rapidamente um pull request complexo.
- ✓Quando uma grande mudança de código precisa de uma explicação guiada, e não de um diff bruto.
- ✓Quando você quer o problema, a mudança e a prova explicados em um só lugar.
Link da skill
https://github.com/mastra-ai/mastra/blob/main/.claude/skills/pr-explainer/SKILL.mdCopie e cole na sua IA (Claude, ChatGPT ou Cursor) pedindo para seguir as instruções.
Como usar
O jeito mais fácil: copie a mensagem e cole na sua IA. Ela lê a skill e segue as instruções.
Mensagem pronta para colar
Para Claude Code, Codex ou Cursor: rode na pasta do projeto e a skill fica instalada.
Baixe o SKILL.md e coloque na pasta de skills do seu agente.
Exemplo do que pedir para a IA
“Crie um guia de revisão em HTML para este pull request, para que meus revisores entendam a mudança em dez minutos.”
5 skills novas por semana. 1 minuto de leitura.
Como funciona
O agente lê o branch, os commits e os arquivos alterados e depois ordena a explicação do problema para o contexto do sistema, as principais mudanças e os resultados dos testes. Ele gera uma única página HTML com seções curtas, exemplos e diagramas.
Conteúdo técnico (SKILL.md original)
Texto original do autor, em inglês, direto do GitHub.
PR Explainer
Create a local, self-contained HTML page that teaches a reviewer the PR story: what changed, why it matters, how it works, how it fits into the system, and how it was verified.
Required workflow
Understand the PR before writing HTML
- Collect PR title/number, branch, link if available, base branch, commit range, changed files, and verification already performed.
- Inspect the current state with
git status --short. - Inspect recent commits with
git log --oneline -n 10. - Inspect scope with
git diff <base>...HEAD --statandgit diff <base>...HEAD. - If one commit carries the main change, inspect it with
git show --stat <commit>andgit show <commit>.
Find the explanation path
- Do not explain files in raw diff order.
- Teach the change in this order when possible:
- problem,
- system context,
- before/after data or control flow,
- key code changes,
- proof from tests/builds/manual checks,
- reviewer takeaway.
- Classify changed files as core behavior, plumbing/integration, tests, release metadata, or incidental noise.
- Highlight only files that help explain the PR.
Write for approachability
- Use plain language, short sections, concrete before/after examples, small focused snippets, diagrams, tables, and callouts.
- Explain the problem before implementation details.
- Define acronyms or package-specific terms before using them.
- Avoid dumping the full diff or assuming the reviewer already knows internal context.
Create a local self-contained HTML file
- Put generated files in
.pr-review/. - Use one HTML file containing all CSS and content.
- Do not commit
.pr-review/by default. - Prefer repo ignore rules or
.git/info/excludeso generated review pages stay out of commits.
- Put generated files in
Recommended HTML structure
Use this structure unless the PR clearly needs a different teaching order:
Hero
- PR number/title, one-sentence summary, branch/link/status.
- Small metrics: files changed, tests added, packages affected.
Problem
- Previous behavior.
- Why it was wrong, confusing, missing, or risky.
System Context
- Where the change sits in the product or architecture.
- Upstream callers, downstream behavior, and why this is the right layer.
- Behavior intentionally not changed.
Before/After Flow
- Visual old path vs. new path when the PR changes flow, state, ownership, permissions, request handling, data transformation, or component relationships.
Code Walkthrough
- Step-by-step explanation path.
- Focused diffs for important files only.
- Explain what each snippet accomplishes and why it is necessary.
Tests / Verification
- Tests added or updated.
- Commands run for tests, build, typecheck, lint, or manual verification.
- Known unrelated warnings or failures, if any.
Reviewer Takeaway
- The shortest useful mental model of the PR.
- What the reviewer should focus on while reviewing the actual diff.
Diagrams
Add diagrams when they reduce cognitive load. Prefer simple HTML/CSS diagrams over external dependencies.
Good diagram types:
- Request flow: Client → Server → Handler → Service → Result
- Before/after path: broken path vs. fixed path
- Ownership map: package/module responsibility boundaries
- Data transformation: input → normalized form → output
- State machine: pending → running → complete/error
Each diagram must answer: “What does this help the reviewer understand faster?”
Focused diff snippets
Show snippets along the explanation path, not giant patches. Each important snippet should include:
- file path,
- relevant added/removed lines only,
- visual styling for additions/removals,
- a short explanation,
- connection back to the PR story.
Use this pattern:
<div class="diff">
<div class="diff-title">packages/example/src/file.ts</div>
<pre>
<span class="del">- old behavior</span>
<span class="add">+ new behavior</span>
</pre>
</div>
A reviewer should understand the PR without opening GitHub, but the page should not replace the final full diff review.
Verification requirements
End with proof. Include exact commands when available, for example:
pnpm --filter @scope/package test path/to/test.ts -- --run
pnpm turbo build --filter ./packages/package
If verification was not run, say so clearly and list the recommended commands
Perguntas frequentes
Ela mostra todos os arquivos alterados?
Não. Ela destaca apenas os arquivos que ajudam a explicar a mudança e deixa de fora o ruído secundário.
Onde a página é salva?
Ela é salva como uma página local em uma pasta de revisão dentro do projeto.
O que ela precisa antes?
O branch do pull request e o histórico de commits, para que ela consiga ver as mudanças.
Detalhes
Descrição original do autor
Use when creating an approachable, self-contained HTML review aid for a pull request; explaining what changed, why it matters, how it works, and how it fits into the broader system; turning PR diffs, commits, tests, and architecture context into a local `.pr-review/` HTML page for reviewers; or helping reviewers understand complex code changes without dumping the full diff.
repo: mastra-ai/mastra
Popularidade
- Estrelas no GitHub
- 29 mil
- Posição no ranking
- #9362
- Licença
- —
- Atualizada em
- 02/11/2026
Comentários
- …
Mais skills deste repositório
debugging-difficult-bugs
29 milAjuda seu agente a depurar um bug difícil registrando o que o programa real faz em tempo de execução, em vez de adivinhar a partir apenas dos testes.
mastra-frontend
29 milAjuda seu agente a criar telas de aplicativo com o sistema de design do playground da Mastra, combinando seus componentes prontos em vez de estilizar do zero.
pr-splitter
29 milAjuda seu agente a dividir um pull request grande e confuso em pull requests menores e revisáveis, mantendo o trabalho original seguro.
ralph-plan
29 milAjuda seu agente a planejar um comando de tarefa focado e estruturado por meio de uma conversa curta, para que o trabalho tenha passos e verificações claros.
Skills parecidas
diffs
394 milPermite que seu agente gere um diff real e compartilhável das edições, como link de visualização ou arquivo de imagem, em vez de um resumo escrito à mão.
coding-agent
394 milAjuda seu agente a passar um trabalho grande de programação para o Codex, Claude Code ou OpenCode em segundo plano e acompanhar o andamento.
gh-issues
394 milAjuda seu agente a encontrar issues do GitHub, escolher quais resolver e abrir pull requests com correções, acompanhando os comentários de revisão.