Repository navigation
feat(nemo_fabric_agent): NeMo Fabric 0.6.1 and an opt-in NeMo Relay path - #5057
Conversation
…nd OpenClaw presets, and build responses from Relay ATIF Signed-off-by: Christian Munley <cmunley@nvidia.com>
…agents, and install OpenHands' dependencies Signed-off-by: Christian Munley <cmunley@nvidia.com>
…eways, keep the fuller trajectory, and pin LiteLLM in the runtime script Signed-off-by: Christian Munley <cmunley@nvidia.com>
|
/ok to test 61e2e62 |
|
/review |
left a comment
There was a problem hiding this comment.
HOLD — two BLOCKERs in Relay trajectory fidelity and three RISKs in configuration, proxy cleanup, and OpenClaw provisioning.
Completed the broad review of all nine changed files, including affected configuration composition, verifier handoff, installation paths, and existing regression tests. Relay is opt-in, so the trajectory and proxy findings are confined to Relay-enabled runs; the configuration and OpenClaw findings affect their respective setup paths.
Static inspection only: tests, dependency resolution, and model rollouts were not executed. Third-party Fabric/Relay implementations are not mounted, so their internal compatibility claims were not independently verified. The findings below are grounded in the mounted source and fixtures.
Note: formal approval is not available for this request, so this review is posted as a comment only.
Review generated by codex. This was a full review. Request a full review with /review reset=true.
…s, close proxy connections, declare Relay options, and provision OpenClaw Signed-off-by: Christian Munley <cmunley@nvidia.com>
commented
Oct 25, 2026
|
/ok to test 4d51f4a |
commented
Oct 25, 2026
|
/review |
left a comment
There was a problem hiding this comment.
SHIP — all five prior findings are resolved in the inspected source; no eligible findings remain in this follow-up.
Verified fixes:
- ATIF normalization preserves structured Relay results, including false, zero, and null. Fallback selection now compares both nonempty and total tool outputs, retaining completed empty native results.
- Proxy cleanup cancels and awaits registered handlers and closes both streams. Post-proxy configuration construction now sits inside the cleanup boundary.
- The base YAML declares both options, allowing composed overrides without weakening unknown-field rejection.
- OpenClaw startup invokes the existing provisioning helper only for that adapter.
Accounted for all ten changed files and compared the fixes with the previous reviewed tree. Discovery remained limited to the prior failures and subsequent changes under the existing impact filter. Relevant regression assertions and directly affected configuration, verifier-handoff, and setup paths were inspected.
Static inspection only: tests, installations, dependency resolution, and rollouts were not executed. Third-party Fabric, Relay, and OpenClaw implementations are not mounted, so runtime compatibility was not independently verified.
Note: formal approval is not available for this request, so this review is posted as a comment only.
Review generated by codex. This was a findings-only review. Request a full review with /review reset=true.
…nd turns from adapter and Relay data, and add the NOOA extra Signed-off-by: Christian Munley <cmunley@nvidia.com>
commented
Oct 25, 2026
|
/ok to test 1c5aed4 |
commented
Oct 25, 2026
|
/review |
LiteLLM 1.82.7 and 1.82.8 were compromised on PyPI, so the server sets a floor above them. The lock still resolves 1.102.4. Signed-off-by: Christian Munley <cmunley@nvidia.com>
…time script The sandbox runtime installs LiteLLM outside the lock, so it needs the same >=1.83.0 floor to skip the compromised releases. Signed-off-by: Christian Munley <cmunley@nvidia.com>
commented
Nov 5, 2026
|
/ok to test 6171bba |
… in its own environment Fabric 0.6.1's Hermes adapter accepts Relay 0.11. Hermes Agent v0.22.7 needs Python 3.14, so the agent syncs a separate locked project and passes its interpreter to Fabric as ADAPTER_PYTHON. The server drops hermes-agent and its pillow and packaging overrides, and the lock policy entry returns to main's. Signed-off-by: Christian Munley <cmunley@nvidia.com>
…ins without a lock Hermes Agent pins its dependencies exactly, so the separate environment installs its pyproject with uv pip instead of committing a lock. Signed-off-by: Christian Munley <cmunley@nvidia.com>
commented
Nov 5, 2026
|
/ok to test 15ad05a |
commented
Nov 6, 2026
|
/review role=automation reset=true |
left a comment
There was a problem hiding this comment.
HOLD — one BLOCKER in Relay result selection, one RISK in OpenClaw provisioning, and one test-isolation NOTE.
I reviewed all 11 changed files, including relevant base/head lock entries and affected setup, configuration, trajectory, and verifier contracts. The earlier structured-result, empty-result, and UTF-8 artifact repairs remain present, but aggregate result counts still allow a different completed tool result to disappear.
Static inspection only: I didn't execute tests, installations, dependency resolution, or rollouts. Third-party Fabric, Relay, and Hermes implementations aren't mounted. One delegated review was cancelled and another detailed report was unavailable; I independently inspected both assigned topics before completing this review.
Review generated by codex. This was a full review. Request a full review with /review reset=true.
| atif_counts, native_counts = _record_counts(atif_items), _record_counts(native_items) | ||
| output_items = ( | ||
| atif_items | ||
| if atif_items and all(atif >= native for atif, native in zip(atif_counts, native_counts)) |
There was a problem hiding this comment.
BLOCKER — Compare completed tool results by call ID, not only by count.
Failure / blast radius: With Relay enabled, take native messages containing a completed c1 result of "kept", followed by the final answer. Let ATIF contain calls c1 and c2, but only a c2 result of "relay-only". Both records have counts (1, 1, 0), so this branch selects ATIF, drops the completed native c1 result, and sends an unmatched c1 call to verification. Likewise, ATIF's empty c1 plus nonempty c2 can displace a nonempty native c1: the unrelated c2 masks the loss. The converter preserves these individual IDs, but the selection discards that evidence. This affects Relay-enabled response and verifier consumers, not Relay-off runs.
Correction — suggested, not executed: After Claude's native-result substitution and before selection, add a per-call completeness guard:
atif_outputs = {
item.call_id: item.output
for item in atif_items
if isinstance(item, NeMoGymResponseFunctionCallOutput)
}
native_results_retained = all(
item.call_id in atif_outputs
and (not item.output or bool(atif_outputs[item.call_id]))
for item in native_items
if isinstance(item, NeMoGymResponseFunctionCallOutput)
)Add and native_results_retained to the existing ATIF eligibility condition. Keep the existing count and reasoning guards. The invariant is that an unrelated Relay result cannot compensate for a missing native result or a nonempty native result reduced to empty. If an adapter uses different call-ID namespaces, retain native output unless their correspondence is established; count equality isn't a safe correspondence.
Preservation / acceptance — proposed checks: Add mocked _create_response cases for both examples above; expect native c1 with exact output "kept". Repeat the missing-result case with native c1=""; its completed result must still survive. Complete ATIF containing matching c1 plus Relay-only c2 must remain eligible, including when both matching results are explicitly empty. Retain the existing fallback assertions, Claude call-ID substitution and Relay-only result assertions, native reasoning preservation, and malformed argument strings. This guard leaves conversion and subagent ordering unchanged. Please verify the suggested code before adopting it.
| @@ -0,0 +1,26 @@ | |||
| # Needs the OpenClaw CLI on PATH (npm install --global openclaw@2026.9.4). The Python extra installs only the adapter. | |||
There was a problem hiding this comment.
RISK — Provision the runtime required by the OpenClaw preset.
Failure / blast radius: On a clean host without OpenClaw on PATH, installing this component and selecting this preset still leaves its required CLI absent. The locked OpenClaw extra installs the Python adapter, while startup only provisions an optional Python adapter project. The README requires a manual npm installation. That leaves this new preset unusable without external setup, contrary to the trusted host-tool provisioning contract.
Correction: Provision the CLI and compatible Node runtime at startup only when adapter_id == "nvidia.fabric.openclaw", expose the executable on PATH, and report actionable setup failures. The existing ensure_openclaw provides an idempotent starting point, but don't reuse its older defaults blindly: this README specifies OpenClaw 2026.9.34 and Node 24.22.1 or later, whereas this YAML comment still specifies 2026.9.4. Align the documented pin and installer, and verify Fabric compatibility. The exact installer integration needs that verification, so I’m not suggesting an unverified one-line call.
Preservation / acceptance — proposed checks: With CLI and Node absent, selecting this preset must provision a compatible runtime and make openclaw --version report the selected exact release before invocation. A compatible existing installation must avoid reinstalling. Every other preset must avoid OpenClaw setup. Failed provisioning must fail clearly before rollout execution. Retain the preset's 120-second startup, 86400-second read, and 5-second shutdown settings, plus its existing planning assertion.
| patch.object(NeMoFabricAgent, "resolve_model_base_url", return_value="http://127.0.0.1:9002"), | ||
| patch("responses_api_agents.nemo_fabric_agent.app.Fabric", return_value=fabric), | ||
| patch( | ||
| "nemo_fabric_adapters.hermes.telemetry.validate_hermes_relay_compatibility", |
There was a problem hiding this comment.
NOTE — Suggestion: mock the compatibility subprocess instead of the parent-process import.
Failure / scope: This patch replaces a function only in pytest's process, but _adapter_supports_relay starts a fresh interpreter. That interpreter doesn't inherit the mock. The intended incompatible-Hermes setup therefore isn't controlled: a successful installed checker makes the assertions fail, while an unrelated import or installation failure can make them pass.
Correction — suggested, not executed: Replace this external-function patch with the boundary the implementation actually calls:
patch(
"responses_api_agents.nemo_fabric_agent.app.subprocess.run",
return_value=MagicMock(
returncode=1,
stderr="Hermes Agent without Relay support",
),
),The invariant is that the test controls the compatibility outcome independently of installed Hermes packages. Production compatibility checking should remain unchanged.
Preservation / acceptance: Retain the assertions that incompatibility omits both Relay configuration and relay_atif. Add a companion case returning returncode=0, stderr=""; with the Relay-capable descriptor, assert Fabric receives the Relay provider and enabled ATIF recording. Neither case should launch a real compatibility subprocess. Please verify the suggested replacement before adopting it.
- Use ATIF output only when it keeps every native tool result under its call ID, so a Relay-only result cannot make up for a dropped or emptied one. - Mock the Hermes Relay compatibility subprocess in its test, and cover the compatible case. - Drop the OpenClaw preset: it needs the OpenClaw CLI and Node.js, which the server does not provision. The adapter stays installed. Signed-off-by: Christian Munley <cmunley@nvidia.com>
The lock still resolves 0.6.1. Signed-off-by: Christian Munley <cmunley@nvidia.com>
commented
Nov 6, 2026
|
/ok to test f27c773 |
commented
Nov 6, 2026
|
/review role=automation |
left a comment
There was a problem hiding this comment.
SHIP — all three findings from the latest review are resolved; no eligible findings remain in this follow-up.
Verified in the current source:
- The per-call Relay guard prevents an unrelated result from compensating for a missing or emptied native result. The regression cases cover both prior failures, completed empty results, and complete ATIF with extra results. The existing count, reasoning, and Claude substitution guards remain intact.
- The Hermes compatibility test now mocks the subprocess boundary and checks both compatible and incompatible outcomes.
- The unprovisioned OpenClaw preset has been withdrawn, rather than given an installer. Its planning case is removed, and the README distinguishes the installed adapter from the available presets.
I compared the subsequent changes with the previously reviewed tree and checked their directly affected response, verifier-handoff, configuration, and dependency paths. The Fabric range matches the lock metadata, which still resolves 0.6.1. No introduced high- or critical-impact regression was established under the existing impact filter.
Static inspection only: I didn't execute tests, installations, dependency resolution, or rollouts. I inspected relevant lock entries, not the full base-to-head lock diff. Third-party implementations aren't mounted. Two delegated detailed reports were unavailable; I independently completed their Relay-selection and Hermes-test inspections.
Review generated by codex. This was a findings-only review. Request a full review with /review reset=true.
What does this PR do?
Updates
nemo_fabric_agentfrom NeMo Fabric 0.2.0 to 0.6.1 and adds an opt-in NeMo Relay path.nemo-fabric>=0.6.0,<0.7). Adds thenooa,openhands,openclaw, andrelayextras and an OpenHands preset. OpenClaw has no preset because this server does not provision its CLI and Node.js (npm install --global openclaw@2026.9.34). Like Fabric's Harbor integration, the agent expects harness CLIs to be preinstalled. The TypeScript adapters (Cline, Droid, Kilo, OpenCode, Pi, Qwen Code) also run through this agent when their npm packages are installed and discovered withfabric_config.discovery.local_paths.relay: true. Records each run with NeMo Relay and builds the response from Relay's ATIF trajectory, unless the adapter's own output has more tool outputs or reasoning, which ATIF does not record.fabric_result.relay_atifholds the trajectories.harness_settings.insecure_http_model_hosts(Relay 0.11).finished_naturally: falseinstead of raising.send_model_base_url: falsefor adapters that read their endpoint elsewhere (Factory Droid).litellm>=1.83.0,<1.103: the floor skips the compromised 1.82.7 and 1.82.8 releases, and later releases import mcp 2 types while nemo-gym pins mcp<2. The portable runtime script applies the same range.hermes_env/, exact pins, no lock) that the agent installs at startup and passes to Fabric asADAPTER_PYTHON(adapter_projectin the Hermes preset). Relay 0.11 works for Hermes there. The server env no longer carries hermes-agent or its overrides, andscripts/component-lock-policy.jsonis unchanged.Validation
pytest responses_api_agents/nemo_fabric_agent/tests tests/unit_tests/tooling/test_component_dependencies.py: 75 passed, including planning for every preset, Relay config, ATIF parsing (Relay's structuredextra.tool_resultand empty results) and fallback, the base URL opt-out, and runs that end out of turns.finished_naturally: false.finished_naturally: false.pre-commiton the changed files: passed.Rollouts
Run on Fabric 0.5.0: every harness ran through Gym with a self-hosted DeepSeek-V4.1-Flash policy on three environments. Each cell is passes over attempts. Most harnesses also needed harness-specific settings, such as permission modes, model fields, or the model server's
reasoning_field.The remaining 0/3 cells come from limits and settings, not the model:
fabric_config.models.default.max_tokensis set, and inline reasoning counts against it. The Alpine image's BusyBoxsetprivlacks--pdeathsig, which the gateway needs.session.promptrequest, and itsbashtool waits for an approval no one gives. ANODE_OPTIONSpreload that disables undici's timeouts plusfabric_config.tools.enabledfixed both. The proper fix for the first belongs in Fabric's Kilo adapter.Relay produced complete trajectories for Claude and Codex on SWE-bench (every tool call has its result). Known Fabric 0.5.0 and Relay 0.10 gaps, kept behind the opt-in flag:
nemo_relay.tools.call_end, so its trajectory has no tool results, and on math more of its runs failed with Relay.Compatibility and benchmark impact
relaydefaults tofalse, so existing runs are unchanged apart from the Fabric version. The pinned benchmark configs that installnemo-fabric[deepagents]==0.2.0(deepsearchqa, widesearch) are left as is.Follow-ups outside this PR:
cache_controlNOOA sends: fix(chat): drop cache_control hints from chat request messages #5059.turns_used.ng_perfstays empty because this agent emits no agent invocation records.Checklist