Free playbook: A practical operating model for AI across the SDLC
Blog/Onboarding an Engineer Into an AI-Built Codebase

Onboarding an Engineer Into an AI-Built Codebase

When an agent helped build the codebase, the old forcing function - read it to change it - quietly disappears. A playbook for onboarding engineers into AI-generated code so real comprehension survives the first commit.

Onboarding an engineer into an AI-built codebase: AI orientation, a comprehension checkpoint, then a gated first change

Engineer onboarding into an AI codebase looks identical to the old version on day one and diverges by the end of week two. The repository clones the same way, the README reads the same, and the test suite runs green. What changed is underneath: a large share of this code was drafted by a coding agent, merged faster than any human read it line by line, and the reasoning behind half the decisions never left the prompt it was typed into.

For two decades, onboarding carried a built-in forcing function. To change code, you first had to read it, and reading it built the mental model you needed to change the next thing safely. That loop is what turned a new hire into someone the team could trust near production. When an agent helped write the codebase, and the new engineer can point the same agent at it, that forcing function quietly disappears from both ends: the code arrived without a human reading it, and the newcomer can now edit it without reading it either.

Consider an illustrative scenario common across engineering teams this year. A strong engineer joins a team whose billing service was largely scaffolded with Cursor and Claude Code over the prior quarter. On day three she is asked to add a proration rule. She describes it to the agent, it edits four files, the tests pass, and the pull request merges by lunch. It looks like exceptional onboarding. Three weeks later a refund path double-charges a customer, and nobody, including her, can explain why the currency rounding sits where it does, because the decision that put it there lived in a chat session that no longer exists.

What does onboarding an engineer into an AI-built codebase actually require?

Engineer onboarding into an AI codebase requires rebuilding the comprehension that agent-assisted work skips over. Use AI to orient quickly - navigate the repo, summarize modules, map dependencies - but make the new engineer reconstruct the why: read the approved plans and decision records, explain the architecture back in their own words, and debug a real issue without the agent before they own any surface.

Key Takeaways

  • The forcing function is gone. Reading code to change it used to build understanding automatically. Agent-written code the newcomer edits with an agent removes that loop on both ends, so comprehension has to be designed back in on purpose.
  • The missing artifact is the why, not the what. The code is readable; the reasoning is not. git blame points at a terse agent commit, and the intent behind it lived in a prompt that is gone. Plans and decision records are the onboarding curriculum.
  • Speed to first commit is a false signal. Shipping a change in week one means little if the engineer cannot explain its blast radius. Measure comprehension, not merge time.
  • AI is a great map and a poor teacher. It is excellent for orientation and terrible as the only path to understanding. Let it accelerate navigation, not replace the reading.
  • Gate the first change through the same plan. A newcomer's first build should pass the team's plan-approval step, so onboarding and governance reinforce each other instead of competing.

Why understanding agent-written code is harder than reading a human's

Understanding agent-written code is harder for a structural reason, not a skill reason. Human-authored code carries a trail: a commit history where messages explain intent, a reviewer who pushed back, a Slack thread, a senior engineer down the hall who remembers the trade-off. An agent compresses all of that into a single merged diff. The deliberation that a new engineer used to absorb by osmosis never happened in a durable place.

Three things make an agent-built codebase specifically opaque to a newcomer:

  • Implicit conventions are invisible. Teams carry norms that live in nobody's documentation: this service never calls that one directly, money is always integer cents, retries go here and not there. An agent trained on the public internet does not know your private conventions, and a newcomer who generates code rather than reads it never absorbs them either. Both inherit the gap.
  • The reasoning is unrecoverable. When a decision looks arbitrary, the old move was to ask the author. For agent-written code the author was a model, invoked in a session that was not saved, against a prompt nobody kept. The what is in the repo; the why evaporated.
  • Uniformity hides boundaries. Agent output is stylistically consistent across the whole codebase, which makes everything read as equally intentional. A newcomer cannot tell the load-bearing abstraction from the throwaway one by feel, because the usual human tells - a scrappy module here, a carefully factored one there - are sanded flat.

