Loop Engineering is the new hype ... and I hate it already

MMaximilian Schwarzmüller
Computing/SoftwareInternet Technology

Transcript

00:00:00I came across this post by Peter Steinberger,
00:00:02the creator of OpenClaw, of course, yesterday on X,
00:00:06where he wrote, "Here's your monthly reminder
00:00:09that you shouldn't be prompting coding agents anymore.
00:00:12You should be designing loops that prompt your agents."
00:00:17And oh boy, I have some thoughts here.
00:00:21So loop engineering it is now, right?
00:00:23I don't think it's an official term yet,
00:00:26but we'll see if it will be.
00:00:27And of course, we're coming from a past
00:00:29where we had prompt engineering.
00:00:31Then parts of the industry decided
00:00:33that this should be rephrased or relabeled
00:00:37as context engineering, which was always stupid
00:00:39because it's the same thing in the end,
00:00:41because it always was about ensuring
00:00:43that the model has the right context.
00:00:45That was the entire idea behind prompt engineering too,
00:00:48because yeah, obviously the right context matters,
00:00:51did matter, still matters, will matter,
00:00:54because if you wanna have better chances
00:00:57of getting good results out of LLMs,
00:00:59you need to give them the right context.
00:01:02You have a better chance then, no guarantee.
00:01:05Even with the right context, mistakes are possible.
00:01:07We're just not getting what you were looking for.
00:01:10That's all possible because it's still
00:01:12a non-deterministic system, a non-deterministic tool.
00:01:15But if you wanna have a shot at getting good results,
00:01:18and you definitely can get good results,
00:01:20then providing the right context is important.
00:01:23Now, around the change from 2025 to 2026 and of course,
00:01:28throughout this year, we then saw the rise of agent decoding
00:01:32since tools like CloudCode and Codex combined with the models
00:01:36that are used inside them, which have been heavily fine-tuned
00:01:39and optimized for instruction following and coding tasks,
00:01:42those tools with the models showed us that, yeah,
00:01:45you can really use these AI models, LLMs for coding tasks
00:01:51and get stuff done with them as assistance.
00:01:55At least that is still my take and my experience.
00:01:58And I've been using these models a lot and these tools,
00:02:02playing around with them pretty much every day,
00:02:05using them every day and not just playing around with them,
00:02:07also using them for serious projects.
00:02:10And of course, that is why I built courses
00:02:12about CloudCode and Codex, where I dive a bit deeper
00:02:15and share my learnings and how to use these tools.
00:02:17And these tools are useful assistance,
00:02:21but they just aren't those replacements
00:02:25of developers yet.
00:02:28And as I've shared in many other episodes,
00:02:31probably also not in the near future.
00:02:33Nonetheless, of course, Anthropic and OpenAI,
00:02:36they added extra commands to these tools
00:02:41like the /goal command in Codex
00:02:43or the /loop command in CloudCode,
00:02:46where the idea is that you can specify a specific goal,
00:02:51a maybe more complex task,
00:02:53with that command added in front of it.
00:02:56And the tool, Codex, CloudCode with the model,
00:03:00will keep on going and will keep on re-prompting itself
00:03:03until that task is completed.
00:03:06And it's kind of only the RALF loop again.
00:03:09Remember the RALF loop at the beginning of 2026,
00:03:13we had that hype around the RALF loop,
00:03:16where some people just sold you that you just need a detailed,
00:03:19step-by-step list of tasks that need to be completed
00:03:24to achieve a certain goal, build a certain feature,
00:03:27and then you could use an extension
00:03:28to keep CloudCode and Codex then at some point going
00:03:33and then work its way through that list.
00:03:34And even though we had the RALF loop back in January already,
00:03:38and some people sold it to you as the solution
00:03:41for building software autonomously,
00:03:44where is all that software?
00:03:46Where is all that software, that error-free, amazing software?
00:03:50Why is CloudCode still flickering?
00:03:54Yeah.
00:03:55Anyway, so we had the RALF loop back then.
00:03:58Now it's back here, officially integrated into CloudCode and Codex.
00:04:03And now we're talking about loop engineering
00:04:05or designing your loops that prompt your agents.
00:04:10And of course, that is something that's easy to say
00:04:12for someone who works for OpenAI in the end
00:04:17because of unlimited tokens,
00:04:20because it turns out this, these loops, these commands,
00:04:23they can burn through a lot of tokens.
00:04:27The problem just is you have the same probabilistic nature
00:04:33of the entire system.
00:04:34And I think one thing that's often overlooked
00:04:38is that indeed my experience has been
00:04:40that these AI models and/or these tools
00:04:43and the models combined, it's really both.
00:04:46They are indeed pretty good at just keeping on going
00:04:50until a certain goal is achieved.
00:04:52I mean, one tiny example I had a few weeks or months ago now
00:04:59is I had a couple of PDF documents
00:05:01which I needed to combine into one,
00:05:03which combined must not be bigger than five megabytes,
00:05:06but each individual document was already like six megabytes
00:05:08because they contain scans.
00:05:10So I just threw my coding agent, I think Codex at the task,
00:05:14and it kept on going, kept on writing some little programs and stuff
00:05:17and until it really achieved that.
00:05:19And obviously, that might not be a super complex task.
00:05:22The point just is, indeed, these models,
00:05:25if they can verify an outcome, they are quite decent at achieving a goal,
00:05:30at achieving a certain task.
00:05:32They just keep on going and try different ways of getting there.
00:05:36The problem just is that is not necessarily how good software is being built.
00:05:41It's one thing to just get something done, to just find a way of doing something.
00:05:48That may be enough for certain use cases.
00:05:51If we're talking about software, software that should be distributed,
00:05:54that should be evolved and maintained,
00:05:57it's not a good strategy to just find a way of getting there
00:06:02because that one way may get one thing done at this point in time.
00:06:08It may break in the future.
00:06:09It may break for a slightly different input.
00:06:11It may contain a lot of bugs or security issues.
00:06:15It may fail for so many reasons, for so many other situations.
00:06:20It may have poor performance.
00:06:22And all that, again, may not matter
00:06:24if you're just trying to get one thing done right now.
00:06:28But that is, again, not what software, in general,
00:06:31if we're talking about software as a product, at least, is about.
00:06:35So there are reasons why we learned as developers
00:06:41that certain patterns and practices and approaches make sense
00:06:45because they're easier to adapt, easier to understand, easier to adjust.
00:06:51Simply cleaner, not just for the cleanliness sake,
00:06:55but for the extensibility, maintainability, performance, security,
00:07:00and understandability sake.
00:07:02And even if you don't care about understanding the code anymore,
00:07:06because you'd say that the AI just needs to understand it, not a human,
00:07:10which is all the really, really a bad take,
00:07:14because obviously AI models have limited context windows and all that.
00:07:17But even then, if that's your take on the understandability,
00:07:21the other parts still matter.
00:07:23And yeah, I don't think there is more to say about that.
00:07:29I really hate the current point in time where we have all these annoying,
00:07:37stupid terms coming up all the time.
00:07:39And then we got people trying to sell you products and courses and stuff off that.
00:07:45And I sell courses myself.
00:07:47I just don't sell and won't sell you a course on loop engineering or anything like that.
00:07:52But yeah, here we are.
00:07:54I'm sure at some point we'll be past that.
00:07:58And we can use these coding agents for what they are helpful assistance.
00:08:03But right now we're still stuck here.
00:08:05And I'm excited to see what will be next after loop engineering.

