> For the complete documentation index, see [llms.txt](https://docs.docbits.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.docbits.com/chinese/guan-li-yu-she-zhi/settings/document-processing/module/skip-hybrid-pdf-xml-extraction.md).

# 跳过混合 PDF XML 提取

### 概述

**Skip Hybrid PDF XML Extraction（跳过混合 PDF XML 提取）设置用于控制 DocBits 如何处理混合 PDF**——即嵌入了结构化电子发票（ZUGFeRD / Factur-X）的 PDF 发票。它决定在自动化处理中，是将 **PDF 中的结构化 XML**作为主文档，还是通过 OCR 将 **PDF 本身**作为主文档处理。

此设置与**美国客户**尤其相关。与欧盟/德国不同，美国没有普遍适用的 B2B 电子发票强制规定，因此美国组织通常希望将 PDF 作为主文档处理，因为它是便于阅读的发票格式——即使交易对方发送的是带有嵌入式 XML 的 ZUGFeRD/Factur-X 文件。

### 它有什么作用？

ZUGFeRD/Factur-X 文件是一个包含机器可读 XML 发票的单一 PDF。默认情况下，DocBits 会检测嵌入式 XML，并将其作为提取的主要来源（结构化电子文档处理路径）。

* **禁用（默认）** — DocBits 会检测嵌入式电子发票 XML，并通过**结构化电子文档处理路径**处理文档。XML 是主要发票数据。在欧盟/德国，这种处理方式符合法律要求，因为结构化电子发票才是相关发票，PDF 仅用于展示和阅读。
* **启用** — DocBits 会**忽略嵌入式 XML**，并将文档路由到 **PDF 处理器（OCR）**。PDF 将成为主要处理文档。对于希望优先处理 PDF 的**美国组织**，通常会选择此设置。

{% hint style="info" %}
此设置仅影响**混合 PDF**（ZUGFeRD / Factur-X，即带有嵌入式 XML 的 `.pdf` 文件）。作为 `.xml` 上传的纯 XRechnung / EDI 文件始终通过结构化电子文档处理路径处理——没有可作为主文档的 PDF。
{% endhint %}

### 审计与合规 — 始终保留原始文件

启用此设置**不会**丢弃电子发票。原始文件始终会保留：

* 原始 ZUGFeRD/Factur-X **PDF（包括其中嵌入的 XML）仍会存储**，并可供下载。文档存储副本中的内容不会被删除。
* 此设置只会改变**由哪种内容驱动提取**（PDF/OCR 还是嵌入式 XML），不会改变归档的内容。

因此，美国组织可以将 PDF 作为主文档处理，同时保留结构化电子发票以供审计。

{% hint style="warning" %}
欧盟/德国组织应将此设置保持为**禁用**。根据 2025 年电子发票规则，结构化电子发票（ZUGFeRD/Factur-X、XRechnung）才是具有法律效力的发票；普通 PDF 仅供阅读。在存在有效电子发票的情况下，将 PDF 而不是结构化数据作为主文档处理并不合适。
{% endhint %}

### 使用方法

1. **打开设置**：
   * 前往 **Settings（设置）**。
   * 选择 **Document Processing（文档处理）**。
   * 选择 **Module（模块）**。
   * 打开 \*\*Document Type（文档类型）\*\*部分。
   * 找到 \*\*Skip Hybrid PDF XML Extraction（跳过混合 PDF XML 提取）\*\*并切换滑块。
2. **选择模式**：
   * **美国 / 优先处理 PDF 的组织** → 启用此开关，以便通过 OCR 将 ZUGFeRD/Factur-X PDF 作为主文档处理。
   * **欧盟/德国组织** → 保持此开关禁用，让结构化电子发票继续作为主文档。
3. **验证**：
   * 上传一个 ZUGFeRD/Factur-X PDF，并检查文档的处理结果——启用此开关时，文件会作为普通 PDF 进行处理（OCR）；禁用时，则会提取嵌入式电子发票数据。

### 何时使用此功能

* **美国客户 / 没有电子发票强制规定**：启用此设置，让熟悉的 PDF 成为主处理文档，同时保留归档的嵌入式电子发票。
* **混合/优先处理 PDF 的工作流**：如果下游流程、验证或审核依赖 PDF 版式而不是 XML，请启用此设置。
* **欧盟/德国合规**：保持此设置禁用，让结构化电子发票数据驱动处理，以满足相关要求。


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.docbits.com/chinese/guan-li-yu-she-zhi/settings/document-processing/module/skip-hybrid-pdf-xml-extraction.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