This is the onboarding mirror image of a problem teams already hit when the same spec is handed to multiple AI coding agents: the output converges while the intent behind it scatters. For the person already on the team it is a drift problem. For the person joining it is a comprehension wall.

flowchart LR J["New engineer\njoins"]:::accent --> O["AI-assisted\norientation"]:::accent O --> C{"Comprehension\ncheckpoint"}:::gate C -->|Can explain\n+ debug unaided| F["Owns a\nsurface"]:::accent C -->|Gaps remain| R["Read plans,\nADRs, pair"]:::metric R --> C F --> P["First change\nvia plan gate"]:::accent classDef accent fill:#fdf6f8,stroke:#853953,color:#853953 classDef gate fill:#ffffff,stroke:#1A1A1A,color:#1A1A1A classDef metric fill:#f4f4f5,stroke:#717171,color:#555555

Workflow summary: A new engineer joins and uses AI for fast orientation across the codebase. Before owning any surface they pass a comprehension checkpoint: can they explain the architecture and debug a real issue without the agent? If gaps remain, they read the approved plans and architecture decision records and pair with a mentor, then return to the checkpoint. Only once they clear it do they make a first change, and that change goes through the team's normal plan-approval gate rather than straight to merge.


Who owns what: the onboarding responsibility matrix

The failure mode in onboarding AI generated code is diffused ownership. The newcomer assumes the agent understood the codebase, the mentor assumes the newcomer read it, and the manager assumes a merged PR means a ramped engineer. Set the boundaries before the first ticket, not during the incident review.

Onboarding concern New Engineer Mentor / Tech Lead Engineering Manager AI Agent
Fast orientation (navigation, summaries) Responsible: drives the exploration Consulted: points at the load-bearing modules Informed: sees the ramp plan Responsible: answers repo questions
Reconstructing the why Responsible: reads plans and decision records Accountable: curates what to read and verifies it landed Informed: unblocks access Informed: not a source of intent
Comprehension checkpoint Responsible: explains architecture, debugs unaided Accountable: judges whether understanding is real Consulted: sets the bar Not involved
First change Responsible: writes and defends the plan Responsible: reviews approach and blast radius Accountable: owns the quality bar Responsible: implements to the approved plan
Recording decisions for the next hire Consulted: flags what was missing Accountable: writes the ADR the agent could not Informed: tracks that it happened Informed: output, not author

Legend: Accountable = signs off and owns the outcome; Responsible = does the work; Consulted = gives input before the decision; Informed = kept in the loop.

This is the onboarding counterpart to the review discipline an EM already runs. If you lead the team the newcomer is joining, pair this with the engineering manager's guide to AI coding agents, so ramp-up and delivery gating share one bar instead of two.


The onboarding playbook: six moves for an AI-built codebase

1. Let AI draw the map, not teach the lesson

Start the newcomer with agent-assisted orientation, because it is genuinely good at it. Anthropic's Claude Code documentation describes how an agent can explore a repository and explain its structure before touching a line, and GitHub's guide to exploring a codebase with Copilot covers asking an attached repository direct questions about how it works. Use this to compress week one of aimless clicking into an afternoon. Then stop: orientation is where AI's onboarding value ends.

2. Make the approved plans and decision records the curriculum

The durable record of why a codebase is shaped the way it is almost never lives in the code. Point the new engineer at the approved plans, specs, and architecture decision records (ADRs - short documents, popularized by Martin Fowler and Michael Nygard, that capture a decision, its context, and its consequences). Where an agent built a surface and no ADR exists, that absence is itself the first assignment: have the newcomer reconstruct the decision and write the record the agent never could.

3. Hold a comprehension checkpoint before any ownership

Set a concrete gate, for example by day 30, where the engineer explains a core subsystem's architecture out loud and debugs a planted or real issue in it without the agent. This is not a hazing ritual; it is the only reliable test that the mental model exists. An engineer who can only navigate the codebase through the agent has not onboarded into it, they have learned to query it.

4. Route the first change through the plan gate, not straight to the agent

