feat(cli): implement dynamic model discovery for NVIDIA#8820
Draft
Varuu-0 wants to merge 3 commits intoKilo-Org:mainfrom
Draft
feat(cli): implement dynamic model discovery for NVIDIA#8820Varuu-0 wants to merge 3 commits intoKilo-Org:mainfrom
Varuu-0 wants to merge 3 commits intoKilo-Org:mainfrom
Conversation
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
| return { | ||
| autoload: true, | ||
| options: input.options, | ||
| async discoverModels(): Promise<Record<string, Model>> { |
Contributor
There was a problem hiding this comment.
CRITICAL: discoverModels is never invoked for NVIDIA
state() only executes discoveryLoaders for gitlab in packages/opencode/src/provider/provider.ts:1305, so this callback is registered but never run. As written, the provider will still expose only the static snapshot and none of the dynamically discovered NVIDIA models from this PR will ever be added.
Contributor
Code Review SummaryStatus: No Issues Found | Recommendation: Merge Files Reviewed (2 files)
Reviewed by gpt-5.4-20260305 · 796,134 tokens |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR: feat(cli): implement dynamic model discovery for NVIDIA
Context
Previously, the NVIDIA provider relied on a static snapshot from
model.dev, which was frequently incomplete and required manual updates. This PR introduces dynamic model discovery by querying NVIDIA's integration API directly, ensuring all available NVIDIA NIMs are immediately accessible. Additionally, all models onbuild.nvidia.comare now explicitly marked as free for development, with a note on the 40req/min rate limit.Implementation
nvidiaprovider inpackages/opencode/src/provider/provider.tsthat implementsdiscoverModels.https://integrate.api.nvidia.com/v1/modelsusing nativefetchwith a 10s timeout and optimizedUser-Agent.isFree: trueand zero cost for all NVIDIA models to reflect their development status on the NVIDIA platform.Implementation Comparison
Before
N/A: The NVIDIA provider was not explicitly defined in the dynamic discovery mapping and relied entirely on static snapshots.
After
How to Test
kilo modelsand verify that NVIDIA models are dynamically listed.isFree: trueand zero cost are correctly assigned.nvidia/llama-3.1-405b-instruct) and verify it utilizes the@ai-sdk/openai-compatibleadapter.Get in Touch
@varuu