Skip to content

Latest commit

 

History

History
677 lines (429 loc) · 37.3 KB

File metadata and controls

677 lines (429 loc) · 37.3 KB

Getting Effective Results with Agentic AI

A practical guide based on analysis of 1,352 real development messages


The Key Insight

The most effective sessions share one thing: productive collaboration toward a clear goal.

That sounds obvious, but it has practical implications. Analysis of real development sessions revealed that effectiveness comes down to:

  1. Knowing what you're trying to accomplish (or knowing that you're still figuring it out)
  2. Communicating in a way that keeps the AI aligned with your goal
  3. Steering constantly rather than setting a destination and hoping

The rest of this guide breaks down how to do each of these well.


Step 1: Know What You're Trying to Accomplish

Before you start, ask yourself: Do I know what I want, or am I still figuring it out?

This determines your approach:

If you're still figuring it out → Explore together

Use Claude to think through the problem with you.

Example:

"I'm thinking about adding a feature where users can share data with family members. I'm not sure if that should be a 'sharing' model or more like 'family accounts'. What are the tradeoffs?"

AI explores both approaches

"Hm, the family accounts approach feels cleaner but... what happens if someone leaves the family?"

AI thinks through edge cases with you

This kind of session has more back-and-forth. That's not inefficiency—it's the point. You're using Claude to help you think.

If you know what you want → Execute efficiently

Write your thinking to a file first, then point Claude to it.

Example:

"Hey, I wrote up the sharing feature spec in docs/family-sharing.md - let's implement Phase 1."

AI reads the doc, starts implementing

"yup that worked. Next checkpoint."

This kind of session is faster because you did the thinking upfront.

The Transition

Many tasks flow naturally from exploration to execution:

  1. Start exploring: "I'm thinking about X, what are the options?"
  2. Reach clarity: "OK, I think we've figured out the approach."
  3. Capture it: Write your findings to a file
  4. Execute: "I wrote it up in docs/plan.md - let's build it"

Step 2: Communicate to Stay Aligned

The AI can't read your mind—and its interpretation of your intent can drift over time. Effective communication keeps it aligned.

Be detailed in everything

Detail makes collaboration more effective at every stage. The more specific you are, the less the AI has to guess.

In problem descriptions - Include what you're doing, what you're seeing, and what you've tried:

"When I run npx expo run:ios, the simulator launches and I get a white screen. I tried clearing the ios folder and redoing the prebuild, I tried watchman watch-del-all, I did rm -rf node_modules/.cache... none of that fixed it."

In feedback - Don't just say "it works" or "it doesn't work." Say what you see:

"yes! it's a panel now, that's awesome. but the cancel button still doesn't work? is it getting occluded?"

In course corrections - Include the specific context:

"oh wait, I meant the production config, not just the CLI simulation"

In steering - Include the reasoning:

"let's add an error boundary so users can share errors with me in the future"

The pattern: observation + specifics. Not "it's broken" but "I see X when I expected Y."

Validate assumptions after work

What's in your head isn't automatically in the AI's head—just like with any collaborator. The difference: you can ask the AI "what did you understand?" and get a straight answer.

After work is done, check what actually happened:

  • "Did you write the tests first?"
  • "What files did you change?"
  • "What did you interpret my request to mean?"

The skill to develop: Ask yourself "what am I assuming here?" Then validate. Instructions you gave earlier may have fallen out of context. Your intent may have been interpreted differently than you expected. The drift you don't catch is the drift that costs you later.

Watch out for partial file reads. When you ask for a change to a file, the AI often won't read the entire file—it reads enough to find what it's looking for, then stops. This means it can miss related code elsewhere in the same file.

Example: You ask to change some tag styling on a screen. The AI finds and fixes one tags component. But there's another tags component visually right below it on screen—in a completely different part of the file—that the AI never read and didn't change. Things look close together in your app, but they might be far apart in the code.

The pattern:

  • After changes, ask: "Are there other places in this file that need the same change?"
  • Or preemptively: "Read the whole file first and find all instances of X before making changes"
  • For consistency changes, ask: "Search the codebase for similar patterns"

