HomeBlog › No goal, no loop: the principle that keeps autonomous agents honest
Blog

No goal, no loop: the principle that keeps autonomous agents honest

Jul 19, 20266 min readBy the Rysh team

An agent loop without a terminating goal isn't autonomy — it's an unattended process with your API key. The rule we build rysh around.

while(true) is not a personality trait.

There's a demo genre you've seen a hundred times by now: "my agent runs forever, autonomously!" — a terminal scrolling with tool calls, no visible end state, presented as ambition. It isn't ambition. It's an unattended process with your API key, and the only thing it reliably produces is a bill.

We build rysh around a blunter rule: no goal, no loop. Before an agent loop gets to run — an autonomous agent spawned from a skill file, a browser recipe under ##auto web, a scheduled ##cron job — it owes you three things. Not aspirationally. Structurally.

1. A goal with a "done"

If you can't say what done looks like, you don't have a task. You have a mood.

Every loop needs a goal whose completion is checkable — by an exit code when you're lucky ("tests pass"), or by evidence a judge can assess when you're not ("a shortlist of twenty guests who fit the show's brief"). The grammatical form matters: it's do/while, not while(true). The condition isn't a safety accessory bolted onto the loop; the condition is the point. Work, then check against the goal, then decide. A loop that never consults its goal isn't autonomous — it's just unsupervised.

This sounds obvious and is violated constantly. "Monitor the codebase for issues" is a mood. "Reduce the lint backlog to zero in these three packages" is a goal. The first loop can run until the sun burns out and never be wrong or right. The second one can finish — which also means it can fail, visibly, which is the property you actually want.

2. Budgets you can say out loud

A goal bounds what; budgets bound how much. In rysh we frame them as pages, books, and shelves — the library framing: concrete caps per pass, per run, per campaign, sized so you can say them in a sentence without flinching. "This gets twenty units per pass, five passes, and that's the run" is a budget. "We'll see how it goes" is not.

Two properties make budgets real rather than decorative:

They're hard. When the budget is spent, the loop stops. Not "logs a warning." Stops. An advisory budget is a suggestion, and agents are exactly as good at honoring suggestions as the rest of us.

Exhaustion is a result. A loop that dies at its cap isn't an error to retry harder — it's data. Either the goal was underspecified, or the approach is wrong, or the budget was genuinely too small; all three are worth a human's attention before someone rounds the budget up and walks away. Budget exhaustion is your loop telling you something. Listen to it.

3. An exit that doesn't require heroics

Every loop needs a way to end that doesn't involve someone noticing at 2 a.m. In rysh there are three ordinary exits, plus a backstop:

And beneath all of it, the engine keeps its own smoke alarm: rysh's orchestrator tracks recent tool calls, and three identical calls inside its sliding window get blocked. Loop detection isn't intelligent, and that's fine — smoke alarms aren't intelligent either. They're just always on.

All of this happens where you can see it. Every tool call lands in a pane; the loop's work, its budget state, its judge verdicts are things you watch, not things you exhume from logs after the fact. Observability isn't a bonus feature of governed loops — it's the substrate that makes "governed" mean anything.

Why this is the honesty principle

Here's the part that goes beyond cost control. Goal + budget + exit makes an agent's work falsifiable.

"The agent is working on it" is, in most stacks, an unfalsifiable claim — indistinguishable from "the agent is wandering." Under no-goal-no-loop, it decomposes into questions with answers: Which goal? How much budget remains? What did the judge last rule? At what point does a human get pulled in? An agent whose progress can be checked is an agent whose failures are survivable — and whose successes are believable.

That's also, we'd argue, the only road to more autonomy, not less. Teams that give agents infinite leashes lose trust at the first runaway, and then over-correct into approval-everything paralysis. Teams that start with small, governed loops — tight goals, spoken-aloud budgets, takeover thresholds — build a track record. Trust compounds. The leash gets longer because it was short and visible first.

Zoom out and it's the AI-native argument in miniature. An AI-native company isn't one with agents scattered everywhere; it's one that runs agents the way SREs run production services. Nobody ships a service without SLOs, alerts, and a kill switch — not because they expect failure, but because that discipline is what makes depending on the service reasonable. Goals, budgets, takeovers, and visible-by-default execution are the same discipline, applied to agents. (And since rysh runs on Claude with your own key, on your own infra — self-hostable — the meter and the kill switch are both, properly, yours.)

None of this makes an agent correct. Governance bounds and exposes; correctness still comes from review, tests, and the approval gates in front of anything dangerous. But bounded and inspectable is the difference between an agent you run overnight and an agent you babysit.

while(true) was never the ambitious choice. The ambitious choice is a loop that knows what done means, knows what it's allowed to spend, and knows when to hand the keys back.


We're recruiting design partners. If your team wants autonomy with a track record instead of a leash you're afraid to drop, come build with us: rysh.ai/design-partner

Related: Pages, books, and shelves: budget your agents like a library · Judge-decided reset and resume

Try Rysh

Every pane is a shell and an AI agent — install takes one command.

Get started free →