Skip to main content

Module acceptance

Module acceptance 

Source
Expand description

What “done” means, checked before the loop says so.

An agent loop ends when the model stops asking for tools. That is the right rule and it answers the wrong question: it tells you the model believes it is finished, not that the work happened. A run that narrates a plan and stops looks exactly like a run that did the job.

harness-loop-engine already draws this distinction — its maker/checker split is the same discipline — but only if you adopt that whole runtime. Most code uses a bare crate::AgentLoop, and there the question wasn’t asked at all. An Acceptance is that question, on the loop everyone actually uses: consulted before Outcome::Done, and when it says no, the reason goes back to the model and the loop carries on.

Keep them cheap and deterministic where you can — a file either exists or it doesn’t, and that costs no tokens. A second agent as judge is possible (the host supplies it) but it’s the expensive end, not the default.

Structs§

FilesExist
Every named path must exist under the workspace root, and be non-empty.
NonEmptyAnswer
The cheapest check there is: the turn produced something.
Verdict
The answer to “is this actually done?”.

Traits§

Acceptance
A condition the run must satisfy before the loop reports success.