How to Configure Custom Models in Cline: Window Size, Temperature, and Pricing
Use Cline's "OpenAI Compatible" provider mode with Base URL https://api.deepseek.com to unlock custom window sizes, temperature controls, and pricing caps for DeepSeek models.
Cline is a VS Code AI-coding assistant that integrates with DeepSeek models through the deepseek-ai/awesome-deepseek-agent ecosystem. While the built-in DeepSeek provider offers a static model list, you must switch to the OpenAI Compatible provider to configure custom models in Cline with precise control over runtime parameters like context windows and inference temperature.
Why Use the OpenAI Compatible Provider
The built-in DeepSeek provider exposes only a predefined list of models without exposing runtime parameter adjustments. To modify window size, temperature, and pricing limits, you must use the OpenAI Compatible provider mode, which transmits these custom configurations directly to the DeepSeek API endpoint at https://api.deepseek.com.
Step-by-Step Configuration Guide
Select the OpenAI Compatible Provider
- Open Cline's settings panel in VS Code.
- Set API Provider to OpenAI Compatible.
- Enter
https://api.deepseek.comin the Base URL field. - Provide your DeepSeek API key.
- Input the desired Model ID (e.g.,
deepseek-v4-pro).
According to the repository's docs/cline.md file (lines 31–38), these steps establish the connection required for custom parameter submission.
Configure Model Parameters
After entering the Model ID, click Model Configuration to adjust the following parameters:
- Window size: The maximum number of tokens the model retains in context per request (typically 1,000–8,000).
- Temperature: Controls output randomness on a scale from 0 (deterministic) to 1 (creative).
- Pricing: Optional spending caps for per-request or daily limits to manage API costs.
These settings are saved locally and appended to each request payload sent to DeepSeek's API. The UI walkthrough for these controls appears in docs/cline.md at lines 51–58.
Save and Validate Settings
Confirm the configuration in the UI. Cline immediately applies your custom window size and temperature values while enforcing any pricing constraints defined in the model configuration panel.
Manual Configuration via VS Code Settings
For automation or version-controlled setups, directly edit Cline's configuration in your VS Code settings.json file. The following JSON structure mirrors the UI configuration options:
{
"apiProvider": "openai",
"baseUrl": "https://api.deepseek.com",
"apiKey": "YOUR_DEEPSEEK_API_KEY",
"modelId": "deepseek-v4-pro",
"modelConfig": {
"windowSize": 4096,
"temperature": 0.3,
"maxCostPerRequest": 0.05,
"maxCostPerDay": 2.0
}
}
Place this object under the cline namespace in your user settings. Adjust windowSize values between 1,000 and 8,000 tokens depending on your context requirements, and set temperature between 0 and 1 to control output variability.
Key Configuration Parameters Explained
Window Size defines the maximum tokens maintained in context per request. Higher values support longer code analysis sessions but consume more tokens per API call.
Temperature regulates output randomness. Set values closer to 0 for deterministic code generation, or increase toward 1 for exploratory or creative coding tasks.
Pricing parameters (maxCostPerRequest, maxCostPerDay) function as client-side spending guardrails. These optional limits prevent requests that would exceed your defined cost thresholds.
Summary
- Use OpenAI Compatible provider mode to access custom configuration options unavailable in the built-in DeepSeek provider.
- Set Base URL to
https://api.deepseek.comand provide your DeepSeek API key. - Adjust window size (1,000–8,000 tokens), temperature (0–1), and pricing caps through the Model Configuration panel or directly in
settings.json. - Configuration implementation details are documented in
docs/cline.mdat lines 31–38 and 51–58 of the deepseek-ai/awesome-deepseek-agent repository.
Frequently Asked Questions
Can I configure custom window size using the built-in DeepSeek provider?
No. The built-in DeepSeek provider only exposes a static list of models without parameter adjustment capabilities. You must use the OpenAI Compatible provider to modify window size, temperature, or pricing settings.
Where does Cline store custom model configurations?
Cline persists configurations locally in VS Code's settings.json file under the cline namespace. These settings remain available across sessions and are transmitted with each API request to DeepSeek.
What is the maximum window size I can set for DeepSeek models in Cline?
The configurable range typically spans 1,000 to 8,000 tokens, though specific effective limits depend on the particular DeepSeek model version you are accessing through the API endpoint.
How do pricing limits work in Cline's OpenAI Compatible mode?
Pricing limits operate as client-side cost controls. When you define maxCostPerRequest or maxCostPerDay in the model configuration, Cline tracks accumulated API spending and blocks requests that would exceed your specified thresholds.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →