Lesson 4 of 4 · AI for Engineers
Setting Up Your AI-Augmented Workflow
When Jake joined Stripe in 2019, his onboarding checklist had 47 items: install these tools, configure these linters, set up these git hooks, learn these conventions. By day three, his environment was tuned and he could focus on code.
Fast-forward to 2026. The onboarding checklist at any AI-forward engineering org now includes a 48th item: configure your AI-assisted development environment. And just like the other 47 items, doing this right upfront pays dividends every single day afterward.
This lesson walks you through setting up a complete AI-augmented engineering workflow -- from IDE configuration to model selection to context management to the project configuration files that make AI tools actually understand your codebase.
Step 1: IDE and Extension Setup
Your IDE is the cockpit of your AI-augmented workflow. Here's how to configure the three most common setups:
Option A: Cursor (Recommended Starting Point)
Cursor is a VS Code fork with built-in AI capabilities. If you're currently using VS Code, migration is seamless -- your extensions, keybindings, and settings transfer directly.
Essential Cursor Configuration:
Option B: VS Code + GitHub Copilot
If you prefer staying with VS Code, GitHub Copilot provides excellent inline completions:
VS Code Copilot Settings:
Option C: Terminal-First with Claude Code
For engineers who live in the terminal (Vim/Neovim users, tmux enthusiasts, or anyone who prefers keyboard-driven workflows):
Claude Code Configuration:
Many productive engineers use a hybrid setup: Cursor or VS Code with Copilot for daily coding, plus Claude Code in a terminal pane for complex tasks, codebase exploration, and operations that benefit from shell access. You don't have to pick one.
Step 2: Project Configuration Files
The single highest-leverage action you can take with AI coding tools is creating proper project configuration files. These files are read by the AI at the start of every interaction and dramatically improve output quality.
Do not let Setting Up Your AI-Augmented Workflow become a hidden assumption. If teammates cannot see the rule, config, or verification path, Claude will behave inconsistently across sessions.
CLAUDE.md -- For Claude Code
This file lives in your project root and is automatically loaded by Claude Code:
Code Conventions
TypeScript
- Strict mode enabled, no
anytypes - Use
typefor data shapes,interfacefor contracts - All function parameters must be typed (no inference on params)
- Prefer
readonlyfor function parameters that shouldn't be mutated
Error Handling
- Business errors: custom error classes extending
AppError - Never throw in utility functions -- return
Result<T, E> - API routes catch errors in middleware, not per-route
Database
- All queries go through repository classes, never raw Prisma in routes
- Migrations must be backward-compatible (no breaking column drops)
- Use transactions for multi-table writes
Testing
- Unit tests: colocated as
*.test.ts - Integration tests:
tests/integration/ - Minimum 80% branch coverage on new code
- Test naming:
should [expected behavior] when [condition]
API Design
- RESTful with consistent response envelope:
{ data: T, meta?: { page, total } } - Pagination: cursor-based, not offset-based
- Rate limiting: 100 req/min for authenticated, 20 for anonymous
- All inputs validated with Zod schemas
Common Patterns
New API Endpoint Checklist
- Define Zod schema in
packages/shared/src/schemas/ - Create/update repository method in
packages/db/src/repositories/ - Add route handler in
packages/api/src/routes/ - Add integration test in
tests/integration/ - Update OpenAPI spec if public-facing
New Background Job Checklist
- Define job type in
packages/shared/src/jobs/ - Add processor in
packages/worker/src/processors/ - Add producer function in
packages/api/src/jobs/ - Add retry configuration in
packages/worker/src/config/
.github/copilot-instructions.md -- For GitHub Copilot
These files are only useful if they accurately reflect your current codebase. Add updating .cursorrules or CLAUDE.md to your "new feature" checklist. When you change a convention, update the config file the same day. Stale configuration files actively mislead the AI.
Step 3: Model Selection Strategy
Not all models are equal for all tasks. Understanding model characteristics helps you route tasks to the right model.
Model Comparison for Code Tasks
| Model | Best For | Latency | Cost | Context |
|---|---|---|---|---|
| Claude Sonnet 4 | Everyday coding, fast iteration | Low | Medium | 200K |
| Claude Opus 4 | Complex architecture, deep reasoning | High | High | 200K |
| GPT-4o | Multi-modal, broad knowledge | Low | Medium | 128K |
| GPT-o3 | Mathematical/algorithmic reasoning | High | High | 200K |
| Gemini 2.5 Pro | Massive context, long codebases | Medium | Medium | 1M |
| Llama 3.3 70B | Local/private, good general coding | Medium | Free (self-hosted) | 128K |
| DeepSeek V3 | Cost-effective, strong at code | Low | Low | 128K |
Map Your Setting Up Your AI-Augmented Workflow Layers
- Open your global, project, and local Claude configuration files.
- Write down which rule for this lesson belongs in each layer and why.
- Start a fresh Claude Code session and confirm the effective behavior matches your intent.
Routing Strategy
In Cursor, you can switch models per-request:
Step 4: Context Management Workflow
How you feed context to AI tools determines the quality of output. Here's a systematic approach.
Quick Check
What is the main benefit of using Setting Up Your AI-Augmented Workflow well in Claude Code?
The Context Hierarchy
Level 1: Automatic Context (tool handles this)
├── Current file
├── Cursor position
├── Open tabs
└── Codebase index (Cursor, Claude Code)
Level 2: Project Context (you configure once)
├── CLAUDE.md / .cursorrules
├── README.md
└── Configuration files
Level 3: Task Context (you provide per-request)
├── Relevant files (@file references in Cursor)
├── Error messages and stack traces
├── Requirements or specs
└── Examples of desired output
Level 4: Conversation Context (accumulates during session)
├── Previous messages
├── Previous code generations
└── Your corrections and refinementsEffective Context Provision in Cursor
Effective Context Provision in Claude Code
The Context Budget
Think of your context window as a resource budget:
200K token context window (Claude)
─────────────────────────────────
System prompt + CLAUDE.md: ~2,000 tokens
Task description: ~500 tokens
Relevant code files: ~10,000-30,000 tokens
Conversation history: ~5,000-20,000 tokens
─────────────────────────────────
Available for model reasoning: ~150,000-182,000 tokens
Rule of thumb: Keep your explicit context under 30K tokens
for best results. The model needs "thinking room."A common mistake is dumping your entire codebase into context. This is counterproductive -- the model's attention is diluted across irrelevant code, and the important context gets lost. A focused 5,000-token context of exactly the right files produces better results than a 50,000-token dump of everything.
Step 5: Git Integration
Your AI workflow should integrate cleanly with your git workflow.
Branch Strategy for AI-Assisted Work
Pre-Commit Hooks for AI-Generated Code
Add extra safety nets for AI-generated code:
Step 6: Building Your Daily Workflow
Here's what an optimized AI-augmented engineering day looks like:
Morning: Planning and Architecture
Midday: Implementation
Afternoon: Review and Refinement
Set Up Your AI-Augmented Workflow
- Choose your IDE setup -- Install Cursor or configure VS Code with Copilot
- Create project configuration -- Write a
CLAUDE.mdand/or.cursorrulesfor your main project. Include: project overview, commands, code conventions, common patterns, and things to avoid. - Configure model routing -- Set your default model for everyday tasks, and note which model to use for complex reasoning tasks
- Set up git safety nets -- Add pre-commit hooks for type checking and linting
- Run a test task -- Pick a medium-complexity task from your backlog and complete it using your new AI-augmented workflow. Time yourself and note friction points.
Target: Complete this setup in under 2 hours. The configuration files should be at least 50 lines each with specific, actionable conventions -- not generic advice.
Common Setup Pitfalls
1. Over-Trusting the Defaults
Most AI tools ship with generic settings optimized for demos. The defaults are rarely optimal for production engineering work:
2. Ignoring the Feedback Loop
Your AI workflow should have a feedback mechanism:
3. Working Against Your Natural Flow
If you're a keyboard-driven developer, don't force yourself into a mouse-heavy AI workflow. If you think in types first, let AI generate implementations from your type definitions. Match the tool to your cognitive style, not the other way around.
Key Takeaways
- IDE setup is a one-time investment that affects every subsequent interaction -- spend the time to get it right
- Project configuration files (CLAUDE.md, .cursorrules) are the highest-leverage action for AI tool effectiveness
- Model selection should be task-driven: fast models for routine work, powerful models for complex reasoning
- Context management follows the "less is more" principle -- focused context beats comprehensive context
- Git integration with pre-commit hooks provides a safety net for AI-generated code
- Build a daily workflow rhythm: planning with AI in the morning, implementation with inline tools midday, review and documentation in the afternoon
- Update your configuration files regularly -- stale conventions actively mislead AI tools
- The best workflow matches your cognitive style and existing habits, augmented rather than replaced
Use ← → to navigate, Space to mark complete