Repository navigation
fix(observability): retain explicit verifier invocations - #4630
Merged
Merged
Conversation
Contributor
giuliolovisotto
force-pushed
the
codex/judge-call-ownership
branch
from
October 15, 2026 13:29
1616e1e to
03a4c39
Compare
giuliolovisotto
force-pushed
the
codex/judge-call-ownership
branch
from
October 19, 2026 11:28
45f4090 to
4b20b91
Compare
Base automatically changed from
glovisotto/model-call-reader-refactor
to
main
October 19, 2026 19:56
ekellbuch
pushed a commit
to ekellbuch/Gym
that referenced
this pull request
Oct 19, 2026
… model (NVIDIA-NeMo#4736) Saved-exchange readers and rollout attachment currently live beside the model-server transport implementation. Move that code into `nemo_gym.observability.model_calls`, leaving capture middleware, streaming reconstruction and persistence in `base_responses_api_model.py`. This is the refactor-only prerequisite for NVIDIA-NeMo#4630. All 18 moved definitions and all definitions remaining in the base-model module have identical ASTs to the original implementations. Consumers and test patch targets use the new import locations; 25 reader tests now live in `test_model_calls.py`, with their assertions unchanged. Verifier IDs, ownership and lifecycle tracking belong to NVIDIA-NeMo#4630. Compatibility: old imports remain available through the repository’s lazy deprecation helper and warn with the replacement path. New code should import `ModelCallRecord` and the reader/aggregation helpers from `nemo_gym.observability.model_calls`; the docs example uses that path. No artifact-format, runtime-behavior or benchmark-result change. A separate issue is unnecessary: this extracts the structural portion of NVIDIA-NeMo#4630 for independent review. Validation of the final review follow-up: 643 focused tests, all-file pre-commit, Fern validation and `git diff --check` passed. All 20 relocated symbols retain identity through legacy imports, both module import orders work, and the docs example executes. Before this follow-up, 1,638 core/conformance tests and 223 adapter tests passed on main `285224a04` plus the refactor. Live model rollouts: N/A for this relocation and compatibility shim; the verifier follow-up retains its live HealthBench validation. ```bash PYTHONPATH="$PWD" .venv/bin/python -m pytest tests/unit_tests/test_base_responses_api_model.py tests/unit_tests/test_model_calls.py tests/unit_tests/test_rollout_collection.py tests/unit_tests/test_rollout_observability.py -q -o addopts='' --disable-warnings --maxfail=2 .venv/bin/pre-commit run --all-files (cd fern && npm run check) git diff --check ``` --------- Signed-off-by: Giulio Lovisotto <[email protected]>
giuliolovisotto
force-pushed
the
codex/judge-call-ownership
branch
from
October 20, 2026 10:35
4b20b91 to
ae5f3df
Compare
This was referenced Oct 22, 2026
giuliolovisotto
force-pushed
the
codex/judge-call-ownership
branch
from
October 26, 2026 16:07
8276cfd to
af6d766
Compare
This was referenced Oct 27, 2026
Signed-off-by: Giulio Lovisotto <[email protected]>
Signed-off-by: Giulio Lovisotto <[email protected]>
Signed-off-by: Giulio Lovisotto <[email protected]>
lafrancef
approved these changes
Oct 28, 2026
Contributor
|
🔄 Merge queue validation started! You can track the progress here: https://github.com/NVIDIA-NeMo/Gym/actions/runs/40721854670 |
7 tasks done
This branch was previously deployed
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.
Judge model calls lacked an explicit verifier owner. Add one
VerifierInvocationperverify()execution, including its outcome and distinct model-call references, persisted inng_trajectory.verifier_invocations.The shared client propagates an optional correlation header; model capture retains the plain ID and observability reconstructs ownership. Verifier observations return through result/failure payloads and collection persists them. Programmatic verifiers are observed too; no verifier sidecar is written. Missing optional verifier evidence is omitted from failure payloads. The fallback turn builder excludes verifier-owned calls even if an agent also references them, while preserving both ownership claims for validation.
Stack: this PR (Gym evidence) → #5114 (conformance checker support) → #4631 (scripted judge scenario). This PR does not change the conformance checker or scenarios. Existing artifacts are not backfilled; custom routes or clients outside the shared wrappers need explicit integration. Scoring and inference payloads are unchanged. No separate issue is needed for this split of the verifier-ownership fix.
Validation on the rebased stack: 727 collection, verifier-observation and SingleAgentTurn tests; 330 checker/runner tests; 107 conformance CI tests; all-file pre-commit passed. A fresh Simple Agent judge scenario passed on #4631. The fallback exclusion uses Gym model_call_id only, matching the verifier capture path; conflicting agent ownership remains visible for validation. No new external-model run was needed for this saved-evidence projection change. Earlier live HealthBench validation retained one agent call and 19 correctly owned judge calls.