Skip to content

docs(inference): improve page readability#6590

Merged
cv merged 15 commits into
mainfrom
codex/restructure-inference-docs
Jul 9, 2026
Merged

docs(inference): improve page readability#6590
cv merged 15 commits into
mainfrom
codex/restructure-inference-docs

Conversation

@miyoungc

@miyoungc miyoungc commented Jul 9, 2026

Copy link
Copy Markdown
Collaborator

Summary

Restructure the inference documentation so dense explanations are broken into shorter task-oriented sections.
Separate the Ollama workflow from self-hosted compatible-server, vLLM, and NIM setup, keeping every resulting inference page below 500 lines.

Changes

  • Rewrite long inference-page paragraphs into concise sections and subsections while preserving commands and technical guidance.
  • Narrow use-local-inference to Ollama and move raw model-file and self-hosted-server guidance to local-compatible-inference-setup.
  • Register the distinct Ollama and self-hosted-server pages in the OpenClaw, Hermes, and Deep Agents navigation variants.
  • Clarify that compatible-endpoint onboarding may probe Responses before choosing the default Chat Completions runtime.
  • Scope post-ready sandbox route verification to local vLLM and Ollama, which are the providers it covers.
  • Explain the containerized-gateway alias's host-side validation limit.
  • Restore and test self-hosted setup, recovery, routing, and verification details that moved during the Ollama split.
  • Point the platform-docs reasoning-mode regression test at the self-hosted guide, where that configuration now lives.
  • Add focused assertions for self-hosted setup links, API-probe selection, sandbox route scope, gateway validation, retained setup content, the loopback-only raw model-server example, and vLLM tool-calling remediation.

Type of Change

  • Code change (feature, bug fix, or refactor)
  • Code change with doc updates
  • Doc only (prose changes, no code sample modifications)
  • Doc only (includes code sample changes)

Quality Gates

  • Tests added or updated for changed behavior
  • Existing tests cover changed behavior — justification:
  • Tests not applicable — justification:
  • Docs updated for user-facing behavior changes
  • Docs not applicable — justification:
  • Sensitive paths changed (security, policy, credentials, preflight, onboarding, inference, runner, sandbox, or messaging)
  • Sensitive-path review completed or maintainer-approved waiver recorded — reviewer/approval link/justification: Reviewed the docs-only inference diff to preserve technical guidance, commands, links, and agent-specific content.
  • Non-success, skipped, or missing CI check accepted by maintainer — check name, approval link, and follow-up issue:

Verification

  • PR description includes the DCO sign-off declaration and every commit appears as Verified in GitHub
  • Normal pre-commit, commit-msg, and pre-push hooks passed, or npm run check:diff passed when hooks were skipped or unavailable
  • Targeted behavior tests pass for the current change set, or tests are marked not applicable above — command/result or justification: npx vitest run test/inference-options-docs.test.ts passed with 10 tests and npx vitest run test/generate-platform-docs.test.ts passed with 19 tests.
  • Applicable broad gate passed — npm test for broad runtime/test-harness changes; npm run check for repo-wide validation/coverage changes — command/result:
  • Quality Gates section completed with required justifications or waivers
  • No secrets, API keys, or credentials committed
  • npm run docs builds without warnings (doc changes only)
  • Doc pages follow the style guide (doc changes only)
  • New doc pages include SPDX header and frontmatter (new pages only)

Signed-off-by: Miyoung Choi miyoungc@nvidia.com

Summary by CodeRabbit

  • New Features

    • Added a new guide for setting up self-hosted, OpenAI-compatible inference servers, including endpoint onboarding validation, NEMOCLAW_PREFERRED_API behavior, setup variables, and post-onboarding verification.
    • Updated inference navigation to replace “Use Local Inference” with “Use Ollama for Local Inference” and “Set Up Self-Hosted Inference Servers” where applicable.
  • Documentation

    • Clarified checked-in agents.yaml manifest consumption and reconciliation behavior.
    • Refreshed multiple inference guides (local inference, provider switching, tool-calling reliability, model capability audit, sub-agent setup) and updated related cross-links.
  • Tests

    • Expanded docs navigation and content-semantic assertions for the new self-hosted inference flow.

Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>
@miyoungc miyoungc self-assigned this Jul 9, 2026
@copy-pr-bot

copy-pr-bot Bot commented Jul 9, 2026

Copy link
Copy Markdown

Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

@coderabbitai

coderabbitai Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

This PR adds a new self-hosted inference guide, updates inference navigation and linked docs, and reflows several related inference documentation pages and tests.

Changes

Local and Compatible Inference Documentation

