Aisuite works only with text-to-text models.
Prerequisites
- Create an API key to authorize requests to Nebius AI Studio.
-
Save the API key into a
NEBIUS_API_KEY
environment variable: -
Install the
aisuite
andopenai
packages:
Create a chat completion
Paste the following code into your script:-
To work with a different model, change
model_id
. You can copy the model ID from the model card or look it up in the list. -
Modify
messages
to get the model’s responses to your questions. To work with a larger context, you can also add previous responses from the model. For example: