# Document Preprocessing

Knowledge base document preprocessing requires upgrading Cherry Studio to v1.4.8 or later.

### Configure OCR service provider

<figure><img src="/files/0f299a884b64b83a812266abb55e085b747bd668" alt=""><figcaption></figcaption></figure>

After clicking Get API KEY, the application address will open in the browser. Click Apply Now, fill out the form, then obtain the API KEY and enter it into API KEY.

<figure><img src="/files/93c4ed196ca4477e36c1ce54f7eb6b570cf29e60" alt=""><figcaption></figcaption></figure>

### Configure knowledge base document preprocessing

<figure><img src="/files/871b4521bf265de498a24d5120fc0378de2ce80d" alt=""><figcaption></figcaption></figure>

By making the above configuration in the created knowledge base, the knowledge base document preprocessing configuration can be completed.

### Upload documents

<figure><img src="/files/763de4f4a19aa6f95f1f63d0ca82f65e39a3da57" alt=""><figcaption></figcaption></figure>

> You can use the search in the top-right corner to check the knowledge base results

### Use in conversation

<figure><img src="/files/431ee3ba53402f130d9b69a5f7620b318e240d4d" alt=""><figcaption></figcaption></figure>

> Knowledge base usage tips: use**more capable**When using a model, you can change the knowledge base search mode to intent recognition. Intent recognition can describe your question more accurately and broadly.

### Enable knowledge base intent recognition

<figure><img src="/files/8e67c8439f61af190c4bc450d7c0c615908bd7e5" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: 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/knowledge-base/document-preprocessing.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.
