> For the complete documentation index, see [llms.txt](https://docs.cherry-ai.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cherry-ai.com/docs/en-us/pre-basic/providers/zi-ding-yi-fu-wu-shang.md).

# Custom Provider

Cherry Studio not only integrates mainstream AI model services, but also gives you powerful customization capabilities. Through **Custom AI Provider** feature, you can easily connect any AI model you need.

## Why do you need a custom AI provider?

* **Flexibility:** No longer limited by the preset provider list, freely choose the AI model that best suits your needs.
* **Diversity:** Try AI models from various platforms and discover their unique strengths.
* **Controllability:** Directly manage your API key and access address to ensure security and privacy.
* **Customization:** Connect to privately deployed models to meet the needs of specific business scenarios.

## How do I add a custom AI provider?

With just a few simple steps, you can add your custom AI provider in Cherry Studio:

<figure><img src="/files/b4e3d3e7cb3f59b9e75c7e2beebc2c8203578c4e" alt=""><figcaption></figcaption></figure>

1. **Open settings:** In the left navigation bar of the Cherry Studio interface, click "Settings" (gear icon).
2. **Go to model services:** On the settings page, select the "Model Services" tab.
3. **Add provider:** On the "Model Services" page, you will see a list of existing providers. Click the "+ Add" button below the list to open the "Add Provider" dialog.
4. **Fill in the information:** In the dialog, you need to fill in the following information:
   * **Provider name:** Give your custom provider an easily recognizable name (e.g., MyCustomOpenAI).
   * **Provider type:** Select your provider type from the drop-down list. Currently supported:
     * OpenAI
     * Gemini
     * Anthropic
     * Azure OpenAI
5. **Save configuration:** After filling it out, click the "Add" button to save your configuration.

## Configure custom AI provider

<figure><img src="/files/e0470bfd5451844000c0de82cac3fa732ce61994" alt=""><figcaption></figcaption></figure>

After adding it, you need to find the provider you just added in the list and configure it in detail:

1. **enabled state** There is an enable switch on the far right of the custom provider list; turning it on enables that custom service.
2. **API key:**
   * Enter the API key provided by your AI provider (API Key).
   * Click the "Check" button on the right to verify whether the key is valid.
3. **API address:**
   * Enter the API access address (Base URL) of the AI service.
   * Be sure to refer to the official documentation provided by your AI provider to get the correct API address.
4. **Model management:**

   * Click the "+ Add" button to manually add the model ID you want to use under this provider. For example `gpt-3.5-turbo`、`gemini-pro` etc.

   <figure><img src="/files/9921b080ea5c385e33f453b54c4d430f138daeab" alt=""><figcaption></figcaption></figure>

   * If you're not sure of the exact model name, please refer to the official documentation provided by your AI provider.
   * Click the "Manage" button to edit or delete models that have already been added.

## Get started

After completing the above configuration, you can select your custom AI provider and model in Cherry Studio's chat interface and start chatting with AI!

## Use vLLM as a custom AI provider

vLLM is a fast and easy-to-use LLM inference library similar to Ollama. The following are the steps to integrate vLLM into Cherry Studio:

1. **Install vLLM:** According to the official vLLM documentation (<https://docs.vllm.ai/en/latest/getting_started/quickstart.html>), install vLLM.

   ```sh
   pip install vllm # if you use pip
   uv pip install vllm # if you use uv
   ```
2. **Start the vLLM service:** Start the service using the OpenAI-compatible interface provided by vLLM. There are mainly two ways, as follows:

   * Use`vllm.entrypoints.openai.api_server`Start

   ```sh
   python -m vllm.entrypoints.openai.api_server --model gpt2
   ```

   * Use`uvicorn`Start

   ```sh
   vllm --model gpt2 --served-model-name gpt2
   ```

Make sure the service starts successfully and listens on the default port `8000` of course, you can also use the parameter`--port`to specify the port number of the vLLM service.

3. **Add the vLLM provider in Cherry Studio:**
   * Follow the steps described earlier to add a new custom AI provider in Cherry Studio.
   * **Provider name:** `vLLM`
   * **Provider type:** Select `OpenAI`.
4. **Configure the vLLM provider:**
   * **API key:** Since vLLM does not require an API key, you can leave this field blank or fill in anything.
   * **API address:** Enter the API address of the vLLM service. By default, the address is: `http://localhost:8000/`(If you use a different port, modify it accordingly).
   * **Model management:** Add the name of the model loaded in vLLM. In the example run above`python -m vllm.entrypoints.openai.api_server --model gpt2`the example, you should fill in`gpt2`
5. **Start chatting:** Now, you can select the vLLM provider and `gpt2` model in Cherry Studio and start chatting with the LLM powered by vLLM!

## Tips and tricks

* **Read the documentation carefully:** Before adding a custom provider, be sure to carefully read the official documentation of the AI provider you are using to understand key information such as API key, access address, and model name.
* **Check API key:** Use the "Check" button to quickly verify the validity of the API key and avoid being unable to use it due to an incorrect key.
* **Pay attention to the API address:** The API address may differ for different AI providers and models, so be sure to enter the correct address.
* **Add models as needed:** Please only add the models you will actually use to avoid adding too many useless models.

***

### 💡 Get help and submit feedback

If you encounter any questions, bugs, or have suggestions for feature improvements during configuration or use, please refer to [Feedback and Suggestions](/docs/en-us/question-contact/suggestions.md) the official channels provided there.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.cherry-ai.com/docs/en-us/pre-basic/providers/zi-ding-yi-fu-wu-shang.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
