This weekend I decided to play around with agentic loops and the results have been :chefskiss:. I’m using loops and combining Codex CLI and Antigravity CLI working with Claude Code as my primary agent to produce great results with less human attention.
This is going to be a quick post about the exact prompts I’m using to share because a user on HN asked about them.
Comparison to Fable
I extensively used Fable when it was available, and I felt like the biggest benefit was that it would run for longer periods without requiring my attention. This recipe has reproduced a similar result using Opus, maybe even better code with similar levels of gumption (working without needing feedback).
Dependencies
- Claude Code, you’ll likely need at least the $100/mo level to do anything substantive. I’m using the Opus 4.8, and almost always in “/effort ultracode” for software development tasks. I’m running Claude Code with “defaultMode: auto” so it doesn’t ask questions for every item.
- Codex CLI, I’ve mostly made do with the $20/mo level, especially if you can wait a few hours on larger sessions for it to reset. Using “/model gpt-5.5” with “Extra high” reasoning level.
- Optional: Antigravity CLI, I’m not sure the exact product I’m using here, I think I’m getting some level of Google AI bundled with a google subscription, but potentially the $20/mo level if you need to buy it. I’m using “/model Gemini 3.5 Flash (High)”.
Project Setup
Create a directory called “loop”. Put a file “description” in there that is a description of what you want to achieve. Think: The prompt you’d type into Claude Code pre-loops.
The prompts are below, skip ahead if you don’t want to hear about some quick experiences with them.
Success Stories
I only started using them a couple days ago, I have a few projects in flight, but I also have had some completed.
- API server port from Python to Go. I have an API and thin app server in Python. I gave it a 1KB prompt asking it to convert it to go. It asked a few questions, and then worked for 4 hours unattended. At the end I had a fully functional replacement for the Python FastAPI server. 3.8KLOC of go, 2.2KLOC unit tests, 3.1KLOC contract test suite. This included porting the release process.
- A Studio Shed “planning dept conversation packet”. I’m building a 200sqft “studio shed” that I need to get a permit to build. But I need to talk to the planning dept about it and what exactly I need to provide (do I need stamped plans, for example). I tried to do this using only Claude prompting and providing feedback and manual review. The results weren’t close to usable. Using this recipe and a 2.7KB “description” file, plus 2 feedback rounds, I got exactly what I was looking for: foundation diagrams, truss diagrams, a site plan, rebar schedules, J-bolt layouts and truss strapping.
The Prompts
There are three prompts you will run in sequence:
Design Prompt:
In the file `loop/description` Is a description of a project I want built. We need to
create a design Specification and an implementation guide including a to-do checklist
That can be used for the implementation of the project and the checklist will be used
for keeping the current status of the project. The files used for the planning, design,
and implementation should all be placed into the `loop` directory.
Create the specification document. Ask any clarifying questions that come up during
the creation of the specification. Use the `description` file To ensure that the
specification document does not drift from the core stated goals of the project. Use
codex and internal review to review the specification And address any concerns raised.
Documenting concerns raised which are Rejected So that it does not continue to
flag them. Loop on this, continuing to ask clarifying questions of me if necessary,
until both you and Codex are happy with the results. However, if you have a clear
recommendation between multiple choices, feel free to choose that and document that
in a `loop/spec-decisions` file. This loop is complete when both codex and internal
review do not flag any medium or higher level concerns.
Once the specification document is created, continue on with the implementation guide
and to-do checklist.
For the implementation guide and To-Do Checklist, use the specification To guide the
implementation plan. Use the `description` file To ensure that the implementation
guide and todo list do not drift from the core stated goals of the project. Use codex
and internal review to review the specification And address any concerns raised.
Documenting concerns raised which are Rejected So that it does not continue to
flag them. Loop on this, continuing to ask clarifying questions of me if necessary,
until both you and Codex are happy with the results. However, if you have a clear
recommendation between multiple choices, feel free to choose that and document that
in a `loop/impl-decisions` file. This loop is complete when both codex and internal
review do not flag any medium or higher level concerns.
Implementation Guide Prompt:
Please review the implementation guide in the `loop` directory, keeping in mind the
larger goals specified in the `loop/description` file, looking for any clarifying
questions that might need to be asked during the implementation of this project.
If any of those questions have obviously good recommendations, feel free to select them.
Please ask me clarifying questions and adjust the implementation include those
decisions. Please record any clarifying questions and the decisions made into the file
`loop/impl-clarifying.md`. Please loop until your review finds no further points that
need clarification for the implementation of this project.
Then please review the checklist in the `loop` directory, keeping in mind the larger goals
specified in the `loop/description` file. For every item on the checklist, please
review it against the specification, the implementation guide, and the description to
see if any clarifying questions may need to be asked during the implementation of this
checklist item. If any of those questions have obviously good recommendations, feel free
to select them. Please ask me clarifying questions and adjust the implementation, spec,
and checklist to include those decisions. Please record any clarifying questions and
the decisions made into the file `loop/impl-checklist.md`. Please loop until your review
finds no further points that need clarification for the implementation of this project.
Then, please create a table of contents in the file `loop/toc.md` that has a of documents
in the `loop` directory along with a concise description of what each document contains.
Build Prompt:
In the `loop` directory are documents describing a software project to build. Please see
`loop/toc.md` for a description of the documents. The checklist and the implementation
guide describe the software that needs to be built. This project is in a git repository
and please commit your changes at every step along the way.
Please loop over the checklist and implement the next logical item to be implemented
until no further items can be completed. Use codex and internal review to review
the implementation of each item until both you and Codex are happy with the results.
At every step ensure correctness and robustness of the results. Once done, mark off
the checklist item.
Costs
I’m able to fit this into my $200/mo Claude plan, $20/mo ChatGPT plan and whatever plan I have from Google. However, it will breeze through the session and weekly limits pretty quickly. I had 4-5 projects running in parallel, but over about a day this weekend I used ~20% of my Claude Code weekly limit and had to wait for ChatGPT limits to reset a couple times.