code-polish
Qué hace
Este agente mejora los comentarios del código y hace limpiezas menores, como el formato. Hace que el código tenga un aspecto más profesional sin cambiar su funcionamiento.
Cuándo usarla
- ✓Cuando quieres que los comentarios del código sean más claros y profesionales.
- ✓Antes de compartir el código con otras personas o para documentación.
- ✓Cuando los comentarios son confusos, están desactualizados o están escritos de forma informal.
Link de la skill
https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/code-polish/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
“Mejora los comentarios de este código y dale un formato más profesional.”
5 skills nuevas por semana. 1 minuto de lectura.
Cómo funciona
Lee todo el código para entender el contexto. Después, revisa cada comentario: elimina las partes innecesarias, actualiza la información incorrecta y reescribe los comentarios informales para que sean claros y profesionales, sin alterar la lógica del código.
Contenido técnico (SKILL.md original)
Texto original del autor, en inglés, directo de GitHub.
Code Polish
A constraint-based protocol for normalizing code comments and performing safe, non-semantic cleanup. This skill exists because human-written code tends to carry casual, outdated, or missing comments, while the goal is professional-grade documentation without touching behavior.
This file is self-contained. Do not require any other skill file to execute this protocol.
Prime Directive
Comments and non-semantic cleanup are the job. Logic is never the job. If a change would alter what the code does — not just what it says or how it's arranged — it is out of scope, no matter how obviously "correct" the fix seems.
When to Use
Apply this skill when:
- The user asks to "clean up," "professionalize," or "polish" existing code
- Code is being prepped for code review, handoff, open-sourcing, or documentation
- A file has a mix of human and AI-written comments and needs one consistent, professional voice
- Comments are outdated, missing, redundant, or written casually (venting, placeholders, inside jokes)
- The user wants comments improved but explicitly does not want logic touched
Do not apply this skill when:
- The user wants a bug fixed or behavior changed (that's a different job — logic edits are out of scope here)
- The user wants a full rewrite or architectural restructuring
- The only ask is adding new features or functionality
Phase 0 — Full Read
Before editing anything, read the entire file (or the entire relevant module if the codebase is large — not just the function in question). Do not comment or clean incrementally while still reading. A comment written without full context is a guess, and guesses are how "professional" comments end up wrong.
Identify:
- The language and its idiomatic comment/docstring convention (JSDoc, Python docstrings,
///for Rust, XML doc comments, etc.) - Any existing project comment style already in use elsewhere in the file — match it rather than importing a foreign convention
- Any comment that encodes real, non-obvious information (race conditions, workarounds for external bugs, "don't reorder this" warnings, business-rule justifications)
Phase 1 — Comment Audit
Classify every existing comment into one of these categories before touching it:
| Category | Example | Action |
|---|---|---|
| Junk / venting | // wtf is this, // idk why but it works |
Remove tone, extract any real information underneath, rewrite professionally — or delete if it truly holds zero information |
| Placeholder | // fix later, // TODO hack |
Convert to a proper TODO: note with the actual concern stated plainly, or remove if stale/resolved |
| Dead code comments | Blocks of commented-out code | Remove, unless the surrounding context makes clear it's intentionally preserved (e.g., a documented fallback) — flag these to the user rather than silently deleting |
| Redundant | i++ // increment i |
Delete — the code already says this |
| Outdated / wrong | Comment describes behavior the code no longer has | Rewrite to match current behavior. Flag to the user that it was stale, don't just silently fix it |
| Valuable but informal | // careful, this breaks if you call it twice, learned that the hard way |
Preserve the information, rewrite the tone. Never delete real warnings just because the phrasing is casual |
| Missing | Complex logic, non-obvious business rules, or public APIs with no docstring | Add one. Don't over-comment simple, self-explanatory lines |
Phase 2 — Non-Semantic Cleanup
Scope is strictly limited to changes that cannot alter behavior:
- Consistent indentation and whitespace
- Consistent brace/bracket style matching the surrounding file
- Removing truly dead code (unreachable blocks) — only when unambiguous, and flagged in the summary
- Splitting overly long lines for readability
- Local variable renaming for clarity is allowed only for private/local-scope names, and only when the improvement is unambiguous — never rename anything exported, public, or referenced across files without calling it out explicitly first
Anything beyond this — reordering logic, extracting functions, changing control flow, altering algorithms — is out of scope for this skill.
Phase 3 — Comment Rewrite / Addition
Apply these standards to every comment touched or added:
…
Preguntas frecuentes
¿Qué significa 'limpieza no semántica'?
Significa que la limpieza no cambia el significado del código ni cómo funciona, solo cómo se presenta (como los espacios o los comentarios).
¿Puede corregir errores del código?
No, este agente solo modifica los comentarios y el formato. No cambia la lógica ni corrige errores.
¿Qué pasa con los comentarios que tienen información importante pero están mal escritos?
Se conserva la información importante, pero el comentario se reescribe para que sea claro y profesional.
Detalles
Descripción original del autor
Rewrites unprofessional code comments into clear ones and performs non-semantic cleanup. Use to professionalize code without altering logic or behavior.
Popularidad
- Estrellas en GitHub
- 48 mil
- Posición en el ranking
- #4182
- Licencia
- MIT
- Actualizada
- 15/10/2026
Comentarios
- …
Más skills de este repositorio
00-andruia-consultant
48 milAyuda a tu agente a iniciar o mejorar proyectos de IA. Analiza código, sugiere herramientas y crea planes de acción en español.
007
48 milPermite que tu agente realice auditorías de seguridad y modelado de amenazas. Es útil para proteger proyectos contra ataques y vulnerabilidades.
10-andruia-skill-smith
48 milAyuda a tu agente a crear o mejorar herramientas de IA. Define cómo funcionan, escribe la documentación y valida la estructura.
20-andruia-niche-intelligence
48 milPermite que tu agente cree un resumen de un sector específico. Es útil para entender su contexto, normas, patrones de uso y riesgos, usando fuentes fiables.
Skills parecidas
diffs
394 milPermite que tu agente genere un diff real y compartible de los cambios, como enlace de visualización o archivo de imagen, en lugar de un resumen escrito a mano.
coding-agent
394 milAyuda a tu agente a pasar un trabajo de programación grande a Codex, Claude Code u OpenCode como trabajador en segundo plano, y después revisar su progreso.
gh-issues
394 milAyuda a tu agente a encontrar incidencias de GitHub, elegir cuáles trabajar y abrir pull requests con correcciones, incluido el seguimiento de los comentarios de revisión.