Technical
AI Pair Programming: What Actually Helps and What's Theater
When I started using AI agents for coding, I treated the agent like a junior engineer I was pairing with. Explain the problem, discuss approaches, then code together. After months of doing this, I've realized most of that ceremony is theater. The agent doesn't need it and I'm wasting tokens.
What a Human Pair Needs
Human pair programming is as much about alignment as code. You explain your reasoning so your partner can challenge it. You build shared context that makes future sessions faster. You're investing in the relationship.
The AI agent doesn't remember. It won't challenge your reasoning unless you ask it to. Every session starts from scratch.
What Actually Helps
The practices that moved the needle for me were the opposite of pair programming ceremony:
- Write the requirement as a test, let the agent make it pass
- Give the agent read-only tools first, let it explore before editing
- Keep prompts short and mechanical once the context is loaded
- Review the diff, not the agent's reasoning
# What I used to do: long explanatory prompt
# What I do now: a failing test
def test_subscribe_rejects_invalid_email():
resp = client.post('/subscribe', json={'email': 'nope'})
assert resp.status_code == 422Then: 'make this pass.' Four words. The test is the spec.
Theater to Drop
Drop the politeness, drop the role play, drop the meta-discussion of approach. The agent is a function that takes context and returns code. Feed it good context, read its output carefully, move on.
See the Anthropic prompt engineering guide for more.
RELATED READING
The Consulting Shift I Am Making In Year Two
After a year of writing and building, my consulting practice is changing shape. Shorter engagements. Sharper outcomes.
ReadThe Frontend Shift: Shipping Less JavaScript In Year Two
A year ago I reached for Next.js for everything. This year I often reach for nothing.
ReadThe Serverless Lesson I Would Write On A Sticky Note
After a year of shipping serverless projects, one rule explains most of the wins and all of the losses.
Read