principle-encode-lessons-in-structure

Converts recurring corrections into lint rules, runtime checks, and automation scripts.

3|2|Updated Aug 28, 2026
One-click install
npx skills add https://github.com/adjohn/pstack --skill principle-encode-lessons-in-structure-adjohn
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: principle-encode-lessons-in-structure
Source: https://github.com/adjohn/pstack/tree/main/skills/principle-encode-lessons-in-structure
Command: npx skills add https://github.com/adjohn/pstack --skill principle-encode-lessons-in-structure-adjohn

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Repeatedly writing the same instruction or correction wastes effort and fails to prevent recurrence, because textual guidance is easy to miss and requires readers to notice, remember, and comply. ## Core Features & Use Cases - Structural Encoding: Turns recurring fixes into lint rules, metadata flags, runtime checks, or scripts that enforce the rule without cooperation. - Strongest-Rung Selection: Guides choosing the strongest available mechanism, from unrepresentable states that cannot compile down to canonical helpers and runtime checks. - Feedback Loop Discipline: Captures every correction, routes it to the right layer (brain note, skill, lint rule, or principle), and closes the loop with concrete action. - Use Case: When you catch yourself telling an agent the same correction a second time, encode it as a CI lint rule or banned API instead of adding more documentation. ## Quick Start Apply this principle whenever you notice a recurring correction by asking whether it can become a lint rule, metadata flag, runtime check, or script, and encode it structurally instead of repeating the instruction.

Frequently Asked Questions about principle-encode-lessons-in-structure

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I stop repeating the same code review feedback?▼

Encode the recurring correction as a lint rule, metadata flag, runtime check, or script instead of writing the instruction again. Structural mechanisms enforce the rule automatically without requiring readers to notice and comply.

When should I write a lint rule instead of documentation?▼

Write a lint rule when you catch yourself giving the same instruction a second time. If the rule can be enforced mechanically, delete the textual instruction; only keep documentation for cases that genuinely require human judgment.

What is the strongest way to enforce a coding rule?▼

The strongest enforcement is an unrepresentable state that cannot compile, followed by a lint rule or banned API that fails CI, then a canonical helper, then a runtime check. Choose the strongest rung the situation allows.

Why do textual coding guidelines fail to prevent errors?▼

Textual instructions require readers to notice, remember, and comply, and agents copy whatever surrounding code already does. A weaker guard becomes the next template, so structural enforcement outperforms written guidance.

What should I do when a fix cannot be automated?▼

If the correction genuinely requires judgment and cannot be encoded structurally, make the instruction more prominent and add a concrete example of the failure mode. Route one-off issues to notes and systemic issues to principles.