<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Gonzalo Chacaltana</title>
    <description>The latest articles on DEV Community by Gonzalo Chacaltana (@gchacaltana).</description>
    <link>https://dev.to/gchacaltana</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F434605%2F242aa47e-fe6a-4b67-a80f-f44c8849457e.jpeg</url>
      <title>DEV Community: Gonzalo Chacaltana</title>
      <link>https://dev.to/gchacaltana</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/gchacaltana"/>
    <language>en</language>
    <item>
      <title>From Prompt Engineering to Loop Engineering</title>
      <dc:creator>Gonzalo Chacaltana</dc:creator>
      <pubDate>Sun, 18 Oct 2026 19:20:13 +0000</pubDate>
      <link>https://dev.to/gchacaltana/from-prompt-engineering-to-loop-engineering-59k5</link>
      <guid>https://dev.to/gchacaltana/from-prompt-engineering-to-loop-engineering-59k5</guid>
      <description>&lt;p&gt;In recent years, we have seen a rapid shift in how we interact with Large Language Models (&lt;strong&gt;LLMs&lt;/strong&gt;). Between 2022 and 2024, &lt;strong&gt;prompt engineering&lt;/strong&gt; dominated, focusing on best practices for crafting detailed instructions.&lt;/p&gt;

&lt;p&gt;In 2025, the focus shifted toward &lt;strong&gt;Context Engineering—prioritizing&lt;/strong&gt; the structure and strategic retrieval of information within the context window through &lt;strong&gt;RAG&lt;/strong&gt;. By 2026, however, we're firmly in the era of &lt;strong&gt;Loop Engineering&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Engineers on the &lt;a href="https://www.anthropic.com/" rel="noopener noreferrer"&gt;Anthropic&lt;/a&gt; team summarize this transformation with a categorical maxim: &lt;em&gt;‘Stop writing prompts and start building loops.’&lt;/em&gt; &lt;a href="https://steipete.me/" rel="noopener noreferrer"&gt;Peter Steinberger&lt;/a&gt; (developer of &lt;a href="https://openclaw.ai/" rel="noopener noreferrer"&gt;OpenClaw&lt;/a&gt;) emphasizes that developers should no longer send prompts directly to code agents; instead, they should design structured loops that guide the agents and automatically issue prompts to them.&lt;/p&gt;

&lt;h2&gt;
  
  
  Anatomy of an Agentic Loop
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Think:&lt;/strong&gt; The LLM reasons explicitly about the current state of the task, analyzes previous errors, and decides on the next logical step.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Act:&lt;/strong&gt; The model selects and invokes a specific tool—such as executing a Python script, querying a REST API, running an SQL query, or performing a web search.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Observe:&lt;/strong&gt; The model captures the output or error message returned by the tool and incorporates it into its context window to inform the next cycle of reasoning.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Fundamental Agent Formula
&lt;/h2&gt;

&lt;blockquote&gt;
&lt;p&gt;Agent = LLM + Memory + Planning + Tool Use&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The loop acts as the execution engine, orchestrating these four components into a unified system and enabling self-correction in the face of unexpected errors. Without a loop, memory remains static, the plan is never re-evaluated, and tool use is reduced to a one-off, static call.&lt;/p&gt;

&lt;h2&gt;
  
  
  Design Patterns
&lt;/h2&gt;

&lt;p&gt;An examination of the technical documentation for prominent frameworks—such as LangGraph, AutoGen, and CrewAI, as well as CLI-based agents like Claude Code and Cursor—reveals four primary architectural patterns:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;ReAct (Reason + Act):&lt;/strong&gt; Combines explicit, text-based reasoning with the execution of tools. Research indicates that allowing models to reason and act within a loop outperforms imitation and reinforcement learning methods, achieving up to 34% higher success rates on decision-making benchmarks.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Reflection Loop:&lt;/strong&gt; Follows a cycle of Generate → Critique → Refine → Repeat. On the HumanEval coding benchmark, incorporating reflection increased model accuracy from 80% to 91%. However, performance gains follow a pattern of diminishing returns: while the initial review identifies the majority of errors, extending the process beyond three iterations primarily increases token consumption with negligible further improvement.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Tool Use Loop:&lt;/strong&gt; The model executes targeted tool calls—including database queries, API requests, and compiler operations—iterating iteratively until it gathers sufficient context to produce a final response.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Multi-Agent Loop:&lt;/strong&gt; Coordinates multiple specialized sub-agents within nested loops. This typically takes one of two forms: the Supervisor Pattern (a central agent manages the workflow) or the Swarm/Handoff Pattern (agents pass tasks directly to one another, much like a relay race).&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  How do you program a loop?
&lt;/h2&gt;

&lt;p&gt;In modern engineering, loops programmed within CLI environments (such as Claude Code, Cursor, or automation servers) consist of five essential structural blocks.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Trigger:&lt;/strong&gt; The event or condition that initiates execution (e.g., a Git webhook triggered when a Pull Request is opened, or a daily cron job set for 8:00 AM).&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Goal:&lt;/strong&gt; The concrete, measurable outcome the system is intended to achieve (e.g., "ensure 100% of unit tests pass without errors").&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Actions:&lt;/strong&gt; The set of authorized tools the AI ​​can employ to make progress toward the goal.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Verification:&lt;/strong&gt; The most critical step in the loop. The system does not stop simply because the model claims "I’m finished"; rather, it stops only when an objective executor—such as a linter, a compiler, or a test script—validates that the goal has been met.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Memory:&lt;/strong&gt; A record of the context, including previous attempts, ensuring that the same failure is not repeated in the next iteration.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The AI ​​Engineer’s Golden Rule: "Workflow First, Prompt Last." Begin by designing the workflow architecture: define the actions, the impartial verification step, the iteration limit (&lt;code&gt;max_iterations&lt;/code&gt;), and the objective stopping conditions. The initial prompt (or "kickoff prompt") is, quite literally, the very last thing to be drafted.&lt;/p&gt;

&lt;h2&gt;
  
  
  Three Essential Loops in the Software Development Life Cycle (SDLC)
&lt;/h2&gt;

&lt;p&gt;To apply this concept to academic or production-grade projects, let’s look at three high-impact loop patterns drawn from the Loop Engineering practice catalog:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;🛠️ Self-Review Loop:&lt;/strong&gt; A loop configured to automatically execute linters, run unit tests, and check style conventions for a Pull Request—all before a human engineer is even asked to perform a review.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;🔍 Product Evaluation Loop:&lt;/strong&gt; An autonomous agent that takes the specifications for a SaaS platform or mobile application, simulates real user stories, compares the UI state against privacy policies, and automatically reports any inconsistencies.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;📚 Documentation Sync Loop (“Docs until complete”):&lt;/strong&gt; One of the biggest headaches in software development is the misalignment between code and documentation. This loop scans for changes in APIs or backend contracts and automatically updates Markdown files and documentation repositories to ensure 100% synchronization.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Conclusions
&lt;/h2&gt;

&lt;p&gt;The transition from &lt;strong&gt;Prompt Engineering&lt;/strong&gt; to &lt;strong&gt;Loop Engineering&lt;/strong&gt; marks a critical milestone in the maturation of &lt;strong&gt;Artificial Intelligence&lt;/strong&gt;, advancing it from a conversational interface into a robust, autonomous execution engine. Consequently, &lt;strong&gt;loop-based architectures&lt;/strong&gt; represent a pivotal core competency in contemporary software engineering, enabling the design of systems capable of iterative reasoning, self-correction, and autonomous decision-making.&lt;/p&gt;

&lt;p&gt;Sources:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/alchaincyf/loop-engineering-orange-book/blob/main/Loop-Engineering-The-Complete-Guide-v260615.pdf" rel="noopener noreferrer"&gt;Loop Engineering: The Complete Guide (Orange Book)&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://www.anthropic.com/engineering/building-effective-agents" rel="noopener noreferrer"&gt;Anthropic Research — Building Effective Agents&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>promptengineering</category>
      <category>loopengineering</category>
      <category>contextengineering</category>
      <category>agents</category>
    </item>
    <item>
      <title>AI Agents: "Super Mushroom" or "Game Over" for Programming?</title>
      <dc:creator>Gonzalo Chacaltana</dc:creator>
      <pubDate>Fri, 13 Feb 2026 23:46:03 +0000</pubDate>
      <link>https://dev.to/gchacaltana/ai-agents-super-mushroom-or-game-over-for-programming-1mc5</link>
      <guid>https://dev.to/gchacaltana/ai-agents-super-mushroom-or-game-over-for-programming-1mc5</guid>
      <description>&lt;p&gt;Recently, &lt;a href="https://www.anthropic.com/" rel="noopener noreferrer"&gt;Anthropic&lt;/a&gt;, the company behind &lt;a href="https://claude.ai/" rel="noopener noreferrer"&gt;Claude Code&lt;/a&gt;, has equipped its &lt;strong&gt;LLM models&lt;/strong&gt; with &lt;strong&gt;"skills"&lt;/strong&gt;: the ability to use tools, execute code, and perform specialized tasks autonomously. In other words, &lt;strong&gt;Claude&lt;/strong&gt; no longer just writes code; now he &lt;strong&gt;"has skills"&lt;/strong&gt;. Meanwhile, the industry, academia, and software development professionals watch in amazement as &lt;a href="https://www.anthropic.com/engineering/building-c-compiler" rel="noopener noreferrer"&gt;teams of AI agents build complex compilers in weeks&lt;/a&gt;. The question arises: &lt;strong&gt;Is programming dying&lt;/strong&gt;, or &lt;strong&gt;is it simply evolving?&lt;/strong&gt; What we are witnessing is the end of code typing and the birth of &lt;strong&gt;intent engineering&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;This article mentioned that &lt;a href="https://solocodigoweb.com/blog/2019/05/29/programacion-un-arte-basado-en-la-logica-y-creatividad/" rel="noopener noreferrer"&gt;programming is an "art" based on logic and creativity&lt;/a&gt;, sorry, it's in spanish. The question that arises now is:&lt;/p&gt;