Key Takeaway

Loop engineering introduces automated self-prompting execution to coding agents, but prioritizing task completion over maintainable software architecture creates fragile codebases.

Highlights

  • AI coding agents use built-in commands like the /goal command in Codex and the /loop command in ClaudeCode to autonomously re-prompt themselves until a task finishes.

  • Autonomous loops consume excessive token usage due to continuous iterative execution.

  • Iterative agent loops successfully executed a task to combine multiple oversized PDF document scans into a single file under five megabytes.

  • Non-deterministic AI models present verification challenges and potential system errors despite continuous execution attempts.

  • Code produced solely to satisfy an immediate prompt loop often fails to account for long-term maintainability, security, and extensibility.

Timeline

The evolution from prompt engineering to loop engineering

  • Prompt engineering evolved into context engineering and eventually into loop engineering.
  • Coding assistants like ClaudeCode and Codex function as helpful development aids rather than full developer replacements.
  • Platform features like the /goal command in Codex and the /loop command in ClaudeCode automate iterative re-prompting.

Terminology shifts from prompt engineering to context engineering reflect ongoing efforts to optimize model inputs. Recent developments integrate continuous execution loops directly into coding tools. These commands allow users to assign complex objectives that prompt the underlying model repeatedly until completion.

Limitations and token consumption of automated loops

  • Automated loops burn through massive token volumes during execution.
  • Coding agents successfully handle constrained verification tasks such as compressing and combining PDF scans.
  • Non-deterministic systems maintain inherent unpredictability despite autonomous execution.

Unlimited token access facilitates heavy reliance on continuous execution loops, though this practice scales costs significantly. While agents demonstrate capability in resolving bounded verification tasks like file compression, the underlying probabilistic nature of language models guarantees ongoing errors and variability.

Software maintenance challenges in automated development

  • Finding a temporary path to complete a task differs from building maintainable software.
  • AI-generated shortcut code frequently introduces security vulnerabilities, bugs, and poor performance.
  • Industry standards around code cleanliness support long-term extensibility and understandability for humans and models alike.

Prioritizing immediate functional completion over software architecture generates fragile systems prone to future breakage. Traditional development patterns exist to ensure security, performance, and adaptability. Dismissing human understandability and established engineering principles in favor of autonomous loops undermines product longevity.

Community Posts

View all posts