dsh-pdf-mineru 0.1.4 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +40 -3
- package/README.md +56 -23
- package/cordis.patch.yml +8 -2
- package/lib/client.js +275 -41
- package/lib/client.js.map +1 -1
- package/lib/index.js +1323 -94
- package/lib/types/client/helpers.d.ts +2 -0
- package/lib/types/client/locales.d.ts +1 -1
- package/lib/types/client/sections/ProviderSection.d.ts +1 -1
- package/lib/types/config/migration-values.d.ts +6 -0
- package/lib/types/config/pure.d.ts +22 -6
- package/lib/types/config.d.ts +21 -3
- package/lib/types/domain/errors.d.ts +1 -1
- package/lib/types/index.d.ts +2 -1
- package/lib/types/loopback-rpc.d.ts +1 -1
- package/lib/types/providers/http-client.d.ts +1 -0
- package/lib/types/providers/provider.d.ts +12 -1
- package/lib/types/providers/retry.d.ts +1 -1
- package/lib/types/providers/{self-hosted-v2.d.ts → self-hosted-legacy-v2.d.ts} +6 -6
- package/lib/types/providers/self-hosted-v1.d.ts +141 -0
- package/lib/types/service/mineru-service.d.ts +4 -1
- package/lib/types/service/result-presenter.d.ts +3 -2
- package/package.json +42 -41
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,42 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.2.0
|
|
4
|
+
|
|
5
|
+
### Added
|
|
6
|
+
|
|
7
|
+
- Add configuration schema 3 with ordered 1→2→3 in-memory migrations, safe default filling for historical values, collision-safe IDs and value-free migration metadata. Startup never writes configuration; explicit save persists the complete migrated snapshot through the host ConfigEditor transaction, including repaired non-form fields.
|
|
8
|
+
- Add an explicit `self-hosted-v1` Provider for MinerU 4.x upload sessions, parse jobs and ZIP artifacts, alongside `self-hosted-legacy-v2` and `official-v4`.
|
|
9
|
+
- Add per-profile V1 tier and OCR mode (auto/txt/ocr), and discover deployed tiers/output/source capabilities with health and tiers requests before uploading.
|
|
10
|
+
- Provide three independently editable settings profiles, protocol-specific controls, bilingual guidance, editable deployment cache revision, and stale-probe invalidation without auto-saving drafts.
|
|
11
|
+
|
|
12
|
+
### Changed
|
|
13
|
+
|
|
14
|
+
- Standardize source, API identifiers, tests and generated declarations on `self-hosted-v1` / `self-hosted-legacy-v2` with separate Provider implementations. Explicit selection replaces automatic protocol fallback; V1 no longer interprets a legacy backend map as a tier.
|
|
15
|
+
- Reject cross-protocol configuration fields. V1 keeps shared legacy/cloud defaults in drafts but does not apply them to requests or cache semantics. V1 provenance.model is null rather than a claimed pipeline/vlm engine.
|
|
16
|
+
- Normalize MinerU 4.x ZIP entries and structured documents through the existing bounded artifact pipeline, preserving metadata and real asset references.
|
|
17
|
+
- Declare the host ConfigEditor runtime peer used by complete migration saves, aligned with the existing DSH 0.2.0-rc.2 baseline.
|
|
18
|
+
- Historical self-hosted-v2 profiles migrate to self-hosted-legacy-v2 and drop their V1-only tier; users of the former automatic V1 detection must explicitly select V1. Missing configuration versions mean schema 2; unknown future versions remain errors. Configuration advances to schema 3; artifacts, cursor v3, index v2, native jobs and tool arguments are not migrated.
|
|
19
|
+
|
|
20
|
+
### Fixed
|
|
21
|
+
|
|
22
|
+
- Preserve valid coupled retry/ZIP-limit values when other historical fields are invalid, and persist repaired non-form fields atomically on explicit migration save rather than leaving invalid raw values behind.
|
|
23
|
+
- Isolate V1 results by tier and effective OCR mode instead of reusing another tier/mode result; transport retries cover result-body interruption after HTTP 200, while cancellation and byte limits remain terminal.
|
|
24
|
+
- Preserve drafts and maintenance confirmation boundaries when switching protocol-specific forms. Legacy submissions no longer contact a V1 detection endpoint.
|
|
25
|
+
|
|
26
|
+
## 0.1.5
|
|
27
|
+
|
|
28
|
+
### Changed
|
|
29
|
+
|
|
30
|
+
- Raise the minimum DSH host to 0.2.0-rc.2 and runtime DSH peers to ^0.2.0-rc.2; pin every development DSH SDK package and workspace release-age exclusion to the exact rc.2 baseline and refresh the lockfile. Cordis, Cosmokit and Schemastery retain the unchanged upstream minimum versions.
|
|
31
|
+
- Align package-contract, native-job and loopback RPC regressions with the published rc.2 SDK, and guard workspace release-age exclusions against baseline drift.
|
|
32
|
+
- Document rc.2 compatibility boundaries and the uninstall/reinstall upgrade flow, including Desktop profile initialization and platform-specific native renderer verification.
|
|
33
|
+
|
|
34
|
+
### Fixed
|
|
35
|
+
|
|
36
|
+
- Restore the offline local/installed-package page smoke fixture's optional attachment injection, so the complete plugin activation chain can exercise both renderers without weakening capability checks; add a built-bundle regression.
|
|
37
|
+
|
|
38
|
+
Provider/config/cache formats, cursor v3, index v2, native-job semantics and tool arguments are unchanged; existing parsed caches require no migration or re-upload. Upgrade the DSH host before installing this plugin version.
|
|
39
|
+
|
|
3
40
|
## 0.1.4
|
|
4
41
|
|
|
5
42
|
### Changed
|
|
@@ -223,7 +260,7 @@ This release includes the bounded-reader work recorded under 0.0.13; the previou
|
|
|
223
260
|
- Re-architected model output and tool descriptions to strict Plain Text English with zero emoji, eliminating hallucinated guidance references to deprecated fields.
|
|
224
261
|
- Decoupled document presentation, outline (TOC) extraction, character budget allocation, and prose formatting from `MinerUService` into dedicated `src/service/result-presenter.ts`.
|
|
225
262
|
- Consolidated shared HTTP request pipelines, timeout management, error body diagnostics, and retry policies into `src/providers/http-client.ts`, eliminating duplicate logic across official and self-hosted providers.
|
|
226
|
-
- Upgraded `self-hosted-v2` multipart streaming to Node 22 native `FormData` and `openAsBlob`, removing third-party `form-data` package dependency.
|
|
263
|
+
- Upgraded `self-hosted-legacy-v2` multipart streaming to Node 22 native `FormData` and `openAsBlob`, removing third-party `form-data` package dependency.
|
|
227
264
|
- Replaced hand-rolled streaming JSON parser in `safe-zip` with standard V8 `JSON.parse`, and standardized delay timers across all modules using `node:timers/promises`.
|
|
228
265
|
- Adopted scoped locking (`withLock`) across mutating storage operations (`clearCache`, `commitTransaction`, `quarantine`) with contention backoff, eliminating startup lifetime lock holding to allow concurrent multi-process initialization.
|
|
229
266
|
- Eliminated self-inflicted read-only (`0o400`/`0o500`) permission cycles in `result-repository`, streamlining cache cleanup and quarantine deletions.
|
|
@@ -255,7 +292,7 @@ This release includes the bounded-reader work recorded under 0.0.13; the previou
|
|
|
255
292
|
|
|
256
293
|
### Changed
|
|
257
294
|
|
|
258
|
-
- New installations now provision independent self-hosted v2 and official v4 Provider profiles, while existing single-Provider settings drafts are completed without overwriting their configured values.
|
|
295
|
+
- New installations now provision independent self-hosted legacy v2 and official v4 Provider profiles, while existing single-Provider settings drafts are completed without overwriting their configured values.
|
|
259
296
|
- Expanded peer compatibility for the current DSH 0.1.2 alpha packages, Cordis 4.0.2, and Schemastery 3.18.2.
|
|
260
297
|
|
|
261
298
|
### Fixed
|
|
@@ -328,4 +365,4 @@ No canonical request, CacheKey, ProviderJobRef, or result manifest schema versio
|
|
|
328
365
|
|
|
329
366
|
## 0.0.1
|
|
330
367
|
|
|
331
|
-
- Initial npm release with provider-independent tools, self-hosted v2 and official v4 adapters, session Jobs, immutable global results, request coalescing, restart recovery, safe ZIP extraction, and Provider-aware settings.
|
|
368
|
+
- Initial npm release with provider-independent tools, self-hosted legacy v2 and official v4 adapters, session Jobs, immutable global results, request coalescing, restart recovery, safe ZIP extraction, and Provider-aware settings.
|
package/README.md
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
<a href="https://awesome-dsh-plugin.com"><img src="https://awesome-dsh-plugin.com/badge.svg" alt="Awesome DSH Plugin"></a>
|
|
13
13
|
<a href="https://www.npmjs.com/package/dsh-pdf-mineru"><img src="https://img.shields.io/npm/v/dsh-pdf-mineru?style=flat-square&label=npm&color=CB3837" alt="npm version"></a>
|
|
14
14
|
<a href="./package.json"><img src="https://img.shields.io/badge/Node.js-%3E%3D22.19.0-339933?style=flat-square&logo=nodedotjs&logoColor=white" alt="Node.js 22.19.0 or newer"></a>
|
|
15
|
-
<img src="https://img.shields.io/badge/DSH-%3E%3D0.2.0--rc.
|
|
15
|
+
<img src="https://img.shields.io/badge/DSH-%3E%3D0.2.0--rc.2%20(RC%20only)-111827?style=flat-square" alt="DSH >=0.2.0-rc.2 (RC only)">
|
|
16
16
|
<img src="https://img.shields.io/badge/MinerU-Official%20v4%20%7C%20Self--hosted%20v2-2563EB?style=flat-square" alt="MinerU v2 and v4">
|
|
17
17
|
<a href="./LICENSE"><img src="https://img.shields.io/badge/license-MIT-2EA44F?style=flat-square" alt="MIT License"></a>
|
|
18
18
|
</p>
|
|
@@ -38,11 +38,11 @@
|
|
|
38
38
|
### 0. 环境要求与版本兼容说明
|
|
39
39
|
|
|
40
40
|
> ⚠️ **重要版本声明与环境要求**:
|
|
41
|
-
> - **最低支持的 DSH 版本**:`>= 0.2.0-rc.
|
|
41
|
+
> - **最低支持的 DSH 版本**:`>= 0.2.0-rc.2`。
|
|
42
42
|
> - **仅支持 RC 版本**:本插件**只会对 DeepSeek Harness 的 RC(Release Candidate)版本及后续正式发布版本进行官方支持**。由于早期 `alpha` 测试版本包含较多实验性且剧烈变动的内部 API,本插件不再对 `alpha` 等非稳定测试版本提供兼容与维护支持。
|
|
43
43
|
> - **运行环境要求**:Node.js `^22.19.0 || >=24.0.0`,包管理器推荐 `pnpm@11+`。
|
|
44
44
|
|
|
45
|
-
插件 `0.1.
|
|
45
|
+
插件 `0.1.5` 起以 DSH `v0.2.0-rc.2` 为基线,当前版本为 `0.2.0`。升级前请先升级宿主;`0.2.0` 将配置升级到 schema 3,旧配置读取时内存迁移、用户显式保存时写入新格式。自托管 Provider 身份变化会导致旧缓存重新解析;工具参数不变。Web 设置与维护 RPC 仅在 `connection` 和 `webServer` 同时可用时注册;无 WebServer 的宿主仍可使用两个模型工具,但不提供这些 HTTP RPC。
|
|
46
46
|
|
|
47
47
|
后台任务使用 DSH 的 SessionId 归属与原生 JobRegistry:阶段进度显示为 `preparing`、`waiting-for-parse`、`reading-result`、`summarizing`,不是页数或百分比;缓存命中跳过等待阶段。完成摘要通过原生任务结果交付,通知、空闲唤醒、输出消费与会话归档准入由 DSH 负责。宿主必须为该会话装配任务控制器(如 `tool-jobs`),否则启动会在解析前拒绝。`job_kill` 仍只取消本次等待,不中止其他调用共用的解析生产者。
|
|
48
48
|
|
|
@@ -54,6 +54,8 @@
|
|
|
54
54
|
dsh plugin --profile web add dsh-pdf-mineru
|
|
55
55
|
```
|
|
56
56
|
|
|
57
|
+
rc.2 暂不支持已安装插件的自动更新。升级已安装版本时,请先升级 DSH 宿主,再在 Plugins 中卸载旧插件并安装 `dsh-pdf-mineru@0.2.0`;操作前备份 profile 配置,不要执行缓存清除。旧配置在内存中自动迁移,保存后写入 schema 3;旧自托管缓存不再按新 Provider 身份复用,首次读取会重新解析。Desktop profile 需先启动过桌面端,生成 profile 后再使用 CLI 管理插件。
|
|
58
|
+
|
|
57
59
|
> 本地开发或测试源码时,可使用:`dsh plugin --profile web add link:/absolute/path/to/dsh-pdf-mineru`
|
|
58
60
|
|
|
59
61
|
### 本地原页渲染的安装条件
|
|
@@ -89,9 +91,10 @@ PDF.js 包解压约34.8 MB,Canvas JS 约0.13 MB,Linux x64 glibc 二进制约
|
|
|
89
91
|
3. 在设置中选择 **Official v4**,保持 **API Key Env Var** 为 `MINERU_API_KEY`,点击 **Test Active Provider** 即可完成验证。
|
|
90
92
|
|
|
91
93
|
#### 方案 B:使用本地 / 私有化自建服务
|
|
92
|
-
1.
|
|
93
|
-
2.
|
|
94
|
-
3.
|
|
94
|
+
1. 启动 MinerU 服务:4.x 请选择 **Self-Hosted MinerU (V1 API)**(常见地址 `http://localhost:8000`);3.x 请选择 **Self-Hosted MinerU (Legacy v2)**(常见地址 `http://localhost:18000`)。API 代际不等于软件大版本,也不要填入 VLM 推理服务地址。
|
|
95
|
+
2. V1 配置档位 `tier` 和独立的 OCR 模式 `ocrMode: auto/txt/ocr`;legacy-v2 配置 backend 映射及共享解析默认值。两种协议显式选择,不自动降级或映射 backend 为 tier。
|
|
96
|
+
3. 本地 HTTP 需勾选 **Allow Insecure HTTP**。点击 **Test Active Provider** 验证:V1 显示部署声明的档位、产物和来源,真实解析前也检查 ZIP、file_id 与选定档位是否可用。验证不等于解析效果保证。
|
|
97
|
+
4. 配置修改只更新草稿,点击 **Save Configuration** 才保存。切换协议、折叠卡片不清空各 profile 的草稿。
|
|
95
98
|
|
|
96
99
|
### 3. 开始使用
|
|
97
100
|
|
|
@@ -179,9 +182,11 @@ flowchart LR
|
|
|
179
182
|
Cache -->|hit| Result[Immutable result]
|
|
180
183
|
Cache -->|miss| Shared[SharedOperationRegistry]
|
|
181
184
|
Shared --> Providers
|
|
182
|
-
Providers -->
|
|
185
|
+
Providers --> V1[Self-hosted V1]
|
|
186
|
+
Providers --> V2[Self-hosted legacy v2]
|
|
187
|
+
V1 --> Staging[Validated staging]
|
|
183
188
|
Providers --> V4[Official v4]
|
|
184
|
-
V2 --> Staging
|
|
189
|
+
V2 --> Staging
|
|
185
190
|
V4 --> Staging
|
|
186
191
|
Staging --> Publish[Atomic publish]
|
|
187
192
|
Publish --> Result
|
|
@@ -190,18 +195,17 @@ flowchart LR
|
|
|
190
195
|
- **统一工具分发**:Agent 发起的同步请求(`read_pdf`)直接返回结果,异步长任务(`async_parse_pdf`)交由 DSH 原生 JobRegistry 调度。
|
|
191
196
|
- **缓存复用**:按文件 SHA-256 与解析语义寻址;命中时无需重新提交上游解析,但仍校验本地源文件及产物。
|
|
192
197
|
- **并发请求合并**:同进程内的并发重复请求由 `SharedOperationRegistry` 合并,避免重复向上游提交。
|
|
193
|
-
-
|
|
198
|
+
- **显式三类 Provider**:`self-hosted-v1` 使用 4.x `/v1/...`,`self-hosted-legacy-v2` 使用 3.x `/tasks`,`official-v4` 使用官方云接口;各自有独立配置、缓存身份和能力校验。
|
|
194
199
|
|
|
195
200
|
## 🔌 Provider 选型对比
|
|
196
201
|
|
|
197
|
-
|
|
|
198
|
-
| --- | --- | --- |
|
|
199
|
-
|
|
|
200
|
-
|
|
|
201
|
-
|
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
| **网络协议** | 强制 HTTPS,安全传输 | 支持 HTTP / HTTPS,本地可配置 `allowInsecureHttp` |
|
|
202
|
+
| 配置类型 | 适用服务 | 可配置解析选项 | 不接受的混用字段 |
|
|
203
|
+
| --- | --- | --- | --- |
|
|
204
|
+
| `self-hosted-v1` | 自部署 MinerU 4.x,V1 API | `tier`(四档或服务端默认)、`ocrMode`(三态) | `modelMap`、请求级模型/语言/公式/表格开关 |
|
|
205
|
+
| `self-hosted-legacy-v2` | 自部署 MinerU 3.x,旧任务 API | `modelMap`;共享 `defaults` 中的模型、解析方式、语言、公式、表格 | `tier`、`ocrMode` |
|
|
206
|
+
| `official-v4` | MinerU 官方云 API | `models`;共享解析默认值(不支持 txt) | `tier`、`ocrMode`、`modelMap` |
|
|
207
|
+
|
|
208
|
+
两类自托管支持显式 HTTP opt-in、可选凭据引用和 `configuredVersion`;官方云保持 HTTPS 与凭据要求。新安装提供三份独立 profile,默认仍选 legacy-v2,不自动更改既有部署目标。
|
|
205
209
|
|
|
206
210
|
---
|
|
207
211
|
|
|
@@ -214,7 +218,7 @@ flowchart LR
|
|
|
214
218
|
|
|
215
219
|
### 1. 官方云 (Official v4) 推荐配置
|
|
216
220
|
```yaml
|
|
217
|
-
schemaVersion:
|
|
221
|
+
schemaVersion: 3
|
|
218
222
|
activeProvider: mp_official
|
|
219
223
|
providers:
|
|
220
224
|
- id: mp_official
|
|
@@ -229,16 +233,16 @@ defaults:
|
|
|
229
233
|
table: true
|
|
230
234
|
```
|
|
231
235
|
|
|
232
|
-
### 2. 本地私有化 (Self-hosted v2) 推荐配置
|
|
236
|
+
### 2. 本地私有化 (Self-hosted legacy v2) 推荐配置
|
|
233
237
|
```yaml
|
|
234
|
-
schemaVersion:
|
|
238
|
+
schemaVersion: 3
|
|
235
239
|
activeProvider: mp_self_hosted
|
|
236
240
|
providers:
|
|
237
241
|
- id: mp_self_hosted
|
|
238
|
-
type: self-hosted-v2
|
|
242
|
+
type: self-hosted-legacy-v2
|
|
239
243
|
baseURL: http://localhost:18000
|
|
240
244
|
allowInsecureHttp: true
|
|
241
|
-
modelMap:
|
|
245
|
+
modelMap: # legacy-v2 的 backend 名称
|
|
242
246
|
pipeline: pipeline
|
|
243
247
|
vlm: vlm-engine
|
|
244
248
|
defaults:
|
|
@@ -248,7 +252,36 @@ defaults:
|
|
|
248
252
|
table: true
|
|
249
253
|
```
|
|
250
254
|
|
|
251
|
-
### 3.
|
|
255
|
+
### 3. MinerU 4.x 自托管(V1 API)配置
|
|
256
|
+
|
|
257
|
+
```yaml
|
|
258
|
+
schemaVersion: 3
|
|
259
|
+
activeProvider: mp_self_hosted_v1
|
|
260
|
+
providers:
|
|
261
|
+
- id: mp_self_hosted_v1
|
|
262
|
+
type: self-hosted-v1
|
|
263
|
+
baseURL: http://localhost:8000
|
|
264
|
+
allowInsecureHttp: true
|
|
265
|
+
apiKeyEnv: MINERU_API_KEY
|
|
266
|
+
tier: standard # 可省略,让服务端选择;不是具体模型名
|
|
267
|
+
ocrMode: auto # auto / txt / ocr;按 V1 profile 独立保存
|
|
268
|
+
configuredVersion: '4.0.10' # 原地升级服务或模型后更新缓存版本
|
|
269
|
+
```
|
|
270
|
+
|
|
271
|
+
V1 不暴露上游已移除的请求级语言/公式/表格参数。隐藏这些共享默认值不会把它们清空,但它们不影响 V1 请求或缓存;内部占位值不表示服务端关闭相关能力。OCR 的 txt 与 auto 保持不同语义,txt 不保证完全不运行视觉模型。档位切换和 OCR 模式变化会隔离缓存;standard/advanced 可以使用同一模型、不同计算量。
|
|
272
|
+
|
|
273
|
+
**配置版本与自动迁移:**当前插件配置为 schemaVersion: 3,独立于 MinerU 软件/API 版本及缓存、游标版本。读取旧配置时只在内存中按 **1 → 2 → 3** 转换;未声明版本的 Provider-based 配置按版本 2 处理。启动、配置读取均不自动改写磁盘;用户点击保存后,才通过宿主事务持久化版本 3 的完整迁移结果,后续普通保存仍沿用原生 Settings。
|
|
274
|
+
|
|
275
|
+
- 1 → 2 移除旧批量/产物默认字段;2 → 3 将 self-hosted-v2 转为 self-hosted-legacy-v2,保留有效 ID、活动选择、地址、凭据引用、backend 映射及其他有效设置,移除 legacy 不支持的 tier。
|
|
276
|
+
- 旧版本缺失或不支持的字段值使用对应默认值修复;重复/无效 ID 采用不冲突的默认 ID。迁移记录只含版本、字段路径和 Provider ID,不记录原始值或密钥。不会因迁移自动开启未经明确授权的 HTTP;缺少授权的 HTTP 默认端点改用 HTTPS,无效凭据引用不会被传给 Provider。
|
|
277
|
+
- 最新版本编辑继续严格校验;未知未来版本和未知结构字段拒绝,防止误降级或吞掉配置。宿主组合基础层中残留的两个已废弃字段仅在内存清除;不恢复旧 flat config。
|
|
278
|
+
- 首次显式保存迁移配置时,完整快照同时保存修复后的非表单字段,避免更新版本号后残留坏值;运行中的 storageRoot/limits 仍不允许改变。保存失败不会提前更新运行时配置。
|
|
279
|
+
|
|
280
|
+
**接口选择与缓存:**迁移不根据 URL/backend/tier 猜测接口。此前依赖 V1 自动识别的部署需主动选择 self-hosted-v1。原自托管缓存不会被新 Provider 身份复用,配置迁移也不改写解析产物;连接失败不会降级到另一个协议。
|
|
281
|
+
|
|
282
|
+
**V1 功能边界:**使用本地路径或会话附件,经上传去重、任务轮询及 ZIP 下载后发布到插件自身缓存。已处理 partial/canceled 状态、逐文件错误和素材实际路径;不把服务器资源 ID 当作重启后可恢复的持久化记录。工具仍是单文件;不暴露 URL/inline 来源、callback/Webhook、服务端 DELETE 取消、HTML/DOCX 产物选择或 Doclib。job_kill 只取消本次等待,不中止共享上游任务。read_pdf.pages 是已解析内容的物理页投影,不是完整上游 page_range 语法;原页 view 仅支持 PDF。当前输入白名单仍限于 PDF、常见图片及 doc/docx/ppt/pptx/xls/xlsx;HTML/MHTML、OpenDocument、RTF、EPUB、OFD、CSV/TSV 等上游新增格式尚未开放,HTML 已验证在上传前明确拒绝。不能将四档×所有文件类型视作均已覆盖或验证。
|
|
283
|
+
|
|
284
|
+
### 4. 存储与限制自定义(可选)
|
|
252
285
|
```yaml
|
|
253
286
|
storage:
|
|
254
287
|
storageRoot: /absolute/path/to/dsh/cache/pdf-mineru # 默认在 $DSH_HOME/cache/pdf-mineru
|
package/cordis.patch.yml
CHANGED
|
@@ -4,11 +4,11 @@
|
|
|
4
4
|
- id: dsh-pdf-mineru
|
|
5
5
|
name: 'dsh-pdf-mineru'
|
|
6
6
|
config:
|
|
7
|
-
schemaVersion:
|
|
7
|
+
schemaVersion: 3
|
|
8
8
|
activeProvider: mp_self_hosted
|
|
9
9
|
providers:
|
|
10
10
|
- id: mp_self_hosted
|
|
11
|
-
type: self-hosted-v2
|
|
11
|
+
type: self-hosted-legacy-v2
|
|
12
12
|
baseURL: 'http://localhost:18000'
|
|
13
13
|
apiKeyEnv: MINERU_API_KEY
|
|
14
14
|
allowInsecureHttp: true
|
|
@@ -23,6 +23,12 @@
|
|
|
23
23
|
- pipeline
|
|
24
24
|
- vlm
|
|
25
25
|
configuredVersion: v4
|
|
26
|
+
- id: mp_self_hosted_v1
|
|
27
|
+
type: self-hosted-v1
|
|
28
|
+
baseURL: 'http://localhost:8000'
|
|
29
|
+
apiKeyEnv: MINERU_API_KEY
|
|
30
|
+
allowInsecureHttp: true
|
|
31
|
+
ocrMode: auto
|
|
26
32
|
defaults:
|
|
27
33
|
model: pipeline
|
|
28
34
|
ocr: false
|