with-agents

All Code Is Slop (Except Mine) — Lauren Tan, SpaceXSI

Lauren Tan argues that each correction to an agent should become code, a lint rule, or a check rather than another AGENTS.md line, because agents copy whatever patterns the codebase shows them. Her Grok Bot examples include banning useEffect in product code, lint-enforced Electron main/renderer separation, removing most comments that let agents justify workarounds, and review based on runtime, TLA+, Lean, and property-based verification evidence. First-party account with team-reported PR counts, revert rate, and performance gains; ends with a product pitch.

AI Engineer

Lauren Tan, who introduces herself as Potato and says she works on Grok Bot at SpaceXSI, says she shipped 3,000 pull requests to production in the month before the talk, many of them while she slept. Her thesis is that a software engineer's job is now to keep or improve code quality while output rises sharply. She frames this as trust: not trusting agents blindly, but investing in their environment until you can trust them to do the right thing. She says this took her six months. Most of the talk explains where that investment goes: the codebase, static checks, and verification before written instructions.

Source basis: This summary uses the video's English auto-generated YouTube captions. No translation or original-audio check was performed. The captions render the product name in several garbled forms (such as "Graph Bot" and "Grabot"); the transcript normalizes them to Grok Bot, the name on the conference's talk page, and corrects tool names such as TLA+ and Lean. The talk does not explain the name SpaceXSI. This is a first-party account: pull-request counts, the revert rate, and performance improvements are team-reported without methods or baselines, and the talk closes with a pitch for Grok Bot, her team's product.

Key points

  • Put effort into deterministic checks before written rules. Tan's "inverse pyramid" orders where to spend time on an agent's environment. The first two layers are deterministic: the code itself (API design, architecture, refactoring) and static tools (lint rules, type systems, compilers, tests), which constrain agents and make the right thing the default. Runtime and formal verification come next, to find bugs, check invariants, and confirm the agent understood the goal. Prose such as rules, skills, and AGENTS.md comes last, for things that need judgment. Her rule: when you correct an agent, try to make the correction a deterministic check instead of another line in AGENTS.md, because a check in code is reproducible and easier to trust. 01:40–03:27(opens in a new tab)
  • Agents copy whatever the codebase shows them. The codebase is one of the largest inputs to an agent. Tan contrasts reviewing about three colleagues' pull requests a day in 2024 with about 300 now, which makes code arrive as a near-continuous stream. Workarounds, anti-patterns, deprecated code, and tech debt look like established patterns, so the next agent copies them and they spread. She compares the engineer's job to gardening: keep the codebase clean so agents copy good examples. 02:32–05:08(opens in a new tab)
  • Dune bans or fences off code patterns that agents misuse. Dune is a client framework the team built for Grok Bot; Tan describes it as roughly "Next.js for Electron apps" and says its value lies in constraints and lint rules that encode lessons from building desktop apps. Her lesson is that anything that needs nuance to use well tends to produce slop. React's useEffect is banned in product code and allowed only inside some Dune APIs, which she says removed the problem from code review. A second example came from Cursor, another Electron app, where agents imported main-thread code into the renderer and caused long tasks and stutter. Tan calls the fix "context through directory structure": Grok Bot and Dune apps use two top-level directories named for Electron main and Electron renderer, and a dependency-graph analyzer plus lint rules forbid imports between them. 05:08–06:56(opens in a new tab)
  • Comments gave agents a place to justify workarounds, so the team banned most of them. Tan says agents use Markdown, comments, rules, and skills to write down why they did not do the right thing, or turn one small correction into an unbreakable rule. At Cursor, agents patched over a clash between VS Code's imperative style and React's declarative style with timers such as setTimeout, requestAnimationFrame, and requestIdleCallback, and wrote comments explaining why each quick fix was justified. The timers spread, and creating and destroying many of them caused major garbage collection and lag. Grok Bot now bans about 99% of comments, because they go stale, people rarely read them, they give agents an escape hatch, and they cannot be enforced. Lint rules instead give error messages telling the agent to fix the root cause. 06:56–09:23(opens in a new tab)
  • As checks accumulate, review shifts to verification evidence. The team's principle is that every correction becomes a deterministic check or a change to API design or architecture that removes the problem. Tan says that if you do this enough, there is eventually nothing left to look for in review, and agents can merge most of their own pull requests. Review has shrunk to inspecting verification artifacts: videos, screenshots, diagrams, and formal verification results. 08:33–10:16(opens in a new tab)
  • Runtime verification gives agents a shared map and reusable tools. Runtime verification means letting the agent run the code and use the debugging tools developers use, such as the Chrome DevTools Protocol. The team's runtime-verification skills include a feature map, a site map of the app's features from the user's point of view, so an agent does not have to guess what "the thingy in the left sidebar" means. The skills also ship custom CLIs that agents reuse each time, which cuts token use and can itself be tested. 09:23–11:06(opens in a new tab)
  • Formal methods and property-based UI tests are still experiments. The team uses TLA+ to model-check major user flows such as notifications across devices and platforms, and Lean to prove properties of algorithms, such as showing that its custom virtualization library does not flicker or jitter. Tan says formal verification has already found quite a few bugs but is "not a silver bullet," just another layer. Property-based UI testing with a library called Bombadil has caught a few UI bugs. Her state chart skill in P-Stack, her plugin, draws state machines from the user's point of view, which she finds easier to review alongside videos and screenshots. 10:16–12:05(opens in a new tab), 12:54–13:45(opens in a new tab)
  • Most token use goes to verification because agents made it cheap. Tan cites a post by an engineer named Cindy, who six months earlier could not trust her agents because subtle bugs were being merged and now says 70% of her daily tokens go to verification. Tan says most of her own tokens go there too. None of these techniques is new; they were often too expensive to write, understand, or maintain, and agents lower that cost. She calls this a "golden age" of testing and verification. 11:06–12:54(opens in a new tab)
  • The team reports high volume without more reverts. Tan says the Grok Bot team shipped 11,000 pull requests to production in the previous month, cuts a stable client release about once a day, and had about 227 contributors in October, including drive-by contributors with little context. She says the share of reverted pull requests has fallen and holds at about 0.5%, and that startup, typing, and opening or switching chats have become faster since launch, though the app is still on Electron. These are team-reported figures without a stated baseline or method. 12:54–15:49(opens in a new tab)
  • Fix the inner loop before automating it. Before building a "software factory," Tan advises fixing problems in the codebase first: add a lint rule to stop new occurrences of an anti-pattern, then clean up the old ones, and make verification strong. If the inner coding loop produces slop, automating it produces more slop and burns more tokens. Her product pitch follows: Grok Bot as the outer loop, with connectors and routines that start Cursor cloud agents and projects. On each release, Grok Bot starts a Cursor project that fuzzes the build by using the app like a real user, opens a fix pull request for each bug, and auto-merges them. She says this works because pull requests tend to be good by default, and that most product code no longer needs deep human review. 14:49–17:31(opens in a new tab)

Full video: https://www.youtube.com/watch?v=O_zcc6Xl12g(opens in a new tab)

Search

Search field guides and resources across the site.

    Keyboard shortcuts

    Press ? to open this guide (usually Shift + /). Close it before using other site shortcuts.

    Show keyboard shortcuts
    ?
    Search site
    Ctrl + K
    Close the current dialog or menu
    Esc

    Site shortcuts are ignored while typing. Browser and extension shortcuts may take priority.