Original Reddit post

I’ve seen people run Claude Code agents in iterative loops where they keep improving outputs without switching into Ralph mode. That made me wonder how far this idea can go. What I’m trying to build is a multi-agent loop to improve a prompt , where each agent has a clearly separated role: Prompt Engineer → writes or improves the prompt. Generator → runs the prompt and produces the output (the test case). Evaluator → critiques the output and provides structured feedback. The evaluator sends feedback to the prompt engineer, the prompt gets improved, and the cycle runs again. The main thing I want to avoid is the classic problem where all agents share the same context and reasoning , so it’s basically the same voice talking to itself. Ideally each role should behave more independently so the evaluator actually challenges the result instead of confirming it. My use case is improving prompts for text generation tasks where output quality matters a lot , so having a critic in the loop should help the prompt converge faster. I already asked Claude Code about this, but the answer was pretty generic and didn’t really address how people actually run agent teams in practice . Has anyone here set up something similar with Claude Code team agents or another multi-agent setup? Curious what workflows or patterns actually work in the real world. submitted by /u/jrhabana

Originally posted by u/jrhabana on r/ClaudeCode