Tools and state
openai_agentic_loop
Agentic loop controller for the Responses API pipeline.
Switching projects opens that project’s default documentation release.
Versions marked “overview” do not contain this page. Selecting one opens that version’s documentation overview.
On this page
Agentic loop controller for the Responses API pipeline.
Configuration Notes
Manages iteration bookkeeping in on_request_body, extracts tool calls from non-streaming response bodies, and evaluates loop control in on_response_body (end-of-stream), writing filter_results for iterative_request_router transitions.
Also extracts tool_search_call items into ResponsesState.tool_search_calls so openai_mcp_dispatch can load deferred connectors on the next iteration without forwarding those items to the inference backend.
Configuration
| Field | Type | Required | Description |
|---|---|---|---|
max_infer_iters | integer | no | Maximum number of inference loop iterations (Praxis-only, not part of the OpenAI API spec). When the iteration counter reaches this limit, the loop returns a 508 Loop Detected error. |
Examples
Example 1
filter: openai_agentic_loop
Example 2
filter: openai_agentic_loop
max_infer_iters: 10