← LeaderboardThe Skill Leaderboard

principle-encode-lessons-in-structure

Apply when you catch yourself writing the same instruction a second time, or notice a recurring correction. Encode the rule as a lint, metadata flag, runtime check, or script instead of more text.

Published by michael-denyer ↗michael-denyer/pstack-claude

Try your first task

principle-encode-lessons-in-structure

Start a fresh conversation. Replace the highlighted placeholders.

Use principle-encode-lessons-in-structure to turn the recurring [failure or correction] in [codebase area] into the strongest practical structural guard, such as a type constraint, lint rule, banned API, canonical helper, runtime check, or automation, and remove redundant textual guidance where the guard covers it.

Required inputs

  • [failure or correction]
  • [codebase area]

User-approved starter prompt based on a pinned source version; check current skill requirements before running. Task evidence ↗

SKILL.md

name: principle-encode-lessons-in-structuredescription: "Apply when you catch yourself writing the same instruction a second time, or notice a recurring correction. Encode the rule as a lint, metadata flag, runtime check, or script instead of more text."user-invocable: false

Encode Lessons in Structure

If the lesson needs judgment and cannot be encoded, make the instruction more prominent and add an example of the failure mode.

Corollary: If the fix is structural, only use the structural fix. The instruction is the symptom.