Writing Less Code With AI (On Purpose)
May 29, 2026 · blog
Just shipped StreakSync in a week. Fast, minimal, works. And the tool that kept me honest wasn't a linter or a code reviewer — it was a prompt plugin called Ponytail.
The Problem With AI-Generated Code
AI coding tools are eager. Ask for a feature and you'll get the feature plus error handling for scenarios that can't happen, configuration for values that never change, abstractions for things that have one implementation, and a factory pattern for something you'll instantiate once.
It's not wrong code. It's unnecessary code. And unnecessary code is a maintenance burden, a reading burden, and a "now I have to understand what this abstraction is for" burden.
The Ponytail Philosophy
Ponytail is a plugin I use with Claude Code. It enforces a simple ladder:
- Does this need to exist at all? (YAGNI — if speculative, skip it)
- Already in this codebase? Reuse it.
- Stdlib does it? Use stdlib.
- Native platform feature? Use it. (
<input type="date">over a date picker library) - Already-installed dependency? Use it. Don't add new deps for what a few lines can do.
- Can it be one line? Make it one line.
- Only then: write the minimum code that works.
You stop at the first rung that holds. Most of the time, that's rung 1–4.
How It Changed StreakSync
Without Ponytail, I'd have:
- A state management library (Redux, Zustand) instead of React Context + hooks
- A custom date utility instead of date-fns (already installed)
- An abstraction layer over Supabase "for testing" (never tested via that layer)
- Error boundary components wrapping everything (it's a streak tracker, not a bank)
With Ponytail, the app is ~400 LOC per feature. No abstractions with one implementation. No config for values that never change. No "what if we need X later" — later can add X when it needs X.
The Rule I Like Most
"Deletion over addition. Boring over clever."
Clever code is what someone decodes at 3am during an incident. Boring code is what they fix in 30 seconds and go back to sleep. AI loves generating clever solutions. Ponytail forces the boring one.
When NOT to Be Lazy
Ponytail has explicit exceptions: never simplify away input validation at trust boundaries, error handling that prevents data loss, security measures, or accessibility. The laziness is about implementation complexity, not about skipping things that matter.
The Result
StreakSync: 6 tables, minimal dependencies, ships in a week, works on day one. No tech debt from over-engineering. The only debt is deliberate (no realtime sync yet — marked with a ponytail: comment noting when to add it).
The laziest solution that works IS the right solution. Until it isn't — and then you upgrade the specific part that needs it, not everything preemptively.