LearnThatStack Ace your next interview
Context Engineering · question
Question 6 of 49

Why is it important to keep rules files lean?

beginner
← All Context Engineering questions
Re-explain

Rules files are loaded often, so every unnecessary paragraph uses context on many requests. Long files also make important guidance harder to notice. Conflicting or overly detailed rules can cause the assistant to follow the wrong instruction, or to spend time reconciling advice that does not apply.

Keep only stable, high-impact facts that change how work should be done.

  • Use clear commands, short examples, and links to deeper documentation.
  • Move subsystem guidance into scoped files when the tool supports them.
  • Remove rules that a formatter, type checker, or test already enforces.
  • Review the file after repeated agent mistakes and after architecture changes.

Lean rules reduce cost, improve attention, and are easier for people to keep accurate.

Rewriting in plainer words…

This answer doesn't lend itself to a diagram - it reads best . No credits were charged.

Why there's no diagram: “”

The interactive diagram is below the answer - jump to diagram ↓ · Below it, the related concept . Jump to it ↓

The diagram below the answer is the concept . Jump to it ↓

Tailored explanation · switch back to · ·
What should the new diagram focus on?
Guided practice for Context Engineering One question at a time. Answer out loud, get graded, see what you missed.
How well did you know this?
AI:

Saved in this browser - sign in to keep your review list.

How should your speech become text?

Listening… your words appear above as you speak - tap Stop when you're done.

Recording · cr - tap Stop & transcribe when you're done.

Transcribing with AI…

Voice:

Keep going - a few more words and AI can grade it.

Interview lens How interviewers actually use this question

Likely follow-ups

What you can say

  1. Rules files load on many requests, so every extra paragraph costs context again and again, and a long file buries the guidance that matters.
  2. Conflicting or overly detailed rules make it worse, because the assistant may follow the wrong one or spend effort reconciling advice that doesn't apply.
  3. So I keep only stable, high-impact facts that change how the work gets done, written as clear commands with short examples and links to deeper docs.
  4. Subsystem guidance goes into scoped files where the tool supports them, and I delete any rule a formatter, type checker or test already enforces.
  5. The payoff is lower cost, better attention on the rules that remain, and a file people can keep accurate.
  6. The catch is that anything moved out of the file only helps if the agent finds it, so I review the file after repeated agent mistakes and after architecture changes.

Weak answers to avoid

  • Only talks about token cost Cost is half of it. Long or conflicting rules also bury the important ones and can make the agent follow the wrong instruction. Cover attention and conflicts too.
  • Says bigger context windows solved this A bigger window doesn't remove the per-request cost or the attention problem. More text fits, but it still competes with the rules that matter.
  • Treats lean as short and cuts useful commands Lean means only stable, high-impact facts. Keep build and test commands and short examples, and move detail into scoped files or linked docs.
  • Trims once and never revisits the file Rules go stale as the code changes. Say when you review it, such as after repeated agent mistakes and after architecture changes.
Interview lens

Likely follow-ups, what you can say, and the weak answers to avoid.

Sign in free to open it Free account - the lens opens as soon as you're back.

Want a quick review of the fundamentals? See the Context Engineering cheatsheet.

← Back to all Context Engineering questions
Pro · $10/mo

42 of 49 Context Engineering answers are in Pro.

Full answers, code samples, and AI explanations that go simpler or deeper. Cancel anytime.

  • Full answers + code
  • AI explanations, simpler or deeper
  • 1,000 AI credits / month
  • Cancel anytime