# klaassen-teach-ai-think-senior-engineer-every-2025-11-07

## Veille

8 AI planning strategies - Parallel research agents - Codebase grounding - Git history - Vibe prototyping - Style agents - Compounding engineering - Every Source Code - Kieran Klaassen

## Titre Article

Teach Your AI to Think Like a Senior Engineer

## Date

2025-11-07

## URL

https://every.to/source-code/teach-your-ai-think-like-a-senior-engineer

## Keywords

planning strategies, research agents, parallel operations, Cora email bankruptcy, reproduce and document, best practices grounding, codebase grounding, libraries grounding, git history, vibe prototyping, synthesis with options, style review agents, compounding engineering, institutional memory, CLAUDE.md, docs knowledge base, AppSignal logs, RubyLLM gem, EmailClassifier, event tracking, specialized reviewers, SDLC, cycle de vie logiciel, SDLC agentique

## Authors

Kieran Klaassen (General Manager, Cora)

## Ton

**Profile:** Advanced practitioner tutorial | First-person practitioner | Prescriptive-systematic | Expert

Klaassen adopts the voice of an experienced practitioner sharing a concrete tactical playbook, following his earlier, more philosophical article. The 8-strategy structure (reproduce → best practices → codebase → libraries → git → vibe → synthesis → review) demonstrates the systematic thinking typical of a senior engineer. Field-engineer language (AppSignal logs, the RubyLLM gem, helper methods, denormalization, pull requests), grounded in production examples from Cora, builds credibility. The confident, prescriptive tone ("You can avoid building the wrong thing, too") reflects mastery. Direct GitHub links and the open-sourced planning system show a commitment to openly sharing knowledge. The emphasis on "how to make this compound" after each strategy reinforces the central thesis of accumulating knowledge. Typical of Every's Source Code advanced tutorials (Klaassen, Dan Shipper's technical pieces), aimed at practitioners ready to implement immediately rather than at conceptual understanding.

## Pense-betes

