AI Coding Agents

Elephant-Goldfish Model: Review the Plan Before AI Writes Code

AI Labs tries the Elephant-Goldfish Model (EGM) on a demo fashion app. Instead of asking a coding agent to implement a new seller analytics page immediately, the team maps the app, debates the feature, writes a design, and sends fresh-context agents to challenge that design. After implementation, a drift check spots a separate rule violation: a sold product could be deleted when it should only have been hidden.

The interesting part is not the number of agents. It is the information boundary: reviewers receive the written plan and relevant code, but not the conversation that led the main agent to its conclusions. They can therefore question assumptions the planning session may have started treating as settled.

The practical answer

Use EGM for a feature where a wrong data rule, user journey or architectural decision would be expensive to unwind. Begin with a human-reviewed design document; let isolated reviewers challenge it; then implement and test against the approved plan. For a small, contained fix, the repo's own getting-started guide says not to force the full workflow. EGM is open source and free to download, but its agent calls still consume your model allowance or API budget.

Watch the AI Labs Walkthrough

Source note: The fashion-app results come from AI Labs' demonstration and supplied transcript; we did not run their app or reproduce the bug. The video includes a Hedra sponsorship and promotes AI Labs' own community and software service. The tool's design and installation details below were checked against the source repository on 26 October 2026.

Three Roles, Different Context

RoleWhat it receivesIts job
ElephantProject history, architecture, user goals and the design conversationClarify the problem and write a reviewable specification.
GoldfishThe design document, relevant code and an assigned review lens; not the prior chatTry to explain, simplify or break the plan before code is written.
HumanThe competing reports and real product constraintsChoose trade-offs, reject weak feedback and approve the work.

This is the model described in Google's open-source announcement and Dave Rensin's foundational essay. “Zero context” means zero inherited conversation, not no information at all. A Goldfish can still overlook a problem, misunderstand the code or share the same model biases. Its report is evidence to evaluate, not an automatic veto.

The GitHub project is published under the Apache 2.0 license and was created at Google. Its README explicitly states that it is not an officially supported Google product. The Google Open Source Blog says the method was developed internally and is used by Google engineers; readers should still treat this repository as community-maintained open-source software rather than a Google support contract.

The Workflow: From Existing Code to Approved Spec

  1. Bootstrap, when needed. /egm-bootstrap maps an existing codebase and creates or updates directory-level README contracts. In the video it produced 28 new READMEs for the demo app. This is optional: the official guide says existing design artifacts may already supply enough context. Review generated documentation before relying on it.
  2. Brainstorm. /egm-brainstorm questions the proposed seller-size and restocking page, then uses separate reviewer lenses to stress-test the concept. The output is a concept brief, not implementation code.
  3. Draft. /egm-draft builds a Markdown design under docs/designs/, including problem scope, user journeys, technical approach, alternatives and implementation steps. The presenter approves sections as they are added.
  4. Review and resolve. /egm-review docs/designs/<feature>.md runs fresh-context reviewers across comprehension, design criticism and implementation readiness. The video describes five review rounds in its chosen run; the repo's current architecture describes the review as a multi-stage pipeline. Resolve findings with human judgment before treating the document as approved.
  5. Implement, test, then check drift. Build against the approved spec, run normal tests and review the diff. Later, /egm-drift-report compares design contracts with the live code. Its findings can mean either the code is wrong or the document is stale; a person decides which to change.

The repository's workflow guide also recommends a human review of the design pull request. EGM does not define your build, security or test strategy for you. A detailed plan is an input to those checks, not a replacement for them.

What the Video's Drift Check Actually Found

AI Labs asks the drift report to inspect the whole demo app against its README rules. The report flags a conflict: shop owners could delete a product after it had sold, while the documented invariant allowed such products to be hidden but not deleted. This is a good example of the method's value because the problem is a business rule across data and UI behavior, not just a malformed line of code.

The video shows the report identifying the issue; it does not establish that EGM found every defect or that the new analytics feature was fully correct. Before a production fix, reproduce the deletion path, check affected orders and permissions, add a regression test, and decide whether the invariant or implementation should change. Drift findings require verification because generated READMEs can themselves be inaccurate.

Install From the Project's Published Instructions

The current harness guide lists separate install routes for Claude Code, Codex and Antigravity. Review the repository and its version before giving any plugin access to a valuable project. These are commands to run in your own terminal when you decide to install; this article did not execute them.