A newcomer's instinct in an AI-built codebase is to describe the change to the agent and merge what passes tests. Require instead that their first few changes start from a written plan the mentor approves, the same gate the team already uses before any agent builds from a ticket. This forces them to state scope, non-goals, and blast radius in their own words before code exists, which is exactly the comprehension step the agent would otherwise skip.

5. Debug the double-charge scenario on purpose

Reserve one real incident-shaped exercise: hand the newcomer a bug that only reveals itself through an implicit convention the codebase assumes and the docs omit. The point is to make the invisible conventions visible early, in a safe context, rather than in production three weeks in. Keeping that institutional context attached to the code, instead of in someone's memory, is the gap Enact was built to close.

6. Capture what onboarding exposed

The newcomer is the last person who will ever see this codebase with fresh eyes. Every question they had to ask, every convention that tripped them, every decision with no record is a documentation gap for the next hire. Treat their first two weeks as a free audit: turn each gap into an ADR or a plan annotation, so onboarding the agent-built codebase gets cheaper each time instead of resetting with every joiner.


Onboarding failure modes in an AI-built codebase

The expensive onboarding failures are rarely the newcomer writing bad syntax. They are comprehension failures that a green test suite hides until much later.

Failure mode What it looks like What the team must do
Agent-as-crutch The engineer ships via the agent for a month but cannot navigate the code unaided. Enforce the comprehension checkpoint; require unaided debugging before ownership.
Convention blindness A change works in isolation but violates an unwritten team norm (money, retries, boundaries). Front-load an incident-shaped exercise that surfaces implicit conventions early.
Lost reasoning A decision looks arbitrary; nobody, agent or human, can reconstruct why. Make missing ADRs the newcomer's first writing task; record intent going forward.
False ramp signal Fast first merges read as a ramped engineer to the manager. Measure comprehension and blast-radius explanations, not time to first commit.
Blast-radius surprise A small-looking change breaks a service the newcomer did not know it touched. Gate the first changes through an approved plan that names affected surfaces.
Onboarding amnesia Each new hire rediscovers the same gaps; nothing compounds. Capture every onboarding question as a durable plan or decision record.

For a regulated team, the last two rows are not just ramp hygiene, they are evidence of who understood what before they shipped, which pairs naturally with keeping an audit trail for AI-generated code.


The AI-built codebase onboarding checklist

Run this for every engineer joining a codebase an agent helped build:

  1. Orientation is AI-assisted and time-boxed: the newcomer maps the repo with an agent in the first days, then moves on from it.
  2. The why is assigned, not assumed: approved plans, specs, and ADRs are the required reading, and missing records become writing tasks.
  3. A comprehension checkpoint exists: a fixed date by which the engineer explains a subsystem and debugs it without the agent.
  4. First changes start from a plan: scope, non-goals, and blast radius are written and approved before code, through the team's normal gate.
  5. An incident-shaped exercise is built in: one deliberate bug that surfaces an implicit convention the docs omit.
  6. Onboarding gaps are captured: every question and missing decision becomes a durable record for the next hire.

Before the next joiner, it is worth quantifying what a comprehension gap actually costs when it ships: the rework cost calculator turns "they merged fast but did not understand it" into the number that justifies the checkpoint.


Onboarding people, not just prompts

The instinct when an AI-built codebase meets a new hire is to lean on the tool that built it: let the agent explain, let the agent change, call a fast first merge a successful ramp. That instinct optimizes the one thing already abundant - code moving - and starves the thing that stayed scarce, which is a human who actually understands the system well enough to be trusted near it.

Onboarding an engineer into an AI codebase well is less about a better tool and more about deliberately rebuilding the comprehension loop that agent-assisted work removed. Use AI to draw the map. Use people, plans, and decision records to teach the territory. The teams that come out ahead are the ones that treat a merged pull request from a newcomer as the start of the question, not the answer to it.

Keeping the why behind an agent-built codebase attached to the code, traceable from product intent through to what shipped, is what Enact was built to do, and it is what makes the next engineer's onboarding faster instead of harder.

Give new engineers the why, not just the what

See how Enact keeps the approved plan and the reasoning behind it traceable from product intent to shipped code, so onboarding into an agent-built codebase gets easier with every hire.

Explore Enact →

Frequently Asked Questions