Skip to content

Transforms complex documents like PDFs and Office docs into LLM-ready markdown/JSON for your Agentic workflows.

fix(ci): repair doclib links and credential file headers

myhlolid77b5f34fa84
diff --git a/docs/next/cli/mineru-server.md b/docs/next/cli/mineru-server.md
index 09899ee1..9c7ef4f0 100644
--- a/docs/next/cli/mineru-server.md
+++ b/docs/next/cli/mineru-server.md
@@ -43,7 +43,7 @@
CLI 自动读取当前配置中的本机 token,状态和停止操作同样需要认证。认证失败保留
`invalid_doclib_token`,不能误报为服务未运行;旧 endpoint 返回 `doclib_upgrade_required`。
首次升级到认证版本前先用旧 CLI 停止旧服务;更换 token 时先 stop,再修改配置,最后 start。
-token 不随普通重启变化,详见 [本机认证与二次开发](../sdk/doclib-client.md#本机认证与二次开发)。
+token 不随普通重启变化,详见 [本机认证与二次开发](../sdk/doclib-client.md#local-authentication)。
关闭时:
diff --git a/docs/next/config.md b/docs/next/config.md
index 39e35108..96530129 100644
--- a/docs/next/config.md
+++ b/docs/next/config.md
@@ -50,7 +50,7 @@ loaded = load_config() # 按当前环境独立装载,不替换进程默认配
`MINERU_DOCLIB_AUTH_TOKEN` 可以覆盖文件值且不回写。普通 `load_config()` / `get_config()` 不生成凭证。
token 以 `SecretStr` 保存,repr/JSON 完全脱敏;不得放入运行时 `/configs` 或诊断输出。
显式 `create_app(cfg)` 需要宿主提供 token。轮换前先停止服务,修改或删除该字段后再启动。
-文件权限、SDK 自动读取及直接 TCP 调用见 [Doclib SDK 本机认证](sdk/doclib-client.md#本机认证与二次开发)。
+文件权限、SDK 自动读取及直接 TCP 调用见 [Doclib SDK 本机认证](sdk/doclib-client.md#local-authentication)。
### 远程 VLM {#remote-vlm}
diff --git a/docs/next/sdk/doclib-client.md b/docs/next/sdk/doclib-client.md
index fa6ddc28..1ff776b8 100644
--- a/docs/next/sdk/doclib-client.md
+++ b/docs/next/sdk/doclib-client.md
@@ -70,7 +70,7 @@ client = DoclibClient()
status = client.get_server_status()
```
-## 本机认证与二次开发
+## 本机认证与二次开发 {#local-authentication}
首次正常启动服务会生成随机凭证并写入 `$MINERU_HOME/config.yaml` 的 `doclib.auth.token`;
`MINERU_CONFIG` 可指定其他配置文件。重启和升级复用已有凭证。`MINERU_DOCLIB_AUTH_TOKEN`
diff --git a/mineru/utils/_private_file_macos.py b/mineru/utils/_private_file_macos.py
index b9a991ef..d84228db 100644
--- a/mineru/utils/_private_file_macos.py
+++ b/mineru/utils/_private_file_macos.py
@@ -1,3 +1,4 @@
+# Copyright (c) Opendatalab. All rights reserved.
"""使用 macOS 原生 ACL 接口保护凭证,避免仅检查 BSD 权限位遗漏额外授权。"""
from __future__ import annotations
diff --git a/mineru/utils/private_file.py b/mineru/utils/private_file.py
index 226bf344..4b106b6c 100644
--- a/mineru/utils/private_file.py
+++ b/mineru/utils/private_file.py
@@ -1,3 +1,4 @@
+# Copyright (c) Opendatalab. All rights reserved.
"""为本机凭证配置提供 POSIX 权限、macOS ACL 和 Windows DACL 保护。"""
from __future__ import annotations