> 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/advanced-basic/mcp/dify.md).

# Configure Dify Knowledge Base

[Dify](https://dify.ai/) is an enterprise-level AI application platform that also has a built-in knowledge base feature. If you've already built a knowledge base on Dify (for company internal docs, or personal RAG apps), this page teaches you**Let the AI in Cherry Studio directly query the Dify knowledge base**.

In short:**You don't need to move your materials from Dify to Cherry Studio; conversations in Cherry Studio can query the content on Dify**.

Requirements: Cherry Studio v1.2.9 or later; at least one knowledge base has been created in Dify and you have obtained that knowledge base's API Key.

### Add the Dify knowledge base MCP server

<figure><img src="/files/1ce65be277d7f55f5490b068fcd9b9cc368a8843" alt=""><figcaption></figcaption></figure>

1. Open `Search MCP`.
2. Add `dify-knowledge` server.

### Configure the Dify knowledge base

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

> Need to configure parameters and environment variables

1. The Dify knowledge base key can be obtained in the following ways

<figure><img src="/files/3703ec6237be13bf4ab2d1857019c6364abd600e" alt=""><figcaption></figcaption></figure>

### Use the Dify knowledge base mcp

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

***

### 💡 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, and the optional `goal` query parameter:

```
GET https://docs.cherry-ai.com/docs/en-us/advanced-basic/mcp/dify.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
