Registry / ai-ml / llama-index-llms-nvidia

llama-index-llms-nvidia

JSON →
library0.5.0pypypi✓ verified 85d ago

LlamaIndex integration for NVIDIA AI Foundation Models and NVIDIA API Catalog. Provides LLM class to interact with NVIDIA-hosted models like Llama, Nemotron, and more. Current version: 0.5.0. Requires Python >=3.10, <4.0.

pip install llama-index-llms-nvidia
INSTALL
IMPORT
SIG · LLAMA-INDEX-LLMS-N
L
llama-index-llms-nvidia
ai-mlpythonv0.5.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

NVIDIA
from llama_index.llms.nvidia import NVIDIA
from llama_index.llms.nvidia.base import NVIDIA
Exposed at top-level, not from base module
NVIDIA
from llama_index.llms.nvidia.base import NVIDIA
from llama_index.llms.nvidia import NVIDIA
In older versions (<0.3.0), the import path was different; check your version

Initialize the NVIDIA LLM with an API key and model name, then call complete.

import os os.environ['NVIDIA_API_KEY'] = os.environ.get('NVIDIA_API_KEY', 'your-api-key-here') from llama_index.llms.nvidia import NVIDIA llm = NVIDIA(model='mistralai/mistral-7b-instruct-v0.3') resp = llm.complete('What is the capital of France?') print(resp)
Debug
Known issues
gotchaAPI key is required even for some free tier models. Set NVIDIA_API_KEY environment variable or pass api_key parameter.
fix
export NVIDIA_API_KEY=... before running code.
affects: all
breakingIn version 0.4.0, the base import path changed from `llama_index.llms.nvidia` to `llama_index.llms.nvidia.base`. However, the recommended top-level import (`from llama_index.llms.nvidia import NVIDIA`) remains consistent.
fix
Use `from llama_index.llms.nvidia import NVIDIA` for current versions.
affects: 0.4.0+
gotchaModel names must match exactly the NVIDIA API catalog format (e.g., 'meta/llama-3.1-8b-instruct'). Check the NVIDIA playground for correct model IDs.
fix
Visit https://build.nvidia.com/ to find exact model names.
affects: all
Errors
Common errors & fixes
ImportError: cannot import name 'NVIDIA' from 'llama_index.llms.nvidia'
Wrong import path or package not installed correctly.
fix
Install the package: pip install llama-index-llms-nvidia, then use: from llama_index.llms.nvidia import NVIDIA
ValueError: Invalid model name provided
Model name does not match NVIDIA API catalog.
fix
Use exact model ID from NVIDIA API catalog, e.g., 'mistralai/mistral-7b-instruct-v0.3'.
AuthenticationError: API key not valid
NVIDIA_API_KEY environment variable not set or invalid.
fix
Set the environment variable or pass api_key='...' to the NVIDIA constructor.
Upgrade
Version history
0.5.0latest on PyPI · released Mar 12, 2026
Audit
Dependencies
llama-index-corerequiredCore LlamaIndex framework required
Agent activity
2 hits · last 30 days
node
2
Resources

No resource links recorded.

llama-index-llms-nvidia — pip install llama-index-llms-nvidia · libregistry