Google's Elephant Goldfish Model (EGM): What It Is and How It Works
Google's open-source EGM plugin uses elephant and goldfish sub-agents to design and review coding features before anyone writes code.

What is the Elephant Goldfish Model (EGM)?
EGM is an open source plugin from Google that adds a design-and-review workflow on top of your existing coding agent, instead of replacing it. It splits the work into two roles: an “elephant” agent that holds full project memory and writes a design document, and “goldfish” sub-agents that review that document with zero prior context. The goal is to catch the gaps that creep in when you and an agent have talked for an hour and both forgotten what a fresh reader wouldn’t know. It’s Apache 2.0 licensed, lives on GitHub under Google’s org, and installs into Claude Code, Codex, ChatGPT work, and Google’s own Antigravity agent.
TL;DR
- EGM is a process layer, not a model. It’s a set of skills and sub-agent prompts that sit on top of whatever coding agent you already use, rather than a new AI system itself.
- The elephant writes, the goldfish reviews. The elephant keeps full conversational context and drafts the design doc; goldfish sub-agents get only the doc and the files it references, with no memory of the conversation that produced it.
- It runs on non-Google tools by design. Despite coming from Google, which already has Gemini, Gemini CLI, Jules, and Antigravity, the project ships first-class install support for Claude Code and Codex, and works through Cline since those tools support markdown skills and sub-agents.
- The workflow has clear stages. Brainstorm, draft, review, and resolve each map to a slash command, and the review step alone runs five separate review passes through fresh sub-agents.
- Reviewers are told not to flatter you. The review personas are explicitly instructed to lead with risks and problems rather than validate your idea, and to argue the strongest case against your proposal.
- It refuses to fake the review. If the host agent can’t spawn genuinely fresh sub-agents with isolated context, EGM is built to stop rather than run a “review” in the same contaminated session.
- It’s not meant for small fixes. The project’s own documentation says a quick bug fix should just go through your normal workflow, since the design and review cycle costs real time and tokens.
Where does the elephant and goldfish idea come from?
The concept is drawn from an essay by Dave Rensin called “Elephants, Goldfish, and the New Golden Age of Software Engineering.” The metaphor maps directly onto two failure modes in long AI coding sessions. An elephant never forgets: it accumulates every requirement, every tangent, every assumption you’ve both made over the course of a conversation. A goldfish forgets almost instantly: it has no memory beyond what’s in front of it right now.
Rensin’s insight, as applied in EGM, is that both properties are useful if you assign them correctly. You want an agent with elephant memory to actually write the design, because it knows the full history of decisions. But you don’t want that same agent to review its own design, because it will read right past the gaps it already filled in mentally during the conversation. A goldfish, with no shared history, reads the document literally. When it hits an undefined term or an unhandled failure case, it has no choice but to flag it, because it has nothing else to go on.
EGM adds a third role on top of these two: the human. The agents draft and critique, but the person using the tool decides what actually gets built and signs off on the design.
How does the EGM workflow actually run?
In Claude Code, every command uses a /gm prefix. The flow has four main stages:
Brainstorm. You describe a feature in plain language. The agent asks clarifying questions, then dispatches six goldfish reviewers in parallel, each reading the idea through a different lens. One plays a contrarian whose job is to ask whether the feature should exist at all, or whether an existing library already covers most of the need. Another focuses on cost and token economics. The output is a concept brief file capturing the agreed direction.
Draft. The concept brief becomes a full design document. Rather than generating the whole thing in one shot, the agent writes it section by section and pauses after each one for feedback, which mirrors how a design doc review should work in practice.
Review. This is where the goldfish do their heaviest lifting, across five distinct passes: a “zoom out” architectural review looking for unnecessary complexity, a comprehension review that flags unexplained terms and acronyms, a hostile design critique focused on architecture and risk, a second zoom-out pass, and an implementation-readiness check meant to catch any decision the document leaves unresolved for whoever builds it. The documentation is upfront that this produces a lot of feedback, more than you’ll likely act on, and tells users to take what’s useful and discard the rest.
Resolve. A final step walks through the review findings so you can decide what to change before implementation starts.
Other agents ship a demo. Remy ships an app.
Real backend. Real database. Real auth. Real plumbing. Remy has it all.
Two supporting skills round out the toolkit: a bootstrap command that walks an existing codebase folder by folder and writes summary documentation up to the root, giving the elephant a map of an unfamiliar project, and a drift report that compares design docs against current code to flag where they’ve diverged, intended to be run periodically.
Why did Google build EGM to work outside its own tools?
This is the detail that stands out most. Google has its own coding agent stack: Gemini, Gemini CLI, Jules, and Antigravity. Yet EGM’s documentation leads with install instructions for Claude Code and Codex, complete with dedicated adapter folders and manifests, not a token afterthought port.
The explanation is architectural rather than political. EGM’s reviewers only need two things from a host agent: the ability to read a markdown skill file and the ability to spawn a genuinely fresh sub-agent with no access to the calling session’s history. Claude Code, Codex, Antigravity, and Cline all now support that pattern in some form. Because EGM’s skills and persona files are a single shared set of text rather than a forked implementation per tool, each harness just maps its own notion of “sub-agent” onto the same prompts. Write the workflow once, run it wherever the underlying agent supports isolated sub-agent contexts.
That also means the practical value of EGM isn’t tied to Gemini models at all. The design-and-review process is model agnostic by construction, which is why people have been running it through third-party model access services with Claude Code or Cline, mixing models like Kimi, GLM, and DeepSeek for different review roles rather than relying on a single provider end to end.
Is EGM worth using for every feature?
No, and the project’s own FAQ says so directly. For a small, well-understood bug fix, the recommendation is to skip EGM and just use your normal workflow. The brainstorm and review stages take real time, and spinning up five or six fresh sub-agents to read a document and reference code from scratch burns noticeably more tokens than just telling an agent to implement something directly.
Where it earns its cost is on features that involve actual tradeoffs: things with failure modes worth thinking through, architectural decisions that are expensive to reverse, or any case where you’d normally spend an hour talking through the problem before writing code anyway. If you’re already having that conversation with an agent, EGM gives it a structured output (a design doc) and a built-in way to stress-test it before implementation starts.
Why does the “no fake reviews” rule matter?
One of the stricter design choices in EGM is that if the host agent can’t create isolated, memory-free sub-agents, the review step is built to stop rather than simulate one in the same context. A review conducted in the same conversation as the draft isn’t a goldfish review at all, since the reviewing agent still carries every assumption from the drafting conversation. This is also why the Claude Code integration ships its own sub-agent adapters with read-only tools and isolated context per reviewer: the mechanism only works if the goldfish is actually forgetful.
Frequently Asked Questions
What does EGM stand for?
EGM stands for Elephant Goldfish Model, named after the memory metaphor from Dave Rensin’s essay on elephants (full context, long memory) and goldfish (no memory, fresh perspective) applied to AI coding agents.
Is EGM an official Google product?
No. The project’s own repository states it is not an officially supported Google product. It is described as a team project, built and apparently used internally by Google engineers, but released without the backing of an official product launch.
Which coding agents support EGM?
EGM has first-class install instructions for Claude Code, Codex, ChatGPT work, and Google’s Antigravity. Because it’s built from plain markdown skills and sub-agent persona files, it can also run in other tools that support the same pattern, such as Cline, with some manual setup.
Does EGM write code itself?
No. EGM is focused entirely on the design and review phase before implementation. It produces a concept brief and a design document, and runs structured reviews against that document. Once the design is approved, you direct your coding agent to build it using your normal workflow.
Why does EGM use multiple review passes instead of one?
Different review passes are tuned to catch different problems: unnecessary complexity, unexplained terminology, architectural and scaling risk, and missing implementation decisions. Running these as separate fresh-context reviews, rather than one general pass, is meant to surface the specific kind of gap each reviewer type is built to look for.




