# Agentic Loops (Inner / Outer / Meta) #concept ## Summary The next paradigm after the [[harness]] (Konstantin's forecast: dominant in 2027): wrap the agent in progressively larger loops. Three levels — **inner** (ReAct), **outer/Ralph** (infinite `while true`), and **meta** (periodic wipe-and-restart). ## Current Understanding - **Inner loop** = the classic ReAct cycle inside the harness: task → call tools → reflect → … → solved → text answer. - **Outer / Ralph loop** (attributed to Geoffrey Huntley): `while true; do claude --dangerously-skip-permissions -p "solve" || true; done`. Lets an agent work for days/weeks and — crucially — stay in the **"smart zone"** (roughly the first third of context, where the model is sharpest) by avoiding the context growth → summarization → decay spiral. Guardrails against "slop": **CI/CD as back-pressure** and code-quality validation. See [[context-as-scarce-resource]]. - **Meta loop** (Konstantin's own, not standard): periodically stop, wipe all agent-created data into an archive the agent can't initially see, and restart from scratch — so it explores a *different* path. Counters **collapse** (Karpathy): asked repeatedly, a model reworks the *same* solution with different words (the "tells the same joke with new characters" example). Good for open-ended research tasks. This is the domain of the emerging **loop-engineer** role (after prompt → context → harness engineer). ## Evidence - Three-level loop model, Ralph loop code, smart-zone argument, meta-loop, collapse, back-pressure — [[2026-07-14-skills-based-on-git]]. - Auto-agent example: weak GigaChat 1/89 → 11/89 over a weekend inside a self-improvement loop (idea from Karpathy's "autoagent"). - Orchestration-era models that self-verify are the model-side complement — [[2026-07-14-everything-we-knew-about-software-has-changed]]. ## Related Pages - Concepts: [[harness]], [[context-as-scarce-resource]], [[skills-as-memory]], [[evolution-of-agent-tooling]] - Entity: [[konstantin]] - Tools: [[claude-code]], [[hermes]] ## Contradictions / Uncertainty - The "smart zone = first third of context" is a rule of thumb, not a measured constant. Status: tentative. - Meta loop is the author's own construct, "not generally accepted." ## Next Questions - What CI signals make the best back-pressure without over-constraining exploration?