Pre-requisites
Before you begin, make sure you have the following:- A free account on SambaCloud.
- VS Code installed.
- AI Toolkit extension installed (via the extensions panel in VS Code).
Setup
Getting started with SambaNova’s LLM in VS Code is quick and easy. Follow the steps below to connect your model and start building generative AI applications.- Open the AI toolkit panel In VS Code, open the AI Toolkit panel (usually located in the sidebar).
-
Add a custom model
-
Select the
+
icon at the top of the AI Toolkit panel -
Select “Add a custom model” from the dropdown
-
Select the
-
Enter the Model Endpoint
-
Paste the SambaNova inference endpoint URL:
The URL may vary if you’re using a dedicated SambaCloud node. -
Paste the SambaNova inference endpoint URL:
-
Enter the Model ID
- Copy the Model ID (from the SambaCloud models page) for the model you would like to use.
- Paste and select Enter.
-
Setup a display name
- Use the same Model ID or create a custom display name.
- Select Enter.
-
Provide your API key.
- Generate an API key on the SambaCloud portal if you don’e have one already.
- Enter the key in
Authorization: Bearer <your-api-key>
and select Enter.
-
Test the connection
- In the AI Toolkit panel, go to the Tools section and open the Playground
- After a few moments, you should see your SambaNova model name appear in the Model dropdown (top-right of the Playground)
- Select your model and:
- Edit the Context (e.g., “You are a helpful coding assistant”)
- Adjust inference parameters (optional)
- Try a test prompt