> For the complete documentation index, see [llms.txt](https://docs.cherryai.com.cn/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cherryai.com.cn/docs/zhong-wen-fan-ti/pre-basic/settings/doc-process.md).

# 文件處理

簡單嚟講：**呢個係 Cherry Studio 將「PDF／複雜版式文件」讀成規整文字嘅中央配置。**

帶表格、多欄、掃描頁嘅 PDF（學術論文、合約、研報等）直接丟畀模型往往會讀到亂晒龍。文檔處理會先用專門嘅解析引擎將佢哋轉成結構清晰嘅文字，再交畀對話或 [知識庫](/docs/zhong-wen-fan-ti/knowledge-base/knowledge-base.md) 使用。

{% hint style="info" %}
**文檔處理 vs OCR**：兩者係分開嘅兩頁設定。

* **文件處理**（本頁）：管 **PDF／複雜版式文件** 嘅結構化解析。
* [**OCR**](/docs/zhong-wen-fan-ti/pre-basic/settings/ocr.md)：管 **圖片／掃描件** 入面嘅文字識別。

普通純文字 PDF、`.md`/`.txt`/`.docx` 入面嘅文字段落兩者都唔需要，直接讀就得。
{% endhint %}

### 設定入口

打開【設定】→【文檔處理】，喺右上角嘅下拉揀解析引擎，**揀中嘅引擎就會作為預設**。

<figure><img src="https://2742912793-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F0Ut5BptC3t8CtSU1UWpM%2Fuploads%2Fgit-blob-ccfff6a9d37c58e6342c96d246156fddce6c0ab1%2Fdoc-process-overview.png?alt=media" alt=""><figcaption><p>文檔處理設定：① 右上角下拉揀解析引擎（預設 MinerU）；下方填入所揀引擎嘅 API 密鑰同 API 地址</p></figcaption></figure>

### 內置解析引擎

文檔處理內置 5 個引擎，預設 **MinerU**：

| 引擎              | 說明                              | 接入方式                                                                           |
| --------------- | ------------------------------- | ------------------------------------------------------------------------------ |
| **MinerU**（預設）  | OpenDataLab 開源嘅高質量 PDF 擷取工具     | API 密鑰（[mineru.net/apiManage](https://mineru.net/apiManage)）                   |
| **PaddleOCR**   | 百度飛槳 OCR 識別系統                   | 填 API 密鑰（[飛槳星河社區](https://aistudio.baidu.com/paddleocr/)）；如自部署，則將 API 地址指向你嘅服務 |
| **Doc2x**       | 高級文件還原引擎                        | API 密鑰（[open.noedgeai.com](https://open.noedgeai.com/apiKeys)）                 |
| **Mistral**     | 文件解析同理解服務                       | API 密鑰（[mistral.ai](https://mistral.ai/api-keys)）                              |
| **Open MinerU** | 可自部署嘅 MinerU 服務，適合希望自行控制處理鏈路嘅團隊 | 自部署後填 API 地址（按需要填 API 密鑰）                                                      |

### 配置 MinerU（預設方案）

{% stepper %}
{% step %}

### 填入 API 密鑰

喺【API 密鑰】欄位填入 MinerU 申請到嘅 key（撳右側「獲取密鑰」跳轉申請頁面，多個密鑰可用逗號分隔）。
{% endstep %}

{% step %}

### 確認 API 地址

【API 地址】保持預設就得。
{% endstep %}

{% step %}

### 喺知識庫／對話中直接使用

匯入複雜 PDF 時會自動跟呢度嘅解析設定，切換去知識庫或者對話時無需額外配置。
{% endstep %}
{% endstepper %}

{% hint style="info" %}
**改用其他引擎**：喺下拉揀中佢，填入該引擎嘅【API 密鑰】／【API 地址】就得，揀中即成為預設。其中 **PaddleOCR** 同 **Open MinerU** 支援自部署——部署後將【API 地址】填成你自己嘅服務地址。
{% endhint %}

### 同知識庫嘅關係

* 文檔處理只負責「複雜文件 → 規整文字」呢一步；
* 轉換後嘅文字繼續走 [嵌入模型](/docs/zhong-wen-fan-ti/knowledge-base/emb-models-info.md) 向量化、入庫；
* 詳細嘅「喺知識庫中啟用」流程見 [知識庫文件預處理](/docs/zhong-wen-fan-ti/knowledge-base/document-preprocessing.md)。

### 提示同技巧

* MinerU 對帶表格／多欄排版嘅 PDF 效果明顯更好，遇到學術論文等首選；
* 需要識別嘅係 **圖片入面嘅文字**（截圖、掃描件）而唔係 PDF 結構，請改用 [OCR](/docs/zhong-wen-fan-ti/pre-basic/settings/ocr.md)。

***

### 攞幫助同提交意見

如果您喺配置或使用過程中遇到任何疑問、Bug 或有功能改善建議，請參考 [反饋與建議](/docs/zhong-wen-fan-ti/question-contact/suggestions.md) 入面提供嘅官方渠道。


---

# 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.cherryai.com.cn/docs/zhong-wen-fan-ti/pre-basic/settings/doc-process.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.
