NemotronModel

class NemotronModel(OpenAICompatibleModel):

Nemotron model API backend with OpenAI compatibility.

Parameters:

  • model_type (Union[ModelType, str]): Model for which a backend is created.
  • api_key (Optional[str], optional): The API key for authenticating with the Nvidia service. (default: :obj:None)
  • url (Optional[str], optional): The url to the Nvidia service. (default: :obj:https://integrate.api.nvidia.com/v1)
  • timeout (Optional[float], optional): The timeout value in seconds for API calls. If not provided, will fall back to the MODEL_TIMEOUT environment variable or default to 180 seconds. (default: :obj:None)
  • Notes: Nemotron model doesn’t support additional model config like OpenAI.

init

def __init__(
    self,
    model_type: Union[ModelType, str],
    api_key: Optional[str] = None,
    url: Optional[str] = None,
    timeout: Optional[float] = None
):

token_counter

def token_counter(self):

check_model_config

def check_model_config(self):