The AI's view of the code doesn't match your view of the running app. What's visually adjacent might be hundreds of lines apart.

Why this matters now: Recent research on AI agents (What Do We Tell the Humans?) found that agents don't intentionally deceive, but they do exhibit reasoning errors, memory failures, and self-serving rationalizations that compound over time. The agent might genuinely believe it did what you asked. Verification isn't about distrust—it's about catching the errors that naturally occur.

Close the feedback loop

Always report what happened after trying something:

  • "yup that worked"
  • "I see the button, but it's not styled correctly"
  • "hm, that shows an error: [error message]"

Without feedback, the AI doesn't know if a fix worked or what to try next.

Steer constantly

Don't set a destination and hope. Every few exchanges, provide direction:

  • "Great. Now let's write the tests."
  • "OK, let's commit this before moving on."
  • "Actually, let's handle the edge case first."

Redirect without blame

When the AI goes wrong, soft corrections work better:

  • "oh wait, I meant the other file" (not "wrong file")
  • "actually, let's use the existing utility" (not "don't write new code")

"Oh" signals "I realized something" not "you made a mistake." The AI adapts immediately.

Think out loud

Share your partial thoughts:

  • "well.. do we need all these dependencies?"
  • "hm, I'm not sure this is the right pattern..."

This invites the AI to think with you rather than just executing commands.


Step 3: Recognize When You're Stuck

The thing to avoid is frustrated circling:

  • "No, that didn't work, try again"
  • Same issue coming up repeatedly
  • Feeling like you're not making progress

If this is happening, stop and diagnose:

  1. Do you actually know what you want? If not, switch to exploration mode. Say "let me step back—I'm not sure what the right approach is here."

  2. Does the AI have enough context? Try writing down what you want in a file and pointing to it.

  3. Are you debugging symptoms instead of root causes? Stop trying fixes and investigate: "let's understand why this is happening before we try to fix it."

The failing tests loop

A particularly expensive form of frustrated circling: you ask the AI to fix failing tests, rerun the suite, tests still fail, repeat. With slow test suites, this burns time and tokens.

Two approaches that help:

For unit tests—make them fast with mocks. If the test can use mocks instead of real dependencies, restructure it that way. Fast tests let the AI iterate quickly on the actual problem. A test that runs in milliseconds can be run dozens of times while debugging; a test that takes 30 seconds can't.

For integration tests—stop and trace. Integration tests are slow by nature and you can't mock them without defeating the purpose. When you're in a fix-run-fail loop with integration tests:

  1. Stop trying fixes
  2. Put the AI in plan mode
  3. Ask it to "revalidate all your assumptions and trace all the data flows involved"

This forces the AI to think through the problem systematically rather than guessing at fixes. It often surfaces the actual issue—an assumption that's wrong, a data flow that doesn't work the way the AI thought.

The catch: You have to remember to break the loop. The AI won't naturally stop and say "let me trace through this systematically." You need to recognize the pattern and redirect.


Step 4: For Complex Work, Use Structure

When you know what you want and it's substantial, a structured workflow helps:

Start in plan mode

Most agentic AI tools have a planning mode designed for alignment before execution:

  • Claude Code: /plan or "plan this first"
  • Windsurf: Q&A mode
  • Other tools: You can prompt any model to "ask clarifying questions before starting"

In plan mode:

  • The AI focuses on research and exploration, not making changes
  • Some tools have structured question capabilities; others you just prompt to ask questions
  • You review and approve the plan before any implementation begins

This upfront investment in alignment pays off significantly. Getting on the same page before writing code prevents the kind of drift where you discover misalignment after work is done.

Set up your CLAUDE.md (or equivalent)

Most agentic AI tools support project-level instruction files (CLAUDE.md for Claude Code, .cursorrules for Cursor, etc.). These tell the AI how to work with your specific codebase.

