Skip to main content

Documentation Index

Fetch the complete documentation index at: https://wb-21fd5541-docs-2661.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

Cline is an AI-powered coding assistant. This tutorial demonstrates how to configure Cline to use models provided by Serverless Inference, so that you can use open-weight models hosted on W&B Inference for your coding tasks. The Cline agent is available as a command line tool or as an integration with many IDEs. The following sections describe configuration with the Cline CLI and with Cline as a Visual Studio Code extension. Configuration in other IDEs is similar.

Prerequisites

You need your W&B API key.

Set up Cline in the command line

Install the Cline CLI.
npm install -g cline
See Cline’s installation instructions for troubleshooting. These instructions were tested with Cline CLI version 2.5.1. Run cline version to verify what you have installed. Next, authenticate Cline against the Serverless Inference endpoint. The following command configures Cline to use the Serverless Inference OpenAI-compatible endpoint and the Kimi K2.5 model. Substitute [YOUR-API-KEY] with your W&B API key.
cline auth -k [YOUR-API-KEY] -p openai -b https://api.inference.wandb.ai/v1 -m moonshotai/Kimi-K2.5
For model availability and pricing, see the W&B Inference model catalog. Run a test to verify everything is working:
cline "What is 2 + 2?"
If Cline responds with an answer, your installation and authentication are complete. For more information about using the Cline CLI, see the Cline Quickstart.

Set up Cline in Visual Studio Code

If you prefer to use Cline inside an IDE, you can install it as a Visual Studio Code extension. Search for Cline in the VS Code Extensions Marketplace, or install it from the Visual Studio Code Marketplace. Click Install.
VS Code extension installation
Click the newly added Cline icon in your Activity Bar to open the Cline sidebar. If the Cline icon isn’t showing in the Activity Bar, click the dropdown to see more options. Cline icon in the VS Code Activity Bar Select Bring my own API key and click Continue. Select Bring Your Own Key Specify the following values, substituting [YOUR-API-KEY] with your W&B API key:
SettingValue
API ProviderOpenAI Compatible
Base URLhttps://api.inference.wandb.ai/v1
OpenAI Compatible API Key[API-KEY]
Model IDmoonshotai/Kimi-K2.5
Specify pricing by expanding Model Configuration. Click Continue. Try submitting a prompt like “Write a Python program to compute the first 10 Fibonacci Numbers”. Submit your coding task to the agent For more information about using Cline, see the Cline Documentation.