If you regularly use autonomous coding tools like Claude Code CLI, Cursor Composer, or Aider, you've probably caught yourself slipping into lazy iterative prompting. Instead of writing a crisp engineering spec with architecture and edge cases, we toss vague one-liners into the terminal: "Make it better," "Add more features," "Polish the layout."
At first, it feels like magic: the model tidies up CSS, adds smooth animations, and cleans up the code. But what happens if you put that loop on autopilot and refuse to hit stop?
Developer and tech reviewer Nate Herk ran a brutal empirical stress test. He took a simple starter website for a local coffee shop (a plain static HTML, CSS, and JavaScript project) and forced Claude Code CLI through exactly 100 consecutive iterations with a single instruction: "Make this website better. Focus on improvements."
Two Anthropic flagships went head-to-head: the balanced Claude Sonnet 5.5 and the heavyweight reasoning model Claude Opus 5.5. The results show vividly why giving autonomous agents unchecked freedom can wreck a live codebase.
Sonnet 5.5 vs. Opus 5.5: The Modest Perfectionist vs. the Mad Architect
Right from the early loops, the two models split onto completely opposite paths.
How Claude Sonnet 5.5 behaved:
- For the first 15 iterations, it stayed strictly pragmatic: cleaned up semantic HTML, improved screen-reader accessibility (a11y), tuned font scales, and added subtle hover micro-animations on menu cards.
- Around iterations 35–45, Sonnet effectively stabilized the codebase. It started reporting that the project was already polished and shifted to micro-tweaks: refining function comments, tidying indentation, and extracting hex colors into CSS variables.
- Final project size stayed completely reasonable: from an initial 800 lines, the codebase grew to just 1,600–1,800 lines of clean, readable code.
What Claude Opus 5.5 did: Opus treated "make it better" as a blank check for runaway expansion. All sense of restraint vanished:
- By iteration 30, the simple coffee shop site had an interactive bean-roasting cost calculator factoring in growing altitude, an online table-booking system with seating-zone selection, and a Canvas particle animation of rising steam over a coffee cup;
- By iteration 60, Opus had built a simulated shopping cart with a fake payment gateway, a multi-tier loyalty rewards system, and a custom coffee recipe generator;
- By iteration 80, the project ballooned past 21,000 lines of code.
And right there, the inevitable collapse hit. New modules started clashing with older dependencies. Vite began crashing with circular import errors, CSS rules trampled one another, and a once-snappy site turned into a sluggish, unmaintainable pile of spaghetti. It's a textbook case of Code Bloat—and AI Slop.
The Tool Hesitation Paradox: Why Neither Model Searched the Web
The experiment also surfaced a surprising quirk every agent pipeline architect should note.
Web search was enabled by default in the Claude Code environment. You'd expect a model handed an open-ended "make this website better" prompt to hop online, check 2026 web design trends, look at real specialty coffee shop sites, or verify current library versions.
Neither Sonnet nor Opus used web search even once. Both models fell into classic Tool Hesitation, relying purely on internal weights and hallucinating new features out of thin air.
Automating Guardrails and Protecting Projects with CLAUDE.md
To track code growth across runs, Nate wrote a simple bash script that looped through iterations and logged line counts with wc:
#!/usr/bin/env bash
# Iterative prompting loop logging lines of code
set -euo pipefail
LOG_FILE="bloat_metrics.csv"
echo "iteration,lines_of_code,files_count" > "$LOG_FILE"
for i in $(seq 1 100); do
echo "--- Iteration $i / 100 ---"
claude -p "Make this website better. Focus on improvements." --dangerously-skip-permissions
LOC=$(find src -type f ( -name "*.js" -o -name "*.css" -o -name "*.html" ) -exec cat {} + | wc -l)
FILES=$(find src -type f ( -name "*.js" -o -name "*.css" -o -name "*.html" ) | wc -l)
echo "$i,$LOC,$FILES" >> "$LOG_FILE"
done
The main takeaway is clear: never give autonomous coding agents unlimited freedom. Any repo using Claude Code needs a CLAUDE.md rules file at the root with hard guardrails:
# Project Architectural Rules (Guardrails)
- Never add new user-facing features without an explicit request.
- Maximum size for any source file: 300 lines of code.
- When given abstract commands ("make it better"), the agent must:
1. Perform only performance optimizations and bug fixes.
2. Add zero new dependencies to package.json.
3. Preserve the existing component architecture.
Without boundaries like these, a powerhouse reasoning model like Opus will turn a clean landing page into a sprawling monster no human engineer can untangle.