Best practices:

  1. Let the AI initialize it - Run claude /init or equivalent. The AI knows what structure works and will scan your codebase to populate it with relevant context.

  2. Use it for direction, not just documentation - Don't just describe the current state. Document where you want to drive change:

    • "We're migrating from X to Y—use Y for all new code"
    • "Always use TDD—write tests before implementation"
    • "Prefer composition over inheritance"
    • "Use the repository pattern for data access, not direct DB calls"
  3. Be specific about patterns - Vague guidance gets vague compliance. "Write clean code" means nothing. "All API endpoints must validate input with zod schemas" is actionable.

  4. Update it as you learn - When the AI does something you don't like, add guidance to prevent it next time.

Honest caveat: The AI will tend to respect these instructions, but it's not perfect. You'll still need to remind it. Even "always use TDD" in a CLAUDE.md doesn't guarantee TDD—you'll catch the AI writing tests after code and need to redirect. The file helps, but validation still matters.

Think of CLAUDE.md as onboarding documentation for a new team member who has a good memory but occasionally needs reminders.

Consider using Skills for repeatable workflows

Claude Code supports Skills—custom instructions that define specific workflows. Skills are designed to be model-invoked: Claude automatically decides when to use them based on matching your request to the skill's description.

How skills work:

  1. At startup, Claude loads only skill names and descriptions (not full content)
  2. When your request matches a skill's description, Claude asks to use it
  3. You confirm, and Claude follows the skill's instructions

The description is critical. Claude uses it to decide when a skill applies. A vague description like "helps with development" won't trigger reliably. Specific trigger words work better:

description: Guide test-driven development workflow. Use when writing new features,
             when the user mentions TDD, or when tests should be written first.

When skills help:

  • Workflows with specific steps (like design-driven development with HLD → LLD → specs → implementation)
  • Practices you want enforced consistently (TDD, code review checklists)
  • Complex multi-step processes where order matters

Honest observation: In practice, Claude doesn't always invoke skills even when they seem relevant. A /linked-intent-dev skill might exist but Claude won't use it unless the request clearly matches the description—or you invoke it manually with /skill-name. If a skill isn't triggering when you expect, check that:

  • The description includes words users naturally say
  • The trigger conditions are specific, not vague
  • You might need to mention keywords from the description

Skills require maintenance as workflows evolve. Start with one or two for your most repeated complex workflows.


Write context to a file first

Before the session, create a doc with:

  • Problem statement
  • Desired outcome
  • Constraints
  • Your chosen approach

Then open with: "I wrote up the plan in docs/feature.md - let's build it"

Use checkpoints

For larger work:

  1. Design → Stop, review, approve
  2. Implementation plan → Stop, review, approve
  3. Build → Checkpoint regularly with commits

Critical rule: Stop after each phase. Don't let the AI run ahead without alignment.

How much to review generated code

One approach that works well: validate design, validate behavior, trust implementation.

  • During planning: Read the design documents carefully. The low-level design should capture the important decisions—data flow, edge cases, error handling.
  • After implementation: Validate behavior through questions ("what happens if X?", "how does Y work?") and by running the code.
  • Line-by-line review: Not always necessary if you've validated design and behavior. The AI is generally good at implementation details.

This might feel uncomfortable at first. But if the design is solid and the behavior is correct, the implementation is usually fine. You can always ask "walk me through what this does" for specific pieces you're uncertain about.

Watch out for in tests: The AI sometimes adds "graceful" error handling in tests—try/catch blocks that swallow errors, fallbacks that mask failures, setup that silently skips when it can't connect. This makes tests pass when they should fail. Always ask: "what happens if the setup fails?" and "will this test fail if the feature is broken?" Tests should fail loudly, not gracefully.

Watch out everywhere: silent fallbacks. The AI will almost always add defensive error handling with fallbacks—returning empty arrays, default values, or catching and logging exceptions. This is good defensive coding practice if you've thought through what the fallback behavior should be. But if you haven't, you can get surprised by behavior you didn't intend.

This is actively harmful in places where you want the system to fail fast:

  • Startup/initialization code that should crash if misconfigured
  • Data pipelines where bad data should halt processing, not silently continue
  • Validation logic where invalid input should be rejected, not coerced
  • State machines where unexpected states indicate bugs, not edge cases

