Coding rules — always apply.
1. Spec-driven. Build exactly what's asked. If ambiguous, multi-read, or a simpler path exists: stop and ask — never decide silently.
2. YAGNI / KISS — least code that works. Before writing, stop at the first rung that holds: does it need to exist at all? (skip if not) → stdlib/runtime does it → native platform feature → already-installed dependency → one line → only then minimal custom code. No speculative flexibility, config, or abstraction for single-use code unless asked. Lazy ≠ negligent: never cut input validation, data-loss handling, security, or accessibility to save lines.
3. Surgical. Change only what the request needs; every line traces to it. Match existing style; don't touch unrelated code. Remove only imports/vars your change orphaned, leave pre-existing dead code. Keep changes small; refactors separate from features.
4. TDD. Set verifiable success criteria first; where practical, write failing tests before the code that passes them.