Repository navigation
support GPT frontier structured responses - #413
Conversation
|
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. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Enterprise Run ID: 📒 Files selected for processing (2)
📜 Recent review details⏰ Context from checks skipped due to timeout. (3)
🧰 Additional context used📓 Path-based instructions (5)configs/**/*.y{a,}ml📄 CodeRabbit inference engine (AGENTS.md)
Files:
**/*📄 CodeRabbit inference engine (AGENTS.md)
Files:
**/*.{yaml,yml}📄 CodeRabbit inference engine (CONTRIBUTING.md)
Files:
{deploy/**,configs/**}⚙️ CodeRabbit configuration file
Files:
**/*.py📄 CodeRabbit inference engine (AGENTS.md)
Files:
🔇 Additional comments (5)
WalkthroughThe PR replaces frontier model profiles with GPT Sol and GPT Luna configurations. It adds schema-based structured-response fallback middleware to deep-research agents. Tests cover promotion, one-time correction, tool handling, middleware wiring, and runtime configuration. ChangesFrontier model configuration
Structured response fallback
Estimated code review effort: 3 (Moderate) | ~25 minutes Sequence Diagram(s)sequenceDiagram
participant ResearcherRunnable
participant StructuredResponseTextFallbackMiddleware
participant AIModel
participant PydanticSchema
ResearcherRunnable->>StructuredResponseTextFallbackMiddleware: process response
StructuredResponseTextFallbackMiddleware->>PydanticSchema: validate JSON text
PydanticSchema-->>StructuredResponseTextFallbackMiddleware: validation result
StructuredResponseTextFallbackMiddleware->>AIModel: request corrected schema JSON without tools
AIModel-->>StructuredResponseTextFallbackMiddleware: corrected response
StructuredResponseTextFallbackMiddleware->>PydanticSchema: validate corrected JSON
StructuredResponseTextFallbackMiddleware-->>ResearcherRunnable: structured or original response
Possibly related PRs
Important Pre-merge checks failedPlease resolve all errors before merging. Addressing warnings is optional. ❌ Failed checks (1 error)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
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 `@tests/aiq_agent/agents/deep_researcher/test_deepagents_runtime.py`:
- Around line 70-80: Extend the assertions in the deep-research runtime test to
validate the changed clarifier_agent model mapping as well as the existing
deep_research_agent mappings. Read the clarifier configuration from the relevant
config structure and assert its llm value against the expected model, while
preserving the current deep-research assertions.
🪄 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: ASSERTIVE
Plan: Enterprise
Run ID: c13f94cd-3021-487c-8f09-48ba0d814004
📒 Files selected for processing (6)
configs/config_frontier_models.ymlsrc/aiq_agent/agents/deep_researcher/custom_middleware.pysrc/aiq_agent/agents/deep_researcher/factory.pytests/aiq_agent/agents/deep_researcher/test_custom_middleware.pytests/aiq_agent/agents/deep_researcher/test_deepagents_runtime.pytests/aiq_agent/agents/deep_researcher/test_factory.py
📜 Review details
⏰ Context from checks skipped due to timeout. (2)
- GitHub Check: Lint and Hooks
- GitHub Check: Pytest and Coverage
🧰 Additional context used
📓 Path-based instructions (7)
**/*.py
📄 CodeRabbit inference engine (AGENTS.md)
**/*.py: Format and lint Python with Ruff using a 120-character line length, Python 3.11 target, rules E/F/W/I/PL/UP, and single-line imports; avoid reformatting unrelated code.
Never print or log secret values, including through tool output or error messages.
**/*.py: Runuv run ruff check .anduv run ruff format --check .for root Python changes.
Runuv run pytestfor root project Python changes.
Files:
src/aiq_agent/agents/deep_researcher/factory.pytests/aiq_agent/agents/deep_researcher/test_deepagents_runtime.pytests/aiq_agent/agents/deep_researcher/test_factory.pysrc/aiq_agent/agents/deep_researcher/custom_middleware.pytests/aiq_agent/agents/deep_researcher/test_custom_middleware.py
src/aiq_agent/**/*.py
📄 CodeRabbit inference engine (AGENTS.md)
src/aiq_agent/**/*.py: Register new data sources indata_source_registryso the UI can toggle them.
Missing-secret paths must degrade gracefully by stubbing or skipping rather than crashing or leaking information.
Respect authenticated data sources by honoringrequires_auth, passing through per-user tokens, using backend token validators, and applying owner guardrails before loading protected report or artifact context into an agent.
Do not weaken or bypassAuthMiddleware, token validators, or authentication gating without prior design discussion.
Files:
src/aiq_agent/agents/deep_researcher/factory.pysrc/aiq_agent/agents/deep_researcher/custom_middleware.py
**/*
📄 CodeRabbit inference engine (AGENTS.md)
**/*: Keep changes inside this repository, avoid editing adjacent repositories, and scope changes to the smallest relevant independent package, especially undersources/.
Run the narrowest relevant validation command first and broaden to the full suite only when a change crosses shared boundaries.
Keep pull requests scoped, exclude unrelated files and generated artifacts, never include secrets, and provide validation commands and results.
**/*: Do not include secrets, credentials, private hostnames, internal-only logs, customer data, or generated local artifacts.
Add or update tests for behavior changes.
Files:
src/aiq_agent/agents/deep_researcher/factory.pytests/aiq_agent/agents/deep_researcher/test_deepagents_runtime.pytests/aiq_agent/agents/deep_researcher/test_factory.pysrc/aiq_agent/agents/deep_researcher/custom_middleware.pyconfigs/config_frontier_models.ymltests/aiq_agent/agents/deep_researcher/test_custom_middleware.py
src/aiq_agent/agents/**/*
⚙️ CodeRabbit configuration file
src/aiq_agent/agents/**/*: Review agent changes for research workflow correctness, graph state transitions, prompt/tool contracts,
HITL behavior, and failure handling. Flag changes that weaken source attribution, report generation,
async cancellation, checkpointing, or data-source selection without focused tests and docs.
Files:
src/aiq_agent/agents/deep_researcher/factory.pysrc/aiq_agent/agents/deep_researcher/custom_middleware.py
configs/**/*.y{a,}ml
📄 CodeRabbit inference engine (AGENTS.md)
Use
_typevalues derived from the registered configuration class names in workflow YAML configuration.
Files:
configs/config_frontier_models.yml
**/*.{yaml,yml}
📄 CodeRabbit inference engine (CONTRIBUTING.md)
For deployment changes, run the relevant Helm or Compose validation and describe the environment used.
Files:
configs/config_frontier_models.yml
{deploy/**,configs/**}
⚙️ CodeRabbit configuration file
{deploy/**,configs/**}: Review deployment and config changes for secret separation, safe defaults, local-vs-production behavior, Helm and
Docker portability, and documentation parity. Flag committed credentials, environment-specific NVIDIA internals in
public defaults, and changes that make examples diverge from CI-tested paths.
Files:
configs/config_frontier_models.yml
🪛 ast-grep (0.45.0)
src/aiq_agent/agents/deep_researcher/custom_middleware.py
[info] 107-107: use jsonify instead of json.dumps for JSON output
Context: json.dumps(schema.model_json_schema(), separators=(",", ":"), ensure_ascii=False)
Note: [CWE-116] Improper Encoding or Escaping of Output.
(use-jsonify)
tests/aiq_agent/agents/deep_researcher/test_custom_middleware.py
[info] 84-84: use jsonify instead of json.dumps for JSON output
Context: json.dumps(payload)
Note: [CWE-116] Improper Encoding or Escaping of Output.
(use-jsonify)
[info] 98-98: use jsonify instead of json.dumps for JSON output
Context: json.dumps(payload)
Note: [CWE-116] Improper Encoding or Escaping of Output.
(use-jsonify)
[info] 118-118: use jsonify instead of json.dumps for JSON output
Context: json.dumps(payload)
Note: [CWE-116] Improper Encoding or Escaping of Output.
(use-jsonify)
[info] 178-178: use jsonify instead of json.dumps for JSON output
Context: json.dumps(self._routing())
Note: [CWE-116] Improper Encoding or Escaping of Output.
(use-jsonify)
🔇 Additional comments (11)
configs/config_frontier_models.yml (4)
1-5: LGTM!
75-100: LGTM!
151-151: LGTM!
172-176: LGTM!tests/aiq_agent/agents/deep_researcher/test_deepagents_runtime.py (1)
48-69: LGTM!src/aiq_agent/agents/deep_researcher/custom_middleware.py (2)
35-36: LGTM!Also applies to: 103-133, 143-159
135-141: 🎯 Functional CorrectnessVerify that
ModelRequest.overrideclears disabled fields.The tests verify arguments passed to
override, butMagicMockdoes not verify framework behavior. Confirm thatresponse_format=Noneandtool_choice=Noneclear inherited values in the installed dependency set. If either value is retained, the corrective request can still use the original structured-output strategy.Add a request-level integration test that records the effective tools, tool choice, and response format. As per coding guidelines, “Add or update tests for behavior changes.”
Source: Coding guidelines
src/aiq_agent/agents/deep_researcher/factory.py (2)
57-57: LGTM!Also applies to: 390-390
462-462: 🗄️ Data Integrity & IntegrationVerify that fallback promotion completes before persistence.
StructuredResponseTextFallbackMiddlewareis placed beforeSourceRoutingPersistenceMiddlewareandPlanPersistenceMiddleware. Confirm that the middleware stack promotes a corrected response before either persistence middleware reads or stores it. If a persistence middleware observes the raw invalid response first, it can persist an incomplete contract or fail before the fallback runs.Add an integration test that sends invalid text followed by valid JSON and verifies that persistence receives only the promoted structured response. As per path instructions, “Review agent changes for research workflow correctness, graph state transitions, prompt/tool contracts, HITL behavior, and failure handling.” As per coding guidelines, “Add or update tests for behavior changes.”
Also applies to: 493-493
Sources: Coding guidelines, Path instructions
tests/aiq_agent/agents/deep_researcher/test_custom_middleware.py (1)
29-29: LGTM!Also applies to: 48-53, 69-191
tests/aiq_agent/agents/deep_researcher/test_factory.py (1)
36-36: LGTM!Also applies to: 267-277, 527-527
Signed-off-by: Ajay Thorve <athorve@nvidia.com>
37c088d to
14cc75f
Compare
Signed-off-by: Ajay Thorve <athorve@nvidia.com>
cdgamarose-nv
left a comment
There was a problem hiding this comment.
Minor clarification, otherwise lgtm
## Summary - keep repository-wide Markdown link validation, but skip `build.nvidia.com` because NVIDIA Build returns HTTP 202 for valid pages and the checker treats that response as dead - update the isolated MCP release lock from `aiohttp` 3.14.1 to 3.14.3 and from `cryptography` 48.0.1 to 50.0.0, resolving the newly published advisories blocking every PR - preserve fail-closed runtime dependency validation with exact compatibility exceptions for `langchain-litellm`, `nvidia-nat-core`, and `oci` - update the MCP security documentation and compatibility tests to match the audited release profile ## Root cause PR #413 exposed two release-branch-wide CI failures unrelated to its GPT compatibility diff: 1. NVIDIA Build began returning HTTP 202 for valid public model and documentation pages. `markdown-link-check` classified every such page as dead. 2. New `aiohttp` and `cryptography` advisories were published after the current MCP release lock was created. The required production audit correctly rejected the vulnerable versions. ## Validation - full `pre-commit run --all-files` - MCP suite: 238 passed, 18 skipped - CI script test harness: 11 passed, 0 failed - production-only MCP sync and runtime import canary - production vulnerability gate: 308 packages audited, 0 vulnerabilities - CycloneDX SBOM and license inventory generation - MCP wheel build and license-file assertion The local Docker daemon was not running, so the Compose health/protocol smoke was not reproduced locally; GitHub Actions will exercise that boundary. ## Summary by CodeRabbit * **Documentation** * Updated MCP release and security guidance for `cryptography` 50.0.0. * Clarified Linux x86_64 with CPython 3.13 support, container usage, and development-only platforms. * Documented unsupported macOS and 32-bit Windows configurations. * **Chores** * Updated dependency resolution and validation rules for the new security baseline. * Excluded NVIDIA Build URLs from automated Markdown link checking. * **Tests** * Expanded coverage for dependency compatibility and platform policy consistency. Authors: - Ajay Thorve (https://github.com/AjayThorve) Approvers: - Tanner Leach (https://github.com/tanleach) URL: #415
|
/merge |
#### Overview Update AIQ 2.2 for the August model-deprecation wave while preserving the existing intent and shallow-research behavior until Nano 3.5 is publicly available: - retain Nemotron 3 Super 120B A12B, with its existing aliases and generation profiles, for intent classification and shallow research; - use Nemotron 3 Ultra 550B A55B for clarification and every default deep-research role; - preserve the GPT Sol/Luna deep-role topology introduced by #413 in `config_frontier_models.yml`, while retaining Super for its intent/shallow fast path; - replace the summary, embedding, and VLM defaults with Gemma 4 31B IT, Nemotron 3 Embed 1B, and Nemotron 3 Nano Omni respectively; and - keep public configs on canonical Build model identifiers and NAT's standard `https://integrate.api.nvidia.com/v1` endpoint. The Super exception is intentionally narrow and temporary. Nano 3.5 is excluded because its GA date is August 11. The intent/shallow switch, benchmarked shallow profile, and tool-first runtime guard are isolated in stacked draft #419 so this migration can merge without depending on a not-yet-public endpoint. The migration covers shipping configs, benchmark profiles, knowledge-layer defaults, agent-skill assets, README/docs, launchable examples, and executable notebook config cells. Repository-wide regression tests enforce the Super intent/shallow and Ultra deep-role boundary while rejecting every other replaced model identifier and private inference endpoint reference. This PR also makes persisted embedding stores fail closed when their model metadata is absent, incompatible, or owned by a different logical collection. Chroma and OpenSearch users receive explicit re-ingestion errors instead of silently querying vectors generated by a different embedding model; Azure AI Search already isolates and validates model/dimension compatibility. The branch is rebased on #412. Its updated Brev getting-started notebook is preserved, with only the targeted model references and deep-role configuration changed here. #### DCO sign-off for the squash commit Signed-off-by: Ajay Thorve <athorve@nvidia.com> #### Validation - [x] `uv run pytest` — 2052 passed, 13 skipped - [x] `uv run pre-commit run --all-files` — all hooks passed, including Ruff, YAML, secrets, agent-skill validation, notebook output clearing, and Markdown link checking - [x] Focused knowledge-layer and default-profile tests — 64 passed - [x] Shipping and FreshQA intent/shallow profiles match `release/2.2` exactly - [x] All three changed notebooks parse as valid JSON after output clearing - [x] `git diff --check` - [x] All commits are DCO-signed and have verified GPG signatures - [x] No Nano 3.5 identifier, private inference endpoint, secret, or credential is included #### Where should reviewers start? Start with `tests/aiq_agent/test_default_model_profiles.py` for the enforced model invariants, the shipping configs for the role mapping, and `sources/knowledge_layer/src/{llamaindex,opensearch}/adapter.py` for the embedding compatibility and ownership guards. #### Related Issues - Builds on the frontier-model compatibility work merged in #413. - Preserves the Brev notebook update merged in #412. - Relates to the August model endpoint deprecation migration. ## Summary by CodeRabbit * **New Features** * Added role-specific Nemotron Ultra and Ultra Writer configurations for clarification, deep research, orchestration, and writing. * Retained the existing Nemotron Super profiles for intent classification and shallow research. * Updated default models for summaries, embeddings, and vision processing. * Added validation to detect incompatible, legacy, or incorrectly owned embedding indexes and collections before ingestion or search. * **Documentation** * Refreshed setup guides, examples, notebooks, hardware guidance, and troubleshooting for the updated model lineup. * Added collection-safe migration guidance for embedding indexes and collections. * **Tests** * Expanded coverage for model assignments, embedding compatibility, ownership checks, and fail-before-request behavior. Authors: - Ajay Thorve (https://github.com/AjayThorve) Approvers: - Soumili Nandi (https://github.com/soumilinandi) URL: #414
## Summary - keep repository-wide Markdown link validation, but skip `build.nvidia.com` because NVIDIA Build returns HTTP 202 for valid pages and the checker treats that response as dead - update the isolated MCP release lock from `aiohttp` 3.14.1 to 3.14.3 and from `cryptography` 48.0.1 to 50.0.0, resolving the newly published advisories blocking every PR - preserve fail-closed runtime dependency validation with exact compatibility exceptions for `langchain-litellm`, `nvidia-nat-core`, and `oci` - update the MCP security documentation and compatibility tests to match the audited release profile ## Root cause PR NVIDIA-AI-Blueprints#413 exposed two release-branch-wide CI failures unrelated to its GPT compatibility diff: 1. NVIDIA Build began returning HTTP 202 for valid public model and documentation pages. `markdown-link-check` classified every such page as dead. 2. New `aiohttp` and `cryptography` advisories were published after the current MCP release lock was created. The required production audit correctly rejected the vulnerable versions. ## Validation - full `pre-commit run --all-files` - MCP suite: 238 passed, 18 skipped - CI script test harness: 11 passed, 0 failed - production-only MCP sync and runtime import canary - production vulnerability gate: 308 packages audited, 0 vulnerabilities - CycloneDX SBOM and license inventory generation - MCP wheel build and license-file assertion The local Docker daemon was not running, so the Compose health/protocol smoke was not reproduced locally; GitHub Actions will exercise that boundary. ## Summary by CodeRabbit * **Documentation** * Updated MCP release and security guidance for `cryptography` 50.0.0. * Clarified Linux x86_64 with CPython 3.13 support, container usage, and development-only platforms. * Documented unsupported macOS and 32-bit Windows configurations. * **Chores** * Updated dependency resolution and validation rules for the new security baseline. * Excluded NVIDIA Build URLs from automated Markdown link checking. * **Tests** * Expanded coverage for dependency compatibility and platform policy consistency. Authors: - Ajay Thorve (https://github.com/AjayThorve) Approvers: - Tanner Leach (https://github.com/tanleach) URL: NVIDIA-AI-Blueprints#415
#### Overview Some OpenAI-compatible frontier providers return the requested Pydantic contract as schema-valid JSON in ordinary assistant content instead of emitting the structured-output tool call. In deep research, that prevents `SourceRoutingPlan`, `ResearchPlan`, or `ResearchNotes` from reaching the persistence middleware and can leave the workflow retrying a completed stage. This change: - promotes exact, schema-valid JSON assistant content to the requested structured response; - makes at most one tools-disabled corrective call for empty or invalid plain-text responses, so the fallback cannot spiral; - leaves native structured responses and ordinary tool calls unchanged; - applies the compatibility middleware only at the source-router, planner, and researcher structured-response boundaries; and - updates the existing frontier profile to use the direct OpenAI provider with `OPENAI_API_KEY`: GPT Sol for orchestration, planning, and writing, and GPT Luna for source routing and research. The default Ultra profile is unchanged. #### DCO sign-off for the squash commit Signed-off-by: Ajay Thorve <athorve@nvidia.com> #### Validation - [x] `uv run ruff check .` - [x] `uv run pytest -q` — 2022 passed, 13 skipped - [x] Focused post-format run — 183 passed - [x] `uv run nat validate --config_file configs/config_frontier_models.yml` - [x] `uv run nat validate --config_file configs/config_web_default_llamaindex.yml` - [x] GPT Sol/Luna semantic smoke advanced through routing, planning, research, and writing with a non-sentinel cited report. - [x] Deterministic 20-task GPT DRB-II pilot completed with 20/20 generation and 20/20 official judge coverage. - [x] Patched-runtime Ultra regression smoke completed a DRB-II task with a 24.6k-character cited report, 1/1 clean collection, and no fallback correction. Harbor used one internal retry before the successful attempt. - [x] I added or updated tests for behavior changes. - [x] Documentation changes are not required; the user-facing frontier example config is updated directly. - [x] I confirmed this PR does not include secrets, credentials, internal endpoints, or internal-only data. - [x] I certify this contribution under the Developer Certificate of Origin (DCO) and signed my commit with `git commit -s`. - [x] I replaced the DCO sign-off placeholder with my GitHub commit identity and kept the required angle brackets around the email address. The remaining all-files Markdown-link and dependency-audit failures are release-branch-wide CI issues unrelated to this diff and are addressed separately by NVIDIA-AI-Blueprints#415. #### Where should reviewers start? Start with `StructuredResponseTextFallbackMiddleware` in `custom_middleware.py`, then its three placements in `factory.py`, and finally the direct-OpenAI Sol/Luna role split in `config_frontier_models.yml`. #### Related Issues - Relates to the model endpoint deprecation migration. ## Summary by CodeRabbit * **New Features** * Improved deep-research reliability by automatically correcting responses that do not match the expected structured format. * Preserved valid structured responses while retrying invalid responses without tool calls. * **Configuration** * Updated frontier-model workflows to use GPT Sol and GPT Luna for orchestration, planning, writing, routing, and research. * Updated model inference settings and token limits. * **Tests** * Added coverage for structured-response recovery, retry behavior, middleware integration, and frontier-model configuration. Authors: - Ajay Thorve (https://github.com/AjayThorve) Approvers: - Chantal D Gama Rose (https://github.com/cdgamarose-nv) URL: NVIDIA-AI-Blueprints#413
) #### Overview Update AIQ 2.2 for the August model-deprecation wave while preserving the existing intent and shallow-research behavior until Nano 3.5 is publicly available: - retain Nemotron 3 Super 120B A12B, with its existing aliases and generation profiles, for intent classification and shallow research; - use Nemotron 3 Ultra 550B A55B for clarification and every default deep-research role; - preserve the GPT Sol/Luna deep-role topology introduced by NVIDIA-AI-Blueprints#413 in `config_frontier_models.yml`, while retaining Super for its intent/shallow fast path; - replace the summary, embedding, and VLM defaults with Gemma 4 31B IT, Nemotron 3 Embed 1B, and Nemotron 3 Nano Omni respectively; and - keep public configs on canonical Build model identifiers and NAT's standard `https://integrate.api.nvidia.com/v1` endpoint. The Super exception is intentionally narrow and temporary. Nano 3.5 is excluded because its GA date is August 11. The intent/shallow switch, benchmarked shallow profile, and tool-first runtime guard are isolated in stacked draft NVIDIA-AI-Blueprints#419 so this migration can merge without depending on a not-yet-public endpoint. The migration covers shipping configs, benchmark profiles, knowledge-layer defaults, agent-skill assets, README/docs, launchable examples, and executable notebook config cells. Repository-wide regression tests enforce the Super intent/shallow and Ultra deep-role boundary while rejecting every other replaced model identifier and private inference endpoint reference. This PR also makes persisted embedding stores fail closed when their model metadata is absent, incompatible, or owned by a different logical collection. Chroma and OpenSearch users receive explicit re-ingestion errors instead of silently querying vectors generated by a different embedding model; Azure AI Search already isolates and validates model/dimension compatibility. The branch is rebased on NVIDIA-AI-Blueprints#412. Its updated Brev getting-started notebook is preserved, with only the targeted model references and deep-role configuration changed here. #### DCO sign-off for the squash commit Signed-off-by: Ajay Thorve <athorve@nvidia.com> #### Validation - [x] `uv run pytest` — 2052 passed, 13 skipped - [x] `uv run pre-commit run --all-files` — all hooks passed, including Ruff, YAML, secrets, agent-skill validation, notebook output clearing, and Markdown link checking - [x] Focused knowledge-layer and default-profile tests — 64 passed - [x] Shipping and FreshQA intent/shallow profiles match `release/2.2` exactly - [x] All three changed notebooks parse as valid JSON after output clearing - [x] `git diff --check` - [x] All commits are DCO-signed and have verified GPG signatures - [x] No Nano 3.5 identifier, private inference endpoint, secret, or credential is included #### Where should reviewers start? Start with `tests/aiq_agent/test_default_model_profiles.py` for the enforced model invariants, the shipping configs for the role mapping, and `sources/knowledge_layer/src/{llamaindex,opensearch}/adapter.py` for the embedding compatibility and ownership guards. #### Related Issues - Builds on the frontier-model compatibility work merged in NVIDIA-AI-Blueprints#413. - Preserves the Brev notebook update merged in NVIDIA-AI-Blueprints#412. - Relates to the August model endpoint deprecation migration. ## Summary by CodeRabbit * **New Features** * Added role-specific Nemotron Ultra and Ultra Writer configurations for clarification, deep research, orchestration, and writing. * Retained the existing Nemotron Super profiles for intent classification and shallow research. * Updated default models for summaries, embeddings, and vision processing. * Added validation to detect incompatible, legacy, or incorrectly owned embedding indexes and collections before ingestion or search. * **Documentation** * Refreshed setup guides, examples, notebooks, hardware guidance, and troubleshooting for the updated model lineup. * Added collection-safe migration guidance for embedding indexes and collections. * **Tests** * Expanded coverage for model assignments, embedding compatibility, ownership checks, and fail-before-request behavior. Authors: - Ajay Thorve (https://github.com/AjayThorve) Approvers: - Soumili Nandi (https://github.com/soumilinandi) URL: NVIDIA-AI-Blueprints#414
Overview
Some OpenAI-compatible frontier providers return the requested Pydantic contract as schema-valid JSON in ordinary assistant content instead of emitting the structured-output tool call. In deep research, that prevents
SourceRoutingPlan,ResearchPlan, orResearchNotesfrom reaching the persistence middleware and can leave the workflow retrying a completed stage.This change:
OPENAI_API_KEY: GPT Sol for orchestration, planning, and writing, and GPT Luna for source routing and research.The default Ultra profile is unchanged.
DCO sign-off for the squash commit
Signed-off-by: Ajay Thorve athorve@nvidia.com
Validation
uv run ruff check .uv run pytest -q— 2022 passed, 13 skippeduv run nat validate --config_file configs/config_frontier_models.ymluv run nat validate --config_file configs/config_web_default_llamaindex.ymlgit commit -s.The remaining all-files Markdown-link and dependency-audit failures are release-branch-wide CI issues unrelated to this diff and are addressed separately by #415.
Where should reviewers start?
Start with
StructuredResponseTextFallbackMiddlewareincustom_middleware.py, then its three placements infactory.py, and finally the direct-OpenAI Sol/Luna role split inconfig_frontier_models.yml.Related Issues
Summary by CodeRabbit
New Features
Configuration
Tests