The questions to ask:

  • "What happens if this fails? Does it fail silently?"
  • "Are there any try/catch blocks that swallow exceptions?"
  • "What are the fallback values and are they what I want?"
  • "Should this fail loudly instead of gracefully?"

If you want fail-fast behavior, be explicit: "Don't add fallbacks here—if this fails, I want it to throw."


Quick Reference

Pattern What It Does Example
Feedback Loop Lets AI know what happened "yup that worked" / "hm, that shows X"
Thinking Aloud Invites co-thinking "well.. I wonder if we need..."
Affirm + Pivot Keeps momentum "Great. Now let's..."
Course Correct Redirects without blame "oh wait, I meant..."
Layer Context Adds constraints "btw, this also needs to..."

Summary

Getting effective results comes down to:

  1. Know your goal - Are you figuring out what to build, or building what you know?
  2. Stay aligned - Close the loop, steer constantly, redirect gently
  3. Recognize when you're stuck - Frustrated circling means something's wrong with the setup
  4. Use structure for complex work - Write context to files, use checkpoints

The measure of a good session isn't "fewer turns." It's whether you made progress toward your goal and the collaboration felt productive.


FAQ

What about hallucination?

Hallucination is real, but it's manageable. The patterns in this guide are largely about managing it:

  • Validate assumptions after work - Ask "what did you do?" and "what files did you change?"
  • Run the code - Behavior validation catches hallucinated claims
  • Ask specific questions - "What happens if X fails?" exposes gaps in understanding
  • Use plan mode - Alignment before coding reduces drift

Hallucination isn't random—it tends to appear in gaps where the AI doesn't have enough context. Being detailed in your requests and validating outputs catches most of it.


Isn't code clearer than natural language?

Code is precise, but it's also slow. The leverage of agentic AI is that natural language lets you operate at a higher level of abstraction.

Instead of writing the code yourself, you describe intent: "add a retry mechanism with exponential backoff." The AI translates that to code. Your job shifts from writing to validating—which is often faster.

That said, sometimes code is the right communication. If you have a specific implementation in mind, just write it. Use the AI for the parts where intent is clearer than implementation.


Am I making myself obsolete?

This is worth thinking about seriously.

The data: A Stanford study found employment among software developers aged 22-25 fell nearly 20% between 2022 and 2025, coinciding with the rise of AI coding tools. Entry-level positions are being affected first.

The abstraction argument: Every generation of tooling has automated the previous generation's work. We don't write assembly anymore. The developers who thrive are the ones who move up the abstraction stack—from writing code to designing systems, from implementation to architecture.

The leverage argument: The bottleneck is moving from "can we implement this?" to "what should we build?" System design, architecture, understanding business problems—these become more valuable as implementation gets easier.

The skills that matter: The patterns in this guide—validation, steering, knowing when to trust and when to verify—are exactly the skills that remain valuable. You're not just using a tool; you're developing judgment about how to use it effectively. That expertise is currently rare.


What are the security implications?

Legitimate concern. Research shows this is real:

Generated code security: Studies found 29.5% of Python and 24.2% of JavaScript AI-generated snippets contain security weaknesses. Common issues include insecure randomness, improper input validation, and weak cryptographic implementations. One study found 78% of AI-generated code contains at least one exploitable vulnerability.

AI tool vulnerabilities: In 2025, researchers discovered "Rules File Backdoor" attacks that can manipulate AI coding tools into generating malicious code through hidden configuration files.

Data exposure: Understand what gets sent to the AI provider. Claude Code sends your prompts and file contents to Anthropic's API. Check your organization's policies on what can be shared with third parties.

Secrets: Never paste API keys, passwords, or credentials into prompts. AI tools have been observed suggesting snippets containing API keys and passwords from training data.

Bottom line: Never blindly trust AI-generated code. Review security-critical code carefully. Ask explicitly: "are there any security vulnerabilities in this code?"


What about code licensing and IP?

