Saltar al contenido
Skillpedia
Programación general41 mil · #7010

minimal-code-discipline

Qué hace

Esta skill guía a un agente para que mantenga los cambios de código lo más pequeños posible sin perder corrección. Está pensada para personas que quieren cambios concentrados, sin relleno ni extras especulativos.

Cuándo usarla

  • ✓Cuando pides un cambio mínimo, ligero o lo más pequeño posible.
  • ✓Cuando un plan o un cambio crece más de lo que se pidió.
  • ✓Cuando quieres revisar un cambio propuesto por si tiene un tamaño innecesario antes de construirlo.

Link de la skill

https://github.com/Yeachan-Heo/oh-my-claudecode/blob/main/skills/minimal-code-discipline/SKILL.md

Cópialo y pégalo en tu IA (Claude, ChatGPT o Cursor) pidiéndole que siga las instrucciones.

Cómo usar

La forma más fácil: copia el mensaje y pégalo en tu IA. Ella lee la skill y sigue las instrucciones.

Mensaje listo para pegar

Usa esta skill para ayudarme: https://github.com/Yeachan-Heo/oh-my-claudecode/blob/main/skills/minimal-code-discipline/SKILL.md Lee el archivo SKILL.md de ese link y sigue sus instrucciones en mi tarea.
¿Quieres que tu IA encuentre skills como esta por sí sola?Instala el MCP gratis de Skillpedia: una línea, y busca entre 15.000+ skills antes de cada tarea.Instalar en 1 minuto →

Ejemplo de qué pedirle a la IA

“Añade un botón sencillo de exportación a la página de informes. Mantén el cambio lo más pequeño posible y reutiliza lo que ya tenemos.”

5 skills nuevas por semana. 1 minuto de lectura.

Cómo funciona

El agente primero pregunta si el cambio es necesario, busca en el código base ayudantes ya existentes y prefiere la herramienta más sencilla que haga el trabajo. Mantiene el cambio corto sin quitar las comprobaciones de seguridad.

Contenido técnico (SKILL.md original)

Texto original del autor, en inglés, directo de GitHub.

Minimal Code Discipline

Use this skill to apply a minimal-code (YAGNI-ladder) discipline while planning and writing code changes. It keeps diffs small and obviously correct without sacrificing the checks that keep users safe.

This skill complements ai-slop-cleaner: that skill cleans slop after it lands; this one keeps it from being written.

When to Use

Use this skill when:

  • the user asks for a minimal, lean, YAGNI, or smallest-possible-diff implementation
  • a plan or in-flight change is growing beyond the stated request
  • writing new code where scope creep, reinvented helpers, or speculative generality are likely
  • reviewing a proposed diff for size before implementation

When Not to Use

Do not use this skill when:

  • the user explicitly asks for a broad, feature-rich, or future-proofed build (their explicit scope wins)
  • the task is exploratory scaffolding the user has marked as throwaway
  • minimization pressure would touch protected behavior (see Non-Negotiables)

The Discipline

Existence first. Ask whether the change needs to exist at all; skip work that serves only a speculative future need.

Reuse before writing. Search the codebase for an existing helper, type, or pattern before writing anything new. Never copy a helper that already lives a few files away — reuse it or extract it to one shared location.

Dependency ladder. Reach for the standard library first, then platform-native capability, then an already-installed dependency. Hand-written code is the last resort. Do not introduce a new dependency when a few lines of code suffice, unless the user explicitly requested or approved it.

Understand before minimizing. Read the affected code and follow its execution path first. Ship the shortest correct diff once the problem is understood — code you never write never breaks.

Boring over clever. Prefer boring, obviously-correct code over clever code.

Mark the ceiling. Record deliberate simplifications with a short comment naming the accepted limit and what would justify replacing it.

Root cause, not symptoms. Fix bugs at the root cause shared by every caller, not with a separate patch for each reported symptom.

Non-Negotiables

Never minimize away:

  • validation wherever a trust boundary is crossed
  • error handling that guards against data loss
  • security controls
  • accessibility fundamentals
  • scope the user explicitly requested

Verification

Before reporting completion, confirm:

  • every added line earns its place (no speculative generality, no duplicate helpers)
  • the diff is the shortest one that correctly solves the stated problem
  • non-negotiables are intact
  • tests still pass and behavior is unchanged except as requested
Preguntas frecuentes

¿Quitará comprobaciones de seguridad para reducir el código?

No. El comportamiento protegido y las comprobaciones de seguridad nunca se eliminan solo para ahorrar líneas.

¿Anula una petición de una función grande?

No. Si pides explícitamente una construcción amplia o preparada para el futuro, prevalece tu alcance.

¿En qué se diferencia de la skill de limpieza?

Esta evita que se escriba código extra, mientras que la skill de limpieza ordena el código después de añadirlo.

Detalles

Descripción original del autor

YAGNI-ladder coding discipline for writing changes — existence-first, reuse before writing, dependency ladder, shortest correct diff, with non-negotiables that must never be minimized away

repo: Yeachan-Heo/oh-my-claudecode

Popularidad

Estrellas en GitHub
41 mil
Posición en el ranking
#7010
Licencia
MIT
Actualizada
2/11/2026

¿Te sirve esta skill?

0

Entra para votar.

Comentarios

  • …

Más skills de este repositorio

Skills parecidas