fix(inference): send max_completion_tokens for GPT-5 and o-series models - #6643
Conversation
GPT-5-family models and the o1/o3/o4 reasoning series (including Azure OpenAI deployments) reject the legacy `max_tokens` parameter on /chat/completions with HTTP 400 and require `max_completion_tokens` instead, so onboarding and agent turns against gpt-5.4 on a custom OpenAI-compatible provider fail out of the box. Add a shared resolveMaxTokensField() resolver and use it in the host onboarding probes and the in-sandbox compatible-endpoint smoke check so both agree on the field name. Add an openclaw gpt-5.4 model-specific setup manifest that routes the reply budget to max_completion_tokens on the managed inference route. Fixes NVIDIA#6642 Signed-off-by: Greg Mercer <gmercer@stanford.edu> Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
Note Reviews pausedIt 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 Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughThe PR adds model-aware selection between ChangesReply-budget compatibility
Estimated code review effort: 4 (Complex) | ~45 minutes Sequence Diagram(s)sequenceDiagram
participant ModelSelector
participant MaxTokensResolver
participant OpenClawConfig
participant CompatibleEndpoint
ModelSelector->>MaxTokensResolver: provide model identifier
MaxTokensResolver-->>ModelSelector: return max_completion_tokens or max_tokens
ModelSelector->>OpenClawConfig: configure provider compatibility field
OpenClawConfig->>CompatibleEndpoint: generate model-specific request payload
CompatibleEndpoint->>CompatibleEndpoint: send selected token field
Suggested labels: Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 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 Target RecommendationRequired E2E targets: Dispatch required E2E targets:
Full E2E target advisor summaryE2E Target AdvisorBase: Required E2E targets
Optional E2E targets
Relevant changed files
|
Signed-off-by: Carlos Villela <cvillela@nvidia.com>
Signed-off-by: Carlos Villela <cvillela@nvidia.com>
E2E Target Results —
|
| Job | Result |
|---|---|
| cloud-onboard | |
| inference-routing | ✅ success |
| kimi-inference-compat | |
| network-policy | |
| onboard-repair | |
| onboard-resume |
There was a problem hiding this comment.
🧹 Nitpick comments (2)
test/generate-hermes-config.test.ts (1)
1100-1128: 🎯 Functional Correctness | 🔵 Trivial | ⚡ Quick winExercise the Hermes generation boundary.
This test calls
discoverModelSpecificSetupsdirectly and checks only match counts, so a regression in registry wiring or effect serialization could pass. Add one case through the public Hermes generation path and assert the resulting configuration effect, or move this case to a focused matcher test and add that integration assertion separately.As per path instructions, tests should prefer observable outcomes through the public boundary over internal implementation checks.
🤖 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/generate-hermes-config.test.ts` around lines 1100 - 1128, Extend the Hermes test beyond direct discoverModelSpecificSetups match counts by exercising the public Hermes generation path for the bounded model-prefix case. Assert the generated configuration contains the expected hermesCompat effect, while preserving the existing non-matching boundary cases; use the public generation API rather than adding further internal matcher assertions.Source: Path instructions
docs/inference/local-compatible-inference-setup.mdx (1)
41-42: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winUse second-person wording in the new documentation.
Rewrite these sentences as direct instructions to the reader.
Proposed wording
-For GPT-5 and the `o1`, `o3`, and `o4` model families, NemoClaw configures OpenClaw to send the maximum reply token limit as `max_completion_tokens` instead of the legacy `max_tokens`. -This automatic compatibility handling recognizes provider-prefixed and suffixed model IDs, such as `azure/gpt-5.4`, `gpt-5.4-turbo`, and `openai/o3-mini`. +When you use GPT-5 or the `o1`, `o3`, and `o4` model families, NemoClaw configures OpenClaw to send the maximum reply token limit as `max_completion_tokens` instead of the legacy `max_tokens`. +You can use provider-prefixed and suffixed model IDs, such as `azure/gpt-5.4`, `gpt-5.4-turbo`, and `openai/o3-mini`.As per coding guidelines, documentation must use active voice, second person, present tense, and direct language.
🤖 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/local-compatible-inference-setup.mdx` around lines 41 - 42, Rewrite the new documentation sentences using active, second-person, present-tense instructions that address the reader directly. Preserve the existing details about max_completion_tokens, legacy max_tokens, and supported provider-prefixed or suffixed model IDs.Source: Coding guidelines
🤖 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 `@docs/inference/local-compatible-inference-setup.mdx`:
- Around line 41-42: Rewrite the new documentation sentences using active,
second-person, present-tense instructions that address the reader directly.
Preserve the existing details about max_completion_tokens, legacy max_tokens,
and supported provider-prefixed or suffixed model IDs.
In `@test/generate-hermes-config.test.ts`:
- Around line 1100-1128: Extend the Hermes test beyond direct
discoverModelSpecificSetups match counts by exercising the public Hermes
generation path for the bounded model-prefix case. Assert the generated
configuration contains the expected hermesCompat effect, while preserving the
existing non-matching boundary cases; use the public generation API rather than
adding further internal matcher assertions.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Enterprise
Run ID: cd3d5975-0def-4841-8ed8-5c26bcee3725
📒 Files selected for processing (9)
agents/hermes/config/model-specific-setup.tsdocs/inference/local-compatible-inference-setup.mdxnemoclaw-blueprint/model-specific-setup/openclaw/gpt-5-o-series-managed-inference.jsonnemoclaw-blueprint/model-specific-setup/schema.jsonscripts/generate-openclaw-config.mtssrc/lib/onboard/compatible-endpoint-smoke.test.tstest/generate-hermes-config.test.tstest/generate-openclaw-config-gpt5-compat.test.tstest/validate-config-schemas.test.ts
E2E Target Results — ✅ All selected jobs passedRun: 29150997910
|
Signed-off-by: Carlos Villela <cvillela@nvidia.com>
E2E Target Results — ✅ All selected jobs passedRun: 29151359546
|
cv
left a comment
There was a problem hiding this comment.
Exact-head maintainer gate passed at bc9bc4c: required CI and CodeRabbit are green, all commits are Verified, six targeted live E2Es passed, and the trusted GPT advisor found no issues. The remaining Nemotron coverage suggestions are already materially exercised across resolver/config/smoke and Hermes boundary tests and are non-blocking.
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 `@src/lib/inference/openai-validation-session.ts`:
- Around line 82-144: Update chatToolPayload so reasoning models identified by
the existing resolveMaxTokensField model logic do not receive the hardcoded
temperature: 0 parameter. Omit temperature for GPT-5/o1/o3/o4 models, while
preserving temperature: 0 for models that support it.
🪄 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: 11f7e12c-5d70-40bb-bc4c-18ba4078804e
📒 Files selected for processing (4)
src/lib/inference/onboard-probes.tssrc/lib/inference/openai-probe-models.tssrc/lib/inference/openai-validation-session.test.tssrc/lib/inference/openai-validation-session.ts
<!-- markdownlint-disable MD041 --> ## Summary Release-prep documentation for v0.0.81 now summarizes user-facing changes merged since v0.0.80. It also closes the Hermes dashboard-profile backup gap and distinguishes direct blueprint-runner actions from public host CLI commands. ## Changes - Add the `v0.0.81` section to `docs/about/release-notes.mdx` with links to the detailed user guides. - Document that Hermes rebuilds preserve `.hermes/dashboard-home/`, including Dashboard `MEMORY.md` and `USER.md`. - Update Hermes manual backup and restore examples to transfer those two profile files without copying generated configuration or the secret-bearing dashboard `.env`. - Explain the new per-item backup failure causes. - Clarify that migration snapshot retention fragments are direct-runner arguments and are not exposed by the host `nemoclaw` CLI. ### Source summary - #6445 -> `docs/about/release-notes.mdx`, `docs/manage-sandboxes/backup-restore.mdx`, and `docs/manage-sandboxes/workspace-files.mdx`: Summarize manifest-owned key-level restore and current-config authority. - #6617 -> `docs/about/release-notes.mdx` and `docs/manage-sandboxes/backup-restore.mdx`: Record the fail-closed `/proc` fallback used to verify an idle Deep Agents runtime before snapshot creation. - #6685 -> `docs/about/release-notes.mdx`, `docs/manage-sandboxes/backup-restore.mdx`, and `docs/manage-sandboxes/workspace-files.mdx`: Document Hermes Web Dashboard profile persistence and safe manual transfer. - #6649 -> `docs/about/release-notes.mdx`: Summarize host-validated loopback compatible-endpoint routing through the sandbox gateway. - #6643 -> `docs/about/release-notes.mdx`: Summarize automatic `max_completion_tokens` handling for GPT-5 and o-series models. - #6661 -> `docs/about/release-notes.mdx`: Summarize bounded connection reuse for eligible provider-validation probes. - #6704 -> `docs/about/release-notes.mdx`: Record that direct blueprint apply stops instead of persisting incomplete state after provider or inference setup fails. - #6677 -> `docs/about/release-notes.mdx`: Summarize transactional recovery for legacy Docker containers whose managed supervisor disappeared after restart. - #6625 -> `docs/about/release-notes.mdx`: Record Hermes managed-startup persistence across direct Docker restarts. - #6597 -> `docs/about/release-notes.mdx`: Record final-sandbox gateway cleanup on macOS. - #6680 -> `docs/about/release-notes.mdx`: Summarize managed Deep Agents first-run and process-tree cleanup improvements. - #6647 -> `docs/about/release-notes.mdx`: Record fail-closed validation for the managed Deep Agents fetch CA bundle. - #6645 -> `docs/about/release-notes.mdx`: Summarize WhatsApp loopback pairing and trusted npm plugin provenance. - #6673 -> `docs/about/release-notes.mdx` and `docs/manage-sandboxes/backup-restore.mdx`: Document stopped-sandbox backup remediation. - #6631 -> `docs/about/release-notes.mdx` and `docs/manage-sandboxes/backup-restore.mdx`: Document per-item backup failure causes. - #6620 -> `docs/about/release-notes.mdx`: Record the created-but-not-ready sandbox lifecycle receipt. - #6664 -> `docs/about/release-notes.mdx`: Record prompt-aware onboarding progress output. - #6598 -> `docs/about/release-notes.mdx`: Summarize stale replay-result invalidation during resumed onboarding. - #6593 -> `docs/about/release-notes.mdx`: Summarize contextual OpenClaw audit findings for managed dashboard compatibility settings. - #6650 -> `docs/about/release-notes.mdx`: Record redaction of token-shaped URL query values. - #6638 -> `docs/about/release-notes.mdx`: Record the exact-path MCP `DELETE` policy recipe for session termination. - #5453 -> `docs/reference/host-files-and-state.mdx`: Clarify that snapshot retention actions belong to direct runner integrations and are not standalone host CLI commands. ### Skipped from docs-skip - #6633 matched the `openclaw-sandbox-permissive.yaml` path in `docs/.docs-skip` and produced no documentation in this update. ## 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 - [ ] Tests added or updated for changed behavior - [ ] Existing tests cover changed behavior — justification: - [x] Tests not applicable — justification: This is a documentation-only release-prep update; behavior is protected by the merged source PRs, and the documentation build validates the changed examples and routes. - [x] 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: - [ ] 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 — tests are not applicable for this documentation-only change; `npm run docs` completed successfully. - [ ] Applicable broad gate passed — `npm test` for broad runtime/test-harness changes; `npm run check` for repo-wide validation/coverage changes — command/result: not run for this documentation-only change. - [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) — 0 errors; two existing Fern warnings remain. - [x] Doc pages follow the [style guide](https://github.com/NVIDIA/NemoClaw/blob/main/docs/CONTRIBUTING.md) (doc changes only) - [ ] New doc pages include SPDX header and frontmatter (new pages only) — no new pages. --- Signed-off-by: Carlos Villela <cvillela@nvidia.com> <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **Documentation** - Added release notes for v0.0.81 covering state preservation, inference setup, sandbox recovery, session setup, pairing, diagnostics, and security policy updates. - Expanded backup and restore guidance to include dashboard profile files and clarify files that must not be copied. - Added dashboard profile persistence details to workspace and rebuild documentation. - Clarified snapshot retention guidance and the distinction between host CLI capabilities and direct runner actions. - Added more detailed backup failure reporting information. <!-- end of auto-generated comment: release notes by coderabbit.ai --> Signed-off-by: Carlos Villela <cvillela@nvidia.com>
…els (NVIDIA#6643) ## Summary GPT-5-family models and the o1/o3/o4 reasoning series (including Azure OpenAI deployments) reject the legacy `max_tokens` parameter on `/chat/completions` with `HTTP 400: Unsupported parameter: 'max_tokens' ... Use 'max_completion_tokens' instead`. As a result, onboarding and agent turns against `gpt-5.4` on a custom OpenAI-compatible provider fail out of the box. This routes the reply-budget field to `max_completion_tokens` for those model families. ## Related Issue Fixes NVIDIA#6642 ## Changes - Add a shared `resolveMaxTokensField()` resolver (`src/lib/inference/max-tokens-field.ts`) that returns `max_completion_tokens` for GPT-5 and o-series (`o1`/`o3`/`o4`) models and `max_tokens` otherwise. Prefix-matched so provider-prefixed and Azure-suffixed ids (`azure/gpt-5.4`, `gpt-5.4-turbo`) resolve correctly. - Use the resolver in the host onboarding probes (`onboard-probes.ts`, both the compatible-endpoint payload and the strict tool-call probe) and the in-sandbox compatible-endpoint smoke script (`compatible-endpoint-smoke.ts`), so host and sandbox agree on the field name. - Expand the declarative OpenClaw model setup to bounded GPT-5 and o1/o3/o4 family prefixes, including provider-prefixed and suffixed model IDs, while preserving exact-match behavior for existing manifests. - Add unit and integration coverage for resolver, probe, smoke retry, schema, and OpenClaw/Hermes config-generation behavior. - Document the automatic GPT-5/o-series reply-budget field selection in the compatible-endpoint guide. ## Type of Change - [ ] Code change (feature, bug fix, or refactor) - [x] Code change with doc updates - [ ] Doc only (prose changes, no code sample modifications) - [ ] 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) - [ ] Sensitive-path review completed or maintainer-approved waiver recorded — reviewer/approval link/justification: requesting maintainer sensitive-path review (inference/onboarding); contributor cannot self-approve. - [ ] 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: affected Vitest slice → 384 passed; focused post-hook generator slice → 142 passed; `npm run typecheck:cli`, `npm run validate:configs`, `npm run test:titles:check`, and the normal commit/push hooks passed. - [ ] Applicable broad gate passed — `npm test` for broad runtime/test-harness changes; `npm run check` for repo-wide validation/coverage changes — command/result: not applicable (scoped inference-probe change, no test-harness or repo-wide validation changes). - [x] Quality Gates section completed with required justifications or waivers - [x] No secrets, API keys, or credentials committed - [x] `npm run docs` builds without errors (doc changes only) - [x] Doc pages follow the style guide (doc changes only) - [ ] New doc pages include SPDX header and frontmatter (new pages only) --- Signed-off-by: Greg Mercer <gmercer@stanford.edu> <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added automatic token-budget compatibility for GPT-5 and o-series models, switching between `max_tokens` and `max_completion_tokens` as needed. * Added model-family matching via bounded prefixes (including provider-prefixed model IDs) and updated generated OpenClaw/Hermes configs accordingly. * Added a new managed inference blueprint for GPT-5 and o-series routing. * **Bug Fixes** * Improved tool-calling and strict probe payloads to consistently use the correct token field. * Enhanced reasoning retries to preserve the correct token budget. * **Documentation** * Updated guidance on reply-budget handling for supported model families. * **Tests** * Expanded coverage for token-field selection, prefix matching, and config validation/schema rules. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Signed-off-by: Greg Mercer <gmercer@stanford.edu> Signed-off-by: Carlos Villela <cvillela@nvidia.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Co-authored-by: Carlos Villela <cvillela@nvidia.com>
<!-- markdownlint-disable MD041 --> ## Summary Release-prep documentation for v0.0.81 now summarizes user-facing changes merged since v0.0.80. It also closes the Hermes dashboard-profile backup gap and distinguishes direct blueprint-runner actions from public host CLI commands. ## Changes - Add the `v0.0.81` section to `docs/about/release-notes.mdx` with links to the detailed user guides. - Document that Hermes rebuilds preserve `.hermes/dashboard-home/`, including Dashboard `MEMORY.md` and `USER.md`. - Update Hermes manual backup and restore examples to transfer those two profile files without copying generated configuration or the secret-bearing dashboard `.env`. - Explain the new per-item backup failure causes. - Clarify that migration snapshot retention fragments are direct-runner arguments and are not exposed by the host `nemoclaw` CLI. ### Source summary - NVIDIA#6445 -> `docs/about/release-notes.mdx`, `docs/manage-sandboxes/backup-restore.mdx`, and `docs/manage-sandboxes/workspace-files.mdx`: Summarize manifest-owned key-level restore and current-config authority. - NVIDIA#6617 -> `docs/about/release-notes.mdx` and `docs/manage-sandboxes/backup-restore.mdx`: Record the fail-closed `/proc` fallback used to verify an idle Deep Agents runtime before snapshot creation. - NVIDIA#6685 -> `docs/about/release-notes.mdx`, `docs/manage-sandboxes/backup-restore.mdx`, and `docs/manage-sandboxes/workspace-files.mdx`: Document Hermes Web Dashboard profile persistence and safe manual transfer. - NVIDIA#6649 -> `docs/about/release-notes.mdx`: Summarize host-validated loopback compatible-endpoint routing through the sandbox gateway. - NVIDIA#6643 -> `docs/about/release-notes.mdx`: Summarize automatic `max_completion_tokens` handling for GPT-5 and o-series models. - NVIDIA#6661 -> `docs/about/release-notes.mdx`: Summarize bounded connection reuse for eligible provider-validation probes. - NVIDIA#6704 -> `docs/about/release-notes.mdx`: Record that direct blueprint apply stops instead of persisting incomplete state after provider or inference setup fails. - NVIDIA#6677 -> `docs/about/release-notes.mdx`: Summarize transactional recovery for legacy Docker containers whose managed supervisor disappeared after restart. - NVIDIA#6625 -> `docs/about/release-notes.mdx`: Record Hermes managed-startup persistence across direct Docker restarts. - NVIDIA#6597 -> `docs/about/release-notes.mdx`: Record final-sandbox gateway cleanup on macOS. - NVIDIA#6680 -> `docs/about/release-notes.mdx`: Summarize managed Deep Agents first-run and process-tree cleanup improvements. - NVIDIA#6647 -> `docs/about/release-notes.mdx`: Record fail-closed validation for the managed Deep Agents fetch CA bundle. - NVIDIA#6645 -> `docs/about/release-notes.mdx`: Summarize WhatsApp loopback pairing and trusted npm plugin provenance. - NVIDIA#6673 -> `docs/about/release-notes.mdx` and `docs/manage-sandboxes/backup-restore.mdx`: Document stopped-sandbox backup remediation. - NVIDIA#6631 -> `docs/about/release-notes.mdx` and `docs/manage-sandboxes/backup-restore.mdx`: Document per-item backup failure causes. - NVIDIA#6620 -> `docs/about/release-notes.mdx`: Record the created-but-not-ready sandbox lifecycle receipt. - NVIDIA#6664 -> `docs/about/release-notes.mdx`: Record prompt-aware onboarding progress output. - NVIDIA#6598 -> `docs/about/release-notes.mdx`: Summarize stale replay-result invalidation during resumed onboarding. - NVIDIA#6593 -> `docs/about/release-notes.mdx`: Summarize contextual OpenClaw audit findings for managed dashboard compatibility settings. - NVIDIA#6650 -> `docs/about/release-notes.mdx`: Record redaction of token-shaped URL query values. - NVIDIA#6638 -> `docs/about/release-notes.mdx`: Record the exact-path MCP `DELETE` policy recipe for session termination. - NVIDIA#5453 -> `docs/reference/host-files-and-state.mdx`: Clarify that snapshot retention actions belong to direct runner integrations and are not standalone host CLI commands. ### Skipped from docs-skip - NVIDIA#6633 matched the `openclaw-sandbox-permissive.yaml` path in `docs/.docs-skip` and produced no documentation in this update. ## 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 - [ ] Tests added or updated for changed behavior - [ ] Existing tests cover changed behavior — justification: - [x] Tests not applicable — justification: This is a documentation-only release-prep update; behavior is protected by the merged source PRs, and the documentation build validates the changed examples and routes. - [x] 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: - [ ] 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 — tests are not applicable for this documentation-only change; `npm run docs` completed successfully. - [ ] Applicable broad gate passed — `npm test` for broad runtime/test-harness changes; `npm run check` for repo-wide validation/coverage changes — command/result: not run for this documentation-only change. - [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) — 0 errors; two existing Fern warnings remain. - [x] Doc pages follow the [style guide](https://github.com/NVIDIA/NemoClaw/blob/main/docs/CONTRIBUTING.md) (doc changes only) - [ ] New doc pages include SPDX header and frontmatter (new pages only) — no new pages. --- Signed-off-by: Carlos Villela <cvillela@nvidia.com> <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **Documentation** - Added release notes for v0.0.81 covering state preservation, inference setup, sandbox recovery, session setup, pairing, diagnostics, and security policy updates. - Expanded backup and restore guidance to include dashboard profile files and clarify files that must not be copied. - Added dashboard profile persistence details to workspace and rebuild documentation. - Clarified snapshot retention guidance and the distinction between host CLI capabilities and direct runner actions. - Added more detailed backup failure reporting information. <!-- end of auto-generated comment: release notes by coderabbit.ai --> Signed-off-by: Carlos Villela <cvillela@nvidia.com>
Summary
GPT-5-family models and the o1/o3/o4 reasoning series (including Azure OpenAI deployments) reject the legacy
max_tokensparameter on/chat/completionswithHTTP 400: Unsupported parameter: 'max_tokens' ... Use 'max_completion_tokens' instead. As a result, onboarding and agent turns againstgpt-5.4on a custom OpenAI-compatible provider fail out of the box. This routes the reply-budget field tomax_completion_tokensfor those model families.Related Issue
Fixes #6642
Changes
resolveMaxTokensField()resolver (src/lib/inference/max-tokens-field.ts) that returnsmax_completion_tokensfor GPT-5 and o-series (o1/o3/o4) models andmax_tokensotherwise. Prefix-matched so provider-prefixed and Azure-suffixed ids (azure/gpt-5.4,gpt-5.4-turbo) resolve correctly.onboard-probes.ts, both the compatible-endpoint payload and the strict tool-call probe) and the in-sandbox compatible-endpoint smoke script (compatible-endpoint-smoke.ts), so host and sandbox agree on the field name.Type of Change
Quality Gates
Verification
Verifiedin GitHubpre-commit,commit-msg, andpre-pushhooks passed, ornpm run check:diffpassed when hooks were skipped or unavailablenpm run typecheck:cli,npm run validate:configs,npm run test:titles:check, and the normal commit/push hooks passed.npm testfor broad runtime/test-harness changes;npm run checkfor repo-wide validation/coverage changes — command/result: not applicable (scoped inference-probe change, no test-harness or repo-wide validation changes).npm run docsbuilds without errors (doc changes only)Signed-off-by: Greg Mercer gmercer@stanford.edu
Summary by CodeRabbit
max_tokensandmax_completion_tokensas needed.