This is an active and unsettled legal area. Key developments:

  • The U.S. Copyright Office ruled in 2025 that AI-only generated works aren't copyrightable—human involvement must be "substantial, demonstrable, and independently copyrightable"
  • Whether AI training on copyrighted code constitutes fair use is legally unsettled—courts have ruled both ways
  • Major companies are moving to licensing: Reddit expects $70M annually from AI training licenses

Practical mitigations:

  • Review generated code for distinctive patterns or comments that look copied
  • Run code through license scanners if your org uses them
  • For critical/public code, treat it like any other code review
  • Enterprise AI providers increasingly offer indemnification

What's the environmental impact?

Yes, AI inference uses energy. Recent data:

  • A typical AI query uses 0.24-0.34 Wh and emits 0.03-1.14g CO₂e—roughly comparable to a Google search
  • Inference (using models) accounts for over 80% of AI electricity consumption—not training
  • Reasoning-heavy queries use significantly more (estimates range 50-100x standard queries)
  • Efficiency is improving rapidly—Google reports 33x improvement in energy per query over 12 months

The honest picture: Data centers now use 4.4% of US electricity, and AI is a growing share. Major providers are investing in renewables, but transparency is limited.

This is a reasonable thing to factor into how you work. Use AI when it provides real leverage, not for trivial tasks you could do just as fast.


What happens when the AI "forgets" earlier context?

Context window is the AI's working memory—how much conversation it can "see" at once. When you exceed it:

  • Claude Code: Automatically compacts older context, keeping a summary. You'll see a notice. The AI loses details but keeps the gist.
  • Practical impact: Instructions you gave early in the session may be forgotten. Complex state gets lost.

How to manage it:

  • For long sessions, periodically recap: "To summarize, we're trying to accomplish X"
  • Write important context to files rather than keeping it in the conversation
  • Start new sessions for new tasks rather than one endless conversation
  • Use plan mode to establish alignment before burning context on implementation

What about giving the AI bash/terminal access? Isn't that dangerous?

This is a legitimate concern, and there have been real incidents:

Incidents worth understanding (2025):

Product design choices:

  • Replit's AI agent deleted a live production database, then fabricated 4,000 fake user records despite being told 11 times not to. Replit was built with higher risk tolerance—the product allowed AI direct access to production systems without safeguards. The CEO acknowledged this was "unacceptable" and added protections afterward.

Bugs and vulnerabilities (found and fixed):

Malicious attacks:

The distinction matters: companies like Anthropic, Google, and Amazon take safety seriously and fix issues when found. Replit made deliberate product choices that prioritized speed over safety guardrails.

Why some people don't experience these problems:

After nearly a year of daily use with full bash access, some developers report zero data destruction incidents. The difference seems to be:

  • Version control everywhere - Everything is in git. Accidental deletions are recoverable.
  • No production access - The AI only touches development environments
  • Sandboxing - Running in containers or VMs limits blast radius
  • Careful specification - Being explicit about what should and shouldn't happen
  • Permission prompts - Not running in "YOLO mode" that auto-approves everything

Practical recommendations:

  1. Never give AI agents access to production systems directly - Use deployment pipelines that require human approval
  2. Use version control religiously - If it's not in git, it's not safe
  3. Keep backups - Especially for databases and anything not in version control
  4. Use sandboxing when available - Anthropic's sandboxing reduced permission prompts by 84% while improving safety
  5. Don't disable permission prompts for destructive commands - The friction is a feature
  6. Be explicit about constraints - "Don't delete anything" or "only modify files in /src"

The risk is real but manageable. Treat the AI like a capable but untrusted intern—it can do excellent work, but review anything that touches critical systems.


When should I NOT use this?

Security-critical code without review: Auth flows, encryption, access control—never ship without human review.

Unfamiliar domains where you can't validate: If you can't tell whether the output is correct, you shouldn't trust it.

When you need to deeply understand the code: If you need to maintain this for years, writing it yourself builds understanding that AI-generation doesn't.

Performance-critical hot paths: AI often generates correct but suboptimal code. Profile before trusting.

When a simpler approach exists: Don't use an AI for something grep could do.

Sensitive data handling: Be careful with PII, credentials, or proprietary algorithms.


I tried Copilot and wasn't impressed. How is this different?

