fix(blueprint): disable native tool search for Nemotron managed inference#4800
Conversation
…ence OpenClaw's native code-based tool search (tool_search_code) requires the model to emit JavaScript that calls openclaw.tools.search/describe/call. nvidia/nemotron-3-super-120b-a12b generates invalid JS for this surface (CommonJS require, search called with an object instead of a string, bad describe/call ids), flooding otherwise-successful agent runs with repeated "[tools] tool_search_code failed" errors. Add a model-specific-setup manifest that sets effects.openclawTools.toolSearch to false for the Nemotron managed inference.local route, mirroring the existing kimi-k2.6 precedent, so the model uses the structured tool-calling surface it handles correctly. Fixes #4780 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
📝 WalkthroughWalkthroughThis PR adds a configuration rule and tests to disable OpenClaw's native code-based tool search for Nemotron 3 Super 120B when accessed via the managed inference endpoint, preventing invalid JavaScript generation during agent execution. ChangesNemotron managed inference tool search configuration
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~4 minutes Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
E2E Advisor RecommendationRequired E2E: Dispatch hint: Full advisor summaryE2E Recommendation AdvisorBase: Required E2E
Optional E2E
New E2E recommendations
Dispatch hint
|
E2E Scenario Advisor RecommendationRequired scenario E2E: Dispatch required scenario E2E:
Full scenario advisor summaryE2E Scenario AdvisorBase: Required scenario E2E
Optional scenario E2E
Relevant changed files
|
PR Review AdvisorFindings: 0 needs attention, 0 worth checking, 0 nice ideas This is an automated advisory review. A human maintainer must make the final merge decision. |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In
`@nemoclaw-blueprint/model-specific-setup/openclaw/nemotron-3-super-120b-managed-inference.json`:
- Around line 1-17: This new JSON manifest (id
"nemotron-3-super-120b-managed-inference") is missing the required SPDX
copyright/license header; add the standard SPDX header block (the project's
canonical copyright and license lines) at the top of the file before the JSON
object so the file conforms to the repository rule that all .json files include
the SPDX header.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Enterprise
Run ID: da126afc-8627-4667-9bd0-3bf58fd6f0ff
📒 Files selected for processing (2)
nemoclaw-blueprint/model-specific-setup/openclaw/nemotron-3-super-120b-managed-inference.jsontest/generate-openclaw-config.test.ts
| { | ||
| "$schema": "../schema.json", | ||
| "id": "nemotron-3-super-120b-managed-inference", | ||
| "agent": "openclaw", | ||
| "description": "Disables OpenClaw's native code-based tool search for nvidia/nemotron-3-super-120b-a12b on the NemoClaw managed inference.local route. The model emits invalid JavaScript for the tool_search_code surface (CommonJS require, openclaw.tools.search called with an object, bad describe/call ids), flooding successful runs with '[tools] tool_search_code failed' errors (#4780); routing it back to the structured tool-calling surface avoids the noise.", | ||
| "match": { | ||
| "modelIds": ["nvidia/nemotron-3-super-120b-a12b"], | ||
| "providerKey": "inference", | ||
| "inferenceApi": "openai-completions", | ||
| "baseUrl": "https://inference.local/v1" | ||
| }, | ||
| "effects": { | ||
| "openclawTools": { | ||
| "toolSearch": false | ||
| } | ||
| } | ||
| } |
There was a problem hiding this comment.
Missing required SPDX header in this new JSON source file.
This manifest is a new .json source file but does not include the required SPDX header text.
As per coding guidelines: **/*.{js,ts,tsx,jsx,sh,md,mdx,json,yaml,yml,css,svg} files must include the specified SPDX copyright and license header.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In
`@nemoclaw-blueprint/model-specific-setup/openclaw/nemotron-3-super-120b-managed-inference.json`
around lines 1 - 17, This new JSON manifest (id
"nemotron-3-super-120b-managed-inference") is missing the required SPDX
copyright/license header; add the standard SPDX header block (the project's
canonical copyright and license lines) at the top of the file before the JSON
object so the file conforms to the repository rule that all .json files include
the SPDX header.
There was a problem hiding this comment.
Declining this one — it's a false positive for this file class. Three reasons, all verifiable against the repo:
-
The SPDX hook deliberately excludes JSON.
.pre-commit-config.yaml'sspdx-headershook scopes tofiles: ^(nemoclaw/src/.*\.ts|scripts/export-catalog-skills\.py|scripts/.*\.ts|nemoclaw-blueprint/.*\.py|.*\.sh)$—.jsonis not matched, so model-specific-setup manifests are intentionally out of scope. The pre-commit run on this branch passed accordingly. -
The established precedent has no header. The sibling manifest
nemoclaw-blueprint/model-specific-setup/openclaw/kimi-k2.6-managed-inference.json(the pattern this PR mirrors) ships without an SPDX header and is green in CI. -
The schema forbids adding one. These manifests validate against
schema.json, which sets"additionalProperties": falseand allows only$schema, id, agent, description, match, effects. JSON has no comment syntax, so the only way to carry SPDX text would be an extra key (e.g.$comment), which would failvalidate-config-schemas.test.ts.
So the header is unenforced for this path and, if added, would break schema validation. Leaving the manifest as-is to stay consistent with the kimi precedent.
There was a problem hiding this comment.
@jason-ma-nv, you're absolutely right — I apologize for the noise. All three points are valid:
- The
spdx-headerspre-commit hook regex explicitly targets only.ts,.py, and.shpaths, not.json. - The existing
kimi-k2.6-managed-inference.jsonsibling sets the precedent with no header. - The strict
additionalProperties: falseschema makes it physically impossible to embed SPDX text without breaking validation.
My comment was a false positive. I'll note this for future reviews.
🐇
✏️ Learnings added
Learnt from: jason-ma-nv
Repo: NVIDIA/NemoClaw PR: 4800
File: nemoclaw-blueprint/model-specific-setup/openclaw/nemotron-3-super-120b-managed-inference.json:1-17
Timestamp: 2026-06-05T05:20:41.172Z
Learning: In the NemoClaw/NemoClaw repository, `.json` files under `nemoclaw-blueprint/model-specific-setup/openclaw/` do NOT require SPDX copyright/license headers. The `spdx-headers` pre-commit hook regex (`^(nemoclaw/src/.*\.ts|scripts/export-catalog-skills\.py|scripts/.*\.ts|nemoclaw-blueprint/.*\.py|.*\.sh)$`) explicitly excludes `.json` files. Additionally, these manifests are validated against `schema.json` which enforces `"additionalProperties": false`, allowing only `$schema, id, agent, description, match, effects` — making it impossible to add any SPDX key without breaking schema validation. Do not flag missing SPDX headers on these JSON manifest files.
Note: Learnings are effective only in the context of similar code segments. To apply general coding guidelines, please configure review instructions. You can manage existing learnings in the app.
## Summary - Adds the `v0.0.60` section to `docs/about/release-notes.mdx` using the dev announcement from discussion #4877. - Fills the source-doc gaps found during release-prep review across inference, policy tiers, command behavior, security boundaries, Hermes dashboard/tooling, runtime context, and troubleshooting. - Refreshes generated agent skills under `.agents/skills/` from the current Fern docs output and upgrades Fern from `5.44.3` to `5.45.0`. ## Source summary - #4037 -> `docs/reference/architecture.mdx`, `docs/about/how-it-works.mdx`, `docs/about/release-notes.mdx`: Documents system-only runtime context that stays out of visible chat. - #4875 -> `docs/reference/architecture.mdx`, `docs/about/how-it-works.mdx`, `docs/about/release-notes.mdx`: Documents try-first sandbox network/filesystem guidance and clearer failure classification. - #4788 -> `docs/security/best-practices.mdx`, `docs/about/release-notes.mdx`: Documents shared OpenClaw device-approval policy for startup and connect. - #4768 -> `docs/reference/network-policies.mdx`, `docs/network-policy/integration-policy-examples.mdx`, `docs/get-started/quickstart.mdx`, `docs/get-started/quickstart-hermes.mdx`, `docs/reference/commands.mdx`: Documents `weather`, `public-reference`, and Hermes managed-tool gateway preset behavior. - #3788 and #4864 -> `docs/reference/network-policies.mdx`, `docs/reference/commands.mdx`: Documents non-interactive policy-tier fail-fast behavior and interactive prompt fallback. - #4756 and #4866 -> `docs/reference/commands.mdx`: Documents env-aware default sandbox resolution for `list`, `status`, and `tunnel` commands. - #4320 -> `docs/reference/commands.mdx`: Documents `$$nemoclaw tunnel status` behavior. - #4328 -> `docs/reference/commands.mdx`: Documents line-scoped policy preset descriptions in `policy-list`. - #4580 and #4748 -> `docs/reference/architecture.mdx`: Documents package-managed OpenShell gateway service and Docker-driver gateway-marker behavior. - #4598 -> `docs/manage-sandboxes/lifecycle.mdx`: Documents concurrent gateway/dashboard cleanup isolation by sandbox name and port. - #4777 -> `docs/reference/troubleshooting.mdx`: Documents Docker GPU patch rollback behavior. - #4610 -> `docs/reference/troubleshooting.mdx`, `docs/reference/commands.mdx`: Keeps mutable OpenClaw config permission guidance aligned and removes skipped experimental wording. - #4868 -> `docs/reference/commands.mdx`: Keeps `.dockerignore` handling for custom `onboard --from <Dockerfile>` contexts in generated skills. - #4870 -> `docs/reference/commands.mdx`, `docs/manage-sandboxes/runtime-controls.mdx`: Documents `NEMOCLAW_MINIMAL_BOOTSTRAP` and generated skill coverage. - #4641 -> `docs/inference/inference-options.mdx`, `docs/reference/troubleshooting.mdx`: Documents local NVIDIA NIM platform-digest pulls and served-model id adoption. - #4810 and #4867 -> `docs/inference/inference-options.mdx`: Documents stable NGC managed-vLLM image lineage and DGX Station DeepSeek V4 Flash coverage. - #4852 -> `docs/inference/use-local-inference.mdx`, `docs/reference/troubleshooting.mdx`: Documents Ollama model fit filtering, 16K context floor, cold-load retry, and failed-model exclusion. - #4847 -> `docs/inference/switch-inference-providers.mdx`: Documents API-family sync, Hermes `api_mode`, and Bedrock Runtime exception. - #4800 -> `docs/inference/tool-calling-reliability.mdx`: Documents Nemotron managed-inference native tool-search fallback. - #4333 -> `docs/inference/switch-inference-providers.mdx`: Documents interactive multimodal input prompting. - #4086 -> `docs/reference/troubleshooting.mdx`: Keeps proxy bypass normalization in generated troubleshooting coverage. - #4811 and #4855 -> `docs/get-started/quickstart-hermes.mdx`: Documents prebuilt Hermes dashboard assets and TUI recovery without runtime rebuilds. - #4854 -> `docs/inference/switch-inference-providers.mdx`, `docs/reference/commands.mdx`: Documents Hermes proxy API-key placeholder preservation during inference switches. - #4248 -> `docs/manage-sandboxes/messaging-channels.mdx`, `.agents/skills/`: Keeps messaging enrollment behavior aligned with manifest-hook implementation. - #4771 -> `docs/security/best-practices.mdx`, `docs/security/credential-storage.mdx`: Documents Hermes placeholder-only secret boundary for sandbox-visible runtime files. - #4787 -> `docs/security/best-practices.mdx`, `docs/about/release-notes.mdx`: Documents expanded memory scanner examples for OpenAI project keys and Slack app-level tokens. - #4848 -> `docs/reference/commands.mdx`: Documents OpenClaw skill install mirroring into the agent home directory. - #4790 -> `docs/about/release-notes.mdx`: Uses the prior release-prep structure and generated `.agents/skills/` refresh as the template for this release. ## Verification - `python3 scripts/docs-to-skills.py docs/ .agents/skills/ --prefix nemoclaw-user --doc-platform fern-mdx` - `python3 scripts/docs-to-skills.py docs/ .agents/skills/ skills/ --prefix nemoclaw-user --doc-platform fern-mdx --dry-run` - `npm run docs` - `git diff --check` - skip-term scan across `docs/`, `.agents/skills/`, and `skills/` - `npm run build:cli` - `npm run typecheck:cli` - Commit and pre-push hook suites, including markdownlint, gitleaks, env-var docs gate, docs-to-skills verification, and skills YAML tests <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit ## Release Notes * **New Features** * DeepSeek-V4-Flash now available as default inference model for DGX Station. * Hermes dashboard improved with dedicated port and OAuth-authenticated tool gateway selection. * Added weather and public-reference policy presets for expanded agent capabilities. * Enhanced Ollama model selection with GPU memory filtering and automatic retry for timeouts. * **Bug Fixes** * Improved policy tier validation to prevent invalid configurations. * Better sandbox cleanup scoping by port to prevent conflicts across deployments. * Added GPU patch failure recovery with automatic rollback. * **Documentation** * Expanded troubleshooting guides for inference, security, and sandbox lifecycle. * Added .dockerignore best practices for custom deployments. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Carlos Villela <cvillela@nvidia.com>
Summary
On the NemoClaw managed
inference.localroute,nvidia/nemotron-3-super-120b-a12bfloods otherwise-successful agent runs with repeated[tools] tool_search_code failederrors because it generates invalid JavaScript for OpenClaw's native code-based tool search. This adds a model-specific-setup manifest that disables native tool search for that route, routing the model back to the structured tool-calling surface it handles correctly.Related Issue
Fixes #4780
Changes
nemoclaw-blueprint/model-specific-setup/openclaw/nemotron-3-super-120b-managed-inference.jsonsettingeffects.openclawTools.toolSearch: falsefor the Nemotron managed inference route (providerKey: inference,inferenceApi: openai-completions,baseUrl: https://inference.local/v1), mirroring the existingkimi-k2.6-managed-inference.jsonprecedent.test/generate-openclaw-config.test.ts: one assertingtools.toolSearch === falsefor the Nemotron managed route, and one asserting non-matching routes (different model, provider, API, or base URL) keeptoolSearch === true.Root cause
scripts/generate-openclaw-config.mtsdefaultstools.toolSearch: true, which enables OpenClaw's native code-basedtool_search_code. That surface requires the model to emit JS callingopenclaw.tools.search/describe/call. Nemotron emits invalid JS for it (CommonJSrequire,searchcalled with{ query }instead of a string, baddescribe/callids), producing the noisy failures. Theopenclaw.tools.*API is OpenClaw-native, and NemoClaw's own compact-catalog patch intentionally skips when native tool search is present, so thetoolSearchconfig flag is the correct NemoClaw-side lever — the same one used for Kimi K2.6.Type of Change
Verification
npx prek run --all-filespassesnpm testpassesnpm run docsbuilds without warnings (doc changes only)Verification notes:
prek runon the changed files passed; I did not record a cleanprek run --all-filesbecause that hook set scans pre-existing untracked worktree directories in my local checkout that are unrelated to this change.generate-openclaw-config.test.ts(incl. the two new [Ubuntu 24.04][Agent&Skills] tool_search_code generates invalid JS and logs repeated errors during successful agent runs #4780 tests),validate-config-schemas.test.ts(validates the new manifest againstschema.json),generate-hermes-config.test.ts, andopenclaw-tool-catalog-patch.test.ts.npm testshows 17 pre-existing, environment-dependent failures unrelated to this change (blocked network egress toapi.telegram.org/Slack/OpenAI, no running Docker/gateway, and an unbuiltnemoclaw/distforssrf-parity.test.ts). A declarative JSON manifest plus a config-generation test cannot affect those paths. CI should run them in a complete environment.Signed-off-by: Jason Ma jama@nvidia.com