- **Follow-up to the previous article**: Stop Coding and Start Planning (2025-11-06)
- **Central thesis**: parallel research operations teach AI your way of thinking faster than sequential human planning
- **8 planning strategies** by fidelity level (One: quick fixes, Two: clear scope, Three: uncertain requirements) **Strategy 1: Reproduce and document**
- Fidelity: One & Two, bug fixes
- Agent role: step-by-step reproduction guide
- Cora example: 19 users stuck on email bankruptcy, AppSignal logs revealed swallowed rate limit errors, silent failures
- Compounding: @kieran-rails-reviewer checklist updated — "background jobs calling external APIs: are rate limits handled?" **Strategy 2: Ground in best practices**
- Fidelity: all, especially for unfamiliar patterns
- Agent: @agent-best-practices-researcher
- Use cases: technical architecture, copywriting, pricing research, upgrade paths
- Example: a gem 2 versions behind; the agent found the official guide + 3 blog posts with edge cases; 3 minutes of research avoided hours of debugging
- Compounding: findings saved in docs/*.md (pay-gem-upgrades.md, pricing-research.md); the agent checks local docs before the web **Strategy 3: Ground in your codebase**
- Fidelity: anything at risk of duplicating an existing feature
- Agent role: search the existing code for related implementations
- Example: event tracking feature; the agent found a forgotten existing tracking system, with helper methods
- Compounding: creation of an @event-tracking-expert agent distilling all tracking patterns, run automatically on relevant features **Strategy 4: Ground in your libraries**
- Fidelity: fast-moving or poorly documented libraries
- Agent role: analyze the source code to understand capabilities
- Example: the RubyLLM gem evolves constantly, docs lag behind; the agent read the source and found undocumented v1.9 streaming support
- Compounding: knowledge updates automatically with every dependency update, never stale information **Strategy 5: Study git history**
- Fidelity: refactors, continuing past work, understanding the "why"
- Agent role: research past decisions and their context
- Example: EmailClassifier v1 vs. v2; the agent found a 3-month-old PR showing the move to v2 had been attempted, had broken edge cases, and had been deliberately reverted
- Compounding: institutional memory preserved and searchable, new team members inherit the reasoning **Strategy 6: Vibe prototype to clarify**
- Fidelity: Three, UX uncertainty, exploratory
- Agent role: quickly build disposable versions to interact with
- Example: Brief interface redesign, 5 prototypes of 5 minutes each, user feedback "archive button top left — reflex inherited from Gmail"
- Compounding: vibe coding turns uncertainty into concrete specifications, user reactions are documented **Strategy 7: Synthesize with options**
- Fidelity: end of the research phase before implementation
- Agent role: present 2-3 solution paths with honest pros/cons
- Example: Gmail inbox sync, 3 options (graft onto existing / real-time / mirror cache), tradeoffs (fast but messy / clean but slow / upfront effort but better long-term)
- Compounding: the choice reveals preferences ("I prefer widely supported over cutting-edge"), codified for similar future decisions **Strategy 8: Review with style agents**
- Fidelity: final planning step before implementation
- Agent role: detect misalignments with code style and architecture
- Three review agents:
- Simplification: flags over-engineering
- Security: checks vulnerabilities
- Style-Kieran: personal preferences (simple queries vs. complex joins, denormalization)
- Compounding: agents accumulate taste over time, every "I don't like this" makes the system smarter **Practical starter guide**:
- Pick a Fidelity Two feature (multi-file, clear scope)
- 15-20 minutes of research: best practices (web), patterns (codebase), library capabilities (docs/source)
- Let AI synthesize: problem (1 sentence), 2-3 approaches (pros/cons), match against existing patterns, edge cases/security
- Capture your review reactions: note "too complex" or "better way" — write down the WHY
- Ship the feature, compare the implementation to the plan, note the divergences
- Codify 1 learning: add it to CLAUDE.md ("When X, check Y" or "Prefer A over B because C")
- Create specialized agents: Event Tracking Expert, Security Checker
- Repeat: the following week, refer back to the notes; the second plan is better than the first **Open source**: Every's GitHub marketplace, /plan command + ready-to-use research agents

## RésuméDe400mots

Kieran Klaassen presents 8 concrete strategies that turn planning philosophy into operational systems to teach AI to think like a senior engineer. Following his previous article on planning vs. vibe coding, this tactical guide details how to run parallel research operations faster than sequential human planning.

**Framework of 8 strategies**

**1. Reproduce and document**: before fixing a bug, reproduce and document it. Example of Cora's email bankruptcy: 19 users stuck; the agent went through AppSignal logs → rate limit errors were being silently swallowed. No more guessing. Compounding: permanent update to the @kieran-rails-reviewer checklist.

**2. Ground in best practices**: @agent-best-practices-researcher searches the web for how others have solved the problem. Use cases: architecture, copywriting, pricing, upgrades. A gem 2 versions behind: 3 minutes of research found the official guide + 3 blog posts on edge cases, avoiding hours of debugging. Compounding: findings saved in docs/*.md, the agent checks local docs first.

**3. Ground in the codebase**: search for existing patterns before recreating. Event tracking feature: the agent found a forgotten existing system with its helper methods, avoiding the construction of a second, incompatible system. Compounding: the @event-tracking-expert agent distills all patterns and runs automatically.

**4. Ground in libraries**: for fast-moving, poorly documented libraries, read the source code. RubyLLM gem: the agent discovered v1.9 streaming support, undocumented but present in the test suite. Compounding: automatic update with every dependency version bump.

**5. Study git history**: understand the "why" behind past decisions. EmailClassifier upgrade: the agent found a 3-month-old PR showing that v2 had been attempted, had broken edge cases (inbox→archive and archive→inbox reversed), and had been deliberately reverted with detailed reasoning. 5 minutes of research avoided reintroducing an already-debugged bug. Compounding: institutional memory preserved and searchable.

**6. Vibe prototype to clarify**: Fidelity Three, uncertain UX. Brief interface: 5 prototypes of 5 minutes each, concrete user feedback ("archive button top left — Gmail reflex"). The prototypes are discarded, the knowledge carries into the plan. Compounding: uncertainty becomes documented, concrete specifications.

**7. Synthesize with options**: combine all research into 2-3 approaches with honest tradeoffs. Gmail inbox sync: option A (graft onto the existing system — fast but messy), B (real-time — clean but slow), C (mirror cache — upfront effort but better long-term). The agent does the research, the human judges. Compounding: choices reveal preferences codified for similar future decisions ("prefer widely supported over cutting-edge").

**8. Review with style agents**: 3 specialized reviewers in the final pass. Simplification agent (flags over-engineering), security agent (checks vulnerabilities), style-Kieran agent (personal preferences: simple queries vs. complex joins, denormalization). Compounding: agents accumulate taste over time.

**A revealing email bankruptcy case**: initially judged easy ("bulk-archive 53,000 emails, how hard could it be?"). 20 minutes of research-agent work brought reality back: Gmail rate limits hit at 2,000, system timeouts, long user wait. The simple feature became a 3-day architectural challenge. Planning avoided building entirely the wrong thing.

**Practical implementation**: pick a Fidelity Two feature → 15-20 minutes of research (web best practices + codebase patterns + library capabilities) → AI synthesizes the plan (problem/approaches/patterns/edge cases) → capture the WHY behind review reactions → ship → compare the implementation to the plan → codify 1 learning into CLAUDE.md → create specialized agents → repeat the following week.

**Open-source contribution**: Klaassen open-sourced his planning system on Every's GitHub marketplace with the /plan command and ready-to-use research agents. Philosophy: don't start from scratch, adapt existing proven systems.

Each strategy includes a "how to make this compound" note, demonstrating the central thesis: parallel research operations teach AI institutional knowledge that accumulates faster than sequential human planning.

## GrapheDeConnaissance

- Kieran Klaassen —a_créé→ Compound Engineering (METHODOLOGIE, 0.95)
- Kieran Klaassen —dirige→ Cora (ORGANISATION, 0.98)
- Kieran Klaassen —travaille_chez→ Every (ORGANISATION, 0.98)
- Compound Engineering —est_basé_sur→ opérations de recherche parallèles (CONCEPT, 0.95)
- opérations de recherche parallèles —remplace→ planification séquentielle humaine (CONCEPT, 0.9)
- Kieran Klaassen —utilise→ Claude Code (TECHNOLOGIE, 0.97)
- Cora —utilise→ Gmail API (TECHNOLOGIE, 0.92)
- Gmail API —mesure→ limite de débit à 2000 emails (MESURE, 0.95)
- AppSignal —permet→ diagnostic logs production (CONCEPT, 0.9)
- Cora —utilise→ RubyLLM (TECHNOLOGIE, 0.88)
- CLAUDE.md —référence→ préférences architecturales (CONCEPT, 0.92)
- git history —permet→ mémoire institutionnelle (CONCEPT, 0.9)
- vibe coding —permet→ transformation des incertitudes UX en spécifications (CONCEPT, 0.88)
- Every —publie→ planning system open-source (TECHNOLOGIE, 0.93)

---
Canonical: https://www.thekb.eu/en/fiches/klaassen-teach-ai-think-senior-engineer-every-2025-11-07/
