Repository navigation
Conversation
Contributor
Author
|
/ok to test 3ea41a4 |
ffrujeri
force-pushed
the
ffrujeri/auto-ontology-rollout-attribution
branch
from
November 5, 2026 00:58
3ea41a4 to
a06a31f
Compare
Contributor
Author
|
/ok to test a06a31f |
ffrujeri
force-pushed
the
ffrujeri/auto-ontology-agent
branch
from
November 6, 2026 17:23
2bd2cdf to
a7a10b4
Compare
ffrujeri
force-pushed
the
ffrujeri/auto-ontology-rollout-attribution
branch
from
November 6, 2026 17:23
a06a31f to
f7d5e80
Compare
Contributor
Author
|
/ok to test f7d5e80 |
ffrujeri
force-pushed
the
ffrujeri/auto-ontology-agent
branch
from
November 9, 2026 19:11
a7a10b4 to
b22020d
Compare
ffrujeri
force-pushed
the
ffrujeri/auto-ontology-rollout-attribution
branch
from
November 9, 2026 19:11
f7d5e80 to
c681ac9
Compare
Contributor
Author
|
/ok to test c681ac9 |
ffrujeri
force-pushed
the
ffrujeri/auto-ontology-agent
branch
from
November 9, 2026 23:10
b22020d to
63c239d
Compare
ffrujeri
force-pushed
the
ffrujeri/auto-ontology-agent
branch
from
November 11, 2026 04:05
76bf403 to
cd14901
Compare
ffrujeri
force-pushed
the
ffrujeri/auto-ontology-rollout-attribution
branch
from
November 11, 2026 04:05
b91c7a0 to
9e9245a
Compare
Contributor
Author
|
/ok to test 9e9245a |
ffrujeri
force-pushed
the
ffrujeri/auto-ontology-agent
branch
from
November 12, 2026 18:32
cd14901 to
cf9145c
Compare
ffrujeri
force-pushed
the
ffrujeri/auto-ontology-rollout-attribution
branch
from
November 12, 2026 18:32
9e9245a to
0bb46ee
Compare
Contributor
Author
|
/ok to test 0bb46ee |
Contributor
Author
|
/ok to test 0097564 |
Contributor
Author
|
/ok to test 82caea0 |
Contributor
Author
|
/ok to test 901dcbc |
Contributor
Author
|
/ok to test 8c4cb19 |
Contributor
Author
|
/ok to test 363169e |
Contributor
Author
|
/ok to test b0ef817 |
Contributor
Author
|
/ok to test 53dc00f |
Contributor
Author
|
/ok to test 0b8382a |
Contributor
Author
|
/ok to test f57b2bf |
Contributor
Author
|
/ok to test c820a94 |
Auto Ontology, NVIDIA's text-to-SQL agent, runs in process as a Gym Agent Server on the bird_interact Environment Server. In each turn the agent steps Auto Ontology's interactive session until it submits, and runs each action as the episode's ask_user or submit_sql tool. It reads the BIRD-Interact ADK's c-Interact texts exactly and fails the activation on a text it does not know. benchmarks/bird_interact/auto_ontology.yaml pairs it with BIRD-Interact Lite in c-Interact. The agent installs Auto Ontology from its repository at the revision auto-ontology-eval pins, and copies auto-ontology-eval's BIRD-Interact feature flags. scripts/component-lock-policy.json keeps sqlalchemy and alembic in the agent's lock, because Auto Ontology's catalog code imports them. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: Felipe Vieira Frujeri <[email protected]>
…Model Server Auto Ontology has two model roles. The reasoning model decides what to ask and what SQL to submit, so it is the policy and runs on policy_model. The fast model makes helper calls (merging the user's answers into the question, evidence checks, structured extraction). It fell back to the reasoning model's server, so the evaluated policy also served those calls. It now runs on its own Model Server, auto_ontology_fast_model, configured in env.yaml like the simulator's user_model, as auto-ontology-eval runs a separate fast model beside its reasoning model. fast_model_server and fast_model are required, so the fast role never falls back to the policy silently. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: Felipe Vieira Frujeri <[email protected]>
…ts that serve agent sessions Main checks that every agent app that seeds agent sessions is in AGENT_SESSION_AGENT_TYPES, which decides how a session environment wires the agent. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: Felipe Vieira Frujeri <[email protected]>
…heir rollouts Auto Ontology keeps one model client for each role for the whole process and calls it from threads, so its calls reached the Model Server without a rollout. The agent now gives those clients an httpx transport that sends each call through ServerClient on the agent's event loop, on the route of the activation that made it: the activation's rollout prefix (with the training-capture segment when that is on) and its invocation ID as x-session-id. The route travels in a context variable that asyncio's and LangChain's executors copy into Auto Ontology's threads. At the pinned revision Auto Ontology takes neither an HTTP client nor an executor, so the agent wraps llm_invoke._build_client and gives the coordinator LangChain's ContextThreadPoolExecutor when it imports Auto Ontology. Model names must select Auto Ontology's ChatOpenAI client. Responses now carry usage. The close bundle declares a model-call gap only when evidence is missing: an activation without a rollout, a call that lost its context while the session was open, or a reply without usage. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: Felipe Vieira Frujeri <[email protected]>
Contributor
Author
|
/ok to test 5b9194e |
Contributor
Author
|
Closing: this is now part of the Auto Ontology agent itself. With Auto Ontology's ReAct agent, the agent builds the chat clients and gives them a transport that sends each model call through Gym's ServerClient on the activation's rollout route ( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Based on #5633 (the Auto Ontology Agent Server). Together they form the Auto Ontology stack. The diff against #5633 changes only
responses_api_agents/auto_ontology_agent/.What changed
Auto Ontology keeps one model client for each role for the whole process, and calls it from threads. So in #5633 its calls reach the Model Server without a rollout: no capture, no usage, and the close bundle declares
model_call_ownership_unavailableandmodel_call_usage_unavailable. This PR attributes each call to its rollout and to the activation that made it, without per-episode clients.The route of an activation (
app.py). The Environment Server activates the session on its rollout's route,/ng-rollout/<capture key>, with the training-capture segment when training capture is on. The agent reads that prefix from the activation's path, assimple_agentdoes, and keeps it with the invocation ID (root,activation-2, ...) in a context variable for the turn.asyncio.to_threadand LangChain's executors copy the variable into Auto Ontology's threads.The transport (
model_calls.py). Auto Ontology's ChatOpenAI clients get an httpx transport. For each call it reads the route and sends the call throughServerClient.poston the agent's event loop, to/ng-rollout/<key>/v1/chat/completionswithx-session-id: <invocation ID>. Gym then captures the call for its rollout and gives it to its invocation, and vLLM keeps the rollout's calls on one backend. The call goes over Gym's aiohttp client; httpx opens no connection (the transport-adapter pattern in AGENTS.md).Auto Ontology's side (
runtime.py). At the pinned revision, Auto Ontology takes neither an HTTP client nor an executor. When the agent imports it,send_model_calls_throughsets two attributes of its modules:llm_invoke._build_client, which builds every chat client, and gives each ChatOpenAI client the transport with the OpenAI SDK'swith_options(http_client=...). Auto Ontology's base URL, timeout and retries stay.ContextThreadPoolExecutor, becauseapply_user_answermakes three model calls in aThreadPoolExecutorthat does not copy the context.A test checks both attributes against the real modules at the pinned revision. If Auto Ontology adds the two options, these become two plain calls.
Usage and gaps. Each response carries the summed usage of its activation's model calls, when every call reported usage. At close, the agent declares a gap only for missing evidence:
model_call_ownership_unavailablewhen an activation came without a rollout;model_call_ownership_unavailablewhen a call lost its context while the session was open. The transport counts such calls and sends them without a rollout. It cannot tell whose call it was, so each session open at the time declares the gap.model_call_usage_unavailablewhen a reply had no usage.Model names. Only Auto Ontology's ChatOpenAI client can take the transport, so
reasoning_modelandfast_modelmust start withopenai/,azure/oraws/. The defaults are nowopenai/${policy_model_name}andopenai/${auto_ontology_fast_model_name}. Gym's Model Servers send their own model name, so the prefix does not change the request the provider sees.README. It has a new "Model calls" section. The capability level is Observability, not yet checked on saved rollouts. Training stays open: the training-capture route reaches every call, but how to train a policy on Auto Ontology's many separate calls is undecided (GYMINT-695).
Tracking: GYMINT-694. This design replaces the per-session clients that the issue proposes: Auto Ontology's clients stay shared for the process, and the route comes from the call's context. #4969 is not needed for this agent.
Validation
pytest testsin the agent's locked venvThreadPoolExecutorreaches the model without a rollout and is counted; a reply without usage leaves the usage unknown; a Model Server that does not reply in time times the call out; a call on the event loop or to another server is refused; through the agent, the activations' routes, the response usage and the close gaps (rollout route, no usage, no rollout, a call outside an activation); a model name that selects another client is refused;send_model_calls_throughagainst the real Auto Ontology modules at the pinned revisionx-session-id, usage, context executor, client swap, the activation's route, both gaps)ServerClientfaked: two concurrent episodes, each a text call and a structured-output call (invoke_with_structured_output) on the reasoning and fast clients, and a call from the coordinator's executorgym env validateandgym env resolveforbenchmarks/bird_interact/auto_ontology.yamlwith the vLLM model config and stand-in settingsopenai/<policy_model_name>for reasoning andopenai/<auto_ontology_fast_model_name>for fast callspre-commit runon the changed filesRollout evidence
Not yet, as for #5633: a run needs Auto Ontology's catalog, filled for each database. The first c-Interact smoke on Docker sandboxes will run with
observability_enabled: trueand check that each rollout's captured calls join their invocations with no model-call gaps.Compatibility
Changes only this agent. A config that set
reasoning_modelorfast_modelwithout anopenai/,azure/oraws/prefix now fails validation with a message that says how to fix it. With such a name, Auto Ontology would have used its ChatNVIDIA client, whose calls cannot carry a rollout.🤖 Generated with Claude Code