writing-for-agents
Qué hace
Ofrece pautas de escritura para documentos que leen los agentes de IA, como las skills y los archivos de instrucciones del proyecto. Es para personas que escriben instrucciones que un agente debe seguir de forma fiable.
Cuándo usarla
- ✓Cuando creas o editas una skill para tu agente.
- ✓Cuando escribes un archivo AGENTS.md o CLAUDE.md.
- ✓Cuando quieres que un agente siga un documento de la misma forma en cada ejecución.
Link de la skill
https://github.com/mattpocock/skills/blob/main/skills/productivity/writing-for-agents/SKILL.mdCó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
Para Claude Code, Codex o Cursor: ejecútalo en la carpeta del proyecto y la skill queda instalada.
Descarga el SKILL.md y ponlo en la carpeta de skills de tu agente.
Ejemplo de qué pedirle a la IA
“Ayúdame a reescribir mi CLAUDE.md para que el agente siga nuestras normas del proyecto con más fiabilidad.”
5 skills nuevas por semana. 1 minuto de lectura.
Cómo funciona
Explica cómo escribir indicadores de contexto y disparadores claros, para que el agente sepa cuándo leer cada parte. Recomienda afinar la redacción antes de añadir más material.
Contenido técnico (SKILL.md original)
Texto original del autor, en inglés, directo de GitHub.
Reference for writing any document an agent consumes: a skill, an AGENTS.md / CLAUDE.md, a doc reached by a pointer. The packaging differs; the writing does not: the same levers make each one predictable, since the agent takes the same process every run rather than producing the same output.
When the document you're writing is a skill, read SKILL-MECHANICS.md for frontmatter, invocation choice, and router skills.
Context pointers
A context pointer is a reference held in the agent's context that names some out-of-context material and encodes the condition for reaching it. A skill's description is one; a line in AGENTS.md naming a doc is the same object. The pointer's wording, not its target, decides when the agent reaches the material, and how reliably. A must-have target behind a weakly worded pointer is a variance bug: sharpen the wording first, and inline the material only if sharpening fails.
A pointer does two jobs: state what the material is, and list the branches that should trigger reaching it (a branch is a distinct case the document handles, so different runs take different paths through it). Every word of an always-loaded pointer costs on every turn, so it earns even harder pruning than the body:
- Front-load the leading word: the pointer is where it does its triggering work.
- One trigger per branch. Synonyms that rename a single branch are one branch written twice; collapse them and keep only genuinely distinct branches.
- Cut identity the body already carries.
The two loads
Every document and pointer you add spends one of two budgets:
- Context load is the cost of always-loaded material on the agent's window: an
AGENTS.mdline, a skill description, anything sitting in context every turn, spending tokens and attention whether or not it fires. - Cognitive load is the cost on the human: which documents exist and when to reach for each. The human is the index. Not a cost to minimise: it is the price of human agency; spend it where human judgement matters, remove it where it does not.
Material reached only through a pointer escapes context load at the price of the pointer's own line; material with no pointer at all rides entirely on cognitive load.
Information hierarchy
A document is built from two content types: steps (the ordered actions the agent performs) and reference (definitions, rules, facts consulted on demand). The two mix freely: all steps (a recipe), all reference (a review's rules, this skill), or both. The core decision is where each piece sits on the information hierarchy, a ladder ranked by how immediately the agent needs the material:
- In-file step is the primary tier: what the agent does, in order.
- In-file reference is consulted on demand. Often a legitimately flat peer-set (every rule of a review on one rung), which is a fine arrangement, not a smell.
- Disclosed reference is pushed out into a separate file, reached by a context pointer, loaded only when the pointer fires. Spans a sibling file in the same folder through fully external reference that lives anywhere and any document can point at.
Push too little down and the top bloats; push too much and you hide material the agent actually needs. That tension is the whole decision.
Progressive disclosure is the move down the ladder (out of the main file and behind a pointer) so the top stays legible. Not primarily a token optimisation: it is how the hierarchy is protected. Branching is the cleanest disclosure test: inline what every branch needs, and push behind a pointer what only some branches reach. When a document has steps, in-file reference that should be disclosed buries them and turns attending to them into a coin-flip: a variance lever, not just a legibility one.
Co-location is the within-file companion: where the ladder decides how far down a piece sits, co-location decides what sits beside it once there. Keep a concept's definition, rules, and caveats under one heading rather than scattered, so reading one part brings its neighbours with it. The test: the document should read like documentation written for the agent. Grouped material reads that way; scattered material does not. (Distinct from duplication: that repeats one meaning in two places; scattering fragments one meaning across many.)
Sprawl is the failure mode here: a document simply too long, even when every line is live and unique. Attenti
Preguntas frecuentes
¿Qué es un indicador de contexto?
Una referencia que el agente conserva, que nombra cierto material y explica cuándo leerlo.
¿Cubre también la configuración de los archivos de skills?
Sí. Para las skills, remite a una referencia aparte sobre el frontmatter y cómo se invocan.
¿Por qué importa tanto la redacción?
La skill indica que la redacción de un indicador decide cuándo el agente llega al material, más que el propio material.
Detalles
Descripción original del autor
Writing documents for agents. Use when creating or editing skills, or modifying AGENTS.md or CLAUDE.md.
repo: mattpocock/skills
Popularidad
- Estrellas en GitHub
- 310 mil
- Posición en el ranking
- #125
- Licencia
- MIT
- Actualizada
- 1/11/2026
Comentarios
- …
Más skills de este repositorio
ask-matt
310 milPermite que tu agente actúe como guía de un conjunto de skills de programación, señalándote la adecuada para tu situación, desde la idea hasta el código entregado.
code-review
310 milRevisa tus cambios frente a las normas de código de tu repositorio y la especificación original, ejecutando ambas revisiones a la vez antes de fusionar.
domain-modeling
310 milCrea un glosario compartido del proyecto y registra las decisiones de diseño clave, para que tu código use las mismas palabras que tu equipo.
implement-spec
310 milConvierte una especificación terminada y sus tickets en código funcional, gestionando los tickets en orden y reuniéndolos en una sola rama.
Skills parecidas
writing-skills
311 milEnseña a tu agente a escribir skills nuevas y a probar cada una primero, comprobando que realmente cambia la forma en que se comporta el agente.
bengali-nlp
280 milHace que tu agente procese texto en bengalí. Ayuda a entender y trabajar con el idioma, normalizando el texto y gestionando sus características propias.
prompt-caching-strategy
280 milAyuda a tu agente a optimizar prompts para modelos de lenguaje. Analiza cómo se construyen los prompts para reducir costes y acelerar las respuestas reutilizando información.