HostOfficial install commandCommand shape afterward
Claude Codeclaude plugin marketplace add google/elephant-goldfish-model
claude plugin install egm@egm
/egm:egm-brainstorm
Codexcodex plugin marketplace add google/elephant-goldfish-model
codex plugin add egm@egm
Invoke the installed EGM skill in a supported Codex surface.
Antigravityagy plugin install https://github.com/google/elephant-goldfish-model/egm-brainstorm or the plugin UI.

The README also offers a generic “Install this repository” prompt for any agent. The explicit plugin route is easier to inspect and less likely to invent extra setup steps. Do not copy only the skills/ folder: EGM's skills refer to reviewer personas and standards elsewhere in the plugin. The repository says Claude Code, Codex and Antigravity have automated install and reviewer-isolation fixtures, while some other surfaces still have trace-verification gaps. Check actual subagent availability in your host rather than assuming feature parity.

The CLAUDE.md Trap in the Video

AI Labs used the generic install prompt. Its agent independently wrote a CLAUDE.md instruction claiming that Claude Code subagents could not create subagents. In the version they tested, that line was wrong, and it blocked the intended nested reviewer workflow until they corrected and retested it. This was a generated local instruction in their setup, not a requirement stated by the EGM README.

After installing, inspect new files under your agent configuration, especially CLAUDE.md or AGENTS.md. Look for claims about tool limits, blanket permissions and commands that are not in the repository. If a nested review cannot run, compare the host's current capabilities with EGM's delegation guide. The project documents a direct-dispatch fallback when nesting is unavailable; it also says a supposed Goldfish review must stop if the host cannot provide a genuinely fresh context. Do not fake independence by asking the same conversation to play a different persona.

One more practical point from the demo: bootstrapped READMEs are useful only if the agent actually reads the relevant ones. Link them from your existing project instructions or use the documented bootstrap options, and keep those instructions short enough that they are followed.

Where the Extra Review Earns Its Keep

Use it for cross-module features, data migrations, access-control changes, financial rules or workflows where an ambiguous plan could create costly rework. Run a small pilot with a clear acceptance test first. Track the time and usage spent on brainstorming and Goldfish reviews against the defects they identify before implementation.

Skip or shorten it for a one-line fix, a reversible prototype or work with a complete, well-tested spec already in hand. The official guide explicitly says the skills are flexible and need not run in a fixed order. The repo is free to download, but each agent pass consumes tokens or plan usage, and longer review can slow delivery. More reports do not automatically mean a better decision.

The productive lesson is simpler than “always run five rounds”: give a fresh reviewer enough written evidence to challenge the plan, preserve the disagreements, and let an accountable human decide. Then test the resulting code.

Video Chapters by Stage

Jump directly to the method, installation or the real bug. Times follow the supplied video outline; the sponsorship is labeled for clarity.

The idea

TimeTopic
00:00Why review the plan before coding?
00:47What the project is
01:43Elephant and Goldfish roles
03:02How it differs from ordinary plan mode

Install and build the plan

TimeTopic
04:54Installation paths
06:07The generated CLAUDE.md issue
07:08Bootstrap the existing app
09:29Hedra sponsor segment
10:18Brainstorm and concept brief
11:32Draft the design document

Review and validate

TimeTopic
12:42Goldfish review rounds
13:50Drift report and product-deletion bug
14:35When the overhead is justified

Sources and Scope

Demo: AI Labs' walkthrough and the user-supplied transcript. Project: Google's repository, getting started, and harness documentation. Background: Google Open Source Blog's announcement and Dave Rensin's essay. We checked these sources on 26 October 2026. We did not install the plugin, reproduce the demo app's bug or measure EGM against ordinary plan mode in a controlled comparison. Recheck the repository before following commands because plugin and agent-host behavior can change.

Common questions

Is the Elephant-Goldfish Model an official Google product?
No. It is an Apache-2.0 open-source project created at Google and published under google/elephant-goldfish-model. Its repository explicitly says it is not an officially supported Google product.
Do Goldfish agents know nothing at all?
They are isolated from the prior design conversation, but they receive the design document, relevant source code, their reviewer instructions and any context explicitly passed to them. Fresh context reduces one source of anchoring; it does not guarantee an unbiased or correct review.
Does EGM work with Codex as well as Claude Code?
The repository documents plugin install paths for both. Actual reviewer isolation and subagent delegation depend on the capabilities exposed by the chosen host. Check the repository harness guide and test with a small project first.
Should I use EGM for every bug fix?
No. The official getting-started guide explicitly recommends using the right tool for the task and not forcing a full design-first process for a simple one-shot fix.
Share
X LinkedIn Reddit
Build Yours

Want a system
like this one?

Book a free 30-minute call. We map your situation, identify the highest-impact automation, and figure out if we are a fit.

Book Free 30-min Call