agentleFS
alvaroofernaandezalvaroofernaandez/aval/skills/prs-pro/SKILL.md

prs-pro

Skill5 starsChanged 3 days agoMITView on GitHub

Write rich GitHub PR descriptions with Mermaid diagrams, commit breakdown, before/after and test plan. Use when asked to create, edit or document a PR ('PR bien documentada', 'prs-pro').

  • Commits and pushes

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

6 rules. About 0 are common, 5 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈5

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    ALWAYS include a commit-by-commit breakdown: when there are multiple commits

    line 44
  2. Very specific:

    Every diagram MUST use custom theming via %%{init}%%:

    line 70
  3. Distinctive:

    Use DIFFERENT color palettes per diagram:

    line 83
  4. Distinctive:

    Don't describe files — describe concerns:

    line 204
  5. Distinctive:

    Start with the architecture/flow diagram.

    line 211
  6. Distinctive:

    Before finalizing any PR description:

    line 240

≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Skill: prs-pro

When to Use

Activate this skill whenever the user mentions:

  • Creating or editing a PR description
  • Documenting a pull request with diagrams or detail
  • "PR bien documentada", "edita la PR", "documenta la PR"
  • "PR con diagramas", "PR completa", "PR pro", "prs-pro"
  • Any variation of "haz la PR", "abre un pull request", "update the PR body"

Philosophy: PRs Are Living Architecture Docs

A PR description is NOT a commit message. It's a living technical document that:

  • Tells the FULL story of WHY these changes were made
  • Gives a reviewer zero-context-needed understanding
  • Documents the before/after state for future reference
  • Shows the architectural impact of every decision
  • Provides a concrete, actionable test plan

Anyone reading the PR 6 months from now should understand the reasoning without the chat history.


Non-Negotiable Rules

  1. ALWAYS read the full diff first — git diff base...HEAD, git log --oneline
  2. ALWAYS include at least 3 Mermaid diagrams with colorful %%{init}%% themes
  3. ALWAYS include emojis in every section header
  4. ALWAYS explain the WHY — not just what changed, but why that decision was made
  5. ALWAYS document before/after state for complex changes
  6. ALWAYS include a commit-by-commit breakdown when there are multiple commits
  7. ALWAYS write the PR body via HEREDOC to preserve Mermaid + formatting
  8. ALWAYS include a matrix of changed files with role/impact
  9. NEVER create a bare PR with just a bullet list — that's not documentation
  10. NEVER guess intent — read the code, understand it, then explain it
  11. ALWAYS close the related issues with Closes #N at the bottom

Mermaid Diagram Requirements

Every PR MUST include diagrams from these categories:

TypeWhen to UseMermaid Type
Architecture overviewAlways for new modules/featuresflowchart TD or flowchart LR
Data flowWhen request/response chain changessequenceDiagram
Before/AfterWhen refactoring existing behaviorTwo flowchart side by side in same diagram
State machineWhen states/transitions involvedstateDiagram-v2
Module dependencyFor new modulesflowchart LR with subgraphs per layer
Decision treeFor guard/auth/routing logicflowchart TD
Timeline/GanttFor parallel/sequential operationsgantt
ER / Data modelFor new DB tables or schema changeserDiagram

Mermaid Styling Rules (MANDATORY — same as issue-creation-pro)

Every diagram MUST use custom theming via %%{init}%%:

%%{init: {'theme': 'base', 'themeVariables': {
  'primaryColor': '#COLOR',
  'primaryTextColor': '#COLOR',
  'primaryBorderColor': '#COLOR',
  'lineColor': '#COLOR',
  'secondaryColor': '#COLOR',
  'tertiaryColor': '#COLOR'
}}}%%

Use DIFFERENT color palettes per diagram:

PalettePrimarySecondaryLineUse For
Ocean#0ea5e9#f43f5e#a855f7Data flow, architecture
Sunset#f59e0b#8b5cf6#ec4899Root cause, decisions
Forest#10b981#3b82f6#f97316Happy path, new features
Royal#7c3aed#06b6d4#f59e0bModule maps, dependencies
Indigo#6366f1#14b8a6#f43f5eSequences, timelines
Cherry#e11d48#8b5cf6#22c55eError flows, bugs fixed

PR Description Structure

Full Template

## 🧨 Contexto y motivación

[1-2 párrafos. ¿Por qué existe este PR? ¿Qué problema resuelve o qué feature añade?
Cero contexto previo requerido — cualquier ingeniero debe entenderlo de aquí.]

---

## 📦 Bloque N — [Nombre descriptivo del bloque de cambios]

### 🔍 ¿Qué había antes / What was the state before?

[Describe the BEFORE state — what was missing, broken, or not implemented.
Use a code snippet, table, or bullet list as appropriate.]

### ✅ ¿Qué cambia / What changes?