Layer / File(s) Summary
Declarative manifest clarifications
docs/inference/declarative-agents-manifest.mdx
Reworks manifest ingestion, primary-agent rules, sub-agent delegation shape, multi-model configuration, and sandbox reconciliation behavior.
Capability audit and tool-calling guidance
docs/inference/model-capability-audit.mdx, docs/inference/tool-calling-reliability.mdx
Restructures the model capability audit checklist and breaks tool-calling guidance into agent-specific subsections with updated next-step navigation.
New self-hosted inference guide
docs/inference/local-compatible-inference-setup.mdx
Adds the self-hosted inference setup page covering OpenAI-compatible, Anthropic-compatible, vLLM, and NIM setup, verification, and timeout configuration.
Inference navigation and option links
docs/index.yml, docs/inference/inference-options.mdx, test/inference-options-docs.test.ts, test/generate-platform-docs.test.ts, docs/about/release-notes.mdx, docs/deployment/deploy-to-remote-gpu.mdx, docs/get-started/windows-preparation.mdx
Updates inference navigation and related inference-option guidance to point to the Ollama and self-hosted setup pages, and aligns supporting tests and linked docs with the new doc paths.
Use-local-inference reflow
docs/inference/use-local-inference.mdx
Reorganizes the Ollama local-inference page into clearer subsections for install, onboarding, proxy setup, non-interactive setup, verification, and next steps.
Sub-agent setup reflow
docs/inference/set-up-sub-agent.mdx
Reflows the sub-agent setup guide’s intro, config export and upload flow, credential instructions, troubleshooting, and delegation instructions.
Provider switch spacing cleanup
docs/inference/switch-inference-providers.mdx
Adjusts paragraph spacing and blank lines across the provider-switching guide without changing the underlying guidance.

Estimated code review effort: 3 (Moderate) | ~30 minutes

Possibly related PRs

  • NVIDIA/NemoClaw#5244: Updates vLLM-managed inference documentation and NEMOCLAW_VLLM_MODEL behavior, which overlaps with the self-hosted/vLLM documentation changes here.