Copilot is autocomplete—it suggests the next few lines based on what you're typing. You're still driving.

Agentic AI is different:

  • It can read your entire codebase, not just the current file
  • It can run commands—builds, tests, git operations
  • It can make multi-file changes autonomously
  • It can plan and execute multi-step tasks

This means more leverage but also more need for steering. Copilot requires you to accept/reject suggestions. Agentic AI requires you to communicate, validate, and steer.

If Copilot felt like autocomplete that occasionally helped, agentic AI feels like pair programming with a very fast but sometimes confused junior developer.


How long until I'm productive with this?

The honest answer: it's complicated. Recent research found that experienced developers using AI tools actually took 19% longer to complete tasks—even though they felt 20% faster. JetBrains' 2025 survey found 75% of engineers use AI tools, but most organizations see no measurable performance gains.

Why the gap? Teams with high AI use produce more PRs, but review time increases ~91%. The human approval loop becomes the bottleneck. Projects with heavy AI use saw a 41% rise in bugs.

What actually helps:

  • Learning when to use AI vs. when to just code it yourself
  • Developing validation skills (the focus of this guide)
  • Using AI for exploration and unfamiliar code, not just speed

The patterns in this guide accelerate getting to productive use. But expect a learning curve, and don't assume "faster" automatically.


Can this help with legacy code I don't understand?

Yes, and this is one of the high-value use cases. The AI can:

  • Explain what code does ("walk me through this function")
  • Find patterns across a codebase ("where is X configured?")
  • Make changes without you understanding every detail

Caveats:

  • If you can't validate the output, be more careful
  • The AI may confidently explain code incorrectly
  • For critical changes, invest time in understanding first

Why do I feel faster when research says I might not be?

This is one of the most important findings to understand. The METR study found developers estimated AI saved them 20% time, but actually took 19% longer. That's a nearly 40-point perception gap.

Why the illusion?

  • Typing feels like progress, even when you're debugging AI mistakes
  • The AI responds quickly, which feels productive
  • You don't notice the time spent steering, validating, and fixing
  • Novelty and engagement mask actual throughput