&lt;h2&gt;
  
  
  Is programming still an art based on logic and creativity?
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://claude.com/blog/building-agents-with-skills-equipping-agents-for-specialized-work" rel="noopener noreferrer"&gt;Anthropic's publication&lt;/a&gt; on &lt;strong&gt;agents with skills&lt;/strong&gt; marks a milestone: we are no longer just looking for a model that &lt;strong&gt;"talks"&lt;/strong&gt; about code, but an agent that &lt;strong&gt;"acts"&lt;/strong&gt; on it. This means that the mechanical aspects of programming—writing boilerplate code, correcting syntax errors, or implementing standard functions—are being absorbed by LLM models hungry for efficiency.&lt;/p&gt;

&lt;p&gt;However, this doesn't negate the article's view that programming is an art based on logic and creativity. On the contrary, I believe that AI elevates it.&lt;/p&gt;

&lt;p&gt;Logic is the necessary structure for a system to be functional and predictable; it's the physics of the digital world. But creativity is what allows that logic to solve complex human problems in elegant ways. An algorithm may be functional, but a well-designed system is a &lt;strong&gt;work of art&lt;/strong&gt; in terms of maintainability, efficiency, and user experience.&lt;/p&gt;

&lt;p&gt;Today, AI can replicate the &lt;strong&gt;"how"&lt;/strong&gt; (the logic), but it remains incapable of understanding the &lt;strong&gt;"why"&lt;/strong&gt; (the creative intent). As a programmer, you no longer "chip away at the stone"; now you are the architect who designs how these agents should interact with each other. The art now lies in defining the boundaries, objectives, and ethics of these autonomous systems.&lt;/p&gt;

&lt;p&gt;So, the question that arises is:&lt;/p&gt;

&lt;h2&gt;
  
  
  What will be the role of the software engineer with the advancement of AI?
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fwrzpnx22n3166r6y9el2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fwrzpnx22n3166r6y9el2.png" alt="new role for software engineer with AI Agents" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;We are leaving behind the era of the &lt;strong&gt;"code writer"&lt;/strong&gt; and entering the era of the &lt;strong&gt;Agent Architect&lt;/strong&gt;. That is, the role will evolve from &lt;strong&gt;code writer&lt;/strong&gt; to conductor, &lt;strong&gt;leading an intelligence team&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;The tasks that many software engineers who use AI agents already perform are:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Agent Orchestration:&lt;/strong&gt; You decide what skills each agent needs and how they should be linked together to solve a real business problem.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Validation and Security:&lt;/strong&gt; AI can generate solutions, but the engineer must be the ultimate judge of the accuracy, security, and efficiency of those solutions.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;High-Level Abstraction:&lt;/strong&gt; The engineer will move away from low-level details to focus on the system architecture and the human experience.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion: Do you eat the Super Mushroom or quit the game?
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fs06wx62rh8kz9xeqqfgm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fs06wx62rh8kz9xeqqfgm.png" alt="AI Agents - Power-Up Programming" width="729" height="475"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Programming was born as an art based on logic and creativity, and it will remain so as long as there is a human with vision. AI is, without a doubt, that &lt;strong&gt;"Super Mushroom"&lt;/strong&gt;: it makes you bigger, allows you to break through blocks that previously held you back, and gives you superhuman agility.&lt;/p&gt;

&lt;p&gt;However, &lt;strong&gt;"Game Over"&lt;/strong&gt; will only come for those who put down the controller and stop creating. For the rest of us, for those of us who remain passionate about solving problems, AI is not the end of the game, but the power-up that will allow us to build the most ambitious level of our lives. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The question isn't whether AI will replace you, but what wonder you will paint today now that your brush moves at the speed of light.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Posts that may interest you:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://solocodigoweb.com/en/blog/2025/11/17/how-generative-ai-is-accelerating-web-modernization/" rel="noopener noreferrer"&gt;How Generative AI is Accelerating Web Modernization&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://solocodigoweb.com/en/blog/2025/11/18/claude-sonnet-4-5-vs-composer-1-the-productivity-duel-in-software-development/" rel="noopener noreferrer"&gt;Claude Sonnet 4.5 vs. Composer 1: The Productivity Duel in Software Development&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>agents</category>
      <category>programming</category>
      <category>ai</category>
      <category>softwareengineering</category>
    </item>
  </channel>
</rss>