Suggested reviewers: cv, jyaunches

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Title check ❓ Inconclusive The title is related to the docs changes, but it is too vague to convey the main split between Ollama and self-hosted inference pages. Use a more specific title such as "docs(inference): split Ollama and self-hosted inference docs".
✅ Passed checks (4 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/restructure-inference-docs

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

PR Review Advisor (Nemotron Ultra) — No blocking findings

Merge posture: No blocking advisor findings
Primary next action: No advisor follow-up required beyond maintainer review.
Open items: 0 required · 0 warnings · 0 suggestions · 0 test follow-ups
Since last review: 0 prior items resolved · 0 still apply · 0 new items found

Workflow run details

This is an automated, non-binding review; it still expects maintainers and agents to respond to each required or warning item. Treat suggestions as current-PR improvements when they touch changed code; defer only with maintainer rationale or a linked follow-up. A human maintainer must make the final merge decision.

@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

E2E Advisor Recommendation

Required E2E: None
Optional E2E: None

Workflow run

Full advisor summary

E2E Recommendation Advisor

Base: origin/main
Head: HEAD
Confidence: high

Required E2E

  • None. No E2E is recommended. The deterministic risk plan has no required jobs, and the PR only changes documentation plus documentation-validation tests. There are no runtime code changes that could affect installer/onboarding, sandbox lifecycle, credentials, security boundaries, network policy, inference routing, deployment execution, or real assistant user flows.

Optional E2E

  • None.

New E2E recommendations

  • None.

@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

E2E Target Recommendation

Required E2E targets: None
Optional E2E targets: None

Workflow run

Full E2E target advisor summary

E2E Target Advisor

Base: origin/main
Head: HEAD
Confidence: high

Required E2E targets

  • None. Docs-only changes plus tests outside test/e2e do not affect the E2E target workflow, registry, live support, fixtures, or target behavior.

Optional E2E targets

  • None.

Relevant changed files

  • None.

@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

PR Review Advisor — No blocking findings

Merge posture: No blocking advisor findings
Primary next action: No advisor follow-up required beyond maintainer review.
Open items: 0 required · 0 warnings · 0 suggestions · 0 test follow-ups
Since last review: 1 prior item resolved · 0 still apply · 0 new items found

Workflow run details

This is an automated, non-binding review; it still expects maintainers and agents to respond to each required or warning item. Treat suggestions as current-PR improvements when they touch changed code; defer only with maintainer rationale or a linked follow-up. A human maintainer must make the final merge decision.

@miyoungc
miyoungc marked this pull request as ready for review July 9, 2026 17:49
@miyoungc miyoungc added area: docs Documentation, examples, guides, or docs build v0.0.79 Release target labels Jul 9, 2026
@miyoungc
miyoungc marked this pull request as draft July 9, 2026 17:56
Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🧹 Nitpick comments (2)
docs/inference/tool-calling-reliability.mdx (1)

123-149: 🎯 Functional Correctness | 🔵 Trivial | ⚡ Quick win

Pin and verify the vLLM recipe.

vllm/vllm-openai:latest makes this setup non-reproducible, and the parser/auto-tool-choice flags are version-sensitive. Please pin a tested image tag or digest and confirm the CLI flags against that release before calling the snippet “known-good.”

Suggested change
-    image: vllm/vllm-openai:latest
+    image: vllm/vllm-openai:<tested-version-or-digest>
🤖 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 `@docs/inference/tool-calling-reliability.mdx` around lines 123 - 149, The vLLM
example in the tool-calling reliability doc is not reproducible because it uses
the floating latest image tag and version-sensitive CLI flags. Update the
vllm-nemoclaw recipe to pin a specific tested vllm/vllm-openai image tag or
digest, and verify that the --enable-auto-tool-choice and --tool-call-parser
hermes options are valid for that exact release before labeling the snippet
known-good.
docs/inference/use-local-inference.mdx (1)

292-292: 📐 Maintainability & Code Quality | 🔵 Trivial

Link this directly to the new setup guide.

Based on the PR split, this paragraph now describes content that lives in local-compatible-inference-setup, so routing readers through Inference Options adds an unnecessary hop.

🤖 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 `@docs/inference/use-local-inference.mdx` at line 292, Update the reference in
the paragraph about full compatible-endpoint prompt flow, non-interactive
variables, API-path controls, managed vLLM profiles, NIM setup, and timeout
settings so it points directly to the new local-compatible-inference-setup guide
instead of routing through Inference Options. Locate the sentence in
use-local-inference.mdx and change the link target to the new setup guide while
keeping the surrounding wording intact.
🤖 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 `@docs/inference/inference-options.mdx`:
- Around line 306-308: The inbound links are still using the old anchor for the
renamed section, so they no longer jump to the correct place. Update the
references in the local inference docs that point to inference-options so they
use the new `#configure-local-and-compatible-providers` anchor, and verify the
link targets still resolve from use-local-inference.mdx and any other matching
references.

In `@docs/inference/set-up-sub-agent.mdx`:
- Around line 99-102: The setup guide text uses the wrong config path for adding
a secondary agent, which can mislead readers about where to place it. Update the
instructions in the sub-agent setup section to reference agents.list instead of
agents, and keep the surrounding wording aligned with the existing config
structure used elsewhere in the guide.

---

Nitpick comments:
In `@docs/inference/tool-calling-reliability.mdx`:
- Around line 123-149: The vLLM example in the tool-calling reliability doc is
not reproducible because it uses the floating latest image tag and
version-sensitive CLI flags. Update the vllm-nemoclaw recipe to pin a specific
tested vllm/vllm-openai image tag or digest, and verify that the
--enable-auto-tool-choice and --tool-call-parser hermes options are valid for
that exact release before labeling the snippet known-good.

In `@docs/inference/use-local-inference.mdx`:
- Line 292: Update the reference in the paragraph about full compatible-endpoint
prompt flow, non-interactive variables, API-path controls, managed vLLM
profiles, NIM setup, and timeout settings so it points directly to the new
local-compatible-inference-setup guide instead of routing through Inference
Options. Locate the sentence in use-local-inference.mdx and change the link
target to the new setup guide while keeping the surrounding wording intact.
🪄 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: 82d186e8-9817-4571-a49d-39f5d05b8bdf

📥 Commits

Reviewing files that changed from the base of the PR and between 5d7f814 and 2e5990e.

📒 Files selected for processing (9)
  • docs/index.yml
  • docs/inference/declarative-agents-manifest.mdx
  • docs/inference/inference-options.mdx
  • docs/inference/local-compatible-inference-setup.mdx
  • docs/inference/model-capability-audit.mdx
  • docs/inference/set-up-sub-agent.mdx
  • docs/inference/switch-inference-providers.mdx
  • docs/inference/tool-calling-reliability.mdx
  • docs/inference/use-local-inference.mdx

Comment thread docs/inference/inference-options.mdx Outdated
Comment on lines +306 to +308
## Configure Local and Compatible Providers

## vLLM

When vLLM is already running on `localhost:8000`, NemoClaw can detect it automatically and query the `/v1/models` endpoint to determine the loaded model.
On supported Linux hosts with NVIDIA GPUs, the onboard wizard can also install or start a managed vLLM container for you.

For an already-running vLLM server, run `$$nemoclaw onboard` and select **Local vLLM [experimental]** from the provider list.

If vLLM is already running, NemoClaw detects the running model and validates the endpoint.
When vLLM exposes runtime metadata such as `max_model_len`, NemoClaw uses that value for the `contextWindow` baked into `openclaw.json` unless you set `NEMOCLAW_CONTEXT_WINDOW` yourself.
If vLLM is not running and your host matches a DGX Spark or DGX Station managed profile, NemoClaw shows the **Install vLLM** or **Start vLLM** entry by default.
Generic Linux NVIDIA GPU hosts still require `NEMOCLAW_EXPERIMENTAL=1` or `NEMOCLAW_PROVIDER=install-vllm` before the managed entry appears.
In interactive runs, the managed vLLM path lists the supported registry models for your host profile before it pulls weights.
Press **Enter** to use the default model, or choose a numbered entry to serve another validated model with its matching `vllm serve` flags.
NemoClaw pulls the vLLM image, downloads model weights into `~/.cache/huggingface`, starts the `nemoclaw-vllm` container on `localhost:8000`, streams Hugging Face download progress, and polls `/v1/models` until the model is ready.
Managed DGX Spark and DGX Station profiles use the stable NGC `nvcr.io/nvidia/vllm:26.05.post1-py3` container image.
If `docker pull` output stops making progress, a watchdog stops the stalled pull instead of failing slow but active downloads on a fixed wall-clock timeout.
If vLLM never becomes ready, NemoClaw prints a short tail of the vLLM container logs before exiting.
The first run can take 10 to 30 minutes.
Later runs reuse the cached image and model weights.

Managed vLLM uses these profiles:

| Host profile | Default model |
|---|---|
| DGX Spark | `nvidia/Qwen3.6-35B-A3B-NVFP4` |
| DGX Station | `deepseek-ai/DeepSeek-V4-Flash` |
| Linux with an NVIDIA GPU | `nvidia/NVIDIA-Nemotron-3-Nano-4B-FP8` |

<Note>
NemoClaw forces the `chat/completions` API path for vLLM.
The vLLM `/v1/responses` endpoint does not run the `--tool-call-parser`, so tool calls arrive as raw text.
</Note>

### Non-Interactive Setup

Use an already-running vLLM server:

```bash
NEMOCLAW_PROVIDER=vllm \
$$nemoclaw onboard --non-interactive
```

Install or start managed vLLM when NemoClaw detects a supported profile.
On DGX Spark and DGX Station, `NEMOCLAW_PROVIDER=install-vllm` is enough for non-interactive runs; add `NEMOCLAW_EXPERIMENTAL=1` on generic Linux NVIDIA GPU hosts.
Non-interactive runs use the profile default unless you set `NEMOCLAW_VLLM_MODEL`.

```bash
NEMOCLAW_PROVIDER=install-vllm \
$$nemoclaw onboard --non-interactive
```

NemoClaw records the model returned by vLLM's `/v1/models` endpoint.
Start vLLM with the model you want before onboarding if you manage the server yourself.

### Override the Managed-vLLM Model

Managed vLLM serves the profile default unless you choose a different registry entry in the interactive picker or set an override for automation.
Export `NEMOCLAW_VLLM_MODEL=<slug>` before invoking the installer to choose a different model without prompting.
NemoClaw uses the matching `vllm serve` flags, including the reasoning parser, tool-call parser, and `--max-model-len`.
Recognized slugs are:

| Slug | Hugging Face model | Notes |
|---|---|---|
| `qwen3.6-27b` | `Qwen/Qwen3.6-27B-FP8` | Supported override |
| `qwen3.6-35b-a3b-nvfp4` | `nvidia/Qwen3.6-35B-A3B-NVFP4` | Default on the DGX Spark profile |
| `nemotron-3-nano-4b` | `nvidia/NVIDIA-Nemotron-3-Nano-4B-FP8` | Default on the generic Linux + NVIDIA GPU profile |
| `deepseek-v4-flash` | `deepseek-ai/DeepSeek-V4-Flash` | Default on the DGX Station profile |
| `deepseek-r1-distill-70b` | `deepseek-ai/DeepSeek-R1-Distill-Llama-70B` | Gated. Requires Hugging Face license acceptance |

The slug is case-insensitive; the full Hugging Face id is also accepted.
An unrecognized value fails fast with a list of valid slugs.

Gated models require a Hugging Face token; export it before onboarding so NemoClaw can forward it into the managed vLLM container:

```bash
export HF_TOKEN=<your-hf-token>
NEMOCLAW_PROVIDER=install-vllm \
NEMOCLAW_VLLM_MODEL=deepseek-r1-distill-70b \
$$nemoclaw onboard --non-interactive
```

NemoClaw accepts `HUGGING_FACE_HUB_TOKEN` as an alternative.
The token check runs on the host before any `docker pull`, so a missing or empty token aborts onboarding before bandwidth is spent on a 401.

### Add Managed-vLLM Serve Arguments

For advanced vLLM options that are not in the NemoClaw registry yet, export `NEMOCLAW_VLLM_EXTRA_ARGS_JSON` as a JSON array of individual non-blank `vllm serve` tokens.
NemoClaw trims and validates the array before pulling images or downloading models, shell-quotes each token, and appends the tokens after the registry defaults.

```bash
NEMOCLAW_PROVIDER=install-vllm \
NEMOCLAW_VLLM_EXTRA_ARGS_JSON='["--max-num-seqs","2","--disable-log-requests"]' \
$$nemoclaw onboard --non-interactive
```

Use this for operator-owned tuning only.
If the selected vLLM image does not support an argument, the managed container exits and NemoClaw prints the vLLM log tail.

## NVIDIA NIM (Experimental)

NemoClaw can pull, start, and manage a NIM container on hosts with a NIM-capable NVIDIA GPU.

<Warning>
On Linux arm64 DGX Spark and DGX Station hosts, some NIM images may not publish a `linux/arm64` manifest.
NemoClaw prints an advisory warning and still attempts the selected image.
If the registry reports that no matching platform manifest exists, select NVIDIA Endpoints, managed vLLM, or another provider with an image for the host architecture.
</Warning>

Set the experimental flag and run onboard.

```bash
NEMOCLAW_EXPERIMENTAL=1 $$nemoclaw onboard
```

Select **Local NVIDIA NIM [experimental]** from the provider list.
NemoClaw filters available models by GPU VRAM, pulls the NIM container image, starts it, and waits for it to become healthy before continuing.
On hosts with mixed NVIDIA GPU models, the preflight summary shows each detected GPU model and the total VRAM so you can confirm which device class the model selection used.
On Docker 29.x or containerd image-store hosts, NemoClaw resolves the host-platform manifest digest before pulling multi-architecture NIM images when the registry exposes an index.
It pulls `repo@digest` and retags the local image so NGC attestation metadata on other architectures does not block the selected platform.
If the registry does not expose a matching index, NemoClaw falls back to the tag pull.

NVIDIA hosts NIM container images on `nvcr.io`, and `docker pull` requires NGC registry authentication.
If Docker is not already logged in to `nvcr.io`, onboard prompts for an [NGC API key](https://org.ngc.nvidia.com/setup/api-key) and runs `docker login nvcr.io` over `--password-stdin` so the key is never written to disk or shell history.
The prompt masks the key during input and retries one time on a bad key before failing.
In non-interactive mode, onboard exits with login instructions if Docker is not already authenticated; run `docker login nvcr.io` yourself, then re-run `$$nemoclaw onboard --non-interactive`.
If `NGC_API_KEY` or `NVIDIA_INFERENCE_API_KEY` is already exported, NemoClaw passes it into the managed NIM container through the process environment instead of command-line arguments.
If the NIM container exits before the health endpoint becomes ready, onboarding stops early and prints the last container log lines.
After NIM becomes healthy, NemoClaw reads `/v1/models` and uses the served model id for validation when it differs from the catalog name.
Unsafe served ids are rejected instead of being written into the sandbox config.

<Note>
NIM uses vLLM internally.
The same `chat/completions` API path restriction applies.
</Note>

### Non-Interactive Setup

```bash
NEMOCLAW_EXPERIMENTAL=1 \
NEMOCLAW_PROVIDER=nim \
$$nemoclaw onboard --non-interactive
```

To select a specific model, set `NEMOCLAW_MODEL`.

## Timeout Configuration

Local inference requests use a default timeout of 180 seconds.
Large prompts on hardware such as DGX Spark can exceed shorter timeouts, so NemoClaw sets a higher default for Ollama, vLLM, NIM, and compatible-endpoint setup.

To override the timeout, set the `NEMOCLAW_LOCAL_INFERENCE_TIMEOUT` environment variable before onboarding:

```bash
export NEMOCLAW_LOCAL_INFERENCE_TIMEOUT=300
$$nemoclaw onboard
```

The value is in seconds.
NemoClaw bakes this setting into the sandbox at build time.
Changing it after onboarding requires re-running `$$nemoclaw onboard`.

`NEMOCLAW_LOCAL_INFERENCE_TIMEOUT` only governs the inference-server validation probe.
During local Ollama setup, NemoClaw treats host-side curl process timeouts as retryable probe failures and retries with a larger timeout before it reports a validation failure.
NemoClaw also retries Docker runtime detection with a longer `docker info` timeout before it chooses the local inference route.
The post-create readiness wait (image build, gateway upload, in-sandbox boot) has its own budget, `NEMOCLAW_SANDBOX_READY_TIMEOUT`, also defaulting to 180 seconds.
On hosts where the sandbox image takes minutes to build or upload, raise both settings together.
Examples include large quantized models, DGX Station first runs, and remote VMs over a slow link.

```bash
export NEMOCLAW_LOCAL_INFERENCE_TIMEOUT=300
export NEMOCLAW_SANDBOX_READY_TIMEOUT=600
$$nemoclaw onboard
```

<AgentOnly variant="openclaw,hermes">
If onboard ends with `Sandbox '<name>' was created but did not become ready within 180s`, refer to [Troubleshooting](../reference/troubleshooting#sandbox-onboard-times-out-with-did-not-become-ready-within-ns).
</AgentOnly>
For custom endpoints, vLLM, NVIDIA NIM, and inference timeout configuration, refer to [Set Up Local and Compatible Inference](local-compatible-inference-setup).

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Search for references to the old heading/anchor text across docs
rg -n "setup-details-for-local-and-compatible-providers|Setup Details for Local and Compatible Providers" docs

Repository: NVIDIA/NemoClaw

Length of output: 686


🏁 Script executed:

#!/bin/bash
rg -n "setup-details-for-local-and-compatible-providers|Setup Details for Local and Compatible Providers" .

Repository: NVIDIA/NemoClaw

Length of output: 690


🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Inspect the relevant section and any explicit anchor overrides in the file.
grep -nE '^## |^{#|id=' docs/inference/inference-options.mdx || true
sed -n '300,315p' docs/inference/inference-options.mdx

# Search for the new heading text and the old slug across the repository.
rg -n "Configure Local and Compatible Providers|setup-details-for-local-and-compatible-providers" .

# Show the surrounding links that still use the old anchor.
sed -n '280,330p' docs/inference/use-local-inference.mdx

Repository: NVIDIA/NemoClaw

Length of output: 5264


Update inbound links to the renamed section. docs/inference/use-local-inference.mdx still points at inference-options#setup-details-for-local-and-compatible-providers; change both references to #configure-local-and-compatible-providers so they jump to the section instead of the page top.

🤖 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 `@docs/inference/inference-options.mdx` around lines 306 - 308, The inbound
links are still using the old anchor for the renamed section, so they no longer
jump to the correct place. Update the references in the local inference docs
that point to inference-options so they use the new
`#configure-local-and-compatible-providers` anchor, and verify the link targets
still resolve from use-local-inference.mdx and any other matching references.

Comment thread docs/inference/set-up-sub-agent.mdx
Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>
@miyoungc

miyoungc commented Jul 9, 2026

Copy link
Copy Markdown
Collaborator Author

Addressed the valid agents.list wording finding in 72311a8. The stale-link findings reference the earlier 2e5990e revision; 5a20de8 removed both old inference-options setup-anchor links, and npm run docs passes on the current head.

Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>
@github-code-quality

github-code-quality Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Code Coverage Overview

Languages: TypeScript

TypeScript / code-coverage/plugin

The overall coverage remains at 96%, unchanged from the branch.

TypeScript / code-coverage/cli

The overall coverage in the branch remains at 77%, unchanged from the branch.

Show a code coverage summary of the most impacted files.
File ac9e1bc 3a6b5f7 +/-
src/lib/state/config-io.ts 95% 88% -7%
src/lib/messagi.../persistence.ts 95% 92% -3%
src/lib/credentials/store.ts 61% 59% -2%
src/lib/adapters/http/probe.ts 89% 91% +2%
src/lib/security/redact.ts 96% 98% +2%
src/lib/actions...estore-phase.ts 87% 93% +6%
src/lib/actions...de-preflight.ts 51% 60% +9%
src/lib/onboard...e-patch-flow.ts 61% 71% +10%
src/lib/actions...confirmation.ts 69% 81% +12%
src/lib/actions...light-guards.ts 71% 88% +17%

Updated July 09, 2026 20:46 UTC
Code Coverage is in Public Preview. Learn more and provide us with your feedback.

cv
cv previously requested changes Jul 9, 2026

@cv cv left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Requesting changes on exact head 72311a8a792c3e9be8b6a979774ac6daf5eef4fa.

The structural split builds cleanly (npm run docs: 0 errors, two existing warnings), the generated variants/routes are current, DCO passes, and all commits are Verified. The remaining blockers are semantic and safety-related:

  1. Complete the link migration. inference-options.mdx:275 sends NIM/vLLM readers to the now Ollama-only page; deploy-to-remote-gpu.mdx:185 points to a timeout anchor that moved; tool-calling-reliability.mdx:214 and several vLLM/NIM release-note entries still route to use-local-inference. Mixed Ollama/vLLM entries should link to both guides. Add focused semantic-link coverage so valid-but-wrong destinations are caught.
  2. Do not recommend an unauthenticated llama-server on 0.0.0.0 without a firewall/authenticated-proxy warning. Prefer loopback for the documented localhost topology and add a regression guard for public compatible-server binds.
  3. Scope the max_model_len/openclaw.json statement in local-compatible-inference-setup.mdx:186. It currently renders into Hermes and Deep Agents variants even though their config surfaces differ.
  4. Restore operational guidance dropped by the move: managed-vLLM reboot recovery, port 8000 coverage by the local-inference preset, and the raw-GGUF non-interactive example/model-id guidance.

The exact-head GPT advisor independently reached merge_after_fixes on the first two items. Please address these while the PR remains draft, resolve the stale review threads, then rerun the docs checks and both advisors.

@cv

cv commented Jul 9, 2026

Copy link
Copy Markdown
Collaborator

Narrowing the changes-requested review for current head 5cd296203b907d5b009e3ccc8e39f2a7b3176beb, which arrived concurrently with the review:

Addressed on this head:

  • The Caveated Local Options section now links Ollama and self-hosted vLLM/NIM separately.
  • The raw llama-server example now binds to 127.0.0.1.
  • Focused semantic-link and loopback assertions were added.

Still requested:

  • Update docs/deployment/deploy-to-remote-gpu.mdx:185; its timeout link still targets the removed use-local-inference#timeout-configuration anchor.
  • Scope or rewrite the unqualified max_model_len / openclaw.json statement in local-compatible-inference-setup.mdx; it currently renders inaccurate OpenClaw-specific config guidance into Hermes and Deep Agents variants.
  • Finish the semantic inbound-link audit, including the vLLM workflow link in tool-calling-reliability.mdx and vLLM/NIM or mixed local-inference entries in release notes.
  • Restore the moved operational details promised by the PR description: managed-vLLM reboot recovery, port 8000 coverage by the local-inference preset, and the raw-GGUF-specific non-interactive/model-id example.

The review remains CHANGES_REQUESTED only for these remaining items.

miyoungc added 5 commits July 9, 2026 11:16
Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>
Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>
Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>
Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>
Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>
@miyoungc
miyoungc marked this pull request as ready for review July 9, 2026 18:49
@jyaunches jyaunches added v0.0.80 Release target and removed v0.0.79 Release target labels Jul 9, 2026

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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 `@test/inference-options-docs.test.ts`:
- Around line 207-223: These tests are overfitted to production source text
instead of behavior, so replace the raw file-content assertions with checks
against the actual public/runtime behavior of the relevant paths. Use the
existing symbols like shouldForceCompletionsApi, LOCAL_INFERENCE_PROVIDERS
consumers, and the isSandboxInternalUrl-gated validation flow to exercise
outcomes indirectly, while keeping only the documentation-prose assertions as
literal markdown checks. This will make the tests resilient to refactors such as
renames, formatting changes, or boolean-expression reordering without changing
behavior.
🪄 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: 6a1a6a9b-4b56-4593-a3bd-90f430e9d131

📥 Commits

Reviewing files that changed from the base of the PR and between 2e5990e and c57a48c.

📒 Files selected for processing (7)
  • docs/index.yml
  • docs/inference/inference-options.mdx
  • docs/inference/local-compatible-inference-setup.mdx
  • docs/inference/set-up-sub-agent.mdx
  • docs/inference/tool-calling-reliability.mdx
  • docs/inference/use-local-inference.mdx
  • test/inference-options-docs.test.ts
✅ Files skipped from review due to trivial changes (5)
  • docs/index.yml
  • docs/inference/tool-calling-reliability.mdx
  • docs/inference/local-compatible-inference-setup.mdx
  • docs/inference/set-up-sub-agent.mdx
  • docs/inference/use-local-inference.mdx

Comment thread test/inference-options-docs.test.ts
miyoungc added 3 commits July 9, 2026 12:00
Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>
Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>
Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>
@miyoungc
miyoungc requested a review from cv July 9, 2026 19:38
@miyoungc
miyoungc marked this pull request as draft July 9, 2026 20:01
@cv

cv commented Jul 9, 2026

Copy link
Copy Markdown
Collaborator

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@miyoungc
miyoungc marked this pull request as ready for review July 9, 2026 20:02

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (2)
test/inference-options-docs.test.ts (2)

266-272: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Fixed 450-char proximity window is brittle.

Matching "host-side endpoint probing is skipped" only within the first 450 characters after each hostGatewayAlias occurrence is an arbitrary heuristic — if the surrounding doc prose grows or is reordered, this could false-negative without any real behavioral regression. Consider anchoring on structural boundaries (e.g., paragraph/section split) instead of a raw character count.

🤖 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 `@test/inference-options-docs.test.ts` around lines 266 - 272, The proximity
check in the markdown test is using a brittle fixed 450-character window after
each hostGatewayAlias occurrence. Update the assertion in
inference-options-docs.test.ts to validate the surrounding documentation using
structural boundaries from the markdown output (such as paragraph or section
splits) instead of slice(0, 450), and keep the same hostGatewayAlias and
“host-side endpoint probing is skipped during onboarding” content checks.

10-37: 🎯 Functional Correctness | 🔵 Trivial | 💤 Low value

Use a direct ESM import for probeOpenAiLikeEndpoint
test/inference-options-docs.test.ts:13-16 can import probeOpenAiLikeEndpoint normally; ../src/lib/inference/onboard-probes already exports it, so createRequire is only needed for typescript.

🤖 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 `@test/inference-options-docs.test.ts` around lines 10 - 37, The
`probeOpenAiLikeEndpoint` import in `test/inference-options-docs.test.ts` is
using `createRequire` unnecessarily even though
`../src/lib/inference/onboard-probes` already provides an ESM export. Update the
top-level imports so `probeOpenAiLikeEndpoint` is brought in with a normal ESM
import, and keep `createRequire` only for the `typescript` CommonJS load; adjust
the surrounding setup in the same test module without changing the test
behavior.

Sources: Coding guidelines, Learnings

🤖 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.

Nitpick comments:
In `@test/inference-options-docs.test.ts`:
- Around line 266-272: The proximity check in the markdown test is using a
brittle fixed 450-character window after each hostGatewayAlias occurrence.
Update the assertion in inference-options-docs.test.ts to validate the
surrounding documentation using structural boundaries from the markdown output
(such as paragraph or section splits) instead of slice(0, 450), and keep the
same hostGatewayAlias and “host-side endpoint probing is skipped during
onboarding” content checks.
- Around line 10-37: The `probeOpenAiLikeEndpoint` import in
`test/inference-options-docs.test.ts` is using `createRequire` unnecessarily
even though `../src/lib/inference/onboard-probes` already provides an ESM
export. Update the top-level imports so `probeOpenAiLikeEndpoint` is brought in
with a normal ESM import, and keep `createRequire` only for the `typescript`
CommonJS load; adjust the surrounding setup in the same test module without
changing the test behavior.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: b442b865-273e-4ca6-8a56-b5cf46c0a619

📥 Commits

Reviewing files that changed from the base of the PR and between 3f9f862 and 9d9f440.

📒 Files selected for processing (6)
  • docs/about/release-notes.mdx
  • docs/deployment/deploy-to-remote-gpu.mdx
  • docs/get-started/windows-preparation.mdx
  • docs/inference/local-compatible-inference-setup.mdx
  • docs/inference/set-up-sub-agent.mdx
  • test/inference-options-docs.test.ts
✅ Files skipped from review due to trivial changes (4)
  • docs/deployment/deploy-to-remote-gpu.mdx
  • docs/get-started/windows-preparation.mdx
  • docs/inference/set-up-sub-agent.mdx
  • docs/about/release-notes.mdx
🚧 Files skipped from review as they are similar to previous changes (1)
  • docs/inference/local-compatible-inference-setup.mdx

@cv
cv dismissed their stale review July 9, 2026 20:49

Addressed on exact head 3a6b5f7: link migration and semantic regression coverage completed, unsafe public bind guidance removed/guarded, agent scoping corrected, operational recovery/policy/model guidance restored, docs build passed, and both exact-head advisors are clean.

@cv
cv merged commit a37e3b4 into main Jul 9, 2026
56 of 58 checks passed
@cv
cv deleted the codex/restructure-inference-docs branch July 9, 2026 21:39
Hadar301 pushed a commit to Hadar301/NemoClaw-OpenShift that referenced this pull request Jul 12, 2026
## Summary

Restructure the inference documentation so dense explanations are broken
into shorter task-oriented sections.
Separate the Ollama workflow from self-hosted compatible-server, vLLM,
and NIM setup, keeping every resulting inference page below 500 lines.

## Changes

- Rewrite long inference-page paragraphs into concise sections and
subsections while preserving commands and technical guidance.
- Narrow `use-local-inference` to Ollama and move raw model-file and
self-hosted-server guidance to `local-compatible-inference-setup`.
- Register the distinct Ollama and self-hosted-server pages in the
OpenClaw, Hermes, and Deep Agents navigation variants.
- Clarify that compatible-endpoint onboarding may probe Responses before
choosing the default Chat Completions runtime.
- Scope post-ready sandbox route verification to local vLLM and Ollama,
which are the providers it covers.
- Explain the containerized-gateway alias's host-side validation limit.
- Restore and test self-hosted setup, recovery, routing, and
verification details that moved during the Ollama split.
- Point the platform-docs reasoning-mode regression test at the
self-hosted guide, where that configuration now lives.
- Add focused assertions for self-hosted setup links, API-probe
selection, sandbox route scope, gateway validation, retained setup
content, the loopback-only raw model-server example, and vLLM
tool-calling remediation.

## Type of Change

- [ ] Code change (feature, bug fix, or refactor)
- [ ] Code change with doc updates
- [ ] Doc only (prose changes, no code sample modifications)
- [x] Doc only (includes code sample changes)

## Quality Gates

- [x] Tests added or updated for changed behavior
- [ ] Existing tests cover changed behavior — justification:
- [ ] Tests not applicable — justification:
- [x] Docs updated for user-facing behavior changes
- [ ] Docs not applicable — justification:
- [x] Sensitive paths changed (security, policy, credentials, preflight,
onboarding, inference, runner, sandbox, or messaging)
- [x] Sensitive-path review completed or maintainer-approved waiver
recorded — reviewer/approval link/justification: Reviewed the docs-only
inference diff to preserve technical guidance, commands, links, and
agent-specific content.
- [ ] Non-success, skipped, or missing CI check accepted by maintainer —
check name, approval link, and follow-up issue:

## Verification

- [x] PR description includes the DCO sign-off declaration and every
commit appears as `Verified` in GitHub
- [x] Normal `pre-commit`, `commit-msg`, and `pre-push` hooks passed, or
`npm run check:diff` passed when hooks were skipped or unavailable
- [x] Targeted behavior tests pass for the current change set, or tests
are marked not applicable above — command/result or justification: `npx
vitest run test/inference-options-docs.test.ts` passed with 10 tests and
`npx vitest run test/generate-platform-docs.test.ts` passed with 19
tests.
- [ ] Applicable broad gate passed — `npm test` for broad
runtime/test-harness changes; `npm run check` for repo-wide
validation/coverage changes — command/result:
- [x] Quality Gates section completed with required justifications or
waivers
- [x] No secrets, API keys, or credentials committed
- [ ] `npm run docs` builds without warnings (doc changes only)
- [x] Doc pages follow the [style
guide](https://github.com/NVIDIA/NemoClaw/blob/main/docs/CONTRIBUTING.md)
(doc changes only)
- [x] New doc pages include SPDX header and frontmatter (new pages only)

---
Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Added a new guide for setting up self-hosted, OpenAI-compatible
inference servers, including endpoint onboarding validation,
`NEMOCLAW_PREFERRED_API` behavior, setup variables, and post-onboarding
verification.
* Updated inference navigation to replace “Use Local Inference” with
“Use Ollama for Local Inference” and “Set Up Self-Hosted Inference
Servers” where applicable.

* **Documentation**
* Clarified checked-in agents.yaml manifest consumption and
reconciliation behavior.
* Refreshed multiple inference guides (local inference, provider
switching, tool-calling reliability, model capability audit, sub-agent
setup) and updated related cross-links.

* **Tests**
* Expanded docs navigation and content-semantic assertions for the new
self-hosted inference flow.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Signed-off-by: Miyoung Choi <miyoungc@nvidia.com>
Co-authored-by: Carlos Villela <cvillela@nvidia.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: docs Documentation, examples, guides, or docs build v0.0.80 Release target

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants