delimit_loop_config
Configure loop safeguards and policies—max iterations, cost cap, error threshold, approval policy—before starting a build session.
Instructions
Configure autonomous build loop safeguards (Pro).
When to use: BEFORE starting a loop session — to set max iterations, cost cap, error threshold, approval policy. When NOT to use: to read loop metrics (use delimit_loop_status) or drive the loop (delimit_build_loop).
Sibling contrast: delimit_loop_status reads metrics; delimit_build_loop runs; this configures the policy.
Side effects: writes the loop session config via ai.loop_engine.loop_config. Only non-zero/non-empty values are applied — pass just the fields you want to change.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| session_id | No | Session to configure. Empty = create new. | |
| max_iterations | No | Max tasks before stopping. Default 50. | |
| cost_cap | No | Max session cost in dollars. Default 5.0. | |
| auto_consensus | No | If True, suggest consensus when ledger empty. | |
| error_threshold | No | Consecutive errors before circuit-breaker trips. Default 3. | |
| status | No | Set loop status — "running", "paused", "stopped". | |
| require_approval_for | No | Comma-separated action types requiring human approval. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||