principle-encode-lessons-in-structure
/principle-encode-lessons-in-structure
Zamienia powtarzającą się poprawkę w sprawdzenie, które pęka przy naruszeniu, np. regułę lintera, typ, asercję lub skrypt, zamiast w kolejną notatkę.
- Autor
- requie ↗
- Repozytorium
- endostack ↗
- Licencja
- MIT
- Ostatnia zmiana repozytorium
- 29.10.2026
Ocena i bezpieczeństwo
- Pliki w paczce
- 1
- Skrypty
- 0
- Komentarze HTML
- 0
- Adresy URL w SKILL.md
- 0
Brak sygnałów. Repozytorium zmienione 29.10.2026, bez odwołań do wycofanych modeli i API.
MIT, otwarta: można używać i zmieniać, z zachowaniem informacji o autorze.
Co robi i kiedy
Zamienia powtarzającą się poprawkę w sprawdzenie, które pęka przy naruszeniu, np. regułę lintera, typ, asercję lub skrypt, zamiast w kolejną notatkę.
Oryginalny opis (EN)
Use when you catch yourself repeating an instruction or the user corrects the same thing again. Convert the lesson into a check that breaks on violation (a lint rule, type, runtime assertion, or script) in place of more prose.
Jak działa
- When it applies
- What to do
- The failure it prevents
- Done when
Podgląd SKILL.md
--- name: principle-encode-lessons-in-structure description: Use when you catch yourself repeating an instruction or the user corrects the same thing again. Convert the lesson into a check that breaks on violation (a lint rule, type, runtime assertion, or script) in place of more prose. disable-model-invocation: true --- # Encode lessons in structure A lesson that keeps coming back should be enforced by a mechanism that fails loudly when broken: a lint rule, a type, a metadata flag, a runtime check, or a script. Writing one more paragraph into an instruction file is what you do only when nothing else works. ## When it applies You notice you are writing an instruction for the second time, or the user keeps issuing the same correction. A one-off correction that has not recurred does not qualify. ## What to do 1. Ask whether the lesson can be checked mechanically. If it can, encode it. "Never log the `Authorization` header" becomes a logger serializer that redacts the header plus a test that fails if the raw value appears in output. "Don't call `subprocess` with `shell=True`" becomes a lint rule in CI. 2. When the lesson depends on judgment that no check can capture, leave it as text. Move it somewhere more visible and pair it with a concrete example of the failure, so readers see what goes wrong. 3. Once a structural fix exists, delete the duplicate instruction. The repetition was a symptom of the missing structure, and keeping both means two sources of truth that will drift. Pick the strongest layer that can hold the rule. From strongest to weakest: an architecture in which the mistake cannot happen; type definitions, lint rules, and CI jobs; tests; and documentation last. The [correct](../correct/SKILL.md) skill applies this ranking across a whole repository. ## The failure it prevents Instruction files grow until agents and people skim them, and a correction helps one run and is forgotten by the next. A check that fails the build is read every time. ## Done when The lesson is enforced by something that fails when violated, or, for a judgment call, it is prominent and illustrated with a real failure. This differs from [principle-build-the-lever](../principle-build-the-lever/SKILL.md), which builds tools for the current task's throughput. This principle builds guardrails that outlive the task. Related: [principle-type-system-discipline](../principle-type-system-discipline/SKILL.md), [principle-build-the-lever](../principle-build-the-lever/SKILL.md).
Wersje
| Repozytorium | Wynik | Licencja |
|---|---|---|
| Ta strona · requie/endostack | 100 | MIT |
| arjitj2/open-pstack | 96 | MIT |
| lgarceau768/agent-principles | 96 | MIT |
| itsvedantkumar/vstack | 96 | MIT |
| modem-dev/ossrules | 96 | MIT |
| v1truv1us/ai-eng-system | 96 | MIT |
Migawka bazy z 13.11.2026 · wersja paczki 44463309c189 (skrót SHA-256 całej paczki)
Pobrania w ostatnich 30 dniach: 0 · ranking
Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.
Podobne skille
- 90qstack-encode-lessons-in-structure
Zamienia powtarzającą się poprawkę lub instrukcję w najsilniejszą praktyczną barierę strukturalną: typ, schemat, lint, sprawdzenie lub skrypt, gdy ten sam błąd wraca. - 86lesson
Zamienia poprawkę lub powtarzający się błąd w zabezpieczenie: regułę, skrypt, test albo wpis w zasadach, jako ostatnią opcję. - 90taste-to-checks
Zamienia powtarzającą się poprawkę błędu agenta w test, regułę lintera, hak lub krok CI, żeby błąd nie wracał. - 90mistake-to-constraint
Zamienia powtarzający się błąd w najsilniejszą barierę: typ, test, lint lub regułę zapisaną w CONSTRAINTS.md. - 100lessons
Przeszukuje bazę lekcji przed debugowaniem lub zadaniem i zapisuje nową lekcję, gdy problem zostanie rozwiązany. - 86principle-model-the-domain
Koduje domenę w strukturze danych zamiast rozsianych warunków, gdy logika stanowa lub rozgałęzienia się mnożą.