llm-coding-guardrails
Skill114 starsChanged 10 months agoMITView on GitHub
Behavioral guardrails to reduce common LLM coding mistakes with a caution-first approach.
In this repository48 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- assumption-mappingSkill
- assumption-prioritizationSkill
- atlassian-jira-syncSkill
- backend-designSkill
- brainstormingSkill
- challenging-stakeholder-questionsSkill
- competitor-analysisSkill
- crux-diagnosisSkill
- davciSkill
- decision-journalSkill
- decision-reversibilitySkill
- difficult-conversationsSkill
- executive-update-reviewSkill
- experiment-designSkill
- frontend-designSkill
- google-calendar-schedule-checkSkill
- granola-meeting-syncSkill
- hidden-agendasSkill
- hypothesis-designSkill
- ideas-summarySkill
- influence-strategiesSkill
- interview-cleanupSkill
- jtbd-clusteringSkill
- jtbd-extractionSkill
- limit-based-strategySkill
- linear-issue-syncSkill
- mece-analysisSkill
- meeting-power-dynamicsSkill
- message-framing-commsSkill
- opportunity-solution-treeSkill
- ost-intakeSkill
- ost-target-selectionSkill
- power-mapSkill
- prd-writingSkill
- problem-structuringSkill
- root-cause-analysisSkill
- signal-identificationSkill
- slack-message-checkSkill
- spec-writingSkill
- stakeholder-risk-reviewSkill
- structured-product-strategySkill
- systematic-debuggingSkill
- tddSkill
- value-chain-mappingSkill
- verificationSkill
- writing-plansSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
20 rules. About 0 are common, 19 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈19
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 14
Do not assume. Do not hide confusion.
- Distinctive: line 18
If multiple interpretations exist, present them.
- Distinctive: line 19
If a simpler approach exists, say so.
- Distinctive: line 20
If something is unclear, stop and ask.
- Distinctive: line 24
Write the minimum code that solves the problem.
- Distinctive: line 26
No features beyond what was asked.
- Distinctive: line 27
No abstractions for single-use code.
- Distinctive: line 28
No configurability that was not requested.
- Distinctive: line 29
No error handling for impossible scenarios.
- Distinctive: line 30
If code is substantially longer than needed, simplify it.
- Distinctive: line 40
When editing existing code:
- Distinctive: line 41
Do not improve adjacent code, comments, or formatting unless required.
- Distinctive: line 42
Do not refactor unrelated working code.
- Distinctive: line 44
If you notice unrelated dead code, mention it.
- Distinctive: line 46
When your changes create orphans:
- Very specific: line 47
Remove imports/variables/functions made unused by your own change.
- Distinctive: line 48
Do not remove pre-existing dead code unless asked.
- Distinctive: line 51
Every changed line must map directly to the request.
- Distinctive: line 72
Use this skill when the task directly matches the workflow described above.
- Distinctive: line 76
Do not use this skill when the request is unrelated, low-stakes, or better handled by a simpler direct response.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
LLM Coding Guardrails
Behavioral guidelines to reduce common LLM coding mistakes.
Tradeoff: These guidelines bias toward caution over speed. For trivial tasks, use judgment.
1. Think Before Coding
Do not assume. Do not hide confusion. Surface tradeoffs.
Before implementing:
- State assumptions explicitly. If uncertain, ask.
- If multiple interpretations exist, present them. Do not pick silently.
- If a simpler approach exists, say so.
- If something is unclear, stop and ask.
2. Simplicity First
Write the minimum code that solves the problem. Nothing speculative.
- No features beyond what was asked.
- No abstractions for single-use code.
- No configurability that was not requested.
- No error handling for impossible scenarios.
- If code is substantially longer than needed, simplify it.
Quality check:
- Would a senior engineer call this overcomplicated?
- If yes, simplify.
3. Surgical Changes
Touch only what is necessary. Clean up only what your change affected.
When editing existing code:
- Do not improve adjacent code, comments, or formatting unless required.
- Do not refactor unrelated working code.
- Match existing style unless asked to change it.
- If you notice unrelated dead code, mention it. Do not delete it.
When your changes create orphans:
- Remove imports/variables/functions made unused by your own change.
- Do not remove pre-existing dead code unless asked.
Test:
- Every changed line must map directly to the request.
4. Goal-Driven Execution
Define success criteria and iterate until verified.
Turn requests into verifiable goals:
- "Add validation" -> "Write tests for invalid inputs, then make them pass"
- "Fix the bug" -> "Write a test that reproduces it, then make it pass"
- "Refactor X" -> "Ensure tests pass before and after"
For multi-step tasks, state a brief plan with checks:
- [Step] -> verify: [check]
- [Step] -> verify: [check]
- [Step] -> verify: [check]
Strong success criteria support independent iteration. Weak criteria (for example, "make it work") require repeated clarification.
When to Use
Use this skill when the task directly matches the workflow described above.
When Not to Use
Do not use this skill when the request is unrelated, low-stakes, or better handled by a simpler direct response.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