[Describe the AFTER state in plain language. What works now that didn't before?]

### ⚙️ ¿Por qué esta decisión?

[The reasoning. If there were alternatives, mention why this approach was chosen.]

```mermaid
[Diagram showing the change — architecture, data flow, or before/after]

[Repeat Bloque section for each independent group of changes]


🏗️ Visión arquitectónica de los cambios

[High-level diagram showing how all the changed pieces fit together. Module graph, layer diagram, or system integration view.]

[Full architecture / module dependency diagram]

🔄 Flujo end-to-end

[Sequence diagram showing the full request-response chain from edge to DB, highlighting which layers were changed.]

sequenceDiagram
    ...

📊 Matriz de cambios por fichero

FicheroCapaTipo de cambioImpacto
path/to/file.tsDomain / Application / Infra / Presentation / FrontendNew / Modified / FixedBrief description

📝 Historial de commits

CommitTipoDescripción
abc1234featNuevo módulo dashboard — backend
def5678fixCorrección seed script

✅ Plan de testing

  • Test unitario / e2e: descripción exacta de qué comprobar
  • Curl / endpoint test: comandos concretos
  • Verificación frontend: ruta, acción, resultado esperado
  • Regresión: qué módulos no deben haber roto

🚀 Issues cerrados

Closes #N Closes #M


🤖 Generated with Claude Code


---

## Workflow Step-by-Step

### 1. Read everything first

```bash
git log --oneline [base]..HEAD        # all commits in this PR
git diff [base]...HEAD --stat         # files changed
git diff [base]...HEAD                # full diff

2. Group changes into logical blocks

Don't describe files — describe concerns:

  • "Bloque A — Nuevo módulo DashboardModule (backend)"
  • "Bloque B — Migración NotificationsButton a TanStack Query (frontend)"
  • "Bloque C — Seed script idempotente + URL sync bandeja"

3. Build diagrams before writing prose

Start with the architecture/flow diagram. The prose is just narration around the diagrams.

4. Write the body via HEREDOC

gh pr edit <number> --repo "OWNER/REPO" --body "$(cat <<'PR_EOF'
[FULL PR BODY]
PR_EOF
)"

Or for creation:

gh pr create --title "feat(scope): title" --body "$(cat <<'PR_EOF'
[FULL PR BODY]
PR_EOF
)"

5. Verify the PR renders correctly

gh pr view <number> --repo "OWNER/REPO"

Quality Checklist

Before finalizing any PR description:

  • Read full diff — no assumption about what changed
  • At least 3 Mermaid diagrams with different color palettes
  • All diagrams use %%{init}%% custom theming
  • Each logical block has its own section with WHY
  • Architecture overview diagram covers all changed modules
  • End-to-end sequence diagram for any API changes
  • File matrix table with layer + impact columns
  • Commit history table
  • Concrete test plan (commands/actions, not vague items)
  • Closes #N for all related issues
  • PR is self-contained — reviewer needs zero prior context

Anti-Patterns

  • ❌ Bullet list of files changed without explanation
  • ❌ "Added X, fixed Y, updated Z" with no WHY
  • ❌ Mermaid diagrams without %%{init}%% theming
  • ❌ All diagrams using the same color palette
  • ❌ Missing the before/after comparison for refactors
  • ❌ Vague test plan ("check that it works")
  • ❌ Missing issues closed at the bottom
  • ❌ Using --body inline for complex descriptions (use HEREDOC)
  • ❌ Single-paragraph descriptions for multi-module PRs
  • ❌ No file matrix — reviewer doesn't know what to focus on

Examples of Good vs Bad Sections

❌ Bad

## Changes
- Added dashboard module
- Fixed seed script
- URL sync in bandeja

✅ Good

## 🏗️ Bloque A — Nuevo módulo `DashboardModule` (backend)

### 🔍 ¿Qué había antes?
El frontend realizaba N llamadas paralelas a distintos endpoints para construir la vista del dashboard, aumentando la latencia y complejidad del cliente.

### ✅ ¿Qué cambia?
Un único `GET /api/internal/dashboard/kpi` agrega en `Promise.all` las queries de expedientes, consultas técnicas y validaciones HIL pendientes. Tiempo de respuesta < 500ms.

### ⚙️ ¿Por qué esta decisión?
Se eligió aggregation en backend en lugar de N fetches en cliente porque:
1. Reduce latencia total (paralelo en backend > paralelo en cliente con JWT overhead)
2. Centraliza la lógica de tenant isolation
3. Simplifica el frontend a una sola query

```mermaid
%%{init: {'theme': 'base', 'themeVariables': {'primaryColor': '#10b981', 'lineColor': '#3b82f6'}}}%%
flowchart LR
    FE["🖥️ DashboardPage"] -->|"GET /dashboard/kpi"| CTRL["DashboardController"]
    CTRL --> UC["GetDashboardKpiUseCase"]
    UC -->|"Promise.all"| A["ExpedienteRepo\n.getKpiSummary()"]
    UC --> B["TcRepo\n.getKpiSummary()"]
    UC --> C["ListPendingHil\nUseCase.execute()"]
    A & B & C -->|"< 500ms"| UC
    UC --> CTRL --> FE

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.