# The Friction Is Your Judgment

Armin Ronacher, Earendil · Cristina Poncela Cubeiro, Earendil

AI Engineer Europe 2026

[Talk page](https://ai.engineer/talks/_Zcw_sVF6hU-friction-is-your-judgment) · [Video](https://www.youtube.com/watch?v=_Zcw_sVF6hU)

## The Friction Is Your Judgment

Agents can produce code faster than teams can understand it. Explicit boundaries, mechanical checks, and focused human review help preserve judgment where speed creates risk.

Familiarity with pull requests, configuration files, and basic application architecture will help; the TypeScript example requires no agent framework knowledge.

### Shipping without friction

[0:23](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=23s)

A forum post about a security incident acquired an unfortunate social preview. An accidentally deployed configuration change had caused the problem; beneath the incident headline, the company’s marketing image promised: “Ship without friction.” The juxtaposition exposes a practical question for software teams: which obstacles should disappear, and which ones make us stop before a consequential mistake?

![A slide shows a social preview with a partially redacted headline about a web app host accidentally enabling a CDN, above an image reading “SHIP WITHOUT FRICTION.”](https://ai.engineer/api/talk-essay-media/318e547aba7f23d88e66d59a9dce30c21f52c94e062828b0a167685f8d707932)

“Ship without friction” beneath a headline about accidentally enabling a CDN and causing data breaches.

Armin Ronacher approaches that question after two decades in software, much of it in open source, including creating [Flask](https://flask.palletsprojects.com/en/stable/). He jokes that the Python framework is so familiar to models that their output now introduces people to it. After leaving Sentry, he had time to explore Claude Code, write about agentic engineering, and hear from other developers experimenting with it. He then started Earendil with a friend in October.

Cristina Poncela Cubeiro, his colleague at Earendil and previously an engineer at Bending Spoons, comes from the other direction. AI tools predate her software engineering career: they helped her learn the work as well as perform it. Together, their experience building with and on agents has brought substantial gains and disappointments. They present an evolving practice, not a settled solution. Two problems recur: psychologically, why is it so difficult to stop prompting and think; technically, why do agents improve some people’s code and worsen others’? Even the prospect of perfect generated code leaves a question about how much judgment humans would still need to exercise.

### When saved time becomes expected output

[3:29](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=209s)

The shift begins pleasantly. After enough unsuccessful prompts, something clicks: the tools become useful, work becomes more enjoyable, and tasks leave extra time. As adoption spreads, however, that advantage becomes a baseline expectation. Everyone is assumed to have the tools, so everyone is expected to ship faster. The time saved is consumed by additional production, leaving less room for review and deliberation.

Poncela Cubeiro describes two parts of the resulting trap. First, the next prompt has an uncertain payoff: it might finish a feature or add the change that destabilizes the product. That uncertainty encourages another attempt. Second, the volume of visible output makes activity feel like efficiency. The stream of changes crowds out the question of whether this is the right implementation—or even the right work. Once the loop is running, stopping becomes difficult for the person, while the agent may keep exploring files it never needed to read. **The human has to retain the agency to interrupt the loop.**

![The Trap slide says agents produce output fast and lists the reward of shipping, later quality drift, and difficulty stopping once in the flow.](https://ai.engineer/api/talk-essay-media/67433326580b00f414c4d6d0434ad85a39e2727c9604cdc62e8ed93ac381fde1)

“The Trap”: fast output feels like progress, crowding out reflection.

### Production grows faster than responsibility

[5:29](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=329s)

At team scale, the same shift changes the balance between creating code and reviewing it. When code creation was the constraint, writing and review capacity were more closely matched. Agents amplify each engineer’s production without an equivalent increase in the engineer’s ability to inspect and understand changes. Pull requests accumulate. At the same time, more people participate: marketing staff can submit code, and CEOs who once worked as engineers can return to coding.

The responsibility does not expand as readily. Engineering teams still have to maintain and operate the result, including changes produced by people whose primary roles lie elsewhere. Machines cannot take responsibility for those changes. When the number of producers outgrows the people able to carry that responsibility, reviews are skipped or rubber-stamped. Small pull requests remain desirable, but the amplification pushes in the opposite direction. Ronacher uses a hypothetical 5,000-line pull request to illustrate the mismatch: it demands careful judgment precisely when its size makes disengagement tempting.

### Runnable code can conceal an invalid system

[7:13](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=433s)

When generating code feels cheap, large changes become easy to request. Ronacher connects the resulting behavior to agents’ optimization for immediate progress: write code, run tests, and unblock the task. A configuration reader illustrates the danger. If reading the required file fails, an agent may add defaults so the program can continue. That looks like recovery locally, but the application may now be operating with settings nobody intended.

Consider a TypeScript configuration loader for a required database URL. Catching a failed read and returning a default URL would let subsequent writes proceed against an unintended configuration. A loader that preserves the failure instead makes the missing or invalid configuration visible before those writes begin:

```typescript
import { readFile } from "node:fs/promises";

type AppConfig = {
  databaseUrl: string;
};

export async function loadRequiredAppConfig(
  path: string,
): Promise<AppConfig> {
  const parsed: unknown = JSON.parse(await readFile(path, "utf8"));

  if (
    typeof parsed !== "object" ||
    parsed === null ||
    !("databaseUrl" in parsed) ||
    typeof parsed.databaseUrl !== "string" ||
    parsed.databaseUrl.trim() === ""
  ) {
    throw new Error("Configuration requires a nonempty databaseUrl");
  }

  return { databaseUrl: parsed.databaseUrl };
}
```

In Ronacher’s illustrative scenario, the configuration mistake is discovered two hours later, after incorrect database records have already been written. The problem is not merely that a read failed; it is that a recovery path hid the failure and allowed consequential work to continue.

In his experience, these attempts to recover from local failures can produce brittle services. The codebase then grows beyond what the agent can navigate reliably: it misses relevant files and creates a new implementation of something that already exists elsewhere. Each local workaround adds complexity that makes the next task harder. A human engineer may feel discomfort while adding this sort of code; an agent does not provide an equivalent emotional brake. That concern has to enter the process through people and explicit constraints.

### Libraries expose a smaller problem

[9:11](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=551s)

Poncela Cubeiro reports an encouraging correlation: agents tend to do better in libraries than in products. A library usually has a defined problem, features that map onto an API surface, and constraints that bound the work. Its core is often simple enough to understand and extend. Products combine more interacting concerns.

| Concern | Library | Product |
| --- | --- | --- |
| Scope | Defined problem | Interacting requirements |
| Surface | Constrained API | UI, API, permissions, billing |
| Structure | Simple, extensible core | Coupled components and states |
| Agent reasoning | More locally bounded | Requires broader context |

For example, a product’s UI and API responses may depend on permissions, feature flags, and billing state. Those relationships can exceed what the agent can hold in context. An edit can be reasonable in the file being changed and incoherent across the application. The design response is to treat **the codebase as infrastructure for the agent**: its structure determines how much of the system the agent can see and reason about while working.

### Make the flow between components explicit

[10:51](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=651s)

Modular components help an agent add a feature in one place without disturbing everything else. But module boundaries alone are insufficient: the execution flow also needs clear stages. In an assistant refactor, Poncela Cubeiro identifies three main steps:

1. Receive the user’s message.
2. Pass the message to the agent loop.
3. Handle the output.

These landmarks were clear to her, and the code at each landmark was relatively orderly.

The trouble accumulated between the stages. Agents introduced conversions between types and added information to state that did not belong there. These additions quietly expanded the set of behaviors the application supported, including unexpected and potentially dangerous ones. Making the transitions explicit matters as much as naming the major components: otherwise, the connecting code becomes a place to accommodate conditions that the design never intended to allow.

The rest of the approach follows familiar engineering principles. Use established patterns that align with what models have learned. Keep the core simple and put necessary complexity in explicit layers. Avoid abstractions that conceal intent the agent needs to respect. Poncela Cubeiro cites React Server Actions and ORMs, compared with raw SQL, as examples of where that concealment can occur. This is her argument for inspectable behavior, not a universal prohibition on those tools: an abstraction becomes a problem when it hides the relationship the agent must understand to change the system correctly.

![An Agent-Legible Codebase slide lists modularization with clear boundaries, known patterns and conventions, a simple core with complexity in layers above, and no hidden magic.](https://ai.engineer/api/talk-essay-media/dcae1c2607c4e9f2bdbea1ead73d8b296ad846021f728c1aef7ace2c0857f8a4)

An agent-legible codebase uses clear boundaries, familiar patterns, a simple core, and no hidden magic.

### Turn design constraints into mechanical checks

[12:32](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=752s)

At Earendil, much of this discipline is enforced with linting rules. The first example is a ban on bare catch-alls. There is a small irony in the presentation: the agent had already found and edited the catch-all intended for the demonstration. The larger point is to make undesirable patterns detectable without relying on someone remembering every convention during review.

- **One SQL query interface.** Keep query access in one place so an agent does not have to hunt across the repository and risk missing a site that also needs to change.
- **One UI primitives library.** Avoid raw input elements outside the shared primitives so styling and behavior stay consistent.
- **No dynamic imports.** Keep this form of runtime indirection out of their codebase.
- **Unique function names.** Make a search identify the intended function unambiguously. If an agent’s grep returns one relevant result, it spends less context on disambiguation and can continue its work more directly.

They are also exploring TypeScript’s [`erasableSyntaxOnly`](https://www.typescriptlang.org/tsconfig/erasableSyntaxOnly.html) option. It restricts TypeScript constructs that need runtime transformation, such as enums and parameter properties, favoring JavaScript with erasable type annotations. That does not itself remove every build or transpilation step. The attraction is a closer relationship between the source the agent reads and the behavior being debugged, with less transformation-related indirection when locating an error.

### Separate repairable defects from human decisions

[14:11](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=851s)

Mechanical checks improve what the agent produces, but a person still needs a signal that restores attention at consequential moments. Ronacher’s team built a [review extension](https://github.com/mitsuhiko/agent-stuff/blob/main/extensions/review.ts) for [Pi](https://pi.dev/) around that distinction. Mechanical bugs and clear violations of `AGENTS.md` belong in feedback the agent can act on. Other changes need an explicit human call-out because understanding their consequences requires judgment beyond the patch.

- **Database migrations.** A migration’s operational risk depends on locks and the amount of data in production. Ronacher wants a human judgment call before it goes in.
- **Permission changes.** The intended authorization rules may be under-documented. A plausible implementation is not enough to establish that the new access is appropriate.

An agent can help identify these changes even when it cannot own the decision. The call-out makes the person notice that this is the point to engage.

In the demonstrated interface, actionable findings appear above a separate group of human call-outs. Selecting the action to fix issues would send the first two categories—mechanical bugs and instruction violations—back to the agent. It would not resolve the human decisions below. The linked extension is a mutable implementation, and its current human call-outs are non-blocking attention signals, not an enforced approval gate. A new dependency, for example, raises questions about whether it belongs in the codebase and whether its maintainers are people the team wants to trust. Fast generation does not answer either question.

### Use speed where it creates a useful starting point

[16:00](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=960s)

Issue reproduction is one of Ronacher’s preferred uses of agents. A customer report can become a concrete reproduction case, giving an engineer a much better starting point. Exploring product directions is another useful application, provided the team accepts responsibility for the generated code. His assessment is less favorable for system architecture and reliability, where interactions and consequences matter more than producing a first working version.

![A two-column slide lists exploration, prototypes, debugging, CI fixes, reproduction cases, and first drafts under High Leverage; reliability, interacting states, unclear specifications, and later cleanup costs under Lower Leverage.](https://ai.engineer/api/talk-essay-media/643e89024941abbf84666026707dbcdb66978a534a6e140b3b64194aae502f35)

“Where Speed Actually Helps” contrasts high-leverage tasks with lower-leverage work.

Ronacher warns that months of technical debt can accumulate in weeks or days; this is an experiential warning, not a measured production rate. As the mess grows, understanding falls, and honest assessment becomes harder both technically and psychologically. He describes finding code that failed in production, then realizing that he had committed it himself with an agent’s help. The disappointment came with recognizing that the responsibility was still his. Slowing down is necessary to see the actual state of the codebase, including mistakes hidden by the satisfaction of having shipped.

### Keep the friction that lets you steer

[17:22](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=1042s)

Some shipping friction is merely annoying and should be removed. Other friction is deliberately designed to make a team consider whether a service is reliable enough, how critical it is, and whether enough people are available to operate it. Ronacher points to service-level objectives, or **SLOs**, as an established example. More precisely, the operational constraint comes from the policy tied to the objective, such as an error-budget policy. Agent speed does not eliminate those reliability and staffing decisions.

The closing analogy is physical: steering requires friction. Software teams also need points of resistance where experience can affect the direction of travel. A review that prompts a real decision about permissions, a migration, or operational risk is not wasted time simply because the code arrived quickly. **Useful friction is where human judgment enters the process.**

## Resources

- [Flask documentation](https://flask.palletsprojects.com/en/stable/) — Official guides, tutorials and API reference for the Flask Python web framework.
- [TypeScript's erasableSyntaxOnly option](https://www.typescriptlang.org/tsconfig/erasableSyntaxOnly.html) — Explains the syntax restrictions used to keep TypeScript compatible with type stripping.
- [Pi review extension](https://github.com/mitsuhiko/agent-stuff/blob/main/extensions/review.ts) — Ronacher's review extension separates actionable defects from changes needing human attention, including migrations and permission changes.
- [Pi Coding Agent](https://pi.dev/) — Installation and documentation for the extensible coding agent used in the review workflow.
- [Mario and Earendil](https://lucumr.pocoo.org/2026/4/8/mario-and-earendil/) — Ronacher discusses Pi, deliberate software design and why quality requires more than faster output.
- [Example Error Budget Policy](https://sre.google/workbook/error-budget-policy/) — A concrete policy for slowing feature releases when reliability falls below an agreed objective.

## Slides

### AI Engineer Europe

The AI Engineer Europe logo opens the recording.

[0:00](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=0s) [AI Engineer Europe logo in white on black.](https://assets.ai.engineer/sites/aiecode2025/sha256/24e440bf5dfd4ecccd4fffdc9ef9243be07fff10b16e87c6b80fbc594828e3ea.webp)

AI Engineer
EUROPE

### Presenting Sponsor

[0:05](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=5s) [Google DeepMind presenting sponsor card.](https://assets.ai.engineer/sites/aiecode2025/sha256/e0a2733394b9e76d5cbcc292edcb1e7d0d4305725368334cfa74aa4dc6f38f30.webp)

PRESENTING SPONSOR

Google DeepMind

### Platinum Sponsors

[0:10](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=10s) [Platinum sponsor logos for Braintrust, WorkOS, and OpenAI.](https://assets.ai.engineer/sites/aiecode2025/sha256/e1dd203f1a8e56f01a056ace3935c40cbc175cc0d1d780777c507da699e961d0.webp)

PLATINUM SPONSORS

Braintrust
WorkOS
OpenAI

### A Security Incident and Frictionless Shipping

A configuration change caused a security incident; the forum post’s social preview paired the breach headline with the company’s “Ship without friction” tagline. Ronacher argues for adding friction.

[0:31](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=31s) [A redacted headline about a CDN-related data breach above a preview reading “Ship without friction.”](https://assets.ai.engineer/sites/aiecode2025/sha256/19514d463f2112b029145f2d6e13c5d5088a87f20103d4e924866aa935b5e487.webp)

[redacted] (web app host) "accidentally enables CDN" causing massive data breaches

SHIP WITHOUT FRICTION

Backend
Just now via GitHub
Frontend
[illegible]
Just now via GitHub
redis
[illegible]

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
Open
AI Engineer EUROPE
THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER
Founder
CRISTINA PONCELA CUBEIRO
Software Engineer
PRESENTED BY Google DeepMind

### Who We Are

Armin Ronacher created Flask, founded Earendil, and spent 10 years at Sentry. Cristina Poncela is an AI engineer at Earendil and previously worked at Bending Spoons.

[0:59](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=59s) [Introductions for Armin Ronacher and Cristina Poncela, with their roles and previous experience.](https://assets.ai.engineer/sites/aiecode2025/sha256/f7b09a852ab278bc93eb9e123f25bd56adec7b1074f39a5ce71f2e87ff55d814.webp)

Who We Are

ARMIN RONACHER
• Creator of Flask
• Founder at Earendil
• 10 years at Sentry

CRISTINA PONCELA
• AI Engineer at Earendil
• Previously at Bending Spoons

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
WorkOS
AI Engineer EUROPE
PRESENTED BY Google DeepMind
THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
EARENDIL

### From Practice, Not Theory

After more than 12 months building with agents, the presenters describe both major gains and messy results. They frame recurring problems as psychological and engineering challenges, and their account as a work in progress.

[2:17](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=137s) [The presenters describe over 12 months of building with agents, mixed results, two recurring problem classes, and an ongoing learning journey.](https://assets.ai.engineer/sites/aiecode2025/sha256/6eefe9e1d2492ce6e47404fb2bfa10ced065aeb9204e7b0ec046be694c70d588.webp)

From Practice, Not Theory

• We have been building with agents for over 12 months
• We had moments of huge leverage and moments of real mess
• Two distinct classes of problems keep recurring and they need different solutions
• Take this as part of a learning journey, not a finished playbook

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
EARENDIL

AI Engineer EUROPE
PRESENTED BY Google DeepMind

### Two Problems

Working with agents presents two challenges: retaining human judgment and structuring codebases so agents can work productively.

[3:03](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=183s) [Two questions: how to retain human judgment and how to structure a codebase for productive agents.](https://assets.ai.engineer/sites/aiecode2025/sha256/721603b6ed9f6949bc5dd275f7b20ab63a16c925dd3ca4e3e7b8c7f355345b2a.webp)

Two Problems

THE PSYCHOLOGY PROBLEM
• How do you work with your own brain so you don't abdicate to the machine?

THE ENGINEERING PROBLEM
• How do you structure a codebase so agents can actually be productive on it?

ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
AI Engineer EUROPE
PRESENTED BY Google DeepMind
THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
EARENDIL

### The Shift

Early agentic coding gave users breathing room. As adoption spread, expectations rose and that spare time became pressure to ship faster.

[3:39](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=219s) [Agentic coding initially created breathing room, but widespread adoption raised expectations and pressure to ship faster.](https://assets.ai.engineer/sites/aiecode2025/sha256/3ca3689b26b6d2a2ab950dae226a7ea6922e71eb80c5fbb7e91507adacb8af99.webp)

The Shift

• Early on, agentic coding felt like a secret unlock: you got more done, had breathing room
• Then it went mainstream and the expectation shifted
• Instead of reclaiming time, everyone is under pressure to ship faster
• The tools didn’t buy us slack but they raised the baseline expectation

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

THE FRICTION IS YOUR JUDGMENT
AI Engineer EUROPE
PRESENTED BY
Google DeepMind
Braintrust
WorkOS
OpenAI

### The Trap

Fast agent output can feel like progress, encouraging engineers to keep prompting instead of stopping to question their design. Early speed can give way to quality drift.

[4:23](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=263s) [Fast agent output can feel like progress, discouraging reflection and leading to quality drift.](https://assets.ai.engineer/sites/aiecode2025/sha256/4b658480678f3d39c73c1e84344e00dbb8fcfc4cada57036a3bbef1a807e13f2.webp)

The Trap

Agents produce output fast, and output feels like progress. So you stop questioning, stop designing, stop saying "wait."

• Your brain rewards you for velocity: shipping feels good
• You get speed early, then quality drift later
• The agent doesn't know when to stop ... and neither do you, once you're in the flow

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
AI Engineer
Engineering the future of AI

[4:26](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=266s) [Slide describing how fast agent output can feel like progress and discourage reflection, leading to quality drift.](https://assets.ai.engineer/sites/aiecode2025/sha256/82ed9d73def18ef7f6ac3d934fe67565644028b0b1cc25f07347f2f4114552a3.webp)

The Trap

Agents produce output fast, and output feels like progress. So you stop questioning, stop designing, stop saying "wait."

• Your brain rewards you for velocity: shipping feels good
• You get speed early, then quality drift later
• The agent doesn't know when to stop ... and neither do you, once you're in the flow

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
AI Engineer
Engineering the future of AI

### The Amplification Problem

Agents increase code output faster than engineers’ review capacity, while responsibility stays with humans. Pull requests pile up, reviews may be skipped or rubber-stamped, and the goal is to keep PRs small.

[5:29](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=329s) [Slide explaining that agents amplify code output while responsibility and review capacity remain with humans; it calls for small pull requests.](https://assets.ai.engineer/sites/aiecode2025/sha256/4cddd374e3e1315a8d3c23d36d87e87c7639dd3bea0106b6237304d59bfa5ee6.webp)

The Amplification Problem

• Before agents: engineers balanced creating and reviewing code
• Now every engineer has an agent amplifying their output
• But responsibility still rests on the human and it hasn’t been amplified
• You are outnumbered by entities that cannot carry responsibility
• Code reviews are increasingly skipped or rubber-stamped
• Goal: small PRs

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Broadcast text:
Braintrust
AI Engineer EUROPE
PRESENTED BY Google DeepMind
THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
EARENDIL

[5:52](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=352s) [Slide explaining that agents amplify code production while responsibility and review capacity remain with humans; it calls for small pull requests.](https://assets.ai.engineer/sites/aiecode2025/sha256/2d371e420757164317584adb15988efa943eda4e79afa7f09bc9a805aadc0769.webp)

The Amplification Problem

• Before agents: engineers balanced creating and reviewing code
• Now every engineer has an agent amplifying their output
• But responsibility still rests on the human and it hasn’t been amplified
• You are outnumbered by entities that cannot carry responsibility
• Code reviews are increasingly skipped or rubber-stamped
• Goal: small PRs

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Broadcast text:
Braintrust
AI Engineer EUROPE
PRESENTED BY Google DeepMind
THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
EARENDIL

### The Amplification Problem

Agents amplify code output while humans still carry responsibility. Ronacher says reviews are increasingly skipped or rubber-stamped and calls for small PRs to support review.

[6:54](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=414s) [Slide describing how agent-generated code amplifies output while review responsibility remains with humans, with small PRs as a goal.](https://assets.ai.engineer/sites/aiecode2025/sha256/c8f9f9197826648e373deb2fa554c076dc511c17ed038921517721f90d45502b.webp)

EARENDIL

The Amplification Problem

• Before agents: engineers balanced creating and reviewing code
• Now every engineer has an agent amplifying their output
• But responsibility still rests on the human and it hasn’t been amplified
• You are outnumbered by entities that cannot carry responsibility
• Code reviews are increasingly skipped or rubber-stamped
• Goal: small PRs

ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
AI Engineer EUROPE
PRESENTED BY Google DeepMind
THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
EARENDIL

### When Thinking Matters Most

A 5,000-line pull request can feel overwhelming, but that is exactly when the reviewer needs to think rather than tap out.

[7:00](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=420s) [Slide says the moments when you want to skip thinking are exactly when thinking matters most.](https://assets.ai.engineer/sites/aiecode2025/sha256/ade9feb26fcb42d6f7f9c18c6daf4c39aef1bd426563bed19bbce5530b4bc77c.webp)

The moments where you want to skip thinking are exactly the moments where thinking matters most.

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
AI Engineer EUROPE
PRESENTED BY Google DeepMind
THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
EARENDIL

### The Engineering Problem

Ronacher opens the engineering section by connecting inexpensive code generation with larger pull requests and massive changes.

[7:10](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=430s) [Part II title slide: The Engineering Problem.](https://assets.ai.engineer/sites/aiecode2025/sha256/ac791211a120127a1d3f2dd44f04bbd9d4a76f4e3ab7ca5ea25ae7df908c81f2.webp)

PART II
The Engineering Problem

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Event text:
AI Engineer EUROPE
PRESENTED BY Google DeepMind
THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
EARENDIL

### Why Agent Code Drifts

Agents can hide failures by catching exceptions or falling back to defaults. Ronacher gives a config file example: a service may keep running with defaults and write wrong data before anyone notices.

[7:21](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=441s) [Slide describes broad exception handling and default fallbacks as causes of hidden failures in agent-generated code.](https://assets.ai.engineer/sites/aiecode2025/sha256/da1a9d228cc8aadfc9f09685733f1c7dd13fa043dc59e27559f96f7fa5db7837.webp)

Why Agent Code Drifts

• Agents are optimized to produce code that runs
• They over-protect locally: catching exceptions broadly, falling back to defaults
• This is the opposite of good design: failures should propagate up, not be swallowed
• A service silently running with wrong config is worse than a service that refuses to start
• Multiply across a codebase and failure modes become invisible

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
AI Engineer EUROPE
PRESENTED BY Google DeepMind
THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
EARENDIL

[8:26](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=506s) [Slide argues that broad exception handling and fallback defaults can hide failures across a codebase.](https://assets.ai.engineer/sites/aiecode2025/sha256/da8e546b2846182e13289a88a7bf9cdb160e21bcd0721e767c3d9527b49b5530.webp)

Why Agent Code Drifts

• Agents are optimized to produce code that runs
• They over-protect locally: catching exceptions broadly, falling back to defaults
• This is the opposite of good design: failures should propagate up, not be swallowed
• A service silently running with wrong config is worse than a service that refuses to start
• Multiply across a codebase and failure modes become invisible

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
AI Engineer EUROPE
PRESENTED BY Google DeepMind
THE FRICTION IS YOUR JUDGMENT
Braintrust
WorkOS
OpenAI

### Entropy Is Self-Reinforcing

As a codebase grows messier, an agent may miss existing files and duplicate code, adding more mess and making future recall harder.

[8:39](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=519s) [A cycle links a messier codebase to worse agent recall, more duplication, and more mess.](https://assets.ai.engineer/sites/aiecode2025/sha256/009b48e781598be16b55bffc0113e21dbcc29e1c18c0d8bb8d2f6c18e3ea7f0f.webp)

Messier codebase → worse agent recall
→ more duplication → more mess
Entropy is self-reinforcing.

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
AI Engineer EUROPE
PRESENTED BY Google DeepMind
THE FRICTION IS YOUR JUDGMENT
Braintrust
WorkOS
OpenAI

### Libraries vs. Products

The speakers find agents tend to excel at libraries with clear problems and constraints. Products intertwine concerns across components, making the full structure harder to fit into an agent’s context window.

[9:10](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=550s) [Two columns contrast clearly defined, constrained library problems with interacting product concerns and limited agent context.](https://assets.ai.engineer/sites/aiecode2025/sha256/5a4e006216b2f6a1e201d858886b47b84d16523371051027c0622ec1d316f873.webp)

EARENDIL

Libraries vs. Products

WHERE AGENTS EXCEL
• Clearly defined problem
• Compact API surface
• Tight constraints
• A legible, stable core to plug into

WHERE AGENTS STRUGGLE
• Interacting concerns: flags, permissions, billing
• No single file owns a feature
• Context window can’t hold the full picture
• Locally reasonable, globally incoherent

ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
AI Engineer EUROPE
PRESENTED BY Google DeepMind
THE FRICTION IS YOUR JUDGMENT
Braintrust
WorkOS
OpenAI

[10:27](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=627s) [Two columns contrast well-defined, constrained library problems with product complexity, intertwined concerns, and limited agent context.](https://assets.ai.engineer/sites/aiecode2025/sha256/210e2af140eecbd7e29cfe1163cdc4cd8239a05de0ced8315fbf40222b14d58e.webp)

EARENDIL

Libraries vs. Products

WHERE AGENTS EXCEL
• Clearly defined problem
• Compact API surface
• Tight constraints
• A legible, stable core to plug into

WHERE AGENTS STRUGGLE
• Interacting concerns: flags, permissions, billing
• No single file owns a feature
• Context window can’t hold the full picture
• Locally reasonable, globally incoherent

ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
AI Engineer EUROPE
PRESENTED BY Google DeepMind
THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
EARENDIL

### Your Codebase Is Infrastructure for the Agent

When an agent cannot fit the whole system into its context window, the proposed response is to design the codebase as infrastructure it can understand and use.

[10:35](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=635s) [Slide states that the codebase is infrastructure for the agent and should be designed that way.](https://assets.ai.engineer/sites/aiecode2025/sha256/bd4e579e356ceb1e41a217024b2d9990495fefff7d35f23cb1b4a27f7866a595.webp)

Your codebase is infrastructure for the agent.
Design it that way.

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
EARENDIL

AI Engineer EUROPE
PRESENTED BY Google DeepMind

### An Agent-Legible Codebase

Clear boundaries let agents change one area without corrupting another. Cristina also separates the flow from user message to agent loop to output, where extra parsing and state can introduce unexpected behavior.

[10:52](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=652s) [Slide recommends clear module boundaries, known patterns, a simple core, and avoiding hidden magic.](https://assets.ai.engineer/sites/aiecode2025/sha256/c274cb3de29ec44156874571803e5a3e4645311c3f9d9b3076694bac3c11f45b.webp)

An Agent-Legible Codebase

• Modularization with clear boundaries: agents work in one area without corrupting another
• Known patterns and conventions: agents pattern-match; give them patterns worth matching
• Simple core, complexity pushed to layers above
• No hidden magic: if the agent can’t see it, it can’t respect it

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
AI Engineer EUROPE
PRESENTED BY Google DeepMind
EARENDIL

[11:38](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=698s) [Slide lists clear boundaries, known patterns, a simple core and visible behavior as principles for an agent-legible codebase.](https://assets.ai.engineer/sites/aiecode2025/sha256/e43a43e04d8052ca0648d76c98978812cdf0c2e461f1361c4807448f19c67f41.webp)

An Agent-Legible Codebase

• Modularization with clear boundaries: agents work in one area without corrupting another
• Known patterns and conventions: agents pattern-match; give them patterns worth matching
• Simple core, complexity pushed to layers above
• No hidden magic: if the agent can’t see it, it can’t respect it

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
AI Engineer EUROPE
PRESENTED BY Google DeepMind
EARENDIL

### Example Mechanical Enforcement

Earendil uses mostly linting rules to guide agent-written code: SQL stays behind one query interface, UI inputs use the component library, and unique function names make code easier to find.

[12:30](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=750s) [Slide lists six codebase enforcement rules, including restrictions on catch-alls, SQL, UI inputs and dynamic imports.](https://assets.ai.engineer/sites/aiecode2025/sha256/4a466b254a18e6dca23bbf4e84e2c7d8b1bc4d8c5b53d4925da7a773906de2a7.webp)

Example Mechanical Enforcement

• No bare catch-alls: forces the agent to think about error handling
• No raw SQL outside the abstraction layer: preserves the query interface
• No raw input boxes in the UI: forces use of the component library
• No dynamic imports
• Unique function names enforced: nudges toward discovery over duplication
• erasableSyntaxOnly TypeScript mode

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
AI Engineer EUROPE
PRESENTED BY Google DeepMind
EARENDIL

### Example Mechanical Enforcement

Most rules use linting: a shared SQL interface keeps agents from hunting across the codebase, while a UI component library keeps input styling and behavior consistent.

[12:53](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=773s) [Slide lists six codebase enforcement rules, including restrictions on catch-alls, SQL, UI inputs and dynamic imports.](https://assets.ai.engineer/sites/aiecode2025/sha256/bc5f9e28b328d94055fe9cc41057f21ee5876c37fff54794a6d858e5861ab96e.webp)

Example Mechanical Enforcement

• No bare catch-alls: forces the agent to think about error handling
• No raw SQL outside the abstraction layer: preserves the query interface
• No raw input boxes in the UI: forces use of the component library
• No dynamic imports
• Unique function names enforced: nudges toward discovery over duplication
• erasableSyntaxOnly TypeScript mode

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
AI Engineer EUROPE
PRESENTED BY Google DeepMind
THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
EARENDIL

[13:05](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=785s) [Slide lists coding rules for error handling, SQL, UI components, imports, function names, and TypeScript syntax.](https://assets.ai.engineer/sites/aiecode2025/sha256/e8198d3174278b7129d50db9f6437b4f5308a8f078fe8eef5ee32698983afac9.webp)

Example Mechanical Enforcement

• No bare catch-alls: forces the agent to think about error handling
• No raw SQL outside the abstraction layer: preserves the query interface
• No raw input boxes in the UI: forces use of the component library
• No dynamic imports
• Unique function names enforced: nudges toward discovery over duplication
• erasableSyntaxOnly TypeScript mode

EARENDIL
ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
AI Engineer EUROPE
PRESENTED BY Google DeepMind
THE FRICTION IS YOUR JUDGMENT
ARMIN RONACHER — Founder
CRISTINA PONCELA CUBEIRO — Software Engineer
EARENDIL

### Pull Request Review

A review extension separates issues the agent can fix, such as mechanical bugs, from human call-outs, including migrations, permissions changes and irreversible destructive operations.

[14:10](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=850s) [Slide separates issues actionable by an agent from changes flagged for human review.](https://assets.ai.engineer/sites/aiecode2025/sha256/7da2bbed30b9617aa4e57548483abd7a08156ef851a97f7d5dc6d47fe7ca9a40.webp)

EARENDIL

Pull Request Review

IMMEDIATELY ACTIONABLE → AGENT
• Style violations
• Mechanical bugs
• Clear engineering rule breaks

CALL-OUTS → HUMAN
• Database migrations added
• New dependencies introduced
• Auth / permissions changes
• Backwards-incompatible API changes
• Irreversible destructive operations

ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
OpenAI
AI Engineer EUROPE
THE FRICTION IS YOUR JUDGMENT
Braintrust
WorkOS
OpenAI

### Review Example

The review flags two image-processing bugs for the agent to fix and calls out dependency changes for a human to assess. The speaker says the agent would act on the first two if the reviewer selects “fix the issues.”

[15:24](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=924s) [Terminal review reports two image-processing issues and flags dependency changes for a human reviewer.](https://assets.ai.engineer/sites/aiecode2025/sha256/684048160f847a431c65391536b2a8b87f05ded26cc5a675b3f29da3fbcb1a66.webp)

EARENDIL

1. [P1] packages/elwing/src/tools/imageAnalysisFallback.ts:77-89 — Fallback sends original image bytes without size reduction, so large images can make the fallback fail

ImageAnalysisFallback re-encodes file.data directly and sends it to Gemini, but the primary image paths (ReadFile/DescribeFile) now explicitly resize to fit inline limits first. In the common case where the original attachment is large (e.g. high-res scans), the model can refuse the first pass, call this fallback, and then this fallback request can fail due to provider image-size limits. That breaks the “must call fallback instead of refusing” flow for exactly the oversized images it should recover.

2. [P2] packages/elwing/src/utils/exif-orientation.ts:67-73 — JPEG EXIF scan stops at first non-EXIF APP1 segment

In findJpegTiffOffset, when marker 0xE1 is found but hasExifHeader(...) is false, the function returns -1 immediately. JPEGs can contain multiple APP1 segments (e.g. XMP first, EXIF later), so this early return skips valid EXIF orientation data and leaves affected images mis-rotated in inline vision flows.

Overall verdict: needs attention

Human Reviewer Callouts (Non-Blocking)
- This change introduces a new dependency: @silvia-odwyer/photon-node, file-type (in packages/elwing/package.json)
- This change changes a dependency (or the lockfile): pnpm-lock.yaml updated for new packages and resolutions

ARMIN RONACHER & CRISTINA PONCELA
EARENDIL INC.

Interface text:
π - elwing
Review session active, return with /end-review
deep
~/Development/elwing (sonnet-native-image)
↑60k ↓6.0k R765k $0.324 (sub) 23.4%/272k (auto)
(openai-codex) gpt-5.3-codex • medium

## Full transcript

[0:00](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=0s) [upbeat music] Morning.

[0:15](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=15s) Thanks for having us. Um, today I wanna talk with Cristina about friction a little bit. Um,

[0:23](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=23s) this is, um, a, a social preview that came up automatically when someone submitted an issue, um, to, um, basically, uh, there was... This is a forum post that goes with, um, a security incident that was deployed accidentally.

[0:40](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=40s) It was a configuration change that caused the problem, and the social preview post had the marketing tagline of that company, which said, "Ship without friction." Um, and we wanna encourage to add a little bit of friction to it, um, and I'll tell you why.

[0:58](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=58s) So who are we? Um, I've been doing software development for 20 years, most of it in the open source space. Um, I have created Flask, which is a Python framework, which ironically is so much in the weights that a lot of people, um, are learning about it now because the machines are producing it.

[1:15](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=75s) Um, and I left my previous company that I worked for, Sentry, in April last year, which perfectly coincided with, um, me having time and then obviously Claude Code. And so I fell deep into a hole of, uh, agentic engineering, and I started writing on my blog and, and, and a lot of people reached out to me over

[1:32](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=92s) the last year, um, being all excited about this. Um, and then I started with a friend in October, a company called Earendil, where we are trying to make sense of all the AI things.

[1:44](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=104s) Um-

[1:46](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=106s) Yeah. And my name is Cristina, and I work with Armin at this company called Earendil. But importantly, I am what I like to call a native AI engineer, and what that basically means is that these tools have been around longer than I have.

[2:00](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=120s) Um, so what this means is, like, they've been super foundational in, well, how I've become a software engineer, not just because obviously I use them to work, but also because this is the means by which I've learned to do what I do.

[2:11](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=131s) And before Earendil, I was working at Bending Spoons.

[2:16](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=136s) So we wanna share a little bit from practice, not just theory, but, um, I will readily admit that I don't think I have all the solutions. So we have been building with or on agents for a good 12 months.

[2:27](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=147s) Um, we had m- huge leverage and great disappointment, and we, we really keep running into two types of problems. Um, I, I think especially if you listen to some earlier talks at, at this conference, you will have learned a lot about, um, that you should k- keep using your brain.

[2:43](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=163s) Um, it's, for some reason, it's really, really hard. So there's a psychological problem, and the other one is the engineering challenge. It's like they, they seem to be producing worse code for some people and better code for some other people, and, like, what is it that actually makes it work?

[2:56](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=176s) Um, and so this is really not a solution as it is our part of the journey [chuckles] of how we think so far we have managed. Um, yeah.

[3:05](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=185s) So problem number one is the psychology part, which is like, why is it even though everybody told you many times over that you should be using your brain, you should be slowing down, it's actually incredibly hard?

[3:14](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=194s) It's just one more prompt and, and we don't sleep that much. Like, what is it that actually makes it so hard? And then would it be that hard if the machines would actually be writing perfect code and we wouldn't have to think quite as much?

[3:24](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=204s) And, like, what is it-- Is there something we can do to make this a little bit better?

[3:29](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=209s) So I'll begin by introducing the first part of these problems, the psychology problem. And what I want to talk first about is the shift. So I'm sure a lot of us here who have been playing with these tools for a while now experienced this at some point.

[3:42](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=222s) We were prompting, prompting, not so good, and then at some point, suddenly it clicked, and they were really, really useful for us. And it was fun in the beginning, and they gave us a lot of extra time, right?

[3:53](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=233s) Because not everyone was using them. They were actually tools that made us more productive, that made it more fun to do our jobs. But very quickly, because they were so useful and they got us so hooked, everyone was using them.

[4:03](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=243s) And so this kind of had the opposite effect, where suddenly the baseline expectation was just that everyone is now using them, and you have to use them. And so this, this fun and free time translated into pressure.

[4:15](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=255s) Now we all have to ship faster and produce more code, and it is just not sustainable to review and to actually have time to think.

[4:25](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=265s) And so this leads us to the trap, and I actually think there's two parts of this problem, of this trap, and one of them a lot of engineers have spoken about, and it's that these tools are super addictive.

[4:36](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=276s) You never know if that next prompt is going to be the one that makes your product work and you've added a new feature, or if it's going to be that last drop of slop that brings your product crashing down.

[4:47](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=287s) And so it's very addictive. We keep doing what we're doing. It's not a great solution. But also most importantly, and I don't think we realize this as much, is that because we produce a lot of output very fast, we are tricked into thinking that we're actually being more efficient, doing more work.

[5:02](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=302s) And this is quite the opposite because now we don't have as much time to actually stop and think and decide what we're doing, ask ourselves, "Is this the best way in which I can implement this, or could I be some- doing something better?"

[5:13](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=313s) And when you're in this flow, it's very difficult for yourself to stop, and it's definitely very difficult for your agent to stop 'cause it's running around and it's reading files that it should have never even read.

[5:23](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=323s) So we are the ones that need to actually have the agency to be in control here.

[5:29](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=329s) And one thing that from a-- if you start scaling this from, like, one person to an engineering team, that actually took me quite a while to realize, is that it really changes the composition of the engineering team.

[5:40](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=340s) We, we were really supply constrained by creation of code, and so, like, the balance between writing code and reviewing code in engineering teams was usually quite decent. Now every engineer has a multitude of producing power compared to their reviewing power, and so obviously we are piling up on pull requests.

[5:58](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=358s) But we are also slowly starting to expand the total amount of humans in an organization that are participating in engineering process. I talked to a lot of engineers over the last year, and increasingly, the, one of the things that came up is like now I have marketing people shipping code.

[6:12](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=372s) I have, um, former CEOs ship-- so CEOs that used to be, like, engineers now shipping code again. And so

[6:20](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=380s) the, the roles that those people have in the companies also doesn't give them... The-there's not that much, um, um... The responsibility doesn't rest in them. The en- the responsibility still rests with the engineering team.

[6:33](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=393s) And so the, the total number of entities, both humans and machines, that are participating in the code creation process outnumbers the ones that can carry responsibility. We are not there where the machine can be responsible for the code changes.

[6:44](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=404s) And so that has led to more and more code reviews being skipped, being rubber-stamped. Um, and on the goal to small PRs that, that we wanna see again so that this reviewing process goes, um, this amplification is something that, at the very least, we need to recognize.

[6:59](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=419s) And so when you get this pull request that looks really daunting and has five thousand lines of code in it, this is actually when you should be thinking, and that's exactly when it's the most overwhelming, and, and increasingly, we're tapping out of this.

[7:13](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=433s) On the engineering side, what we're doing is we are creating larger pull requests. We're creating these massive changes because the, it is free now, right? And the-- If you think about how the agents work, they're really optimized to creating code that runs.

[7:28](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=448s) Like, their main objective is write some code, run the tests, make some progress. The reinforcement learning sort of gets this in. And so the, the agents are writing kind of codes that is, is when you as a human, as an s-software engineer, start learning how to write code you wouldn't necessarily write.

[7:46](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=466s) So, for instance, you see quite a bit of code that tries to read a config file, and if it doesn't read the config file, it loads some defaults. And as an engineer, you know that's actually not great because I might not notice that I'm reading, re-reading the default config file.

[7:58](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=478s) And so I might only discover that I have a massive problem after two hours when I already wrote database records with wrong data. And so these machines, they, they optimize towards making progress, towards shipping stuff, to, like, unblocking themselves.

[8:13](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=493s) And as a result, they're creating many more failure conditions than human-written code normally would do. And in part, it's because you as a human feel a little bit of a...

[8:21](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=501s) You feel bad when you write code like this. There's, there's something that sort of builds up emotionally in yourself. But the agent doesn't have a reason for this. It, it doesn't feel anything.

[8:30](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=510s) And so if you, if you create these services that are sort of hobbling along and they're actually willing to, to recover from local failures, you actually create very, very brittle systems.

[8:40](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=520s) And this also means that you're very quickly creating a code base of the size and complexity that the agent itself can no longer dig itself out from. It's going to start no longer reading all the files that it should.

[8:51](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=531s) It's, it's creating code in a new file that it has already done somewhere else. And so this, this entire machinery over time creates much more entropy in the source code than you would normally have if, if humans were on it.

[9:04](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=544s) And, and a big part of this is that humans feel bad, and the agents don't really have any emotions that they communicate to you.

[9:11](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=551s) But as Armin likes to say, don't worry. Not all is lost. We have sou-found some correlation between what the agents really excel at doing and the types of code bases that we actually put them to work into.

[9:23](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=563s) And for example, the main example here is libraries versus products. What we found is that for libraries, they tend to excel a lot more. And this makes sense because intrinsically, when you're building a library, you tend to have a very clearly defined problem that you're trying to solve.

[9:37](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=577s) And most of the time, you can even map the set of features that you want to build to the API surface, and it has very tight cons-constraints. And because this is something that you probably want to build on top of or make accessible to other people, it's likely that it's going to be a very simple core in

[9:51](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=591s) which you can then plug into. And on the other hand, products, and perhaps this is a bit more unlucky for the rest of us because we all probably are more into building products, uh, it's much harder because there are so many interacting concerns and components.

[10:05](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=605s) Like, for example, you have your UI, your API response. You have different permissions depending on the feature flags, the billing, and so on. And so there's this very heavy intertwining between different components.

[10:16](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=616s) And what this means is that for the agent itself, it's impossible to fee-fit all of this into its context window. It has no way to actually understand the entire global structure.

[10:27](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=627s) And so locally, the agent tends to be very reasonable, but when it gets to the global scale, it becomes a bit demented.

[10:34](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=634s) So what we're proposing here is that just as you would do with any type of system design in the past, your code base has now become infrastructure. And as such, you have to design it in a way so that it is also legible for the agent, and it can make the most of it.

[10:51](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=651s) And so this is what we're proposing is an agent-legible code base. And one of the main points that is very clear to all of us, I'm sure, is modularization.

[10:59](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=659s) So, like, we have different components, and this makes it easy for the agent to add one feature in one spot without corrupting everything else. But importantly, this also means modularizing your code flow itself.

[11:10](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=670s) So, for example, I've been working on some refactoring. We're building somewhat of an AI assistant. And for me, it was super important to understand which steps of my code are actually, like, the main points.

[11:21](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=681s) So say, like, you get user message, then I pass the message to the agent's loop, and then I have to deal with the output. And this is where these points are very clearly defined for me, so the code was not as messy.

[11:33](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=693s) But it happens to be that between these points, between these steps, that's where the agent tends to add the most fuzz. So it will be parsing between different types.

[11:41](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=701s) It's adding things to state that shouldn't be in state. And so you end up with these behaviors that you didn't want to support and that are unexpected and can be quite dangerous.

[11:51](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=711s) Another point is trying to follow all of the known patterns because I think we all know by now there's no point in fighting the RL, the reinforcement learning. The more we can lean into it, the better that our out-output is going to be, and it's also more scalable down the line.

[12:07](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=727s) Then as mentioned with libraries, like if you have a simple core and you push the complexity to other abstraction layers, then it's going to be easier for yourself and the agent to be able to read your code base, and no hidden magic.

[12:18](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=738s) So for example here, uh, using React Server Actions or using ORM instead of raw SQL, what this does is that it hides intent from the agent, and if the agent can't see something, it can surely not respect it.

[12:32](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=752s) And so to be more precise, these are the examples of mechanical enforcement that we have been using at the company. And most of these we actually achieve with, uh, linting rules.

[12:44](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=764s) So the main example would be no bare catch-alls. Great. [laughs] Imagine that there's an example here. The agent found a bare catch-all, and it was like, "Oh, no, this is bad.

[12:53](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=773s) Edited it." But yeah. So we also try to have our SQL, uh, always in one query interface, so that the agent doesn't have to go hunting around the code base finding all of the different places.

[13:05](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=785s) Because if it misses one, then you can have breaking behaviors, and again, that's dangerous. We try to have one primitives components library for the UI and not have any raw, for example, input bo- uh, input boxes, uh, so that it's-- we always have one type of styling.

[13:19](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=799s) It's very consistent, one kind of behavior. We don't have any dynamic imports. And this may not sound as important, but actually w- we enforce unique function names. And the reason for this is not just more legibility for you and the agent, but it's actually also the token efficiency.

[13:34](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=814s) So if your agent is grepping for a specific feature or something in your code base, if it only gets one output, it's going to be much better at continuing with the loop.

[13:43](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=823s) And we've started exploring something recently called erasableSyntaxOnly TypeScript mode. And what this does is that your code is basically JavaScript, and it has the type annotations on top. And this means that there's no transpiling indirection because there's one source of truth between your actual code and the compiler.

[14:01](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=841s) And so when the agent is looking for errors, it doesn't have to have this, like, confusion of, "Oh my God, where am I looking at?" It's, it's much better at finding them.

[14:11](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=851s) And so the goal really is get in this loop somehow. Like, get the agent to produce as good code as it can, but you really need to find a way to feel the pain that the agent doesn't feel, and you need to be woken up in a way when you should be looking at this.

[14:28](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=868s) And one of the things we have been doing is we build a pi extension for our review needs, where we are separating out the kind of input that normally would go back to the agent.

[14:37](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=877s) So this is mechanical bugs. It is where it clearly violated AGENTS.md. Um, but then we specifically call out the kind of changes where the human's brain should reactivate, right?

[14:48](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=888s) It's like we don't think that the database migration should ever go in without a human making a judgment call on this because it very much depends on the locks, the size of the data in production.

[14:57](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=897s) Um, if there are permissioning changes, you better think about this themselves rather than the agent because they can be, they can be under-documented. They're just some examples where we learned if we miss it, we regret it.

[15:09](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=909s) Um, and you will miss it, but these, these machines can help you find this. And then you see this, and then you actually get a little bit of a hit and like, "Oh, now I have to kick into gear and do something here."

[15:21](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=921s) Um, this is what this looks like in pi. Um, you have the, um... On the bottom, you have the human call-outs. On the top, you have what is go- what's basically if you were to end this review and select fix the issues, the, the agent would go back and automatically act on the first two.

[15:37](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=937s) Um, but, but this is the moment where I will now go and see, like, is this a dependency I actually wanna have in this code base? Like, do I like the maintainers?

[15:44](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=944s) Is this-- Does this work for me? And we obviously like the speed. Like, this is addictive. It is great. We feel there's a lot of productivity. But it is so devious if you start relying on that speed where you really shouldn't.

[16:00](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=960s) And so I can only encourage you to find the areas where you, you have this feeling that this is actually not positive. For me, a lot of this is reproduction cases.

[16:09](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=969s) Like, when a customer reports an issue, I can, I can have the agent reproduce this perfectly, and I have a really good starting point. Exploring different type of product directions for as long as you commit yourself to doing this, uh, with the code that it generates.

[16:22](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=982s) Um, all of this is great, but on the other hand, system architecture, creating reliability in the system, they are just not very good at.

[16:29](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=989s) Because we really still have to go slow. It's-- There is so much mess that can appear in a code base in so little time. Mario was already talking about this earlier, but, like, we forget that we are producing months and months of technical debt in the, in the, in a time of weeks, in a time of days

[16:43](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=1003s) sometimes. And it becomes so much harder to actually understand what's going on in this code base. The-- When the understanding of your own code drops, it is really, really hard, and it's also psychologically hard.

[16:54](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=1014s) I found some code pieces that actually didn't work in production, and I was kind of frustrated learning that I was the one that committed with the agent and just didn't really see that.

[17:04](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=1024s) It's, it's a very disappointing experience when it happens, and then you realize that you actually were the one that screwed up. Um, and so it is, it is psychologically incredibly hard to s- to really judge objectively the state of the code base, and the only way right now is to really slow down a little bit on, on

[17:22](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=1042s) that front. And this, this friction, I know that friction, like every engineering team I've ever worked at said, like, "We need to get rid of the friction in, in shipping," and, and that is true.

[17:32](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=1052s) Like, there's a lot of stuff that's very, very annoying and shouldn't be there. But if you have worked in large enough engineering org, SLOs are a great system that is intentionally designed to put friction to the engineering process to make you think, "Do I need this reliability?

[17:45](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=1065s) Do I need this criticality of the service? Am I sufficiently staffed to run it?" And with the agents, we have now gotten this idea that we should get rid of all of this, when in all reality we need of it.

[17:56](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=1076s) Um, because the friction actually in many ways is what's necessary on a physical level to steer. Like, without friction, there is no steering, and, and that is really necessary.

[18:07](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=1087s) Um, so you should, you should g- put a little bit more of a positive association to this idea of friction, um, because this is really where your judgment is, this is where your experience is, and you should be inserting that and start feeling it.

[18:19](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=1099s) Thank you.

[18:20](https://www.youtube.com/watch?v=_Zcw_sVF6hU&t=1100s) Thank you. [audience applauding] [upbeat music]