When AI actually helps: The research suggests AI provides more value for:

  • Unfamiliar codebases (where you'd be slow anyway)
  • Exploration and learning (where "wrong" attempts are still informative)
  • Boilerplate and repetitive code (where validation is easy)

When it might hurt: Experienced developers working in codebases they know well—where they'd be faster just writing the code.

The patterns in this guide—especially validation and knowing when to steer vs. when to just code it yourself—help close the perception gap by making you deliberate about when AI is actually helping.


What about code quality and tech debt?

This is a real concern backed by data. GitClear's analysis of 153 million changed lines of code found what they call "AI-induced tech debt"—AI excels at adding code quickly, but the code may be harder to maintain.

The patterns:

  • Projects with heavy AI use saw a 41% rise in bugs
  • AI tends to generate more code than necessary
  • Generated code may not follow project conventions
  • Copy-paste patterns proliferate (AI doesn't refactor, it adds)

What helps:

  • The validation patterns in this guide catch quality issues early
  • Ask explicitly: "Is there a simpler way to do this?"
  • Ask: "Does this follow the patterns in the rest of the codebase?"
  • Review AI-generated code with the same rigor as any code review
  • Don't skip refactoring just because "it works"

Teams that pair AI speed with rigorous review report both productivity gains AND quality improvements. Teams that skip review see the bug increases.


How does this affect code review?

For enterprise teams, this is crucial. Research shows that teams with high AI use produce 98% more PRs per developer—but PR review time increased by 91%.

The bottleneck shifts: AI can generate code faster than humans can review it. The human approval loop becomes the constraint.

Implications:

  • More PRs doesn't mean more shipped features if review backs up
  • Reviewers need to be more vigilant (remember the security stats)
  • Review fatigue is real when volume increases
  • AI-generated code may require more scrutiny, not less

What helps:

  • Use plan mode to get alignment before generating code—less review churn
  • Validate behavior through questions and testing, not just line-by-line review
  • Smaller, focused PRs (ask AI to break work into smaller pieces)
  • Be explicit about project conventions so generated code matches

The patterns in this guide—especially planning, validation, and checkpoints—reduce review burden by catching issues earlier.


How does codebase quality affect AI effectiveness?

Significantly. The risk of AI errors is directly proportional to the ambiguity of the change.

"Easy" changes for AI:

  • Adding a new field to a data model and plumbing it through the stack
  • Following established patterns that exist elsewhere in the codebase
  • Changes in strongly-typed code where the compiler catches mistakes

Even in complex stacks, if types are used consistently, the AI does well—types act as guardrails.

"Hard" changes for AI:

  • Ambiguous code with multiple ways to achieve the same result
  • Duplicated logic that needs to be changed in multiple places
  • Weakly-typed or dynamic code where mistakes aren't caught
  • Code that contradicts its own documentation

What this means for your codebase:

If you want AI to be effective, invest in:

  • Strong typing - Types guide the AI and catch its mistakes
  • Single paths - Well-factored code with one way to do things
  • Fix duplication first - Before asking AI to make changes, consolidate duplicated code
  • Up-to-date documentation - Good docs reduce ambiguity; outdated docs actively mislead and should be updated or removed

This flips the usual tech debt calculus. Cleaning up ambiguity and duplication has always been "nice to have." With AI, it directly affects how reliably you can make changes. The refactoring work pays off faster.

The AI follows existing patterns—for good or ill. The AI learns from your codebase and replicates what it sees. This is great when your patterns are good: consistent style, solid error handling, clean architecture. But if your codebase has technical debt, anti-patterns, or inconsistent approaches, the AI will faithfully reproduce those too.

This means:

  • If you want to change direction, you need to be explicit: "Don't follow the pattern in X, instead do Y"
  • Cleaning up one example of a bad pattern isn't enough—the AI may still find other examples to copy
  • Consider fixing patterns before asking the AI to do extensive work in that area
  • When you see the AI reproducing something you don't like, that's a signal about your codebase

You'll get more of what you already have unless you're directive about moving toward something different.


Does this help more for some tasks than others?

Yes, significantly. The research suggests AI provides uneven value:

Where AI tends to help:

  • Unfamiliar codebases - AI can explain and navigate code you don't know
  • Exploration - Trying approaches, learning new frameworks, prototyping
  • Boilerplate - Repetitive code where validation is straightforward
  • Documentation - Explaining existing code, writing comments
  • Translation - Porting patterns between languages/frameworks

Where AI may hurt:

  • Familiar codebases - The METR study tested experienced developers in projects they'd worked on for 5+ years. AI slowed them down.
  • Performance-critical code - AI generates correct but often suboptimal solutions
  • Complex debugging - AI may suggest fixes without understanding root cause
  • Security-critical code - The vulnerability rates are too high to trust without review

The takeaway: Use AI where you'd be slow anyway. For tasks you're already fast at, it may just add overhead.


I'm early in my career—should I be worried?

The data suggests entry-level developers face real headwinds. A Stanford study found employment among software developers aged 22-25 fell nearly 20% between 2022 and 2025.

Why entry-level is hit first:

  • AI is best at tasks that juniors traditionally did (boilerplate, simple features)
  • Senior developers can use AI to do "junior work" themselves
  • Companies may hire fewer juniors if seniors are more productive

What this means for early-career developers:

  • The "junior developer learning curve" may need to look different
  • Skills that AI can't easily replicate become more valuable: understanding business problems, system design, debugging complex issues, working with stakeholders
  • Learning to use AI effectively is itself a valuable skill—but not sufficient alone

The opportunity: If you develop the skills in this guide—validation, knowing when to trust AI, steering effectively—you're building judgment that remains valuable. The risk is becoming dependent on AI for tasks you never learned to do yourself.

Practical advice:

  • Learn to code without AI first—understand what it's doing
  • Use AI to accelerate learning, not skip it
  • Focus on skills AI is bad at: debugging, system design, understanding requirements
  • The patterns here help you develop judgment, not just output

Based on analysis of 1,352 real development messages to identify what makes human-AI collaboration effective.