Adding AI to the Zed IDE using Generative APIs
Zed is an IDE (Integrated Development Environment) including AI coding assistance support. Scaleway's Generative APIs support Zed AI code completion and more.
Before you start
To complete the actions presented below, you must have:
- A Scaleway account logged into the console
- Owner status or IAM permissions allowing you to perform actions in the intended Organization
- A valid API key for API authentication
- Installed Zed on your local machine
Configure custom endpoints and models
-
Edit Zed settings located in
settings.json
, and add the following content to it:{ "language_models": { "openai": { "api_url": "https://api.scaleway.ai/v1", "available_models": [ { "name": "devstral-small-2505", "display_name": "Devstral Small - Scaleway", "max_tokens": 128000 } ], "version": "1" } }, "agent": { "default_profile": "write", "default_model": { "provider": "openai", "model": "devstral-small-2505" } } }
This configuration will add a
devstral-small-2505
Scaleway hosted model available with the Zedopenai
provider, and use it as default model. -
Open AI Assistant configuration by either using the command palette and typing
assistant: show configuration
or clicking on the bottom right Assistant Panel button and then Assistant menu in top right and finally Configure. -
Scroll down to the OpenAI configuration, and paste your Scaleway secret key as API Key credentials.
-
Your setup is complete. If you open a new chat and select the
Devstral Small - Scaleway
model, you can send text and see the model using local tools to perform actions such as file reading or editing. You can review changes before they are applied and also add custom remote tools using Custom MCP Servers. Additionally, you can use the Inline Assist feature when editing your code.