Transforms complex documents like PDFs and Office docs into LLM-ready markdown/JSON for your Agentic workflows.
Python ai4sciencedocument-analysisdocxextract-datalayout-analysisocrparserpdfpdf-converterpdf-extractor-llmpdf-extractor-pretrainpdf-extractor-ragpdf-parserpptxpythonxlsx
refactor: rename parsing tiers
jinzhenj57aa965d41aa
diff --git a/README.md b/README.mdindex 1beea555..10269979 100644--- a/README.md+++ b/README.md@@ -102,7 +102,7 @@ Then answer from `content.content`. If `next_request` exists and the question ne```bashmineru parse "book.pdf" --pages 1~10 --limit 12000 --json-mineru read "doc:ab12cd3/tier:high/page:11" --limit 12000 --json+mineru read "doc:ab12cd3/tier:standard/page:11" --limit 12000 --json```Continue with returned `next_request.locator`.@@ -110,15 +110,15 @@ Continue with returned `next_request.locator`.### Read or inspect a known location```bash-mineru read "doc:ab12cd3/tier:high/page:42" --context 1 --json-mineru read "doc:ab12cd3/tier:high/page:12/block:5" --format image --output ./page12-block5.png+mineru read "doc:ab12cd3/tier:standard/page:42" --context 1 --json+mineru read "doc:ab12cd3/tier:standard/page:12/block:5" --format image --output ./page12-block5.png```### Search local library, then read```bash-mineru search "liquidated damages" --min-tier medium --json-mineru read "doc:ab12cd3/tier:high/page:18" --json+mineru search "liquidated damages" --min-tier basic --json+mineru read "doc:ab12cd3/tier:standard/page:18" --json```## Installation And Setup@@ -279,14 +279,14 @@ MinerU has four tiers:| Tier | Quality and speed | Local requirements | Local model download | Use for ||---|---|---|---|---|| `flash` | Lowest quality; fastest | No special hardware | None | Discovery, preview, and indexing; never default final reading quality |-| `medium` | Medium quality; moderate speed | At least 16 GB total memory; CPU works, GPU can accelerate | About 2 GB | Private local reading or lower-resource local parsing |-| `high` | High quality; similar speed to `medium` on suitable hardware | At least 16 GB total memory plus a supported accelerator | About 4 GB | Default for normal active reading and complex documents |-| `xhigh` | Highest quality; slowest | Same as high, with greater compute use | About 4 GB | Maximum-quality work when the user accepts a longer wait |+| `basic` | Basic quality; moderate speed | At least 16 GB total memory; CPU works, GPU can accelerate | About 2 GB | Private local reading or lower-resource local parsing |+| `standard` | Standard high quality; similar speed to `basic` on suitable hardware | At least 16 GB total memory plus a supported accelerator | About 4 GB | Default for normal active reading and complex documents |+| `advanced` | Standard quality on ordinary documents and better quality on difficult documents; slowest | Same as Standard, with greater compute use | About 4 GB | Difficult documents and maximum-quality work when the user accepts a longer wait |Default tier behavior:- Omit `--tier` when the user wants normal reading quality.-- For parse-server based parsing, MinerU chooses `high`, then `xhigh`, then `medium`; `flash` is not a default final reading tier.+- For parse-server based parsing, MinerU chooses `standard`, then `advanced`, then `basic`; `flash` is not a default final reading tier.- For `mineru read doc:{short_id}`, MinerU reads the best cached result rather than starting a new parse.- If normal reading quality is unavailable, inspect `mineru server status --json`, then present the applicable choices to the user:- Use remote parsing with `--remote`, which uploads the document and requires explicit permission.@@ -301,9 +301,9 @@ Examples:```bashmineru parse "paper.pdf"-mineru parse "paper.pdf" --tier medium-mineru parse "paper.pdf" --tier high-mineru parse "paper.pdf" --tier xhigh+mineru parse "paper.pdf" --tier basic+mineru parse "paper.pdf" --tier standard+mineru parse "paper.pdf" --tier advancedmineru parse "paper.pdf" --tier flash```@@ -340,7 +340,7 @@ Agent rules:## Local Parse Server-Use a local parse server when the user wants `medium`, `high`, or `xhigh` quality without sending the document to remote parsing.+Use a local parse server when the user wants `basic`, `standard`, or `advanced` quality without sending the document to remote parsing.### Assess Local Hardware@@ -355,12 +355,12 @@ Use available read-only system commands to inspect the OS, architecture, total mClassify each local quality tier as `hardware-supported`, `hardware-unsupported`, or `hardware-unknown`. These labels describe hardware suitability only, not whether the required dependencies and models are installed or the tier is currently available:-- `medium`: `hardware-supported` with at least 16 GB total memory. A CPU is sufficient, but warn that CPU-only parsing may be slow and GPU acceleration can materially reduce parsing time.-- `high` and `xhigh`: `hardware-supported` with at least 16 GB total memory and either a Volta-or-newer NVIDIA GPU with at least 8 GB available VRAM or Apple Silicon with at least 16 GB unified memory.-- For `high` and `xhigh`, an `npu`, `gcu`, `musa`, `mlu`, or `sdaa` qualifies as `hardware-supported` only when MinerU compatibility with the exact device and runtime can be verified; otherwise report `hardware-unknown`.+- `basic`: `hardware-supported` with at least 16 GB total memory. A CPU is sufficient, but warn that CPU-only parsing may be slow and GPU acceleration can materially reduce parsing time.+- `standard` and `advanced`: `hardware-supported` with at least 16 GB total memory and either a Volta-or-newer NVIDIA GPU with at least 8 GB available VRAM or Apple Silicon with at least 16 GB unified memory.+- For `standard` and `advanced`, an `npu`, `gcu`, `musa`, `mlu`, or `sdaa` qualifies as `hardware-supported` only when MinerU compatibility with the exact device and runtime can be verified; otherwise report `hardware-unknown`.- Report `hardware-unsupported` when a requirement is clearly not met. If a required property cannot be verified, report `hardware-unknown`.-Before asking the user to choose a tier, summarize the detected hardware and identify each local tier's hardware status. Recommend local `high` when `hardware-supported`, otherwise local `medium` when `hardware-supported`, otherwise offer remote `high` when privacy rules allow or explicit `flash`. Mention `xhigh` only when the user wants maximum quality and accepts the extra time. Do not install dependencies, download models, change config, or restart services without approval.+Before asking the user to choose a tier, summarize the detected hardware and identify each local tier's hardware status. Recommend local `standard` when `hardware-supported`, otherwise local `basic` when `hardware-supported`, otherwise offer remote `standard` when privacy rules allow or explicit `flash`. Mention `advanced` only when the user wants maximum quality and accepts the extra time. Do not install dependencies, download models, change config, or restart services without approval.### Configure Managed Local Parsing@@ -372,40 +372,40 @@ The following examples assume the current install tool is `uv tool`. If `mineru`Installing extras with `uv tool install --force --prerelease allow` can reinstall or upgrade the `mineru` package. Restart the MinerU server after installing extras so the CLI client, doclib server, and managed parse server use the same installed version.-Managed local `medium`, `high`, and `xhigh` all require downloaded model files. Download the target tier models before switching `parse_server.local.mode` to `managed`.+Managed local `basic`, `standard`, and `advanced` all require downloaded model files. Download the target tier models before switching `parse_server.local.mode` to `managed`.-Enable managed local parsing for `medium`:+Enable managed local parsing for `basic`:```bash-uv tool install --force --prerelease allow "mineru[medium]"-mineru-kit models download --tier medium-mineru-kit models verify --tier medium+uv tool install --force --prerelease allow "mineru[basic]"+mineru-kit models download --tier basic+mineru-kit models verify --tier basicmineru server restart-mineru config set parse_server.local.managed_tier medium+mineru config set parse_server.local.managed_tier basicmineru config set parse_server.local.mode managedmineru server status --json```-Enable managed local parsing for `high`:+Enable managed local parsing for `standard`:```bash-uv tool install --force --prerelease allow "mineru[high]"-mineru-kit models download --tier high-mineru-kit models verify --tier high+uv tool install --force --prerelease allow "mineru[standard]"+mineru-kit models download --tier standard+mineru-kit models verify --tier standardmineru server restart-mineru config set parse_server.local.managed_tier high+mineru config set parse_server.local.managed_tier standardmineru config set parse_server.local.mode managedmineru server status --json```-Enable managed local parsing for `xhigh`:+Enable managed local parsing for `advanced`:```bash-uv tool install --force --prerelease allow "mineru[xhigh]"-mineru-kit models download --tier xhigh-mineru-kit models verify --tier xhigh+uv tool install --force --prerelease allow "mineru[advanced]"+mineru-kit models download --tier advanced+mineru-kit models verify --tier advancedmineru server restart-mineru config set parse_server.local.managed_tier xhigh+mineru config set parse_server.local.managed_tier advancedmineru config set parse_server.local.mode managedmineru server status --json```@@ -417,7 +417,7 @@ Rules:- After installing extras, restart the MinerU server to avoid CLI/server version mismatch.- Set `parse_server.local.managed_tier` before `parse_server.local.mode=managed`.- Poll `mineru server status --json` and use managed parsing only after the target tier is healthy.-- If local `medium`, `high`, or `xhigh` cannot start, do not add `--remote` automatically; ask the user first.+- If local `basic`, `standard`, or `advanced` cannot start, do not add `--remote` automatically; ask the user first.## First Read From A File@@ -480,7 +480,7 @@ Rules:MinerU output may include a command to continue reading:```text-<!-- Next: mineru read doc:ab12cd3/tier:high/page:11 -->+<!-- Next: mineru read doc:ab12cd3/tier:standard/page:11 -->```or:@@ -517,10 +517,10 @@ doc:{short_id}/tier:{tier}/page:{page_no}/block:{block_no}/char:{offset}Examples:```bash-mineru read "doc:ab12cd3/tier:high/page:4"-mineru read "doc:ab12cd3/tier:high/page:4/block:7"-mineru read "doc:ab12cd3/tier:high/page:4/block:7" --context 2-mineru read "doc:ab12cd3/tier:high/page:4" --limit 8000 --json+mineru read "doc:ab12cd3/tier:standard/page:4"+mineru read "doc:ab12cd3/tier:standard/page:4/block:7"+mineru read "doc:ab12cd3/tier:standard/page:4/block:7" --context 2+mineru read "doc:ab12cd3/tier:standard/page:4" --limit 8000 --json```Rules:@@ -535,9 +535,9 @@ Rules:Use image output only when the user needs visual inspection, layout evidence, cropped figures, page screenshots, or block-level visual verification.```bash-mineru read "doc:ab12cd3/tier:high/page:4" --format image-mineru read "doc:ab12cd3/tier:high/page:4/block:7" --format image-mineru read "doc:ab12cd3/tier:high/page:4/block:7" --format image --output ./block-7.png+mineru read "doc:ab12cd3/tier:standard/page:4" --format image+mineru read "doc:ab12cd3/tier:standard/page:4/block:7" --format image+mineru read "doc:ab12cd3/tier:standard/page:4/block:7" --format image --output ./block-7.png```Rules:@@ -563,7 +563,7 @@ Use `search` for parsed document content:```bashmineru search "revenue recognition"mineru search "transformer architecture" --type pdf-mineru search "appendix" --min-tier medium --limit 10 --json+mineru search "appendix" --min-tier basic --limit 10 --json```Rules:@@ -634,8 +634,8 @@ Watch rules:Use parsing rules only when the user wants automatic parse policy for paths:```bash-mineru config parsing-rules add "*/papers/*" --tier high --pages all-mineru config parsing-rules add "*/contracts/*" --tier high --remote+mineru config parsing-rules add "*/papers/*" --tier standard --pages all+mineru config parsing-rules add "*/contracts/*" --tier standard --remotemineru config parsing-rules listmineru config parsing-rules remove 3```@@ -691,7 +691,7 @@ Invalidate cached parse results:```bashmineru invalidate "report.pdf"-mineru invalidate "report.pdf" --tier high+mineru invalidate "report.pdf" --tier standard```Rules:@@ -839,11 +839,11 @@ When answering after reading a document:Citation style examples:```text-The warranty period is 24 months (doc:ab12cd3/tier:high/page:7/block:3).+The warranty period is 24 months (doc:ab12cd3/tier:standard/page:7/block:3).``````text-The method is described across pages 4-5; I checked doc:ab12cd3/tier:high/page:4 and doc:ab12cd3/tier:high/page:5.+The method is described across pages 4-5; I checked doc:ab12cd3/tier:standard/page:4 and doc:ab12cd3/tier:standard/page:5.```## Operating Rulesdiff --git a/README_en.md b/README_en.mdindex e7273f1c..abfc95ef 100644--- a/README_en.md+++ b/README_en.md@@ -234,9 +234,9 @@ A WebUI developed based on Gradio, with a simple interface and only core parsing<tr><th>Accuracy<sup>1</sup></th><td style="text-align:center;">86.47</td>- <td style="text-align:center;">95.39 (high)<br>95.26 (medium)</td>+ <td style="text-align:center;">95.39 (effort=high)<br>95.26 (effort=medium)</td><td style="text-align:center;">95.30</td>- <td style="text-align:center;">95.39 (high)<br>95.26 (medium)</td>+ <td style="text-align:center;">95.39 (effort=high)<br>95.26 (effort=medium)</td><td style="text-align:center;">95.30</td></tr><tr>diff --git a/README_zh.md b/README_zh.mdindex 85fdb3dd..a785c259 100644--- a/README_zh.md+++ b/README_zh.md@@ -232,9 +232,9 @@ https://github.com/user-attachments/assets/4bea02c9-6d54-4cd6-97ed-dff14340982c<tr><th>精度指标<sup>1</sup></th><td style="text-align:center;">86.47</td>- <td style="text-align:center;">95.39(high)<br>95.26(medium)</td>+ <td style="text-align:center;">95.39(effort=high)<br>95.26(effort=medium)</td><td style="text-align:center;">95.30</td>- <td style="text-align:center;">95.39(high)<br>95.26(medium)</td>+ <td style="text-align:center;">95.39(effort=high)<br>95.26(effort=medium)</td><td style="text-align:center;">95.30</td></tr><tr>diff --git a/docker/china/Dockerfile b/docker/china/Dockerfileindex 1d6ac5bb..5055b722 100644--- a/docker/china/Dockerfile+++ b/docker/china/Dockerfile@@ -21,7 +21,7 @@ RUN python3 -m pip install -U 'mineru[core]>=3.4.0' -i https://mirrors.aliyun.copython3 -m pip cache purge# Download models and update the configuration file-RUN /bin/bash -c "mineru-kit models download --tier high -s modelscope"+RUN /bin/bash -c "mineru-kit models download --tier standard -s modelscope"# Set the entry point to activate the virtual environment and run the command line toolENTRYPOINT ["/bin/bash", "-c", "export MINERU_MODEL_SOURCE=local && exec \"$@\"", "--"]diff --git a/docker/china/corex.Dockerfile b/docker/china/corex.Dockerfileindex 3c90a879..24e1e2fb 100644--- a/docker/china/corex.Dockerfile+++ b/docker/china/corex.Dockerfile@@ -21,7 +21,7 @@ RUN python3 -m pip install -U pip -i https://mirrors.aliyun.com/pypi/simple && \python3 -m pip cache purge# Download models and update the configuration file-RUN /bin/bash -c "mineru-kit models download --tier high -s modelscope"+RUN /bin/bash -c "mineru-kit models download --tier standard -s modelscope"# Set the entry point to activate the virtual environment and run the command line tool-ENTRYPOINT ["/bin/bash", "-c", "export MINERU_MODEL_SOURCE=local && exec \"$@\"", "--"]\ No newline at end of file+ENTRYPOINT ["/bin/bash", "-c", "export MINERU_MODEL_SOURCE=local && exec \"$@\"", "--"]diff --git a/docker/china/dcu.Dockerfile b/docker/china/dcu.Dockerfileindex 98465aa8..ec1a0954 100644--- a/docker/china/dcu.Dockerfile+++ b/docker/china/dcu.Dockerfile@@ -25,7 +25,7 @@ RUN python3 -m pip install -U pip -i https://mirrors.aliyun.com/pypi/simple && \python3 -m pip cache purge# Download models and update the configuration file-RUN /bin/bash -c "mineru-kit models download --tier high -s modelscope"+RUN /bin/bash -c "mineru-kit models download --tier standard -s modelscope"# Set the entry point to activate the virtual environment and run the command line tool-ENTRYPOINT ["/bin/bash", "-c", "export MINERU_MODEL_SOURCE=local && exec \"$@\"", "--"]\ No newline at end of file+ENTRYPOINT ["/bin/bash", "-c", "export MINERU_MODEL_SOURCE=local && exec \"$@\"", "--"]diff --git a/docker/china/gcu.Dockerfile b/docker/china/gcu.Dockerfileindex 2c57e75d..49f2288c 100644--- a/docker/china/gcu.Dockerfile+++ b/docker/china/gcu.Dockerfile@@ -24,7 +24,7 @@ RUN python3 -m pip install "mineru[core]>=3.4.0" \python3 -m pip cache purge# Download models and update the configuration file-RUN /bin/bash -c "mineru-kit models download --tier high -s modelscope"+RUN /bin/bash -c "mineru-kit models download --tier standard -s modelscope"# Set the entry point to activate the virtual environment and run the command line toolENTRYPOINT ["/bin/bash", "-c", "export MINERU_MODEL_SOURCE=local && exec \"$@\"", "--"]diff --git a/docker/china/kxpu.Dockerfile b/docker/china/kxpu.Dockerfileindex 29d76816..86c4639f 100644--- a/docker/china/kxpu.Dockerfile+++ b/docker/china/kxpu.Dockerfile@@ -24,7 +24,7 @@ RUN python3 -m pip install -U pip -i https://mirrors.aliyun.com/pypi/simple && \python3 -m pip cache purge# Download models and update the configuration file-RUN /bin/bash -c "mineru-kit models download --tier high -s modelscope"+RUN /bin/bash -c "mineru-kit models download --tier standard -s modelscope"# Set the entry point to activate the virtual environment and run the command line toolENTRYPOINT ["/bin/bash", "-c", "export MINERU_MODEL_SOURCE=local && exec \"$@\"", "--"]diff --git a/docker/china/maca.Dockerfile b/docker/china/maca.Dockerfileindex 7b960f93..3b1d0ce5 100644--- a/docker/china/maca.Dockerfile+++ b/docker/china/maca.Dockerfile@@ -32,7 +32,7 @@ RUN /opt/conda/bin/python3 -m pip install -U pip -i https://mirrors.aliyun.com/p/opt/conda/bin/python3 -m pip cache purge# Download models and update the configuration file-RUN /bin/bash -c "/opt/conda/bin/mineru-kit models download --tier high -s modelscope"+RUN /bin/bash -c "/opt/conda/bin/mineru-kit models download --tier standard -s modelscope"# Set the entry point to activate the virtual environment and run the command line toolENTRYPOINT ["/bin/bash", "-c", "export MINERU_MODEL_SOURCE=local && exec \"$@\"", "--"]diff --git a/docker/china/mlu.Dockerfile b/docker/china/mlu.Dockerfileindex 0c8ab4a5..868e94cd 100644--- a/docker/china/mlu.Dockerfile+++ b/docker/china/mlu.Dockerfile@@ -36,7 +36,7 @@ RUN /bin/bash -c '\if [ "$BACKEND" = "vllm" ]; then \source /torch/venv3/pytorch_infer/bin/activate; \fi && \- mineru-kit models download --tier high -s modelscope'+ mineru-kit models download --tier standard -s modelscope'WORKDIR /workspacediff --git a/docker/china/musa.Dockerfile b/docker/china/musa.Dockerfileindex 52d6832e..102dc5db 100644--- a/docker/china/musa.Dockerfile+++ b/docker/china/musa.Dockerfile@@ -29,7 +29,7 @@ RUN python3 -m pip install -U pip -i https://mirrors.aliyun.com/pypi/simple && \python3 -m pip cache purge# Download models and update the configuration file-RUN /bin/bash -c "mineru-kit models download --tier high -s modelscope"+RUN /bin/bash -c "mineru-kit models download --tier standard -s modelscope"# Set the entry point to activate the virtual environment and run the command line toolENTRYPOINT ["/bin/bash", "-c", "export MINERU_MODEL_SOURCE=local && exec \"$@\"", "--"]diff --git a/docker/china/npu.Dockerfile b/docker/china/npu.Dockerfileindex e916e43b..b82ab0d8 100644--- a/docker/china/npu.Dockerfile+++ b/docker/china/npu.Dockerfile@@ -29,7 +29,7 @@ RUN python3 -m pip install -U pip -i https://mirrors.aliyun.com/pypi/simple && \python3 -m pip cache purge# Download models and update the configuration file-RUN TORCH_DEVICE_BACKEND_AUTOLOAD=0 /bin/bash -c "mineru-kit models download --tier high -s modelscope"+RUN TORCH_DEVICE_BACKEND_AUTOLOAD=0 /bin/bash -c "mineru-kit models download --tier standard -s modelscope"# Set the entry point to activate the virtual environment and run the command line toolENTRYPOINT ["/bin/bash", "-c", "export MINERU_MODEL_SOURCE=local && exec \"$@\"", "--"]diff --git a/docker/china/ppu.Dockerfile b/docker/china/ppu.Dockerfileindex b3444961..b9160a8b 100644--- a/docker/china/ppu.Dockerfile+++ b/docker/china/ppu.Dockerfile@@ -28,7 +28,7 @@ RUN python3 -m pip install -U pip -i https://mirrors.aliyun.com/pypi/simple && \python3 -m pip cache purge# Download models and update the configuration file-RUN /bin/bash -c "mineru-kit models download --tier high -s modelscope"+RUN /bin/bash -c "mineru-kit models download --tier standard -s modelscope"# Set the entry point to activate the virtual environment and run the command line toolENTRYPOINT ["/bin/bash", "-c", "export MINERU_MODEL_SOURCE=local && exec \"$@\"", "--"]diff --git a/docker/global/Dockerfile b/docker/global/Dockerfileindex ef948f88..8e46f8e8 100644--- a/docker/global/Dockerfile+++ b/docker/global/Dockerfile@@ -21,7 +21,7 @@ RUN python3 -m pip install -U 'mineru[core]>=3.4.0' --break-system-packages && \python3 -m pip cache purge# Download models and update the configuration file-RUN /bin/bash -c "mineru-kit models download --tier high -s huggingface"+RUN /bin/bash -c "mineru-kit models download --tier standard -s huggingface"# Set the entry point to activate the virtual environment and run the command line toolENTRYPOINT ["/bin/bash", "-c", "export MINERU_MODEL_SOURCE=local && exec \"$@\"", "--"]diff --git a/docs/en/quick_start/index.md b/docs/en/quick_start/index.mdindex 45b92daa..b2db63f6 100644--- a/docs/en/quick_start/index.md+++ b/docs/en/quick_start/index.md@@ -53,9 +53,9 @@ A WebUI developed based on Gradio, with a simple interface and only core parsing<tr><th>Accuracy<sup>1</sup></th><td style="text-align:center;">86.47</td>- <td style="text-align:center;">95.39 (high)<br>95.26 (medium)</td>+ <td style="text-align:center;">95.39 (effort=high)<br>95.26 (effort=medium)</td><td style="text-align:center;">95.30</td>- <td style="text-align:center;">95.39 (high)<br>95.26 (medium)</td>+ <td style="text-align:center;">95.39 (effort=high)<br>95.26 (effort=medium)</td><td style="text-align:center;">95.30</td></tr><tr>diff --git a/docs/en/usage/cli_tools.md b/docs/en/usage/cli_tools.mdindex 7863da15..dbc3d2bf 100644--- a/docs/en/usage/cli_tools.md+++ b/docs/en/usage/cli_tools.md@@ -14,14 +14,14 @@ Options:-m, --method [auto|txt|ocr] Parsing method: auto (default), txt, ocr (hybrid* backend only)-b, --backend [hybrid-engine|hybrid-http-client]Parsing backend (default: hybrid-engine)- --effort [low|medium|high] Hybrid parsing effort (default: medium)+ --effort [medium|high|xhigh] Hybrid parsing effort (default: high)-l, --lang [ch|ch_server|korean|ta|te|ka|th|el|arabic|east_slavic|cyrillic|devanagari]Specify document language (improves OCR accuracy, hybrid* backend only)-u, --url TEXT OpenAI-compatible backend URL passed through to the server when using http-client-s, --start INTEGER Starting page number for parsing (0-based)-e, --end INTEGER Ending page number for parsing (0-based)--image-analysis BOOLEAN Enable image/chart analysis for hybrid- backend. Hybrid low and medium efforts+ backend. Hybrid medium and high effortsautomatically disable image/chart analysis(default: enabled)--client-side-output-generation BOOLEANdiff --git a/docs/en/usage/model_source.md b/docs/en/usage/model_source.mdindex 5cdbbd84..1efce583 100644--- a/docs/en/usage/model_source.md+++ b/docs/en/usage/model_source.md@@ -38,13 +38,13 @@ mineru-kit models download --help```or download all built-in model bundles:```bash-mineru-kit models download --tier high+mineru-kit models download --tier standard```> [!NOTE]>- Models are downloaded under `config.model.base_dir`. By default, this is `~/.mineru/models`.>- `mineru-kit models download` does not write model paths to `mineru.json`.>- If you need a custom model directory, set `model.base_dir` in `config.yaml` before downloading.->- If you need to update model files, run `mineru-kit models download --tier high` again. Existing files in the same `model.base_dir` are incrementally reused by the provider SDK.+>- If you need to update model files, run `mineru-kit models download --tier standard` again. Existing files in the same `model.base_dir` are incrementally reused by the provider SDK.>- `mineru-kit models download` must use a remote model source to perform a real download. If your current config sets `model.source: local`, this command temporarily treats it as `auto` for this invocation.>- MinerU marks a fully downloaded repository with an empty `.mineru_complete` file at its root. Repositories downloaded by required paths instead mark each completed model directory. A directory left by an older release or an interrupted download without its marker is checked through an incremental provider download before use. With `model.source: local`, such a directory is reported as not ready instead of accessing the network.diff --git a/docs/next/README.md b/docs/next/README.mdindex 1c27f132..db98b690 100644--- a/docs/next/README.md+++ b/docs/next/README.md@@ -18,7 +18,7 @@3. [端到端工作流](workflows.md): 串起 watch、ingest、parse、cache、search、API、SDK 和 Agent 读取流程。4. [实现计划](implementation-plan.md): 面向编程 Agent 的细粒度任务拆分、边界和验收。5. [系统架构](architecture.md): 再理解本地文档库、服务、任务和存储模型。-6. [解析 Tier](tiers.md): 理解默认选择、`flash`、`medium`、`high`、`xhigh` 的质量、速度、硬件和隐私边界。+6. [解析 Tier](tiers.md): 理解默认选择、`flash`、`basic`、`standard`、`advanced` 的质量、速度、硬件和隐私边界。7. [CLI 规格](cli.md): 理解本地入口和批处理体验。8. [Unified API](api.md): 理解云端和自部署 API 的统一模型。9. [SDK 设计](sdk.md): 理解 Tool SDK 与 Product SDK 的分层。diff --git a/docs/next/api/README.md b/docs/next/api/README.mdindex e2e1cd56..96f70f5b 100644--- a/docs/next/api/README.md+++ b/docs/next/api/README.md@@ -36,7 +36,7 @@ ID 使用 OpenAI 风格的前缀加随机串。官方 API 使用 24 字符 base6所有 endpoint 都带 `/v1` 版本前缀,例如 `GET https://mineru.net/api/v1/health`。-官方远程 API 在相当长时间内只提供 `high` 解析。Local Parse Server 默认监听 loopback;如需对局域网或公网暴露,必须由部署者显式配置 host、防火墙和认证。+官方远程 API 在相当长时间内只提供 `standard` 解析。Local Parse Server 默认监听 loopback;如需对局域网或公网暴露,必须由部署者显式配置 host、防火墙和认证。## Endpoint 地图diff --git a/docs/next/api/examples.md b/docs/next/api/examples.mdindex df490243..ac7bbf44 100644--- a/docs/next/api/examples.md+++ b/docs/next/api/examples.md@@ -42,7 +42,7 @@ RESP=$(curl -s -X POST https://mineru.net/api/v1/parse/jobs \\"files\": [{\"source\": {\"type\":\"file_id\",\"file_id\":\"$FILE_ID\"}}],- \"tier\": \"high\",+ \"tier\": \"standard\",\"output_formats\": [\"markdown\",\"middle_json\",\"zip\"]}")```diff --git a/docs/next/api/health-models.md b/docs/next/api/health-models.mdindex fd77a767..1dbda9a7 100644--- a/docs/next/api/health-models.md+++ b/docs/next/api/health-models.md@@ -135,8 +135,8 @@ GET /v1/tiers HTTP/1.1"object": "list","data": [{- "id": "high",- "description": "High-accuracy VLM-based parsing.",+ "id": "standard",+ "description": "Standard parsing for most documents.","current_model": "MinerU2.5-Pro-2605-1.2B"}]@@ -147,7 +147,7 @@ Tier 对象字段:| 字段 | 类型 | 必带 | 说明 ||------|------|:--:|------|-| `id` | string | 是 | 当前服务提供的真实质量 tier,例如 `medium`、`high` 或 `xhigh`。 |+| `id` | string | 是 | 当前服务提供的真实质量 tier,例如 `basic`、`standard` 或 `advanced`。 || `description` | string | 是 | 档位说明。 || `current_model` | string 或 null | 是 | 当前 tier 背后的模型 ID。 |@@ -182,7 +182,7 @@ Local Parse Server 的 `health` 通常返回:| 字段 | 类型 | 说明 ||------|------|------|| `parser_version` | string | 本地解析器版本。 |-| `models` | object | 各后端健康状态,例如 `{"medium":"ok","high":"ok","xhigh":"missing"}`。 |+| `models` | object | 各解析档位健康状态,例如 `{"basic":"ok","standard":"ok","advanced":"missing"}`。 |这些额外字段只供运维和调试使用,通用客户端不能依赖。@@ -190,13 +190,13 @@ Local Parse Server 的 `health` 通常返回:| 本地 api-server 进程能力 | `/v1/tiers` 应返回 ||-------------------------|-------------------|-| Medium | `medium` |-| High | `high` |-| Extra High | `xhigh` |+| Basic | `basic` |+| Standard | `standard` |+| Advanced | `advanced` || 只有 Flash | 不应把 `flash` 作为用户质量解析 tier;默认选择请求应失败。 |本地或兼容服务应以 `/v1/tiers` 返回值作为能力发现事实。它可以只暴露一个 tier,也可以暴露多个 tier;客户端不应假设具体进程模型。如果本地 server 支持 `flash`,它可以用于显式 `flash`、仅支持 flash tier 的输入归一化、watch 或索引机制,但不应出现在 PDF/image 面向用户质量解析的默认选择候选中。-`mineru.net/api` 在相当长时间内只提供 `high`。远端 `/v1/tiers` 因此应返回 `high`;省略 `tier` 或传 `null` 等价于使用 `high`。+`mineru.net/api` 在相当长时间内只提供 `standard`。远端 `/v1/tiers` 因此应返回 `standard`;省略 `tier` 或传 `null` 等价于使用 `standard`。diff --git a/docs/next/api/parse-jobs.md b/docs/next/api/parse-jobs.mdindex ea1404d2..d18d2e2c 100644--- a/docs/next/api/parse-jobs.md+++ b/docs/next/api/parse-jobs.md@@ -156,7 +156,7 @@ OCR 策略和图片分析能力由 `tier` 与服务端实际引擎自动决定"job_id": "job_01HXYZ123ABCDEF","status": "queued","created_at": "2026-05-21T08:30:00Z",- "tier": "high",+ "tier": "standard","output_formats": ["markdown", "middle_json", "structured_content", "zip"],"access_level": "registered","files": [@@ -199,7 +199,7 @@ OCR 策略和图片分析能力由 `tier` 与服务端实际引擎自动决定"created_at": "2026-05-21T08:30:00Z","started_at": "2026-05-21T08:30:02Z","finished_at": "2026-05-21T08:30:48Z",- "tier": "high",+ "tier": "standard","output_formats": ["markdown", "middle_json", "zip"],"access_level": "registered","progress": {diff --git a/docs/next/api/usage-limits.md b/docs/next/api/usage-limits.mdindex 0f09605e..37e72a14 100644--- a/docs/next/api/usage-limits.md+++ b/docs/next/api/usage-limits.md@@ -16,7 +16,7 @@| 单任务文件数 | 100 | 100 || 并发任务 | 10+ | 10+ || 队列优先级 | 默认 | 优先 |-| `tier` | 当前服务可用 tier。`mineru.net/api` 当前为 `high`;可省略或传 `null` | 当前服务可用 tier。`mineru.net/api` 当前为 `high`;可省略或传 `null` |+| `tier` | 当前服务可用 tier。`mineru.net/api` 当前为 `standard`;可省略或传 `null` | 当前服务可用 tier。`mineru.net/api` 当前为 `standard`;可省略或传 `null` || 高级输出格式 | 不支持 `html`、`latex`、`docx` | 支持 || `callback` | 不支持 | 支持 || 产物保留期 | 30 天 | 30 天 |diff --git a/docs/next/architecture.md b/docs/next/architecture.mdindex 4d76f642..b1a3f71d 100644--- a/docs/next/architecture.md+++ b/docs/next/architecture.md@@ -19,11 +19,11 @@ mineru CLI / MCP Server / MinerU.app- SQLite + FTS5-> local parse-server- 独立进程- - medium / high / xhigh tier+ - basic / standard / advanced tier- HTTP API```-`doclib` 是默认常驻的本地文档库服务,负责文件入库、SHA256 去重、解析任务调度、缓存、搜索、配置和本地 API。`local parse-server` 是可选独立进程,负责加载较重模型并执行 `medium` / `high` / `xhigh` 等质量 tier 解析。+`doclib` 是默认常驻的本地文档库服务,负责文件入库、SHA256 去重、解析任务调度、缓存、搜索、配置和本地 API。`local parse-server` 是可选独立进程,负责加载较重模型并执行 `basic` / `standard` / `advanced` 等质量 tier 解析。Tier 的产品语义以 [解析 Tier](tiers.md) 为准;本文只描述它们在 doclib 和 ParseWorker 中的执行路径。@@ -151,7 +151,7 @@ metadata 更新规则:入库阶段写基础 metadata;解析完成后,只| 字段 | 含义 ||------|------|| `sha256` | 指向文档内容 |-| `tier` | 实体 tier:`flash` / `medium` / `high` / `xhigh`;未指定 tier 应在入队前或执行前解析为实体 tier |+| `tier` | 实体 tier:`flash` / `basic` / `standard` / `advanced`;未指定 tier 应在入队前或执行前解析为实体 tier || `page_range` | 正值页码范围字符串,如 `1~5,46~50` || `status` | `pending` / `parsing` / `done` / `failed` / `superseded` || `priority` | Agent 同步请求高于 watch 后台任务 |@@ -192,7 +192,7 @@ SQLite 运行在 WAL 模式,使用 FTS5 提供搜索能力。每次 DB 操作阶段 2: 解析-> flash: 本地轻量解析-> 默认选择: 通过 parse-server 能力发现解析为质量 tier- -> medium/high/xhigh: local 或 remote parse-server+ -> basic/standard/advanced: local 或 remote parse-server-> 写 parsed artifacts-> 更新 fts_contents-> 更新 parses/docs 状态@@ -200,7 +200,7 @@ SQLite 运行在 WAL 模式,使用 FTS5 提供搜索能力。每次 DB 操作这样用户无需理解“索引”和“解析”两个概念;不同 tier 只是解析深度和执行路径不同。-注意:`flash` 是 watch 自动发现和搜索索引的低成本 tier,不应作为 PDF/image 主动阅读时的默认最终质量。PDF/image 主动阅读未指定 tier 时应使用默认选择策略;有能力发现上下文时按 `high` -> `xhigh` -> `medium` 解析。Office/HTML 的归一规则见 [ADR-0024](decisions/0024-file-type-tier-normalization.md);text 只入库和索引,直接读取源文件。+注意:`flash` 是 watch 自动发现和搜索索引的低成本 tier,不应作为 PDF/image 主动阅读时的默认最终质量。PDF/image 主动阅读未指定 tier 时应使用默认选择策略;有能力发现上下文时按 `standard` -> `advanced` -> `basic` 解析。Office/HTML 的归一规则见 [ADR-0024](decisions/0024-file-type-tier-normalization.md);text 只入库和索引,直接读取源文件。### 4.2 文件发现到入库@@ -272,9 +272,9 @@ ParseWorker 按 `tier`、`privacy` 和 parse-server 健康状态路由:| 条件 | 执行路径 ||------|----------|-| 未指定 tier | PDF/image 通过当前目标 parse-server 能力发现,按 `high` -> `xhigh` -> `medium` 解析;Office/HTML 归一为 `flash`;text 直接读取 |+| 未指定 tier | PDF/image 通过当前目标 parse-server 能力发现,按 `standard` -> `advanced` -> `basic` 解析;Office/HTML 归一为 `flash`;text 直接读取 || `tier=flash` | 直接本地调用轻量 parser,`via=local` |-| `tier=medium/high/xhigh` 且 `privacy=remote` | 优先调用 config 中的远端地址,默认使用 `https://mineru.net/api` |+| `tier=basic/standard/advanced` 且 `privacy=remote` | 优先调用 config 中的远端地址,默认使用 `https://mineru.net/api` || remote 不可用 | 尝试 fallback 到 local parse-server || `privacy=local` 且 local parse-server disabled | 返回 `no_engine` || local parse-server 配置但探活失败 | 返回可重试错误 |@@ -311,13 +311,13 @@ ParseWorker 按 `tier`、`privacy` 和 parse-server 健康状态路由:flash/1~5_1710000000000.json98~102_1710000123000.json- medium/+ basic/1~10_1710001234000.json11~20_1710002234000.jsonimages/ # 仅在解析结果包含必要 sidecar 时存在- high/+ standard/1~20_1710003234000.json- xhigh/+ advanced/1~20_1710004234000.json```@@ -385,7 +385,7 @@ parse-server 配置:| key | 默认值 | 说明 ||-----|--------|------|| `parse_server.local.mode` | `disabled` | `disabled` / `managed` / `self_hosted` |-| `parse_server.local.managed_tier` | `high` | managed 模式启动的 tier;当前允许 `medium` / `high` / `xhigh` |+| `parse_server.local.managed_tier` | `standard` | managed 模式启动的 tier;当前允许 `basic` / `standard` / `advanced` || `parse_server.local.self_hosted_url` | 无 | self-hosted 地址 || `parse_server.remote.url` | `https://mineru.net/api` | 默认远端地址 || `parse_server.remote.api_key` | 无 | 远端 API Key |@@ -406,7 +406,7 @@ Watch、parsing-rules 和 exclude 规则也由 CLI 写入 SQLite。Parsing-rules|------|------|| 纯文本 | 直接读取,无需模型解析 || Office / HTML | 本地 CPU 全量解析 |-| PDF / Image | 按 tier 路由到默认选择 / flash / medium / high / xhigh |+| PDF / Image | 按 tier 路由到默认选择 / flash / basic / standard / advanced |## 9. 错误与恢复diff --git a/docs/next/cli/mineru-e2e-test-cases.md b/docs/next/cli/mineru-e2e-test-cases.mdindex 0e12f681..54cb434e 100644--- a/docs/next/cli/mineru-e2e-test-cases.md+++ b/docs/next/cli/mineru-e2e-test-cases.md@@ -58,10 +58,10 @@- `$MINERU_E2E_FIXTURE_DIR/no-read.pdf`,权限不可读文件;若平台无法稳定制造权限场景,可标记相关用例 BLOCKED。- `$MINERU_E2E_FIXTURE_DIR/output-dir/`,用于输出文件测试的目录。- 测试环境允许启动本地 doclib server。-- 测试环境必须安装 `xhigh` extra,以覆盖本地 `medium`、`high`、`xhigh` quality parse-server;默认 tier 相关用例应验证本地 quality tier 可用,不再按缺少本地 quality tier 的预期失败分支判定。-- MinerU 的公开 tier 只有 `flash`、`medium`、`high`、`xhigh`;默认 quality tier 选择顺序为 `high`、`xhigh`、`medium`,已缓存结果的读取顺序为 `xhigh`、`high`、`medium`、`flash`。-- 显式指定 quality tier 的 remote 请求应按 remote 成功、remote 失败后同 tier local fallback、remote 与 local 均不可用三个分支判定;不得 fallback 到 `flash`。未指定 tier 时需要先从 remote 能力中按 `high`、`xhigh`、`medium` 选择默认值,无法选择时返回 `quality_tier_unavailable`。-- PARSE-013A1 是 remote high 硬性测试,remote parse-server 不可用或不支持 high 均记录为失败。+- 测试环境必须安装 `advanced` extra,以覆盖本地 `basic`、`standard`、`advanced` quality parse-server;默认 tier 相关用例应验证本地 quality tier 可用,不再按缺少本地 quality tier 的预期失败分支判定。+- MinerU 的公开 tier 只有 `flash`、`basic`、`standard`、`advanced`;默认 quality tier 选择顺序为 `standard`、`advanced`、`basic`,已缓存结果的读取顺序为 `advanced`、`standard`、`basic`、`flash`。+- 显式指定 quality tier 的 remote 请求应按 remote 成功、remote 失败后同 tier local fallback、remote 与 local 均不可用三个分支判定;不得 fallback 到 `flash`。未指定 tier 时需要先从 remote 能力中按 `standard`、`advanced`、`basic` 选择默认值,无法选择时返回 `quality_tier_unavailable`。+- PARSE-013A1 是 remote Standard 硬性测试,remote parse-server 不可用或不支持 Standard 均记录为失败。### 2.1 测试 HOME 与隔离配置@@ -88,12 +88,12 @@ rm -rf .venvuv venv .venvsource .venv/bin/activatecd ~/MinerU-Repo-uv pip install ".[xhigh]"+uv pip install ".[advanced]"cd ~/mineru-e2e-testmineru --help```-当前仓库的 `xhigh` extra 会依次包含 `high` 和 `medium` extra,因此上述安装用于覆盖全部本地 quality tier。+当前仓库的 `advanced` extra 会依次包含 `standard` 和 `basic` extra,因此上述安装用于覆盖全部本地 quality tier。安装完成后,`mineru` 应由 `pyproject.toml` 的脚本入口直接提供,不需要配置 shell alias。@@ -101,20 +101,20 @@ mineru --help### 2.2.1 本地模型准备-本地 managed `medium`、`high` 和 `xhigh` 均要求模型文件已下载到 `config.model.base_dir`。模型准备属于测试环境 setup,不属于正式 `mineru` CLI case。+本地 managed `basic`、`standard` 和 `advanced` 均要求模型文件已下载到 `config.model.base_dir`。模型准备属于测试环境 setup,不属于正式 `mineru` CLI case。在执行需要本地 quality tier 的 case 前,测试环境应先准备并验证目标模型:```bashcd ~/mineru-e2e-testsource .venv/bin/activate-mineru-kit models download --tier xhigh-mineru-kit models verify --tier xhigh+mineru-kit models download --tier advanced+mineru-kit models verify --tier advanced```说明:-- `xhigh` 覆盖 `high` 和 `medium` 所需模型。+- `advanced` 覆盖 `standard` 和 `basic` 所需模型。- 如果需要验证模型未准备好的 config 拦截分支,应使用新的隔离 `MINERU_HOME`,或在测试开始前清空该隔离 HOME 下的 `models/` 目录。- 正式 case 执行阶段仍只调用 `mineru ...` 命令。@@ -744,7 +744,7 @@ mineru config show --json命令:```bash-mineru config set parse_server.local.managed_tier high+mineru config set parse_server.local.managed_tier standardmineru config get parse_server.local.managed_tier```@@ -752,14 +752,14 @@ mineru config get parse_server.local.managed_tier- 两条 exit code = 0- get 输出包含 `parse_server.local.managed_tier`-- get 输出包含 `high`+- get 输出包含 `standard`### CONFIG-003A JSON 读取配置命令:```bash-mineru config set parse_server.local.managed_tier high+mineru config set parse_server.local.managed_tier standardmineru config get parse_server.local.managed_tier --json```@@ -769,7 +769,7 @@ mineru config get parse_server.local.managed_tier --json- set 使用普通文本输出;本用例不要求 `config set` 支持 `--json`- get stdout 为可直接解析的 JSON- get JSON 包含 `parse_server.local.managed_tier`-- get JSON 中 value 为 `high`,并且 source 应体现 override 或等价覆盖来源+- get JSON 中 value 为 `standard`,并且 source 应体现 override 或等价覆盖来源### CONFIG-003B managed tier 模型未准备时拒绝配置@@ -787,7 +787,7 @@ mineru config get parse_server.local.managed_tier --json命令:```bash-mineru config set parse_server.local.managed_tier medium+mineru config set parse_server.local.managed_tier basicmineru config get parse_server.local.managed_tier --json```@@ -796,9 +796,9 @@ mineru config get parse_server.local.managed_tier --json- 第一条命令 exit code = 1- 第一条命令输出可读错误- stdout 或 stderr 表明目标 tier 的模型文件未准备完成-- stdout 或 stderr 包含 `mineru-kit models download --tier medium`+- stdout 或 stderr 包含 `mineru-kit models download --tier basic`- 第二条命令 exit code = 0-- get JSON 中 `value` 仍为默认值 `high`,或保持该隔离 HOME 中原有值+- get JSON 中 `value` 仍为默认值 `standard`,或保持该隔离 HOME 中原有值- 不包含 Python traceback### CONFIG-003C managed mode 模型未准备时拒绝启用@@ -821,7 +821,7 @@ mineru config get parse_server.local.mode --json- 第一条命令 exit code = 1- 第一条命令输出可读错误- stdout 或 stderr 表明当前 managed tier 的模型文件未准备完成-- stdout 或 stderr 包含 `mineru-kit models download --tier high`+- stdout 或 stderr 包含 `mineru-kit models download --tier standard`- 第二条命令 exit code = 0- get JSON 中 `value` 仍为默认值 `disabled`,或保持该隔离 HOME 中原有值- 不包含 Python traceback@@ -830,12 +830,12 @@ mineru config get parse_server.local.mode --json前置条件:-- 使用已完成 `mineru-kit models download --tier medium` 和 `mineru-kit models verify --tier medium` 的 `MINERU_HOME`。+- 使用已完成 `mineru-kit models download --tier basic` 和 `mineru-kit models verify --tier basic` 的 `MINERU_HOME`。命令:```bash-mineru config set parse_server.local.managed_tier medium+mineru config set parse_server.local.managed_tier basicmineru config set parse_server.local.mode managedmineru config get parse_server.local.managed_tier --jsonmineru config get parse_server.local.mode --json@@ -844,7 +844,7 @@ mineru config get parse_server.local.mode --json预期:- 四条命令均 exit code = 0-- `managed_tier` get JSON 中 `value = medium`+- `managed_tier` get JSON 中 `value = basic`- `mode` get JSON 中 `value = managed`- 不包含 Python traceback@@ -861,14 +861,14 @@ mineru config get parse_server.local.managed_tier- 两条 exit code = 0- unset 输出包含 `removed` 或 `unchanged`-- get 仍能返回有效配置值,默认值应为 `high` 或等价默认 tier+- get 仍能返回有效配置值,默认值应为 `standard` 或等价默认 tier### CONFIG-004A unset 后 JSON 读取配置命令:```bash-mineru config set parse_server.local.managed_tier high+mineru config set parse_server.local.managed_tier standardmineru config unset parse_server.local.managed_tiermineru config get parse_server.local.managed_tier --json```@@ -878,7 +878,7 @@ mineru config get parse_server.local.managed_tier --json- 三条 exit code = 0- unset 使用普通文本输出;本用例不要求 `config unset` 支持 `--json`- get 输出为可直接解析的 JSON-- unset 后 get 仍能返回有效配置值,默认值应为 `high` 或等价默认 tier+- unset 后 get 仍能返回有效配置值,默认值应为 `standard` 或等价默认 tier### CONFIG-005 exclude-rules@@ -1185,7 +1185,7 @@ mineru list parses --tier flash --status done --json- 三条命令均 exit code = 0,stdout 均为可直接解析的 JSON- show file JSON 中 `watch-doc.pdf` 最终存在 `flash` parse/cache- list parses 中与该文件 sha256 匹配的 parse record 为 `tier = flash`、`privacy = local`、`via = local`-- 未命中 parsing rule 时不自动创建 `medium`、`high`、`xhigh` 或 remote parse record+- 未命中 parsing rule 时不自动创建 `basic`、`standard`、`advanced` 或 remote parse record- watch 结果仅用于发现和索引,不视为默认最终阅读质量- 不包含 Python traceback@@ -1445,7 +1445,7 @@ mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier flash --pages 1~1 --for命令:```bash-mineru config set parse_server.local.managed_tier high+mineru config set parse_server.local.managed_tier standardmineru config set parse_server.local.mode managedmineru server status --jsonmineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --pages 1~1 --force --wait 180 --json@@ -1454,97 +1454,97 @@ mineru show parse <created_parse_id> --json执行说明:-- 重复执行 `mineru server status --json`,直到 local parse-server healthy 且 `supported_tiers` 包含 `high`,再执行 parse。+- 重复执行 `mineru server status --json`,直到 local parse-server healthy 且 `supported_tiers` 包含 `standard`,再执行 parse。- `<created_parse_id>` 从 parse JSON 的 `parse.created_parse_ids[0]` 提取。预期:- 五条命令均 exit code = 0- parse JSON 和 show JSON 均可直接解析-- 默认实际 tier 为 `high`,不为 `flash`-- show JSON 中 `tier = high`、`privacy = local`、`via = local`+- 默认实际 tier 为 `standard`,不为 `flash`+- show JSON 中 `tier = standard`、`privacy = local`、`via = local`- 不允许静默返回 flash 内容- 不包含 Python traceback-### PARSE-007A PDF local medium tier+### PARSE-007A PDF local basic tier命令:```bash-mineru config set parse_server.local.managed_tier medium+mineru config set parse_server.local.managed_tier basicmineru config set parse_server.local.mode managedmineru server status --json-mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier medium --pages 1~1 --force --wait 120 --json+mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier basic --pages 1~1 --force --wait 120 --jsonmineru show parse <created_parse_id> --json```执行说明:-- 重复执行 `mineru server status --json`,直到 local parse-server healthy 且 `supported_tiers` 包含 `medium`,再执行 parse。+- 重复执行 `mineru server status --json`,直到 local parse-server healthy 且 `supported_tiers` 包含 `basic`,再执行 parse。- `<created_parse_id>` 从 parse JSON 的 `parse.created_parse_ids[0]` 提取。预期:- 五条命令均 exit code = 0- parse JSON 和 show JSON 均可直接解析-- `parse.tier = medium`+- `parse.tier = basic`- `parse.status = done`- `content` 不为 null-- show JSON 中 `tier = medium`、`privacy = local`、`via = local`+- show JSON 中 `tier = basic`、`privacy = local`、`via = local`- 不包含 Python traceback-### PARSE-007B PDF local high tier+### PARSE-007B PDF local standard tier命令:```bash-mineru config set parse_server.local.managed_tier high+mineru config set parse_server.local.managed_tier standardmineru config set parse_server.local.mode managedmineru server status --json-mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier high --pages 1~1 --force --wait 180 --json+mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier standard --pages 1~1 --force --wait 180 --jsonmineru show parse <created_parse_id> --json```执行说明:-- 重复执行 `mineru server status --json`,直到 local parse-server healthy 且 `supported_tiers` 包含 `high`,再执行 parse。+- 重复执行 `mineru server status --json`,直到 local parse-server healthy 且 `supported_tiers` 包含 `standard`,再执行 parse。- `<created_parse_id>` 从 parse JSON 的 `parse.created_parse_ids[0]` 提取。预期:- 五条命令均 exit code = 0- parse JSON 和 show JSON 均可直接解析-- `parse.tier = high`+- `parse.tier = standard`- `parse.status = done`- `content` 不为 null-- show JSON 中 `tier = high`、`privacy = local`、`via = local`+- show JSON 中 `tier = standard`、`privacy = local`、`via = local`- 不包含 Python traceback-### PARSE-007C PDF local xhigh tier+### PARSE-007C PDF local advanced tier命令:```bash-mineru config set parse_server.local.managed_tier xhigh+mineru config set parse_server.local.managed_tier advancedmineru config set parse_server.local.mode managedmineru server status --json-mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier xhigh --pages 1~1 --force --wait 300 --json+mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier advanced --pages 1~1 --force --wait 300 --jsonmineru show parse <created_parse_id> --json```执行说明:-- 重复执行 `mineru server status --json`,直到 local parse-server healthy 且 `supported_tiers` 包含 `xhigh`,再执行 parse。+- 重复执行 `mineru server status --json`,直到 local parse-server healthy 且 `supported_tiers` 包含 `advanced`,再执行 parse。- `<created_parse_id>` 从 parse JSON 的 `parse.created_parse_ids[0]` 提取。预期:- 五条命令均 exit code = 0- parse JSON 和 show JSON 均可直接解析-- `parse.tier = xhigh`+- `parse.tier = advanced`- `parse.status = done`- `content` 不为 null-- show JSON 中 `tier = xhigh`、`privacy = local`、`via = local`+- show JSON 中 `tier = advanced`、`privacy = local`、`via = local`- 不包含 Python traceback### PARSE-007D 旧 tier 名称不可用@@ -1559,7 +1559,7 @@ mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier pro --pages 1~1预期:- 两条命令均 exit code != 0-- 输出明确说明 tier 取值无效,并列出或体现 `flash`、`medium`、`high`、`xhigh` 中的合法值+- 输出明确说明 tier 取值无效,并列出或体现 `flash`、`basic`、`standard`、`advanced` 中的合法值- 不启动 parse,不生成新的 parse record- 不包含 Python traceback@@ -1683,7 +1683,7 @@ mineru show parse <created_parse_id> --json- 如果 remote parse-server 暴露 quality tier:- parse 和 show 均 exit code = 0,stdout 均为可直接解析的 JSON- - 默认 tier 按 `high`、`xhigh`、`medium` 的顺序选择第一个受 remote 支持的 tier+ - 默认 tier 按 `standard`、`advanced`、`basic` 的顺序选择第一个受 remote 支持的 tier- show JSON 中 `privacy = remote`、`via = remote`- 如果 remote parse-server 未暴露任何 quality tier:- exit code != 0@@ -1692,12 +1692,12 @@ mineru show parse <created_parse_id> --json- 不允许 fallback 到 `flash`- 不包含 Python traceback-### PARSE-013A1 PDF remote high tier+### PARSE-013A1 PDF remote standard tier命令:```bash-mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier high --remote --pages 1~1 --force --wait 180 --json+mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier standard --remote --pages 1~1 --force --wait 180 --jsonmineru show parse <created_parse_id> --json```@@ -1708,10 +1708,10 @@ mineru show parse <created_parse_id> --json预期:- 两条命令均 exit code = 0,stdout 均为可直接解析的 JSON-- `parse.tier = high`-- show JSON 中 `tier = high`、`privacy = remote`、`via = remote`-- remote 不可用、remote 不支持 high、或实际 `via = local` 均记录为失败-- 不允许 fallback 到 local high、其它 tier 或 flash+- `parse.tier = standard`+- show JSON 中 `tier = standard`、`privacy = remote`、`via = remote`+- remote 不可用、remote 不支持 Standard、或实际 `via = local` 均记录为失败+- 不允许 fallback 到 local standard、其它 tier 或 flash- 不包含 Python traceback### PARSE-013B remote no-wait@@ -1719,7 +1719,7 @@ mineru show parse <created_parse_id> --json命令:```bash-mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier high --remote --pages 1~1 --force --no-wait --json+mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier standard --remote --pages 1~1 --force --no-wait --jsonmineru show parse <created_parse_id> --json```@@ -1731,7 +1731,7 @@ mineru show parse <created_parse_id> --json预期分支:- 第一条 exit code = 0,stdout 为可直接解析的 JSON,不长时间阻塞-- `parse.tier = high`、`parse.created_parse_ids` 非空,状态为 pending、parsing 或 done+- `parse.tier = standard`、`parse.created_parse_ids` 非空,状态为 pending、parsing 或 done- 最终 done 时,show JSON 中 `privacy = remote`,`via` 为 `remote` 或同 tier fallback 的 `local`- 最终 failed 时,show JSON 中 `error_code` 为 `parse_server_unavailable`、`engine_unavailable`、`tier_mismatch` 或其它结构化执行错误码- 不允许 fallback 到 `flash` 或其它 tier@@ -1742,7 +1742,7 @@ mineru show parse <created_parse_id> --json命令:```bash-mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier high --remote --pages 1~1 --force --wait 180 --json+mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier standard --remote --pages 1~1 --force --wait 180 --jsonmineru show parse <created_parse_id> --json```@@ -1756,9 +1756,9 @@ mineru show parse <created_parse_id> --json- parse 和 show 均 exit code = 0,stdout 均为可直接解析的 JSON- 不复用旧的 done batch 作为唯一依据,JSON 中应体现新 parse 或 force 后结果- show JSON 中 `privacy = remote`- - remote 成功时 `via = remote`;remote 不可用但 local high 可用时允许 `via = local`+ - remote 成功时 `via = remote`;remote 不可用但 local Standard 可用时允许 `via = local`- 后续普通 remote parse 不因 force 损坏缓存-- 如果 remote 不支持 high,或 remote 和 local high 均不可用:+- 如果 remote 不支持 Standard,或 remote 和 local Standard 均不可用:- exit code != 0- stdout 为可直接解析的 JSON error- 依据 `error.code` 判定,不依赖 `error.message` 文案@@ -1770,7 +1770,7 @@ mineru show parse <created_parse_id> --json命令:```bash-mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier high --remote --pages 1~1 --force --wait 180 --output "$MINERU_E2E_FIXTURE_DIR/output-dir/remote-output.md"+mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier standard --remote --pages 1~1 --force --wait 180 --output "$MINERU_E2E_FIXTURE_DIR/output-dir/remote-output.md"```预期分支:@@ -1780,7 +1780,7 @@ mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier high --remote --pages 1- 输出包含 `Written to` 或等价成功信息- stdout 不大量打印完整文档内容- 输出路径为命令指定路径-- 如果 remote 和 local high 均不可用:+- 如果 remote 和 local Standard 均不可用:- exit code != 0- 不创建空的成功输出文件- 不允许 fallback 到 `flash` 或其它 tier@@ -1792,14 +1792,14 @@ mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier high --remote --pages 1```bashmineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier flash --pages 1~1 --wait 60 --json-mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier high --remote --pages 1~1 --force --wait 180 --json+mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier standard --remote --pages 1~1 --force --wait 180 --jsonmineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier flash --pages 1~1 --wait 60 --json```预期:- 第一条和第三条 local flash 命令 exit code = 0,tier = flash-- 第二条按 PARSE-013C 的 remote/local fallback 分支判定,成功时 tier 必须为 high+- 第二条按 PARSE-013C 的 remote/local fallback 分支判定,成功时 tier 必须为 standard- remote 成功或失败均不得污染 local flash 缓存- 第三条不应因为第二条 remote 失败而失败@@ -1808,7 +1808,7 @@ mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.pdf" --tier flash --pages 1~1 --wai命令:```bash-mineru config parsing-rules add "*/sample.pdf" --tier high --remote --pages 1~1 --name e2e-remote-rule --json+mineru config parsing-rules add "*/sample.pdf" --tier standard --remote --pages 1~1 --name e2e-remote-rule --jsonmineru watch add "$MINERU_E2E_FIXTURE_DIR" --label e2e-remote-rule-watch --jsonmineru watch rescan "$MINERU_E2E_FIXTURE_DIR" --wait 60 --jsonmineru list parses --limit 20 --json@@ -1825,9 +1825,9 @@ mineru config parsing-rules remove <rule_id>- add/watch/rescan/list/remove exit code = 0,JSON 可解析- parsing-rule 的 `remote` 字段用于规则命中后的自动解析策略,尤其是 watch 自动触发/后台解析;不要求用户主动 `mineru parse <path>` 在未传 `--remote` 时也按该规则上传远端-- 规则命中的 parse record 应为 `tier = high`、`privacy = remote`+- 规则命中的 parse record 应为 `tier = standard`、`privacy = remote`- remote 成功时 parse record 的 `via = remote`-- remote 不可用但 local high 可用时允许 `via = local`;remote 和 local high 均不可用时 parse record 应为 failed,并记录结构化 `error_code`+- remote 不可用但 local Standard 可用时允许 `via = local`;remote 和 local Standard 均不可用时 parse record 应为 failed,并记录结构化 `error_code`- 不允许规则任务 fallback 到 `flash` 或其它 tier- remove 后规则不再影响后续 watch 自动解析@@ -1836,8 +1836,8 @@ mineru config parsing-rules remove <rule_id>命令:```bash-mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.docx" --tier high --wait 60 --json-mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.docx" --tier high --remote --wait 60 --json+mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.docx" --tier standard --wait 60 --json+mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.docx" --tier standard --remote --wait 60 --json```预期:@@ -1845,7 +1845,7 @@ mineru parse "$MINERU_E2E_FIXTURE_DIR/sample.docx" --tier high --remote --wait 6- 两条命令均 exit code != 0,stdout 均为可直接解析的 JSON error- 第一条 `error.code = tier_unsupported_for_file_type`,`error.param = tier`- 第二条 `error.code = remote_unsupported_for_file_type`,`error.param = remote`-- Office 文件只允许 local `flash`,不创建 high/remote parse record+- Office 文件只允许 local `flash`,不创建 Standard/remote parse record- 不包含 Python traceback### PARSE-014 非法 format@@ -1920,7 +1920,7 @@ mineru read "doc:<short_id>/tier:flash/page:1" --json### READ-002A 无 tier locator 读取最高缓存-前置: PARSE-007A、PARSE-007B、PARSE-007C 已为同一 `sample.pdf` 的第 1 页生成 `medium`、`high`、`xhigh` 三种 done 缓存。+前置: PARSE-007A、PARSE-007B、PARSE-007C 已为同一 `sample.pdf` 的第 1 页生成 `basic`、`standard`、`advanced` 三种 done 缓存。命令模板:@@ -1931,7 +1931,7 @@ mineru read "doc:<short_id>" --json预期:- exit code = 0,stdout 为可直接解析的 JSON-- 返回 `tier = xhigh`+- 返回 `tier = advanced`- `request_scope.locator` 体现输入 locator 或规范化 locator- 命令只读取最高已缓存结果,不创建新的 parse record- 不包含 Python traceback@@ -3390,7 +3390,7 @@ mineru server start命令:```bash-mineru config set parse_server.local.managed_tier high+mineru config set parse_server.local.managed_tier standardmineru server restartmineru config get parse_server.local.managed_tier --jsonmineru config unset parse_server.local.managed_tier@@ -3399,7 +3399,7 @@ mineru config unset parse_server.local.managed_tier预期:- 四条 exit code = 0-- restart 后 get JSON 仍体现 `high`,并且 source 应体现 override 或等价覆盖来源+- restart 后 get JSON 仍体现 `standard`,并且 source 应体现 override 或等价覆盖来源- unset 后恢复默认配置来源- 不包含 Python traceback@@ -3644,9 +3644,9 @@ mineru server start- PARSE-006A force 默认输出不打印过程 status- PARSE-006B verbose 输出允许过程 status- PARSE-007 默认 tier 行为-- PARSE-007A PDF local medium tier-- PARSE-007B PDF local high tier-- PARSE-007C PDF local xhigh tier+- PARSE-007A PDF local basic tier+- PARSE-007B PDF local standard tier+- PARSE-007C PDF local advanced tier- PARSE-007D 旧 tier 名称不可用- PARSE-008 输出到文件- PARSE-010 limit 截断与 next_request@@ -3654,7 +3654,7 @@ mineru server start- PARSE-012 no-marker- PARSE-013 remote 不接受 flash tier- PARSE-013A remote 默认 tier-- PARSE-013A1 PDF remote high tier+- PARSE-013A1 PDF remote standard tier- PARSE-013B remote no-wait- PARSE-013C remote force- PARSE-013D remote output@@ -3669,7 +3669,7 @@ mineru server start- remote 路由必须通过 `show parse --json` 的 `privacy`、`via`、`tier` 验证,不能从 parse JSON 中推断。- 显式 quality tier 的 remote 请求在 remote 不可用时允许同 tier local fallback;未指定 tier 且 remote 无 quality tier 时应返回 `quality_tier_unavailable`。- remote/local fallback 不得改变 tier,也不得降级到 `flash`。-- PARSE-013A1 是 remote high 硬性测试;remote 不可用或不支持 high 均记录为失败,不能静默 fallback 到 local 或其它 tier。+- PARSE-013A1 是 remote standard 硬性测试;remote 不可用或不支持 standard 均记录为失败,不能静默 fallback 到 local 或其它 tier。- force/cache/no-wait 用例必须记录 parse id/status 是否符合预期。### COVERAGE-007 read 边界、续读、image 与 context 补充@@ -3859,7 +3859,7 @@ Blocked:Environment:- mineru version: <如果 help/status 输出能看到则填写,否则 unknown>- fixture dir: ...-- quality tier available: medium/high/xhigh-- remote high available: yes+- quality tier available: basic/standard/advanced+- remote Standard available: yes- pdf fixture source: ...```diff --git a/docs/next/cli/mineru-kit-api-server.md b/docs/next/cli/mineru-kit-api-server.mdindex b3aa05f3..b28b6e59 100644--- a/docs/next/cli/mineru-kit-api-server.md+++ b/docs/next/cli/mineru-kit-api-server.md@@ -8,7 +8,7 @@## 1. 定位-`mineru-kit api-server` 是正式的 self-hosted parse-server 启动入口。当前一个进程可以通过重复 `--tier` 暴露一个或多个 tier;不传 `--tier` 时暴露 `flash`、`medium`、`high`、`xhigh`。+`mineru-kit api-server` 是正式的 self-hosted parse-server 启动入口。当前一个进程可以通过重复 `--tier` 暴露一个或多个 tier;不传 `--tier` 时暴露 `flash`、`basic`、`standard`、`advanced`。`mineru doclib` 可以通过 HTTP 调用它执行解析任务。@@ -45,11 +45,11 @@ api-server 必须提供能力发现接口,让 doclib 或客户端知道当前| api-server 启动 tier | 请求未指定 tier 时 ||---------------------|--------------------|-| 包含 `high` | `high` |-| 不包含 `high`,但包含 `xhigh` | `xhigh` |-| 不包含 `high` / `xhigh`,但包含 `medium` | `medium` |+| 包含 `standard` | `standard` |+| 不包含 `standard`,但包含 `advanced` | `advanced` |+| 不包含 `standard` / `advanced`,但包含 `basic` | `basic` || 只包含 `flash` | 返回 `quality_tier_unavailable`,除非请求显式传 `tier=flash` |-| 未传 `--tier` | 暴露 `flash`、`medium`、`high`、`xhigh`,默认 `high` |+| 未传 `--tier` | 暴露 `flash`、`basic`、`standard`、`advanced`,默认 `standard` |因此,如果只以 `--tier flash` 启动裸 api-server,请求未指定 tier 时不应静默使用 `flash`。需要 `flash` 时调用方必须显式传 `tier=flash`;非 PDF/image 文件的批量归一规则见 [ADR-0024](../decisions/0024-file-type-tier-normalization.md)。@@ -69,13 +69,13 @@ managed 是生命周期管理方式,不是用户直接执行的命令模式。api-server 启动时可使用 `--tier` 限定暴露档位;该选项可重复:```bash-mineru-kit api-server --tier medium --port 16580-mineru-kit api-server --tier high --port 15982-mineru-kit api-server --tier medium --tier high --port 8000-mineru-kit api-server --tier high --language en --ocr-mode ocr --disable-image-analysis+mineru-kit api-server --tier basic --port 16580+mineru-kit api-server --tier standard --port 15982+mineru-kit api-server --tier basic --tier standard --port 8000+mineru-kit api-server --tier standard --language en --ocr-mode ocr --disable-image-analysis```-未传 `--tier` 时暴露 `flash`、`medium`、`high`、`xhigh`;PDF/image 请求未指定 tier 时默认 `high`。+未传 `--tier` 时暴露 `flash`、`basic`、`standard`、`advanced`;PDF/image 请求未指定 tier 时默认 `standard`。启动完成后,HTTP API 不暴露 backend。`GET /v1/tiers` 也不新增 backend 字段;调用方如需推断实现,只能从 `current_model` 做弱推断。diff --git a/docs/next/cli/mineru-kit-models.md b/docs/next/cli/mineru-kit-models.mdindex f0af1106..f5cb413d 100644--- a/docs/next/cli/mineru-kit-models.md+++ b/docs/next/cli/mineru-kit-models.md@@ -55,14 +55,14 @@ model:```bashmineru-kit models download <repo> [flags]-mineru-kit models download --tier <flash|medium|high|xhigh> [flags]+mineru-kit models download --tier <flash|basic|standard|advanced> [flags]```参数:| Flag | 简写 | 类型 | 默认 | 说明 ||------|------|------|------|------|-| `--tier` | - | `flash \| medium \| high \| xhigh` | - | 按 tier 下载所需模型 |+| `--tier` | - | `flash \| basic \| standard \| advanced` | - | 按 tier 下载所需模型 || `--source` | `-s` | `auto \| huggingface \| modelscope` | 配置值 | 本次下载源 || `--verbose` | `-v` | bool | false | 输出详细路径 |@@ -83,15 +83,15 @@ mineru-kit models download --tier <flash|medium|high|xhigh> [flags]Tier 到 repo 的映射:- `flash`: 不需要模型-- `medium`: `PDF-Extract-Kit-1.0`-- `high`: `PDF-Extract-Kit-1.0` + `MinerU2.5-Pro-2605-1.2B`-- `xhigh`: `PDF-Extract-Kit-1.0` + `MinerU2.5-Pro-2605-1.2B`+- `basic`: `PDF-Extract-Kit-1.0`+- `standard`: `PDF-Extract-Kit-1.0` + `MinerU2.5-Pro-2605-1.2B`+- `advanced`: `PDF-Extract-Kit-1.0` + `MinerU2.5-Pro-2605-1.2B`示例:```bash-mineru-kit models download --tier medium-mineru-kit models download --tier high --source modelscope+mineru-kit models download --tier basic+mineru-kit models download --tier standard --source modelscopemineru-kit models download PDF-Extract-Kit-1.0mineru-kit models download MinerU2.5-Pro-2605-1.2B --source huggingface```@@ -122,7 +122,7 @@ mineru-kit models show```bashmineru-kit models verifymineru-kit models verify <repo>-mineru-kit models verify --tier <flash|medium|high|xhigh>+mineru-kit models verify --tier <flash|basic|standard|advanced>```规则:@@ -138,7 +138,7 @@ mineru-kit models verify --tier <flash|medium|high|xhigh>```bashmineru-kit models verifymineru-kit models verify PDF-Extract-Kit-1.0-mineru-kit models verify --tier high+mineru-kit models verify --tier standard```## 4. 相关文档diff --git a/docs/next/cli/mineru-kit-parse.md b/docs/next/cli/mineru-kit-parse.mdindex 71563edb..6c549f15 100644--- a/docs/next/cli/mineru-kit-parse.md+++ b/docs/next/cli/mineru-kit-parse.md@@ -113,7 +113,7 @@ local 模式支持:2. 可以只传 `--backend`3. 可以同时传 `--tier` 和 `--backend`4. 如果二者不兼容,直接报错-5. `--tier` 与 `--backend` 都不传时,PDF/image 当前默认为 `high`+5. `--tier` 与 `--backend` 都不传时,PDF/image 当前默认为 `standard`6. 单文件 Office/HTML 未指定 tier 时归一为 `flash`;显式指定质量 tier 时报错7. 多文件或目录输入按批量规则处理,Office/HTML 即使遇到质量 tier 也归一为 `flash`8. PDF/image 的 `flash` 只能显式指定:@@ -133,7 +133,7 @@ remote 模式通过以下参数进入:1. `--remote` 与 `--remote-url` 互斥2. remote 模式允许传 `--tier`3. remote 模式禁止传 `--backend`-4. remote 模式未传 `--tier` 时,PDF/image 使用目标服务的默认选择策略,按 `high` -> `xhigh` -> `medium` 选择+4. remote 模式未传 `--tier` 时,PDF/image 使用目标服务的默认选择策略,按 `standard` -> `advanced` -> `basic` 选择5. remote 模式传了 `--tier` 时:- 服务提供该 tier,则按该 tier 解析- 服务不提供该 tier,则报错diff --git a/docs/next/cli/mineru-kit.md b/docs/next/cli/mineru-kit.mdindex 7cb44d49..bd673e01 100644--- a/docs/next/cli/mineru-kit.md+++ b/docs/next/cli/mineru-kit.md@@ -49,7 +49,7 @@- 只支持文件和目录输入,不支持 stdin、路径列表、URL 输入和递归目录。- `--output` 必填。-- local 模式支持 `tier` 与 `backend`;PDF/image 二者都不传时当前默认使用 `high` 对应 backend,仅支持 flash tier 的输入按 ADR-0024 归一。+- local 模式支持 `tier` 与 `backend`;PDF/image 二者都不传时当前默认使用 `standard` 对应 backend,仅支持 flash tier 的输入按 ADR-0024 归一。- remote 模式支持 `--remote` / `--remote-url` / `--api-key`,允许传 `--tier`,但禁止传 `--backend`;`mineru-kit parse` 允许 remote 处理非 PDF/image 输入。详细命令契约见 [ADR-0016](../decisions/0016-mineru-kit-parse-command.md)。diff --git a/docs/next/cli/mineru-library.md b/docs/next/cli/mineru-library.mdindex f06416d8..ac09ae14 100644--- a/docs/next/cli/mineru-library.md+++ b/docs/next/cli/mineru-library.md@@ -18,8 +18,8 @@```bashmineru search "keyword"-mineru search "keyword" --tier medium-mineru search "keyword" --min-tier medium --type pdf+mineru search "keyword" --tier basic+mineru search "keyword" --min-tier basic --type pdf```行为:@@ -127,7 +127,7 @@ JSON 输出至少包含:```json[{"tier": "flash", "page_range": "1~20"},- {"tier": "medium", "page_range": "1~5,18~20"}+ {"tier": "basic", "page_range": "1~5,18~20"}]```@@ -135,7 +135,7 @@ JSON 输出至少包含:```json[- {"id": 123, "tier": "high", "page_range": "6~17", "status": "parsing"}+ {"id": 123, "tier": "standard", "page_range": "6~17", "status": "parsing"}]```@@ -336,13 +336,13 @@ parsing-rules 用于按路径规则指定自动解析策略。示例:```bash-mineru config parsing-rules add "*/论文/*" --tier medium --pages all-mineru config parsing-rules add "*/合同/*" --tier high --remote+mineru config parsing-rules add "*/论文/*" --tier basic --pages all+mineru config parsing-rules add "*/合同/*" --tier standard --remote```parsing-rule 的 `tier` 和 `remote` 只适用于 PDF 和 image。Office 和 HTML 命中规则时忽略 `tier` 和 `remote`,按 `flash` 解析,并且 parse row 记录为 `flash`;text 只入库和索引,不创建 parse row。-PDF/image 命中规则时,系统必须检查本地或远端能力是否支持对应 tier。rule 未指定 tier 时,按 `high` -> `xhigh` -> `medium` -> `flash` 选择可用 tier,并记录实际 tier。完整文件类型归一规则见 [ADR-0024](../decisions/0024-file-type-tier-normalization.md)。+PDF/image 命中规则时,系统必须检查本地或远端能力是否支持对应 tier。rule 未指定 tier 时,按 `standard` -> `advanced` -> `basic` -> `flash` 选择可用 tier,并记录实际 tier。完整文件类型归一规则见 [ADR-0024](../decisions/0024-file-type-tier-normalization.md)。## 已收敛规则diff --git a/docs/next/cli/mineru-parse.md b/docs/next/cli/mineru-parse.mdindex a9f6ff1a..0a1e934f 100644--- a/docs/next/cli/mineru-parse.md+++ b/docs/next/cli/mineru-parse.md@@ -48,7 +48,7 @@ mineru parse <file> [flags]| Flag | 类型 | 默认 | 说明 ||------|------|------|------|-| `--tier` | `flash` / `medium` / `high` / `xhigh` | 不传 | 解析 tier;省略时由服务端决定;语义见 [解析 Tier](../tiers.md) |+| `--tier` | `flash` / `basic` / `standard` / `advanced` | 不传 | 解析 tier;省略时由服务端决定;语义见 [解析 Tier](../tiers.md) || `-p, --pages` | range | 不传 | 分页文档的页码范围;`all` 表示全部页 || `--after` | cursor | 不传 | 从服务端返回的 cursor 继续读取 || `--limit` | int | `30000` | STDOUT 内容软字符上限 |@@ -74,7 +74,7 @@ mineru parse <file> [flags]`mineru parse` 未指定 `--tier` 时使用默认选择策略。-PDF/image 的默认选择策略通过当前目标 parse-server 的能力发现,按 [解析 Tier](../tiers.md) 定义的 `high` -> `xhigh` -> `medium` 顺序选择。如果找不到可用质量 tier,返回可解释错误。Office/HTML 归一为 `flash` 语义,详见 [ADR-0024](../decisions/0024-file-type-tier-normalization.md)。文本文件不创建 parse 任务或 Middle JSON,显式请求返回 `parse_not_required`。+PDF/image 的默认选择策略通过当前目标 parse-server 的能力发现,按 [解析 Tier](../tiers.md) 定义的 `standard` -> `advanced` -> `basic` 顺序选择。如果找不到可用质量 tier,返回可解释错误。Office/HTML 归一为 `flash` 语义,详见 [ADR-0024](../decisions/0024-file-type-tier-normalization.md)。文本文件不创建 parse 任务或 Middle JSON,显式请求返回 `parse_not_required`。`flash` 只有在用户显式指定 `--tier flash` 时才作为最终解析结果返回。@@ -153,7 +153,7 @@ Markdown 中的可视图片使用 `mineru read` 可读取的 block locator,不- `--no-wait`:立即返回任务状态。- 超过等待时间:返回可继续查询的状态,而不是丢失任务。-缓存实体应落到解析后的实体 tier,例如 `medium`、`high` 或 `xhigh`。+缓存实体应落到解析后的实体 tier,例如 `basic`、`standard` 或 `advanced`。## 未决问题diff --git a/docs/next/cli/mineru-read.md b/docs/next/cli/mineru-read.mdindex 0615541a..4dd01b43 100644--- a/docs/next/cli/mineru-read.md+++ b/docs/next/cli/mineru-read.md@@ -48,11 +48,11 @@ doc:{short_id}/tier:{tier}/page:{page_no}/block:{block_no}/char:{offset}规则:- `short_id` 是 doclib 为文档生成的稳定短 ID。-- `tier` 取值为 `flash`、`medium`、`high`、`xhigh`。+- `tier` 取值为 `flash`、`basic`、`standard`、`advanced`。- `page_no` 和 `block_no` 使用 1-based 编号。- `char:{offset}` 使用 block 渲染文本内的 0-based 字符 offset。-当只给出 `doc:{short_id}` 时,系统不会创建新解析,而是在当前已缓存的非 `flash` 质量 tier 中选择最高质量结果,顺序为 `xhigh` -> `high` -> `medium`。如果不存在非 `flash` 质量 tier 结果,则返回错误,不静默降级到 `flash`。+当只给出 `doc:{short_id}` 时,系统不会创建新解析,而是在当前已缓存的非 `flash` 质量 tier 中选择最高质量结果,顺序为 `advanced` -> `standard` -> `basic`。如果不存在非 `flash` 质量 tier 结果,则返回错误,不静默降级到 `flash`。## 4. 核心参数@@ -89,7 +89,7 @@ doc:{short_id}/tier:{tier}/page:{page_no}/block:{block_no}/char:{offset}Markdown 继续优先输出 table、chart 和 formula 的结构化内容。需要输出图片时,doclib 使用可读取的 block locator,不暴露 Middle JSON 内部的 `image_path`:```markdown-+![Table block]()```@@ -155,7 +155,7 @@ locator-first 读取时:普通 markdown 输出中,如果还有下一段可读内容,CLI 会输出:```text-<!-- Next: mineru read doc:ab12cd3/tier:medium/page:5 -->+<!-- Next: mineru read doc:ab12cd3/tier:basic/page:5 -->````--json` 时,通过 `next_request.locator` 表示下一次建议读取的位置。diff --git a/docs/next/cli/mineru.md b/docs/next/cli/mineru.mdindex b7d0fca7..fcc5e88c 100644--- a/docs/next/cli/mineru.md+++ b/docs/next/cli/mineru.md@@ -75,7 +75,7 @@-> 输出到 STDOUT 或文件```-纯文本文件可以直接读取;Office 和 HTML 通常可本地 CPU 解析;PDF 和图片按 tier 路由到默认选择、`flash`、`medium`、`high` 或 `xhigh`。+纯文本文件可以直接读取;Office 和 HTML 通常可本地 CPU 解析;PDF 和图片按 tier 路由到默认选择、`flash`、`basic`、`standard` 或 `advanced`。## 5. parse 与 read@@ -93,7 +93,7 @@ read(locator) = read existing parsed content by stable locator1. `mineru parse report.pdf`2. 从输出或 JSON 响应中拿到后续 locator-3. `mineru read doc:ab12cd3/tier:medium/page:11`+3. `mineru read doc:ab12cd3/tier:basic/page:11`## 6. 与 mineru-kit 的关系diff --git a/docs/next/config.md b/docs/next/config.mdindex 6d12ab29..6f8be2d9 100644--- a/docs/next/config.md+++ b/docs/next/config.md@@ -91,7 +91,7 @@ MinerU 有两类配置:| `watches` 表 | watch 目录、可插拔设备状态 | 表结构 | 文件发现配置 || `exclude_rules` 表 | exclude | 表结构 | 路径排除规则 || `parsing_rules` 表 | parsing-rules | 表结构 | 路径解析规则 |-| 当前命令显式参数 | `--tier high`、`--remote` | 不持久化 | 当前请求覆盖 |+| 当前命令显式参数 | `--tier standard`、`--remote` | 不持久化 | 当前请求覆盖 || 环境变量 | `MINERU_API_KEY` | 不持久化 | 临时凭证或 CI 覆盖 || SDK client 参数 | `base_url`、`api_key` | 调用方决定 | 当前 client 实例 |@@ -119,19 +119,19 @@ SDK client 显式参数属于当前调用方传入的请求上下文;当它最| key | 默认值 | 说明 ||-----|--------|------|| `parse_server.local.mode` | `disabled` | 本地 parse-server 模式 |-| `parse_server.local.managed_tier` | `high` | managed 模式启动 tier |+| `parse_server.local.managed_tier` | `standard` | managed 模式启动 tier || `parse_server.remote.url` | `https://mineru.net/api` | 默认远端 API 地址 |## 5. Parse-server 配置-parse-server 是 `medium` / `high` / `xhigh` 等质量 tier 的解析能力来源。它可以是本地独立进程,也可以是远端 `mineru.net/api`。+parse-server 是 `basic` / `standard` / `advanced` 等质量 tier 的解析能力来源。它可以是本地独立进程,也可以是远端 `mineru.net/api`。### 5.1 Local parse-server| key | 默认值 | 说明 ||-----|--------|------|| `parse_server.local.mode` | `disabled` | `disabled` / `managed` / `self_hosted` |-| `parse_server.local.managed_tier` | `high` | managed 模式启动的 tier |+| `parse_server.local.managed_tier` | `standard` | managed 模式启动的 tier || `parse_server.local.self_hosted_url` | 无 | self-hosted parse-server URL || `parse_server.local.self_hosted_api_key` | 无 | self-hosted API Key,可选 |@@ -188,7 +188,7 @@ API Key 读取优先级:```bashmineru config parse-server local.mode managed-mineru config parse-server local.managed-tier medium+mineru config parse-server local.managed-tier basicmineru config parse-server remote.api-key sk-...```@@ -228,15 +228,15 @@ Watch 用于自动发现文件和建立搜索索引。Parsing-rules 通过路径 glob 指定自动解析策略。```bash-mineru config parsing-rules add "*/论文/*" --tier medium --pages all-mineru config parsing-rules add "*/合同/*" --tier high --remote+mineru config parsing-rules add "*/论文/*" --tier basic --pages all+mineru config parsing-rules add "*/合同/*" --tier standard --remote```约束:- 对 PDF/image,规则必须显式指定 remote,才允许上传远端。- 对 PDF/image,规则命中的 tier 必须经过能力检查。-- 对 PDF/image,规则未指定 tier 时按 `high` -> `xhigh` -> `medium` -> `flash` 选择,并只记录实际使用的实体 tier。+- 对 PDF/image,规则未指定 tier 时按 `standard` -> `advanced` -> `basic` -> `flash` 选择,并只记录实际使用的实体 tier。- 对 Office/HTML,parsing-rule 的 tier 和 remote 不生效,实际按 `flash` 记录;text 只入库和索引,不创建 parse row。- 完整归一规则见 [ADR-0024](decisions/0024-file-type-tier-normalization.md)。diff --git a/docs/next/decisions/0003-parse-request-wait-batches.md b/docs/next/decisions/0003-parse-request-wait-batches.mdindex 101d7acf..0aed2ab9 100644--- a/docs/next/decisions/0003-parse-request-wait-batches.md+++ b/docs/next/decisions/0003-parse-request-wait-batches.md@@ -26,7 +26,7 @@ parse 请求返回本次请求需要等待的 batch 集合,而不是单个 `pa```json{"sha256": "...",- "tier": "medium",+ "tier": "basic","page_range": "1~10","status": "pending","wait_parse_ids": [12, 13],@@ -69,8 +69,8 @@ GET /parses?ids=12,13```json{"parses": [- {"id": 12, "sha256": "...", "tier": "medium", "page_range": "1~5", "status": "done"},- {"id": 13, "sha256": "...", "tier": "medium", "page_range": "6~10", "status": "parsing"}+ {"id": 12, "sha256": "...", "tier": "basic", "page_range": "1~5", "status": "done"},+ {"id": 13, "sha256": "...", "tier": "basic", "page_range": "6~10", "status": "parsing"}]}```diff --git a/docs/next/decisions/0004-doclib-http-api-resources.md b/docs/next/decisions/0004-doclib-http-api-resources.mdindex 98447980..103fd9f5 100644--- a/docs/next/decisions/0004-doclib-http-api-resources.md+++ b/docs/next/decisions/0004-doclib-http-api-resources.md@@ -50,7 +50,7 @@ POST /invalidate```json{"sha256": "...",- "tier": "medium",+ "tier": "basic","page_range": "1~10","status": "pending","cache_hit": false,@@ -64,9 +64,9 @@ POST /invalidate```httpGET /parses?ids=12,13-GET /parses?sha256=...&tier=medium-GET /parses?sha256=...&tier=medium&status=pending-GET /parses?sha256=...&tier=medium&page_range=1~10+GET /parses?sha256=...&tier=basic+GET /parses?sha256=...&tier=basic&status=pending+GET /parses?sha256=...&tier=basic&page_range=1~10````ids` 查询用于 CLI wait 等精确请求状态判断。`sha256 + tier + page_range` 查询用于计算页覆盖状态。@@ -93,7 +93,7 @@ GET /docs/{sha256}`GET /docs/{sha256}/content` 从有效 done parse record 的 Middle JSON 中读取并转换内容:```http-GET /docs/{sha256}/content?tier=medium&page_range=1~10&format=markdown+GET /docs/{sha256}/content?tier=basic&page_range=1~10&format=markdown```读取内容不触发解析。缺页时应返回明确错误或 pending 状态,由调用方再决定是否 `POST /parses`。@@ -108,7 +108,7 @@ GET /docs/{sha256}/content?tier=medium&page_range=1~10&format=markdown{"target": "parses","path": "/a/b/report.pdf",- "tier": "medium"+ "tier": "basic"}```@@ -118,7 +118,7 @@ GET /docs/{sha256}/content?tier=medium&page_range=1~10&format=markdown{"target": "parses","sha256": "...",- "tier": "medium",+ "tier": "basic","invalidated_count": 2}```diff --git a/docs/next/decisions/0012-doclib-block-locator.md b/docs/next/decisions/0012-doclib-block-locator.mdindex 96ffeb70..327f399b 100644--- a/docs/next/decisions/0012-doclib-block-locator.md+++ b/docs/next/decisions/0012-doclib-block-locator.md@@ -36,7 +36,7 @@ P0 定义两级定位:```textpage:1/block:3-doc:ab12cd3/tier:medium/page:1/block:3+doc:ab12cd3/tier:basic/page:1/block:3```字段规则:@@ -44,7 +44,7 @@ doc:ab12cd3/tier:medium/page:1/block:3| 字段 | 说明 ||------|------|| `short_id` | `docs.short_id`,见 [ADR-0011](0011-doclib-doc-short-id.md)。 |-| `tier` | 实际解析档位: `flash` / `medium` / `high` / `xhigh`。 |+| `tier` | 实际解析档位: `flash` / `basic` / `standard` / `advanced`。 || `page_no` | 1-based 页号。 || `block_no` | 1-based block 号。 |@@ -116,7 +116,7 @@ Structured Content item 可包含:```json{"locator": "page:1/block:3",- "block_ref": "doc:ab12cd3/tier:medium/page:1/block:3",+ "block_ref": "doc:ab12cd3/tier:basic/page:1/block:3","page": 1,"block": 3,"type": "paragraph"@@ -128,7 +128,7 @@ Structured Content item 可包含:Markdown 可选 locator marker 可包含:```html-<!-- mineru:block {"ref":"doc:ab12cd3/tier:medium/page:1/block:3","locator":"page:1/block:3","type":"paragraph"} -->+<!-- mineru:block {"ref":"doc:ab12cd3/tier:basic/page:1/block:3","locator":"page:1/block:3","type":"paragraph"} -->```规则:@@ -143,7 +143,7 @@ Agent citation record 可包含:```json{- "block_ref": "doc:ab12cd3/tier:medium/page:4/block:12",+ "block_ref": "doc:ab12cd3/tier:basic/page:4/block:12","locator": "page:4/block:12","page": 4,"block": 12,diff --git a/docs/next/decisions/0013-doc-content-progressive-reading.md b/docs/next/decisions/0013-doc-content-progressive-reading.mdindex ba8fa95e..4dd08341 100644--- a/docs/next/decisions/0013-doc-content-progressive-reading.md+++ b/docs/next/decisions/0013-doc-content-progressive-reading.md@@ -82,9 +82,9 @@ def get_doc_content(HTTP API 使用 GET query,不使用 request body:```http-GET /api/v1/docs/{sha256}/content?tier=medium&page_range=1~10&limit=30000-GET /api/v1/docs/{sha256}/content?tier=medium&page_range=7~10&after=doc:ab12cd3/tier:medium/page:7/block:4&limit=30000-GET /api/v1/docs/{sha256}/content?tier=medium&after=doc:ab12cd3/tier:medium/page:1/block:42&limit=30000+GET /api/v1/docs/{sha256}/content?tier=basic&page_range=1~10&limit=30000+GET /api/v1/docs/{sha256}/content?tier=basic&page_range=7~10&after=doc:ab12cd3/tier:basic/page:7/block:4&limit=30000+GET /api/v1/docs/{sha256}/content?tier=basic&after=doc:ab12cd3/tier:basic/page:1/block:42&limit=30000```## 默认值@@ -139,7 +139,7 @@ doc:{short_id}/tier:{tier}/page:{page_no}/block:{block_no}/char:{offset}示例:```http-GET /api/v1/docs/{sha}/content?tier=medium&after=doc:ab12cd3/tier:medium/page:21+GET /api/v1/docs/{sha}/content?tier=basic&after=doc:ab12cd3/tier:basic/page:21```若文档至少有 30 页,规范化为:@@ -148,7 +148,7 @@ GET /api/v1/docs/{sha}/content?tier=medium&after=doc:ab12cd3/tier:medium/page:21{"request_scope": {"page_range": "21~30",- "after": "doc:ab12cd3/tier:medium/page:21",+ "after": "doc:ab12cd3/tier:basic/page:21","limit": 30000}}@@ -172,8 +172,8 @@ GET /api/v1/docs/{sha}/content?tier=medium&after=doc:ab12cd3/tier:medium/page:21"content_ranges": [{"page_range": "1~10",- "start": "doc:ab12cd3/tier:medium/page:1",- "end": "doc:ab12cd3/tier:medium/page:10"+ "start": "doc:ab12cd3/tier:basic/page:1",+ "end": "doc:ab12cd3/tier:basic/page:10"}]}@@ -191,13 +191,13 @@ GET /api/v1/docs/{sha}/content?tier=medium&after=doc:ab12cd3/tier:medium/page:21"content_ranges": [{"page_range": "1~5",- "start": "doc:ab12cd3/tier:medium/page:1",- "end": "doc:ab12cd3/tier:medium/page:5"+ "start": "doc:ab12cd3/tier:basic/page:1",+ "end": "doc:ab12cd3/tier:basic/page:5"},{"page_range": "20~25",- "start": "doc:ab12cd3/tier:medium/page:20",- "end": "doc:ab12cd3/tier:medium/page:25"+ "start": "doc:ab12cd3/tier:basic/page:20",+ "end": "doc:ab12cd3/tier:basic/page:25"}]}@@ -240,7 +240,7 @@ truncated=false => next_request may be null or non-null请求:```http-GET /api/v1/docs/{sha}/content?tier=medium&page_range=1~10&limit=30000+GET /api/v1/docs/{sha}/content?tier=basic&page_range=1~10&limit=30000```响应:@@ -255,8 +255,8 @@ GET /api/v1/docs/{sha}/content?tier=medium&page_range=1~10&limit=30000"content_ranges": [{"page_range": "1~10",- "start": "doc:ab12cd3/tier:medium/page:1",- "end": "doc:ab12cd3/tier:medium/page:10"+ "start": "doc:ab12cd3/tier:basic/page:1",+ "end": "doc:ab12cd3/tier:basic/page:10"}],"truncated": false,@@ -292,7 +292,7 @@ GET /api/v1/docs/{sha}/content?tier=medium&page_range=1~10&limit=30000请求:```http-GET /api/v1/docs/{sha}/content?tier=medium&page_range=1~10&limit=30000+GET /api/v1/docs/{sha}/content?tier=basic&page_range=1~10&limit=30000```如果 Server 只输出到第 6 页,并在页边缘停止:@@ -302,8 +302,8 @@ GET /api/v1/docs/{sha}/content?tier=medium&page_range=1~10&limit=30000"content_ranges": [{"page_range": "1~6",- "start": "doc:ab12cd3/tier:medium/page:1",- "end": "doc:ab12cd3/tier:medium/page:6"+ "start": "doc:ab12cd3/tier:basic/page:1",+ "end": "doc:ab12cd3/tier:basic/page:6"}],"truncated": true,@@ -322,7 +322,7 @@ GET /api/v1/docs/{sha}/content?tier=medium&page_range=1~10&limit=30000请求:```http-GET /api/v1/docs/{sha}/content?tier=medium&page_range=7~10&limit=30000+GET /api/v1/docs/{sha}/content?tier=basic&page_range=7~10&limit=30000```响应:@@ -332,14 +332,14 @@ GET /api/v1/docs/{sha}/content?tier=medium&page_range=7~10&limit=30000"content_ranges": [{"page_range": "7",- "start": "doc:ab12cd3/tier:medium/page:7",- "end": "doc:ab12cd3/tier:medium/page:7/block:4"+ "start": "doc:ab12cd3/tier:basic/page:7",+ "end": "doc:ab12cd3/tier:basic/page:7/block:4"}],"truncated": true,"next_request": {"page_range": "7~10",- "after": "doc:ab12cd3/tier:medium/page:7/block:4"+ "after": "doc:ab12cd3/tier:basic/page:7/block:4"}}```@@ -351,14 +351,14 @@ GET /api/v1/docs/{sha}/content?tier=medium&page_range=7~10&limit=30000"content_ranges": [{"page_range": "7",- "start": "doc:ab12cd3/tier:medium/page:7/block:4/char:0",- "end": "doc:ab12cd3/tier:medium/page:7/block:4/char:32784"+ "start": "doc:ab12cd3/tier:basic/page:7/block:4/char:0",+ "end": "doc:ab12cd3/tier:basic/page:7/block:4/char:32784"}],"truncated": true,"next_request": {"page_range": "7~10",- "after": "doc:ab12cd3/tier:medium/page:7/block:4/char:32784"+ "after": "doc:ab12cd3/tier:basic/page:7/block:4/char:32784"}}```@@ -372,7 +372,7 @@ GET /api/v1/docs/{sha}/content?tier=medium&page_range=7~10&limit=30000示例:```http-GET /api/v1/docs/{sha}/content?tier=medium&page_range=1~5,20~25+GET /api/v1/docs/{sha}/content?tier=basic&page_range=1~5,20~25```若文档还有第 26 页之后的内容:@@ -416,13 +416,13 @@ GET /api/v1/docs/{sha}/content?tier=medium&page_range=1~5,20~25"content_ranges": [{"page_range": null,- "start": "doc:ab12cd3/tier:medium/page:1/block:1",- "end": "doc:ab12cd3/tier:medium/page:1/block:42"+ "start": "doc:ab12cd3/tier:basic/page:1/block:1",+ "end": "doc:ab12cd3/tier:basic/page:1/block:42"}],"truncated": true,"next_request": {- "after": "doc:ab12cd3/tier:medium/page:1/block:42"+ "after": "doc:ab12cd3/tier:basic/page:1/block:42"}}```@@ -434,13 +434,13 @@ GET /api/v1/docs/{sha}/content?tier=medium&page_range=1~5,20~25"content_ranges": [{"page_range": null,- "start": "doc:ab12cd3/tier:medium/page:1/block:1/char:0",- "end": "doc:ab12cd3/tier:medium/page:1/block:1/char:32784"+ "start": "doc:ab12cd3/tier:basic/page:1/block:1/char:0",+ "end": "doc:ab12cd3/tier:basic/page:1/block:1/char:32784"}],"truncated": true,"next_request": {- "after": "doc:ab12cd3/tier:medium/page:1/block:1/char:32784"+ "after": "doc:ab12cd3/tier:basic/page:1/block:1/char:32784"}}```@@ -458,7 +458,7 @@ CLI marker 是展示层,不是协议源头。Server 返回 `next_request`,CL分页文档页内 continuation:```html-<!-- Next: mineru parse report.pdf --pages 7~10 --after doc:ab12cd3/tier:medium/page:7/block:4 -->+<!-- Next: mineru parse report.pdf --pages 7~10 --after doc:ab12cd3/tier:basic/page:7/block:4 -->```非分页文档:diff --git a/docs/next/decisions/0014-mineru-read-command.md b/docs/next/decisions/0014-mineru-read-command.mdindex 83fd484f..f7f3b75b 100644--- a/docs/next/decisions/0014-mineru-read-command.md+++ b/docs/next/decisions/0014-mineru-read-command.md@@ -177,7 +177,7 @@ parse read 返回示例:{"sha256": "...","short_id": "ab12cd3",- "tier": "medium",+ "tier": "basic","format": "markdown","content": "...","request_scope": {@@ -190,8 +190,8 @@ parse read 返回示例:"content_ranges": [{"page_range": "1~10",- "start": "doc:ab12cd3/tier:medium/page:1",- "end": "doc:ab12cd3/tier:medium/page:10/block:18"+ "start": "doc:ab12cd3/tier:basic/page:1",+ "end": "doc:ab12cd3/tier:basic/page:10/block:18"}],"truncated": false,@@ -210,21 +210,21 @@ locator read 返回示例:{"sha256": "...","short_id": "ab12cd3",- "tier": "medium",+ "tier": "basic","format": "markdown","content": "...","request_scope": {"page_range": "4","after": null,"limit": 30000,- "locator": "doc:ab12cd3/tier:medium/page:4/block:12",+ "locator": "doc:ab12cd3/tier:basic/page:4/block:12","context": 2},"content_ranges": [{"page_range": "4",- "start": "doc:ab12cd3/tier:medium/page:4/block:10",- "end": "doc:ab12cd3/tier:medium/page:4/block:14"+ "start": "doc:ab12cd3/tier:basic/page:4/block:10",+ "end": "doc:ab12cd3/tier:basic/page:4/block:14"}],"truncated": false,@@ -239,21 +239,21 @@ image read 返回示例:{"sha256": "...","short_id": "ab12cd3",- "tier": "medium",+ "tier": "basic","format": "image","content": "","request_scope": {"page_range": "4","after": null,"limit": 30000,- "locator": "doc:ab12cd3/tier:medium/page:4/block:12",+ "locator": "doc:ab12cd3/tier:basic/page:4/block:12","context": 0},"content_ranges": [{"page_range": "4",- "start": "doc:ab12cd3/tier:medium/page:4/block:12",- "end": "doc:ab12cd3/tier:medium/page:4/block:12"+ "start": "doc:ab12cd3/tier:basic/page:4/block:12",+ "end": "doc:ab12cd3/tier:basic/page:4/block:12"}],"truncated": false,@@ -281,7 +281,7 @@ read 使用 locator continuation:- CLI continuation marker 渲染为:```markdown-<!-- Next: mineru read doc:ab12cd3/tier:medium/page:5 -->+<!-- Next: mineru read doc:ab12cd3/tier:basic/page:5 -->```P0 暂不实现 block locator marker,即不在每个 block 前默认输出:@@ -419,8 +419,8 @@ def read_content(HTTP 路由:```http-GET /api/v1/content?locator=doc:ab12cd3/tier:medium/page:4&format=markdown&limit=30000-GET /api/v1/content?locator=doc:ab12cd3/tier:medium/page:4/block:12&format=image&image_format=png+GET /api/v1/content?locator=doc:ab12cd3/tier:basic/page:4&format=markdown&limit=30000+GET /api/v1/content?locator=doc:ab12cd3/tier:basic/page:4/block:12&format=image&image_format=png```P0 不为 locator-first content API 提供 POST export。`GET /api/v1/content` 可以在 server 内部生成临时 image asset,并接受 `image_format=jpeg|png|webp` 控制 asset 编码,但不接受 client 指定的 output path。CLI `read --output` 是 client 侧文件写入/copy 行为,不是 doclib HTTP API 行为。diff --git a/docs/next/decisions/0016-mineru-kit-parse-command.md b/docs/next/decisions/0016-mineru-kit-parse-command.mdindex cdde44fd..2c71890c 100644--- a/docs/next/decisions/0016-mineru-kit-parse-command.md+++ b/docs/next/decisions/0016-mineru-kit-parse-command.md@@ -105,7 +105,7 @@ mineru-kit parse <input...> -o <output> [flags]3. `--remote` 与 `--remote-url` 互斥4. remote 模式下允许传 `--tier`5. remote 模式下禁止传 `--backend`-6. remote 模式未传 `--tier` 时,PDF/image 使用目标服务的默认选择策略,按 `high` -> `xhigh` -> `medium` 选择+6. remote 模式未传 `--tier` 时,PDF/image 使用目标服务的默认选择策略,按 `standard` -> `advanced` -> `basic` 选择7. remote 模式传了 `--tier` 时:- 服务提供该 tier,则按该 tier 解析- 服务不提供该 tier,则报错diff --git a/docs/next/decisions/0017-mineru-kit-api-server-command.md b/docs/next/decisions/0017-mineru-kit-api-server-command.mdindex 57cbbda7..dcb131d8 100644--- a/docs/next/decisions/0017-mineru-kit-api-server-command.md+++ b/docs/next/decisions/0017-mineru-kit-api-server-command.md@@ -49,9 +49,9 @@ managed 是生命周期管理方式,不是用户直接操作的独立命令产支持的公开 tier:- `flash`-- `medium`-- `high`-- `xhigh`+- `basic`+- `standard`+- `advanced`规则:@@ -59,7 +59,7 @@ managed 是生命周期管理方式,不是用户直接操作的独立命令产2. `--backend` 是高级覆盖参数3. 可以同时传 `--tier` 和 `--backend`4. 如果二者不兼容,启动直接报错-5. 未传 `--tier` 时暴露 `flash`、`medium`、`high`、`xhigh`;请求未指定 tier 时默认 `high`+5. 未传 `--tier` 时暴露 `flash`、`basic`、`standard`、`advanced`;请求未指定 tier 时默认 `standard`### 4. backend 的公开边界diff --git a/docs/next/decisions/0022-doclib-file-type-tier-remote-semantics.md b/docs/next/decisions/0022-doclib-file-type-tier-remote-semantics.mdindex 45e22b0d..7acc2385 100644--- a/docs/next/decisions/0022-doclib-file-type-tier-remote-semantics.md+++ b/docs/next/decisions/0022-doclib-file-type-tier-remote-semantics.md@@ -8,7 +8,7 @@`mineru parse` 支持多种输入格式,但不同格式背后的解析路径并不相同:-- PDF 和 image 可以进入质量 tier 路径,支持 `flash`、`medium`、`high` 和 `xhigh`。+- PDF 和 image 可以进入质量 tier 路径,支持 `flash`、`basic`、`standard` 和 `advanced`。- Office 文件走专门的 Office parser,实际只支持 `flash`。- HTML 不走 PDF 质量后端,只具备 `flash` 语义。- text 输入可入库和建立搜索索引,但无需解析,不产生 parse row 或 Middle JSON。@@ -40,7 +40,7 @@ image 扩展名只进入 `INGESTIBLE_EXTENSIONS`,不进入 `DISCOVERABLE_EXTEN质量 tier 只对 PDF 和 image 有意义。-| 文件类型 | `flash` | `medium` | `high` | `xhigh` |+| 文件类型 | `flash` | `basic` | `standard` | `advanced` ||----------|---------|----------|--------|---------|| PDF | 支持 | 支持 | 支持 | 支持 || image | 支持 | 支持 | 支持 | 支持 |diff --git a/docs/next/decisions/0024-file-type-tier-normalization.md b/docs/next/decisions/0024-file-type-tier-normalization.mdindex e63d371e..6061cdb0 100644--- a/docs/next/decisions/0024-file-type-tier-normalization.md+++ b/docs/next/decisions/0024-file-type-tier-normalization.md@@ -8,11 +8,11 @@MinerU doclib 可以接收 PDF、image、Office、text 和 HTML 输入,但这些输入并不具备相同的解析能力。-PDF 和 image 支持质量 tier: `flash`、`medium`、`high`、`xhigh`。Office 和 HTML 当前只有 `flash` 语义,没有对应的质量 tier。text 可入库和搜索,但不需要解析。此前不同入口对“非 PDF/image + 质量 tier”的处理不完全一致:+PDF 和 image 支持质量 tier: `flash`、`basic`、`standard`、`advanced`。Office 和 HTML 当前只有 `flash` 语义,没有对应的质量 tier。text 可入库和搜索,但不需要解析。此前不同入口对“非 PDF/image + 质量 tier”的处理不完全一致:- 有的入口报错。- 有的入口静默走 Office / HTML parser,或为 text 返回没有对应缓存的合成成功响应。-- parsing-rule 可能创建 `tier=high` 等 parse row,但实际执行的仍是 Office / flash 语义。+- parsing-rule 可能创建 `tier=standard` 等 parse row,但实际执行的仍是 Office / flash 语义。这种不一致会让 parse row、缓存目录、locator 和用户看到的实际解析能力脱节。因此需要定义一套按操作类型区分的归一化规则。@@ -26,11 +26,11 @@ MinerU 在 tier 语义上把输入分为三组:| 分组 | 文件类型 | Tier 能力 ||------|----------|-----------|-| 支持多 tier 的输入 | PDF、image | `flash`、`medium`、`high`、`xhigh` |+| 支持多 tier 的输入 | PDF、image | `flash`、`basic`、`standard`、`advanced` || 仅支持 flash tier 的输入 | Office、HTML | 仅 `flash` 语义 || 无需解析的文本输入 | `.txt`、`.md`、`.markdown`、`.csv`、`.rst`、`.tex` | 无 tier;直接读取源文件 |-Office 和 HTML 即使通过高层接口传入了 `medium`、`high` 或 `xhigh`,也不能把结果记录为这些质量 tier,除非未来另有 ADR 明确引入对应能力。text 不创建 parse row 或 Middle JSON,显式 parse 返回 `parse_not_required`。+Office 和 HTML 即使通过高层接口传入了 `basic`、`standard` 或 `advanced`,也不能把结果记录为这些质量 tier,除非未来另有 ADR 明确引入对应能力。text 不创建 parse row 或 Middle JSON,显式 parse 返回 `parse_not_required`。### 2. 单对象主动操作@@ -43,7 +43,7 @@ Office 和 HTML 即使通过高层接口传入了 `medium`、`high` 或 `xhigh`规则:-| 输入类型 | 未指定 tier | 指定 `flash` | 指定 `medium/high/xhigh` |+| 输入类型 | 未指定 tier | 指定 `flash` | 指定 `basic/standard/advanced` ||----------|-------------|--------------|--------------------------|| PDF / image | 使用该入口默认质量选择策略 | 使用 `flash` | 使用指定质量 tier || Office / HTML | 归一为 `flash` | 使用 `flash` | 报错 |@@ -63,7 +63,7 @@ Office 和 HTML 即使通过高层接口传入了 `medium`、`high` 或 `xhigh`规则:-| 输入类型 | 未指定 tier | 指定 `flash` | 指定 `medium/high/xhigh` |+| 输入类型 | 未指定 tier | 指定 `flash` | 指定 `basic/standard/advanced` ||----------|-------------|--------------|--------------------------|| PDF / image | 使用该入口默认选择策略 | 使用 `flash` | 使用指定质量 tier || Office / HTML | 归一为 `flash` | 使用 `flash` | 归一为 `flash` |@@ -86,7 +86,7 @@ parsing-rule 是批量/后台规则,不是用户对单个文件的显式 parse- PDF/image 命中 parsing-rule 但未指定 tier 时,按以下顺序选择可用 tier:```text-high -> xhigh -> medium -> flash+standard -> advanced -> basic -> flash```这与用户主动阅读默认选择不同。parsing-rule 是后台批量策略,可以接受最后降级到 `flash`,因为 watch 自动发现本身也接受 `flash`。@@ -145,7 +145,7 @@ doclib 单文件主动解析中,`remote=true` 表示用户显式要求把该- doclib 单文件主动解析保持严格语义: Office/HTML 显式质量 tier 报错;text 返回 `parse_not_required`。- Office/HTML 未指定 tier 或指定 `flash` 时,实际记录为 `flash`。- parsing-rule 触发 Office/HTML 时,实际 parse row 必须为 `flash`;text 只入库和索引。-- parsing-rule 对 PDF/image 未指定 tier 时,允许 `high -> xhigh -> medium -> flash` 兜底。+- parsing-rule 对 PDF/image 未指定 tier 时,允许 `standard -> advanced -> basic -> flash` 兜底。### 对 SDK 和 mineru-kit@@ -162,11 +162,11 @@ doclib 单文件主动解析中,`remote=true` 表示用户显式要求把该### 对缓存和 locator- 缓存键、parse row、locator 和产物 metadata 必须记录实际 tier。-- Office/HTML 不应产生 `medium`、`high` 或 `xhigh` 缓存;text 不应产生任何解析缓存。+- Office/HTML 不应产生 `basic`、`standard` 或 `advanced` 缓存;text 不应产生任何解析缓存。## 后续动作1. 更新 doclib parsing-rule 入队逻辑,确保 Office/HTML 创建 `tier=flash` 的 parse row,text 不创建 parse row。-2. 更新 parsing-rule 的 PDF/image 默认 tier 选择顺序为 `high -> xhigh -> medium -> flash`。+2. 更新 parsing-rule 的 PDF/image 默认 tier 选择顺序为 `standard -> advanced -> basic -> flash`。3. 检查 SDK、mineru-kit 和 API Server,对单对象和批量操作分别应用本 ADR 的归一化规则。4. 同步更新 CLI、SDK 和 API 文档,避免继续表述为“所有入口统一报错”或“所有入口统一静默降级”。diff --git a/docs/next/decisions/0025-model-download-local-dir.md b/docs/next/decisions/0025-model-download-local-dir.mdindex 6fa499c7..23cb3b13 100644--- a/docs/next/decisions/0025-model-download-local-dir.md+++ b/docs/next/decisions/0025-model-download-local-dir.md@@ -253,17 +253,17 @@ PDF_EXTRACT_KIT.pytorch_paddle.path(rec_model_name).ensure()```pythonREPOS_FOR_TIER = {"flash": (),- "medium": (PDF_EXTRACT_KIT,),- "high": (PDF_EXTRACT_KIT, MINERU_2_5_PRO_2605_1_2B),- "xhigh": (PDF_EXTRACT_KIT, MINERU_2_5_PRO_2605_1_2B),+ "basic": (PDF_EXTRACT_KIT,),+ "standard": (PDF_EXTRACT_KIT, MINERU_2_5_PRO_2605_1_2B),+ "advanced": (PDF_EXTRACT_KIT, MINERU_2_5_PRO_2605_1_2B),}```语义:- `flash` 不需要本地模型下载。-- `medium` 需要 `PDF-Extract-Kit-1.0`。-- `high` 和 `xhigh` 需要 `PDF-Extract-Kit-1.0` 与 `MinerU2.5-Pro-2605-1.2B`。+- `basic` 需要 `PDF-Extract-Kit-1.0`。+- `standard` 和 `advanced` 需要 `PDF-Extract-Kit-1.0` 与 `MinerU2.5-Pro-2605-1.2B`。repo registry 不反向依赖 tier。tier 只选择需要的 repo 集合,repo 自身仍只描述模型仓库。@@ -393,9 +393,9 @@ def verify_model_tier(tier: Tier) -> ModelReadyResult:`mineru-kit models download` 支持按 tier 或按模型仓库下载:```bash-mineru-kit models download --tier medium-mineru-kit models download --tier high-mineru-kit models download --tier xhigh+mineru-kit models download --tier basic+mineru-kit models download --tier standard+mineru-kit models download --tier advancedmineru-kit models download PDF-Extract-Kit-1.0mineru-kit models download MinerU2.5-Pro-2605-1.2B```@@ -440,7 +440,7 @@ source 解析规则:`mineru-kit models verify` 使用与 download 相同的目标选择语义:```bash-mineru-kit models verify --tier high+mineru-kit models verify --tier standardmineru-kit models verify PDF-Extract-Kit-1.0mineru-kit models verify```@@ -507,7 +507,7 @@ mineru-kit models verify- `pipeline` / `vlm` 是旧实现分组名,不是模型仓库名。- 用户关心的是准备某个 tier 所需模型,或下载某个具体模型仓库。-- 继续暴露 bundle 会让 `medium/high/xhigh` 与模型准备动作之间多一层间接概念。+- 继续暴露 bundle 会让 `basic/standard/advanced` 与模型准备动作之间多一层间接概念。- 当前实际远端模型仓库只有两个,用真实仓库名表达更直接。### 方案 G: 为每个 repo 编写强类型路径类或 decorator 语法@@ -561,7 +561,7 @@ PDF_EXTRACT_KIT.pp_doclayout_v2.ensure()- 本地模型目录稳定、可解释。- `mineru-kit models show/verify` 能直接展示模型仓库、tier 需求、expected local dir 和 readiness。-- `mineru-kit models download --tier high` 直接表达“准备 high tier”,不要求用户理解旧 `pipeline` / `vlm` 分组。+- `mineru-kit models download --tier standard` 直接表达“准备 standard tier”,不要求用户理解旧 `pipeline` / `vlm` 分组。- 使用 `model.source=local` 时,离线部署行为更明确。- 首次模型准备可以从“parse 时静默下载”转为“配置/下载命令显式准备”。diff --git a/docs/next/decisions/0027-doclib-visual-block-locators.md b/docs/next/decisions/0027-doclib-visual-block-locators.mdindex 0a77fc6d..f886f91f 100644--- a/docs/next/decisions/0027-doclib-visual-block-locators.md+++ b/docs/next/decisions/0027-doclib-visual-block-locators.md@@ -25,10 +25,10 @@ PDF Middle JSON 仍可能包含解析阶段生成的 `image_path`。通用 Markddoclib 对外生成的 Markdown 使用 block locator 表示可读取的视觉 block:```md----++++```locator 为空表示原文存在对应视觉 block,但 doclib 当前没有可读取的图片:@@ -43,7 +43,7 @@ locator 为空表示原文存在对应视觉 block,但 doclib 当前没有可非空 locator 是公共能力承诺: 在生成该 Markdown 时,这个 block 具备明确的 image 读取路径。用户或 Agent 可以执行:```bash-mineru read "doc:ab12cd3/tier:high/page:1/block:4" --format image --output image.jpg+mineru read "doc:ab12cd3/tier:standard/page:1/block:4" --format image --output image.jpg```源文件或缓存文件在 Markdown 生成后仍可能被移动、删除或损坏;locator 不对未来文件状态提供永久保证。diff --git a/docs/next/errors.md b/docs/next/errors.mdindex a9507476..fea10dc0 100644--- a/docs/next/errors.md+++ b/docs/next/errors.md@@ -33,7 +33,7 @@"error": {"type": "engine_error","code": "quality_tier_unavailable",- "message": "Default tier selection requires medium, high, or xhigh, but only flash is available. Start a parse-server, use --remote, or explicitly pass --tier flash.",+ "message": "Default tier selection requires basic, standard, or advanced, but only flash is available. Start a parse-server, use --remote, or explicitly pass --tier flash.","param": "tier","retryable": false,"user_action": "start_parse_server_or_use_remote_or_explicit_flash",@@ -68,7 +68,7 @@## 5. Tier 与引擎错误-Tier 语义见 [解析 Tier](tiers.md)。本节定义 `flash`、`medium`、`high` 和默认选择策略相关错误。+Tier 语义见 [解析 Tier](tiers.md)。本节定义 `flash`、`basic`、`standard` 和默认选择策略相关错误。| type | code | HTTP | retryable | param | 触发场景 | user_action ||------|------|------|:--:|-------|----------|-------------|@@ -90,7 +90,7 @@ Tier 语义见 [解析 Tier](tiers.md)。本节定义 `flash`、`medium`、`high关键约束:- `quality_tier_unavailable` 不能自动 fallback 到 `flash`。-- `tier_mismatch` 不自动降级。例如用户请求 `high`,server 只支持 `medium`,必须报错。+- `tier_mismatch` 不自动降级。例如用户请求 `standard`,server 只支持 `basic`,必须报错。- `parse_failed` 不做 remote/local fallback;文件级解析失败应直接暴露。- `engine_unavailable` 和 `parse_server_unavailable` 可重试,但重试不得改变 `privacy`。@@ -185,7 +185,7 @@ CLI 在 TTY 中可以用表格或 rich 文本展示,但非 TTY、`--json` 或"error": {"type": "engine_error","code": "quality_tier_unavailable",- "message": "Default tier selection requires medium, high, or xhigh, but only flash is available. Start a local parse-server, use --remote, or explicitly pass --tier flash.",+ "message": "Default tier selection requires basic, standard, or advanced, but only flash is available. Start a local parse-server, use --remote, or explicitly pass --tier flash.","param": "tier","retryable": false,"user_action": "start_parse_server_or_use_remote_or_explicit_flash",@@ -233,7 +233,7 @@ CLI 在 TTY 中可以用表格或 rich 文本展示,但非 TTY、`--json` 或"error": {"type": "engine_error","code": "no_engine",- "message": "No local engine available for tier 'medium'. Available tiers: flash. Use --remote or --tier flash.",+ "message": "No local engine available for tier 'basic'. Available tiers: flash. Use --remote or --tier flash.","param": "tier","retryable": false,"user_action": "enable_parse_server_or_change_tier",diff --git a/docs/next/everydoc-doclib-gap-review.md b/docs/next/everydoc-doclib-gap-review.mdindex 97a7f477..db0190aa 100644--- a/docs/next/everydoc-doclib-gap-review.md+++ b/docs/next/everydoc-doclib-gap-review.md@@ -12,7 +12,7 @@- 去掉 everydoc 中显式暴露给用户的 `index` 概念。- 在 doclib 中用“入库 + flash parse”替代 everydoc 的 lightweight index。-- 将解析能力统一到 `flash` / `medium` / `high` / `xhigh` 解析档位。+- 将解析能力统一到 `flash` / `basic` / `standard` / `advanced` 解析档位。- 将解析结果存储收敛为 Middle JSON,Markdown / Content List 等格式读取时即时转换。尽管如此,everydoc 仍有一些已经设计清楚、甚至已经实现的 doclib 类能力。最近补齐文件变化检测时发现,MinerU doclib 曾遗漏 everydoc 中命名清晰的 `discover_file` / change detection 机制,因此有必要系统性回看 everydoc 中还有哪些设计值得回收。@@ -276,13 +276,13 @@ MinerU 当前状态:风险:- Agent 很难按解析档位和文件类型控制搜索范围。-- 用户无法快速判断结果来自低成本 flash,还是 medium / high / xhigh 的质量解析。+- 用户无法快速判断结果来自低成本 Flash,还是 Basic / Standard / Advanced 的质量解析。P0 结论:- `search()` 增加 `tier`、`min_tier`、`file_type` 过滤。- `tier` 表示只返回指定解析档位索引结果。-- `min_tier` 表示返回不低于该解析档位的索引结果,档位顺序为 `flash < medium < high < xhigh`。+- `min_tier` 表示返回不低于该解析档位的索引结果,档位顺序为 `flash < basic < standard < advanced`。- 如果 `tier` 与 `min_tier` 同时出现,二者同时生效;不兼容时返回空结果。- 时间范围过滤、watch 过滤放到 P1。- 搜索结果可信度不新增 `confidence` 或 `quality` 字段,只使用 `tier` 表达。diff --git a/docs/next/glossary.md b/docs/next/glossary.mdindex 339ab1b2..1becae27 100644--- a/docs/next/glossary.md+++ b/docs/next/glossary.md@@ -50,15 +50,15 @@| Tier | 类型 | 含义 ||------|------|------|| `flash` | 实体 tier | CPU-only、快速、低质量,用于 watch、发现和索引 |-| `medium` | 实体 tier | 面向普通本地硬件的模型解析能力 |-| `high` | 实体 tier | 绝大多数场景足够好的高质量解析能力,可来自 `mineru.net/api` 或高端本地硬件 |-| `xhigh` | 实体 tier | 最高质量解析能力,比 `high` 消耗更多算力和时间 |+| `basic` | 实体 tier | 面向普通本地硬件的模型解析能力 |+| `standard` | 实体 tier | 绝大多数场景足够好的高质量解析能力,可来自 `mineru.net/api` 或高端本地硬件 |+| `advanced` | 实体 tier | 最高质量解析能力,比 `standard` 消耗更多算力和时间 |规范:- CLI/API/SDK 的用户可见参数应使用 `tier`。- CLI 不传 `--tier`、HTTP API 省略 `tier` 或传 JSON `null`、Python SDK 传 `None` 表示使用默认选择策略。-- 任务入队、缓存目录、产物 metadata 应记录实际使用的实体 tier,即 `flash`、`medium`、`high` 或 `xhigh`。+- 任务入队、缓存目录、产物 metadata 应记录实际使用的实体 tier,即 `flash`、`basic`、`standard` 或 `advanced`。- PDF/image 的默认选择策略不能解析为 `flash`;Office/HTML 这类仅支持 flash tier 的输入归一规则见 [ADR-0024](decisions/0024-file-type-tier-normalization.md);text 直接读取。完整产品语义见 [解析 Tier](tiers.md)。@@ -111,7 +111,7 @@|--------|------|| `parse()` | Tool SDK 的便捷函数 || `DocumentParser` | Parser 抽象接口 |-| `PdfPipelineParser` | 旧 SDK 兼容类,内部委托 Hybrid medium |+| `PdfPipelineParser` | 旧 SDK 兼容类,内部委托 Hybrid medium effort || `PdfVlmParser` | 调用 VLM backend 的 parser || `PdfHybridParser` | 调用 hybrid backend 的 parser || `DocxParser` / `PptxParser` / `XlsxParser` | Office parser |@@ -159,7 +159,7 @@`parse-server` 是最终术语,中文统一为“解析服务”。它是无状态解析服务,提供 v1 Unified API,并且已经作为配置命名的一部分使用。-它接收文件或本地路径,执行 `medium` / `high` / `xhigh` 等解析能力,并返回解析任务与产物。它不管理长期文档库、watch、搜索索引或用户本地配置。+它接收文件或本地路径,执行 `basic` / `standard` / `advanced` 等解析能力,并返回解析任务与产物。它不管理长期文档库、watch、搜索索引或用户本地配置。文档中推荐写法:@@ -198,7 +198,7 @@ Local Parse Server 的 API 尽量兼容官方 v1 API,但可以简化 Webhook`mineru.net API` 是 MinerU 官方远程 API。-它是 v1 Unified API 的主线定义来源,也是当前 `high` tier 的默认远端能力来源。+它是 v1 Unified API 的主线定义来源,也是当前 `standard` tier 的默认远端能力来源。不要把 `mineru.net API` 写成 `doclib API`。doclib 是本地产品服务,`mineru.net API` 是官方远程解析和对话 API。@@ -504,7 +504,7 @@ Local Parse Server 默认不按公网 access level 做售卖或配额区分。|----------|------|| `tier` | 字段名、参数名、泛指解析档位 || Tier | 章节标题或概念名 |-| `flash` / `medium` / `high` / `xhigh` | tier 枚举值 |+| `flash` / `basic` / `standard` / `advanced` | tier 枚举值 || parse-server | 最终术语,泛指解析服务 || Local Parse Server | 本地解析服务 || Remote Parse Server | 远端解析服务 |@@ -546,7 +546,7 @@ Local Parse Server 默认不按公网 access level 做售卖或配额区分。| 不推荐说法 | 推荐说法 | 原因 ||------------|----------|------|| 默认 tier 是某个 engine | 默认选择策略 | 默认选择是一段选择逻辑,不是一个解析后端 |-| High backend | `high` tier 或具体 backend | `high` 是解析档位,不是解析后端名称 |+| Standard backend | `standard` tier 或具体 backend | `standard` 是解析档位,不是解析后端名称 || Flash 是默认解析 | watch 默认 `flash`;主动阅读不指定 tier 时走默认选择策略 | 避免误解质量策略 || parser server | parse-server | 服务类别统一写法 || doclib API 等同 v1 API | doclib server API / v1 Unified API | 两者资源模型不同 |diff --git a/docs/next/implementation-plan.md b/docs/next/implementation-plan.mdindex a917df71..1f99abf5 100644--- a/docs/next/implementation-plan.md+++ b/docs/next/implementation-plan.md@@ -804,7 +804,7 @@ M1 和 M2 的部分测试任务可以并行,但 `ParseResult.from_dict()`、JS- FTS 有内容。- Markdown 不落盘。-- tier-gated 更新符合 `flash < medium < high < xhigh`。+- tier-gated 更新符合 `flash < basic < standard < advanced`。验证方式:@@ -843,11 +843,11 @@ M1 和 M2 的部分测试任务可以并行,但 `ParseResult.from_dict()`、JS具体步骤:-1. 构造 health: local supported tiers = `["medium", "high"]`。+1. 构造 health: local supported tiers = `["basic", "standard"]`。2. 请求 `tier=None`。-3. 期望入队 tier 为 `high`。-4. 构造 health: local supported tiers = `["medium"]`。-5. 期望入队 tier 为 `medium`。+3. 期望入队 tier 为 `standard`。+4. 构造 health: local supported tiers = `["basic"]`。+5. 期望入队 tier 为 `basic`。6. 构造 health: only `flash` 或空。7. 期望返回 `quality_tier_unavailable` 或等价错误。@@ -988,10 +988,10 @@ M1 和 M2 的部分测试任务可以并行,但 `ParseResult.from_dict()`、JS具体步骤:-1. mock parse-server supported tiers = `["medium"]`。-2. 请求 `tier="high"`。+1. mock parse-server supported tiers = `["basic"]`。+2. 请求 `tier="standard"`。3. 期望 `tier_mismatch`。-4. 确认不会改成 `medium`。+4. 确认不会改成 `basic`。5. 确认不会改成 `flash`。完成边界:@@ -1090,14 +1090,14 @@ M1 和 M2 的部分测试任务可以并行,但 `ParseResult.from_dict()`、JS2. 增加 `tier: str | None = None`。3. `backend` 显式传入时覆盖 `tier`。4. `tier=flash` 映射到 `flash` backend。-5. `tier=medium` 映射到默认 medium backend。-6. `tier=high` 映射到默认 high backend。+5. `tier=basic` 映射到默认 basic backend。+6. `tier=standard` 映射到默认 standard backend。7. `tier=None` 在 Tool SDK 的 PDF/image 场景中如果不能发现非 `flash` 质量 tier,应报错,不静默 flash;Office/HTML 这类仅支持 flash tier 的输入按实际能力归一为 `flash`。完成边界:- `parse(path, tier="flash")` 可用。-- `parse(path, tier="medium")` 可用或返回明确能力错误。+- `parse(path, tier="basic")` 可用或返回明确能力错误。- `parse(path, backend="pipeline")` 兼容。- `backend` 覆盖 `tier` 有测试。diff --git a/docs/next/middle-json/agent-gaps.md b/docs/next/middle-json/agent-gaps.mdindex fdf1e316..678b0460 100644--- a/docs/next/middle-json/agent-gaps.md+++ b/docs/next/middle-json/agent-gaps.md@@ -46,7 +46,7 @@ doc:{short_id}/tier:{tier}/page:{page_no}/block:{block_no}示例:```text-doc:ab12cd3/tier:medium/page:1/block:3+doc:ab12cd3/tier:basic/page:1/block:3```规则:@@ -88,7 +88,7 @@ Agent 对外返回引用时,建议使用 citation record,而不是直接暴```json{- "block_ref": "doc:ab12cd3/tier:medium/page:4/block:12",+ "block_ref": "doc:ab12cd3/tier:basic/page:4/block:12","locator": "page:4/block:12","page": 4,"bbox": [10.0, 20.0, 300.0, 160.0],diff --git a/docs/next/middle-json/backend-gaps.md b/docs/next/middle-json/backend-gaps.mdindex 7081c1e3..d15423c7 100644--- a/docs/next/middle-json/backend-gaps.md+++ b/docs/next/middle-json/backend-gaps.md@@ -83,7 +83,7 @@- VLM 输出不出现归一化 bbox。- VLM 特有 block type 能被 renderer 和 Agent locator 识别。-- 默认选择得到的 `high` 结果可以恢复为 `ParseResult`。+- 默认选择得到的 `standard` 结果可以恢复为 `ParseResult`。## Hybriddiff --git a/docs/next/middle-json/envelope.md b/docs/next/middle-json/envelope.mdindex a9e2bdba..a85cd3b9 100644--- a/docs/next/middle-json/envelope.md+++ b/docs/next/middle-json/envelope.md@@ -25,7 +25,7 @@"_meta": {"mineru_version": "2.x","backend": "hybrid",- "tier": "medium",+ "tier": "basic","file": {"sha256": "...","page_count": 12,@@ -64,7 +64,7 @@|------|------|:--:|------|| `mineru_version` | string | 是 | 生成该结果的 MinerU 版本。 || `backend` | string | 是 | `hybrid`、`office`、`html`、`flash`。 |-| `tier` | string 或 null | 是 | `flash`、`medium`、`high`、`xhigh` 的解析结果语义;未经过 tier 解析的工具层结果可为 `null`。 |+| `tier` | string 或 null | 是 | `flash`、`basic`、`standard`、`advanced` 的解析结果语义;未经过 tier 解析的工具层结果可为 `null`。 || `file` | object | 是 | 文件级信息。 || `features` | object | 是 | 本次解析启用的能力。 || `models` | object | 是 | 实际模型信息。 |diff --git a/docs/next/middle-json/rendering.md b/docs/next/middle-json/rendering.mdindex 4d1c4f8d..a832d6d6 100644--- a/docs/next/middle-json/rendering.md+++ b/docs/next/middle-json/rendering.md@@ -124,7 +124,7 @@ P2:为了 Agent 引用,Markdown 可以支持可选 locator marker:```markdown-<!-- mineru:locator doc:ab12cd3/tier:medium/page:3/block:12 -->+<!-- mineru:locator doc:ab12cd3/tier:basic/page:3/block:12 -->正文内容```diff --git a/docs/next/middle-json/structured-content-schema.md b/docs/next/middle-json/structured-content-schema.mdindex 718fce05..9f2b90cc 100644--- a/docs/next/middle-json/structured-content-schema.md+++ b/docs/next/middle-json/structured-content-schema.md@@ -32,7 +32,7 @@ Structured Content 是从 Middle JSON render 得到的结构化内容 JSON。它"mime_type": "application/pdf"},"parse": {- "tier": "high",+ "tier": "standard","backend": "hybrid","version": "3.1.14"},@@ -70,7 +70,7 @@ Structured Content 是从 Middle JSON render 得到的结构化内容 JSON。它```json{- "tier": "medium",+ "tier": "basic","backend": "hybrid","version": "3.1.14"}@@ -78,7 +78,7 @@ Structured Content 是从 Middle JSON render 得到的结构化内容 JSON。它约束:-- `tier` 只记录实际使用的实体 tier: `flash` / `medium` / `high` / `xhigh`。+- `tier` 只记录实际使用的实体 tier: `flash` / `basic` / `standard` / `advanced`。- 不记录 `requested_tier` / `resolved_tier`。- `backend` 是实现信息,普通客户端不应依赖它做产品逻辑。diff --git a/docs/next/open-questions.md b/docs/next/open-questions.mdindex b3371e27..813fde5d 100644--- a/docs/next/open-questions.md+++ b/docs/next/open-questions.md@@ -35,9 +35,9 @@| JSON 输出格式 | 不把 `json` 作为正式产物名;正式格式为 `middle_json`、`content_list`、`structured_content`,详见 [ADR-0001](decisions/0001-json-output-formats.md)。 || Force 与 invalidate | `--force` 跳过 done cache,可复用 active parse,只为未覆盖页创建新 parse;invalidate 才改变旧缓存可用性,详见 [ADR-0002](decisions/0002-force-vs-invalidate.md)。 || doclib HTTP API | 本地 doclib HTTP API 使用 `/docs`、`/parses`、`/search` 和 `POST /invalidate`,详见 [ADR-0004](decisions/0004-doclib-http-api-resources.md)。 |-| 本地 `high` | `high` 本地运行是正式支持能力,不是实验能力;当前代码基本 ready。 |-| mineru.net tier | `mineru.net/api` 在相当长时间内默认提供 `high` 解析;`high` 是绝大多数场景足够好的高质量档位,但不是最高档。 |-| api-server tier | `mineru-kit api-server --tier` 可重复;未传时当前暴露 `flash`、`medium`、`high`、`xhigh`。 |+| 本地 `standard` | `standard` 本地运行是正式支持能力,不是实验能力;当前代码基本 ready。 |+| mineru.net tier | `mineru.net/api` 在相当长时间内默认提供 `standard` 解析;`standard` 是绝大多数场景足够好的高质量档位,但不是最高档。 |+| api-server tier | `mineru-kit api-server --tier` 可重复;未传时当前暴露 `flash`、`basic`、`standard`、`advanced`。 || managed 生命周期 | managed 模式下,模型下载、预热、重试和退避由 `mineru-kit api-server` 负责。 || 本地 api-server 安全 | 本地 api-server 默认监听 loopback;可通过 `--api-key` 设置固定 API Key,默认不设置。 || P0 主链路 | P0 包含完整 watch、rules、search,不再把它们标为可选主链路。 |@@ -50,8 +50,8 @@| `mineru-kit` 参数稳定性 | 暂不划分 `stable` / `experimental` 等稳定性等级,先保持简单。 || `mineru-kit parse` 输入 | 当前只支持文件和目录输入;不支持 stdin、路径列表、URL 输入和递归目录。 || `mineru-kit parse` 输出 | `--output` 必填;单文件可输出到文件路径或目录路径;多文件只能输出到目录路径;同名冲突直接报错并终止整个批次。 |-| `mineru-kit parse` local/remote | local 支持 `tier/backend` 并校验兼容,PDF/image 二者都不传时默认 `high`,Office/HTML 按 ADR-0024 归一,text 不作为解析输入;remote 支持 `--remote`/`--remote-url`/`--api-key`,允许传 `tier`,禁止传 `backend`。 |-| parsing-rules 默认 tier | parsing-rules 允许不指定 tier;PDF/image 按 `high` -> `xhigh` -> `medium` -> `flash` 选择,Office/HTML 归一为 `flash`,text 只入库和索引;只记录实际 tier。 |+| `mineru-kit parse` local/remote | local 支持 `tier/backend` 并校验兼容,PDF/image 二者都不传时默认 `standard`,Office/HTML 按 ADR-0024 归一,text 不作为解析输入;remote 支持 `--remote`/`--remote-url`/`--api-key`,允许传 `tier`,禁止传 `backend`。 |+| parsing-rules 默认 tier | parsing-rules 允许不指定 tier;PDF/image 按 `standard` -> `advanced` -> `basic` -> `flash` 选择,Office/HTML 归一为 `flash`,text 只入库和索引;只记录实际 tier。 || Telemetry P0 | P0 必须实现 doclib server telemetry 状态、聚合、flush 和 CLI 管理入口;纯工具无 telemetry 能力。 || `mineru parse` 默认页码范围 | 分页文档默认解析和读取 `1~min(page_count,10)`;该默认由 doclib 读取/解析计划负责,CLI 参数层不硬编码默认 `--pages`。 || 渐进式阅读协议 | Server 返回结构化 `next_request`;CLI marker 只由 `next_request` 渲染,不作为协议源头,详见 [ADR-0013](decisions/0013-doc-content-progressive-reading.md)。 |diff --git a/docs/next/roadmap.md b/docs/next/roadmap.mdindex e57f1674..6182fb4e 100644--- a/docs/next/roadmap.md+++ b/docs/next/roadmap.md@@ -137,7 +137,7 @@ Agent 使用 MinerU 有两条通道:| 搜索 | P0 | 文件名与内容检索,属于 watch、rules、search 主链路 || 桌面端 | P1 | CLI 的 GUI 壳 |-解析能力通过 `flash`、`medium`、`high`、`xhigh` 暴露;用户未指定 tier 时使用默认选择策略。tier 的用户语义、硬件边界和质量策略见 [解析 Tier](tiers.md)。+解析能力通过 `flash`、`basic`、`standard`、`advanced` 暴露;用户未指定 tier 时使用默认选择策略。tier 的用户语义、硬件边界和质量策略见 [解析 Tier](tiers.md)。命令分工:diff --git a/docs/next/sdk/api-parser.md b/docs/next/sdk/api-parser.mdindex f54351c3..6ac1d3e6 100644--- a/docs/next/sdk/api-parser.md+++ b/docs/next/sdk/api-parser.md@@ -17,7 +17,7 @@ from mineru.parser import MinerUApiParserparser = MinerUApiParser(api_url="https://mineru.net/api",api_key="...",- tier="high",+ tier="standard",)result = parser.parse("report.pdf")@@ -59,7 +59,7 @@ class MinerUApiParser(DocumentParser):|------|------|| `api_url` | v1 API base URL,如 `https://mineru.net/api` 或 `http://127.0.0.1:16580`。省略时读取 `MINERU_API_URL`,再退回默认官方 API。 || `api_key` | Bearer token。省略时读取 `MINERU_API_KEY`;Local Parse Server 未启用鉴权时可为空。 |-| `tier` | `flash`、`medium`、`high`、`xhigh` 或 `None`。`None` 表示 SDK 在 HTTP 请求中省略 `tier`,让 v1 API 使用默认选择策略;非 PDF/image 文件按 API Server 批量规则归一,见 [ADR-0024](../decisions/0024-file-type-tier-normalization.md)。 |+| `tier` | `flash`、`basic`、`standard`、`advanced` 或 `None`。`None` 表示 SDK 在 HTTP 请求中省略 `tier`,让 v1 API 使用默认选择策略;非 PDF/image 文件按 API Server 批量规则归一,见 [ADR-0024](../decisions/0024-file-type-tier-normalization.md)。 || `include_images` | 是否从 zip 产物读取图片 sidecar,并挂载到 `ParseResult` 图片缓存。 || `include_model_output` | 是否请求并保留模型原始输出;开启时通过 zip 产物读取。 |@@ -121,9 +121,9 @@ Local Parse Server 必须通过 `--allow-local-source` 开启,并在 `features|----------|----------|| `None` | 省略 || `flash` | `flash` |-| `medium` | `medium` |-| `high` | `high` |-| `xhigh` | `xhigh` |+| `basic` | `basic` |+| `standard` | `standard` |+| `advanced` | `advanced` |它不接受也不保存 backend 参数。backend 是本地 parser 层的高级实现概念,不应出现在 API-backed parser 的公开构造参数、实例属性或请求 payload 中。diff --git a/docs/next/sdk/doclib-client.md b/docs/next/sdk/doclib-client.mdindex b30ca1c4..793885bb 100644--- a/docs/next/sdk/doclib-client.md+++ b/docs/next/sdk/doclib-client.md@@ -75,7 +75,7 @@ def ensure_parse(self, request: ParseRequest) -> ParseResponse: ...| 参数 | 说明 ||------|------|| `path` | 本地文件路径。 |-| `tier` | `flash`、`medium`、`high`、`xhigh` 或 `None`。`None` 表示使用 doclib 规则和默认策略;非 PDF/image 单文件未指定 tier 时归一为 `flash`,显式质量 tier 报错。 |+| `tier` | `flash`、`basic`、`standard`、`advanced` 或 `None`。`None` 表示使用 doclib 规则和默认策略;非 PDF/image 单文件未指定 tier 时归一为 `flash`,显式质量 tier 报错。 || `page_range` | 页码范围。 || `force` | 跳过已有 done 缓存并重新解析;可复用 active parse,只为未覆盖页创建新 parse。 || `remote` | 是否允许调用远端 parse-server。默认 `False`。远端 URL 来自 doclib config;API Key 优先来自 doclib config,未配置时使用环境变量。 |diff --git a/docs/next/sdk/migration.md b/docs/next/sdk/migration.mdindex 7893ca34..cb1bc1c7 100644--- a/docs/next/sdk/migration.md+++ b/docs/next/sdk/migration.md@@ -66,8 +66,8 @@ SDK 迁移的目标不是重写现有 parser,而是稳定已经成形的边界验收:-- `parse(path, tier="medium")` 可用。-- `parse(path, tier="high")` 可用或给出明确 engine error。+- `parse(path, tier="basic")` 可用。+- `parse(path, tier="standard")` 可用或给出明确 engine error。- PDF/image 的 `parse(path)` 或 `parse(path, tier=None)` 不会静默使用 flash;Office/HTML 这类仅支持 flash tier 的输入未指定 tier 时返回实际 `flash` 语义。- `parse(path, tier="flash")` 只有显式请求时使用 flash。diff --git a/docs/next/sdk/parser.md b/docs/next/sdk/parser.mdindex 84dc47f3..9afb549c 100644--- a/docs/next/sdk/parser.md+++ b/docs/next/sdk/parser.md@@ -33,7 +33,7 @@| `DocumentParser` | abstract class | 所有 parser 的统一接口。 || `ParseResult` | dataclass | 解析结果对象。 || `PdfFlashParser` | class | CPU-only PDF/image 快速解析。 |-| `PdfPipelineParser` | class | 旧 SDK 兼容类,内部委托 Hybrid medium。 |+| `PdfPipelineParser` | class | 旧 SDK 兼容类,内部委托 Hybrid medium effort。 || `PdfVlmParser` | class | VLM backend。 || `PdfHybridParser` | class | hybrid backend。 || `DocxParser` | class | DOCX parser。 |@@ -104,7 +104,7 @@ class DocumentParser:| Parser | 输入 | 主要 backend | 说明 ||--------|------|--------------|------|| `PdfFlashParser` | PDF/image | flash | CPU-only,快速但质量最低,主要用于发现和索引。 |-| `PdfPipelineParser` | PDF/image | hybrid medium | 旧 SDK 兼容类,等价于 `PdfHybridParser(effort="medium")`。 |+| `PdfPipelineParser` | PDF/image | Hybrid medium effort | 旧 SDK 兼容类,等价于 `PdfHybridParser(effort="medium")`。 || `PdfVlmParser` | PDF/image | VLM | VLM 解析,可通过 server URL 委托。 || `PdfHybridParser` | PDF/image | hybrid | 本地小模型 + VLM 混合解析。 || `DocxParser` | DOCX | office | Office 文档解析。 |@@ -119,11 +119,11 @@ class DocumentParser:| Tier | 默认 backend | 说明 ||------|--------------|------|| `flash` | `flash` | 快速 CPU-only。 |-| `medium` | `hybrid-engine` + `effort="medium"` | 消费级硬件可用的本地小模型组合。 |-| `high` | hybrid 默认高质量 backend | 绝大多数场景足够好的高质量档位。 |-| `xhigh` | hybrid backend + 更高 effort | 最高质量档位,用更多算力和时间换取小幅质量提升。 |+| `basic` | `hybrid-engine` + `effort="medium"` | 消费级硬件可用的本地小模型组合。 |+| `standard` | hybrid 默认高质量 backend | 绝大多数场景足够好的高质量档位。 |+| `advanced` | hybrid backend + 更高 effort | 最高质量档位,用更多算力和时间换取小幅质量提升。 |-`tier=None` 表示使用默认选择策略。PDF/image 直接本地解析且没有能力列表时默认 `high`,有能力发现上下文时按 `high` -> `xhigh` -> `medium` 选择;Office/HTML 这类仅支持 flash tier 的输入未指定 tier 时归一为 `flash`,显式质量 tier 应报错。完整 tier 语义见 [解析 Tier](../tiers.md) 和 [ADR-0024](../decisions/0024-file-type-tier-normalization.md)。+`tier=None` 表示使用默认选择策略。PDF/image 直接本地解析且没有能力列表时默认 `standard`,有能力发现上下文时按 `standard` -> `advanced` -> `basic` 选择;Office/HTML 这类仅支持 flash tier 的输入未指定 tier 时归一为 `flash`,显式质量 tier 应报错。完整 tier 语义见 [解析 Tier](../tiers.md) 和 [ADR-0024](../decisions/0024-file-type-tier-normalization.md)。## 重依赖边界@@ -132,7 +132,7 @@ class DocumentParser:目标:- `from mineru.parser import parse, ParseResult` 应足够轻。-- `PdfPipelineParser` 仅作为旧 SDK 类名保留,内部走 Hybrid medium,不再加载独立 pipeline backend。+- `PdfPipelineParser` 仅作为旧 SDK 类名保留,内部走 Hybrid medium effort,不再加载独立 pipeline backend。- `PdfVlmParser` / `PdfHybridParser` 只在执行 VLM/hybrid 时加载对应 backend。- Office parser 可以在构造时绑定 analyze function,但不应在模块 import 时加载重依赖。@@ -141,7 +141,7 @@ class DocumentParser:```pythonfrom mineru.parser import parse-result = parse("report.pdf", tier="medium", page_range="1~5")+result = parse("report.pdf", tier="basic", page_range="1~5")print(result.markdown())```diff --git a/docs/next/sdk/tiers-errors.md b/docs/next/sdk/tiers-errors.mdindex b8f91548..e1e14a0a 100644--- a/docs/next/sdk/tiers-errors.md+++ b/docs/next/sdk/tiers-errors.md@@ -13,7 +13,7 @@ SDK 层必须使用与产品一致的 tier 语义。完整产品语义见 [解SDK 中未指定 tier,或 Python 调用传 `tier=None` 时,必须遵循 [解析 Tier](../tiers.md) 和 [ADR-0024](../decisions/0024-file-type-tier-normalization.md) 中的默认选择策略。-对 PDF/image,默认选择不能变成 `flash`。Office/HTML 没有质量 tier;单文件解析未指定 tier 时归一为 `flash`,显式传入 `medium`、`high` 或 `xhigh` 应报错。text 不作为解析输入,应直接读取。+对 PDF/image,默认选择不能变成 `flash`。Office/HTML 没有质量 tier;单文件解析未指定 tier 时归一为 `flash`,显式传入 `basic`、`standard` 或 `advanced` 应报错。text 不作为解析输入,应直接读取。## Tool SDK 的 tier 处理@@ -29,11 +29,11 @@ SDK 中未指定 tier,或 Python 调用传 `tier=None` 时,必须遵循 [解| Tier | Backend ||------|---------|| `flash` | `flash` |-| `medium` | `hybrid-engine` + `effort="medium"` |-| `high` | hybrid 默认高质量 backend |-| `xhigh` | hybrid backend + 更高 effort |+| `basic` | `hybrid-engine` + `effort="medium"` |+| `standard` | hybrid 默认高质量 backend |+| `advanced` | hybrid backend + 更高 effort |-`tier=None` 使用默认选择策略。PDF/image 直接本地解析且没有能力列表时默认 `high`;有能力发现上下文时按 `high` -> `xhigh` -> `medium` 选择。Office/HTML 单文件解析未指定 tier 时归一为 `flash`。结果记录实际 tier,不能为仅支持 flash tier 的输入记录伪质量 tier。text 不产生解析结果。+`tier=None` 使用默认选择策略。PDF/image 直接本地解析且没有能力列表时默认 `standard`;有能力发现上下文时按 `standard` -> `advanced` -> `basic` 选择。Office/HTML 单文件解析未指定 tier 时归一为 `flash`。结果记录实际 tier,不能为仅支持 flash tier 的输入记录伪质量 tier。text 不产生解析结果。## Doclib SDK 的 tier 处理diff --git a/docs/next/telemetry-minimum.md b/docs/next/telemetry-minimum.mdindex 77828bd6..1e15f023 100644--- a/docs/next/telemetry-minimum.md+++ b/docs/next/telemetry-minimum.md@@ -499,7 +499,7 @@ lock 存储规则:"dimensions": {"source": "cli","caller": "agent",- "tier": "medium(default)",+ "tier": "basic(default)","status": "queued"}}@@ -690,7 +690,7 @@ status = <metric-specific low-cardinality status>按需补充:```text-tier = default | flash | medium | high | xhigh | medium(default) | high(default) | xhigh(default) | unknown+tier = default | flash | basic | standard | advanced | basic(default) | standard(default) | advanced(default) | unknownserver = local(flash) | local(managed) | local(self-hosted) | remote(official) | remote(custom) | none | unknownerror_code = <telemetry_error_code>bucket = <metric bucket value>@@ -747,8 +747,8 @@ scan_failed`tier` 归一化规则:-- `flash` / `medium` / `high` / `xhigh` 表示用户显式指定,或后台任务的实体 tier。-- `medium(default)` / `high(default)` / `xhigh(default)` 只用于入口请求层指标,表示请求未显式指定 tier,但默认选择策略最终解析到了 `medium`、`high` 或 `xhigh`。+- `flash` / `basic` / `standard` / `advanced` 表示用户显式指定,或后台任务的实体 tier。+- `basic(default)` / `standard(default)` / `advanced(default)` 只用于入口请求层指标,表示请求未显式指定 tier,但默认选择策略最终解析到了 `basic`、`standard` 或 `advanced`。- `default` 只用于入口请求在默认 tier 解析完成前就失败,且调用方未显式指定 tier 的场景。- `unknown` 表示无法安全判断。@@ -1142,7 +1142,7 @@ parse.invalidate.count:- `parse.finished.count {status=failed}` 的 `tier` 规则:- 调用方显式指定 tier 且请求失败时,使用该显式 tier。- 调用方未显式指定 tier,且在默认 tier 解析完成前就失败时,使用 `default`。- - 调用方未显式指定 tier,但默认选择策略已明确解析到了实体 tier 后才失败时,使用 `medium(default)`、`high(default)` 或 `xhigh(default)`。+ - 调用方未显式指定 tier,但默认选择策略已明确解析到了实体 tier 后才失败时,使用 `basic(default)`、`standard(default)` 或 `advanced(default)`。采集点位:diff --git a/docs/next/telemetry.md b/docs/next/telemetry.mdindex b5c08871..351f64d9 100644--- a/docs/next/telemetry.md+++ b/docs/next/telemetry.md@@ -194,7 +194,7 @@ Content-Type: application/json"dimensions": {"source": "cli","caller": "agent",- "tier": "medium(default)",+ "tier": "basic(default)","status": "succeeded"}},@@ -204,7 +204,7 @@ Content-Type: application/json"dimensions": {"source": "cli","caller": "agent",- "tier": "medium(default)"+ "tier": "basic(default)"}}]@@ -257,7 +257,7 @@ Metric 的 `name` 表示数值指标,`value` 表示计数或数值累加。"name": "parse.completed.count","value": 1,"dimensions": {- "tier": "medium",+ "tier": "basic","status": "succeeded"}}@@ -268,7 +268,7 @@ Metric 的 `name` 表示数值指标,`value` 表示计数或数值累加。```json{"name": "parse.tier",- "value": "medium"+ "value": "basic"}```@@ -278,7 +278,7 @@ Dimension 只允许低基数字段:|------|-------------|| `source` | `http_api` / `sdk` / `cli` / `mcp` / `web` / `app` / `watch` / `background` / `unknown` || `caller` | `agent` / `user` / `http_client` / `sdk` / `web` / `app` / `system` / `unknown` |-| `tier` | `default` / `flash` / `medium` / `high` / `xhigh` / `medium(default)` / `high(default)` / `xhigh(default)` / `unknown` |+| `tier` | `default` / `flash` / `basic` / `standard` / `advanced` / `basic(default)` / `standard(default)` / `advanced(default)` / `unknown` || `status` | `succeeded` / `failed` / `partial` / `canceled` || `input_type` | `pdf` / `docx` / `pptx` / `xlsx` / `html` / `other` / `unknown` || `output_format` | `middle_json` / `markdown` / `structured_content` / `other` |@@ -324,8 +324,8 @@ CLI 的 `caller` 可以通过父进程识别。若父进程是 Claude Code、Cod`tier` 同时表达请求档位和实际解析档位:- 用户未指定 tier,且尚未解析到实体 tier 时,使用 `default`。-- 用户显式指定实体 tier,或任务已经完成且没有必要保留默认来源时,使用 `flash`、`medium`、`high` 或 `xhigh`。-- 用户未指定 tier,且已经解析到实体 tier,同时仍需要保留来源信息时,使用 `medium(default)`、`high(default)` 或 `xhigh(default)`。+- 用户显式指定实体 tier,或任务已经完成且没有必要保留默认来源时,使用 `flash`、`basic`、`standard` 或 `advanced`。+- 用户未指定 tier,且已经解析到实体 tier,同时仍需要保留来源信息时,使用 `basic(default)`、`standard(default)` 或 `advanced(default)`。- 默认选择不会解析为 `flash`,因此不定义 `flash(default)`。- parse-server 相关 metric 也使用同一个 `tier` 维度,不再单独使用 `parse_server_tier`。@@ -457,7 +457,7 @@ Parse-server 相关 metric 必须带以下维度,便于区分用户是否使```textserver: local(managed) | local(self-hosted) | remote(official) | remote(custom) | unknown-tier: medium | high | xhigh | medium(default) | high(default) | xhigh(default) | unknown+tier: basic | standard | advanced | basic(default) | standard(default) | advanced(default) | unknownstatus: succeeded | failed | partial | canceled```@@ -476,7 +476,7 @@ Parse-server 配置口径:- 数量: `parse_server.requested.count`、`parse_server.completed.count`、`parse_server.files.count`、`parse_server.processed_page_count`,且 `server=local(managed)` 或 `local(self-hosted)`。- 性能: `parse_server.duration.bucket.count`,且 `server=local(managed)` 或 `local(self-hosted)`。- 模式: 由 `server=local(managed)` 或 `local(self-hosted)` 区分。-- tier: `tier=medium`、`high`、`xhigh`、`medium(default)`、`high(default)` 或 `xhigh(default)`。+- tier: `tier=basic`、`standard`、`advanced`、`basic(default)`、`standard(default)` 或 `advanced(default)`。Telemetry 自身:diff --git a/docs/next/tiers.md b/docs/next/tiers.mdindex 4403b1d7..bc8ff664 100644--- a/docs/next/tiers.md+++ b/docs/next/tiers.md@@ -2,7 +2,7 @@状态: Draft读者: CLI/API/SDK 使用者、Agent skill 作者、核心开发者-范围: `flash`、`medium`、`high`、`xhigh` 解析 tier 的产品语义、默认选择策略、适用场景、质量边界和执行路径+范围: `flash`、`basic`、`standard`、`advanced` 解析 tier 的产品语义、默认选择策略、适用场景、质量边界和执行路径非目标: 固定具体模型名称或 backend 实现;定义 middle_json 字段级 schema底稿: 用户讨论;旧路线图、旧 CLI 与旧设计底稿迁移内容@@ -15,33 +15,33 @@ MinerU 当前定义四个公开 tier。文档中使用面向用户的显示名| 显示名 | 字面量 | 定位 | 一句话说明 ||--------|--------|------|------------|| Flash | `flash` | 快速发现与索引 | 随 MinerU 默认安装,最快、质量最低,用于大量文件的低成本预处理 |-| Medium | `medium` | 本地主力解析 | 需要额外依赖,CPU 可运行,GPU 可加速,质量和资源消耗折中 |-| High | `high` | 高质量解析 | 需要 VLM 相关依赖和支持的本地加速器,也可由 MinerU 线上 API 提供 |-| Extra High | `xhigh` | 专家最高档 | 与 High 硬件要求相同,但消耗更多算力和时间,面向更高质量要求 |+| Basic | `basic` | 基础解析 | 需要额外依赖,CPU 可运行,GPU 可加速,质量和资源消耗折中 |+| Standard | `standard` | 标准解析 | 需要 VLM 相关依赖和支持的本地加速器,也是 MinerU 线上 API 提供的档位 |+| Advanced | `advanced` | 高级解析 | 与 Standard 硬件要求相同,但消耗更多算力和时间,困难文档质量更高 |`auto` 不再作为公开 tier 值。CLI 中不传 `--tier`、HTTP API 中省略 `tier` 或传 JSON `null`、Python SDK 中传 `None`,都表示使用当前入口的默认选择策略。核心原则:- `flash` 用于发现、预览和建立搜索索引,不是 PDF/image 默认阅读质量。-- 当 Agent 或用户决定读取 PDF/image 文档时,如果没有指定 tier,默认选择不能解析为 `flash`;有能力发现上下文时优先使用 `high`。+- 当 Agent 或用户决定读取 PDF/image 文档时,如果没有指定 tier,默认选择不能解析为 `flash`;有能力发现上下文时优先使用 `standard`。- 默认选择策略在 PDF/image 质量解析语境下不会等价于 `flash`;Office/HTML 这类仅支持 flash tier 的输入按 [ADR-0024](decisions/0024-file-type-tier-normalization.md) 归一为 `flash` 语义;text 直接读取。-- `high` 是高质量 tier,也是 `mineru.net/api` 对外提供的解析层级。-- `xhigh` 是当前公开 tier 中质量和成本最高的档位。-- 本地运行 `high` 和 `xhigh` 是正式支持能力,不是实验能力;它们依赖 VLM 相关依赖、支持的本地加速器和足够的显存或统一内存。-- `mineru.net/api` 在相当长时间内只提供 `high`,不暴露低成本远端 `medium`。+- `standard` 是高质量 tier,也是 `mineru.net/api` 对外提供的解析层级。+- `advanced` 是当前公开 tier 中质量和成本最高的档位。+- 本地运行 `standard` 和 `advanced` 是正式支持能力,不是实验能力;它们依赖 VLM 相关依赖、支持的本地加速器和足够的显存或统一内存。+- `mineru.net/api` 在相当长时间内只提供 `standard`,不暴露低成本远端 `basic`。- 不使用 `--remote` 时,MinerU 不会把文档发送到 `mineru.net/api`。## 2. 实体 tier 区别-| 维度 | Flash (`flash`) | Medium (`medium`) | High (`high`) | Extra High (`xhigh`) |+| 维度 | Flash (`flash`) | Basic (`basic`) | Standard (`standard`) | Advanced (`advanced`) ||------|---------|------------|--------|--------------|| 主要目标 | 快速扫大量文件,建立基础索引 | 在普通本地硬件上提供可接受的高质量解析 | 提供高质量解析 | 提供最高成本/最高质量档位 |-| 安装依赖 | 随 MinerU 默认安装 | 需要额外 runtime 依赖 | 需要更多 runtime 依赖和 VLM 依赖 | 同 `high` |+| 安装依赖 | 随 MinerU 默认安装 | 需要额外 runtime 依赖 | 需要更多 runtime 依赖和 VLM 依赖 | 同 `standard` || 底层原理 | 纯 CPU 实现 | 基于模型 | 基于 VLM 的高质量模型路径 | 基于 VLM 的更高成本模型路径 || 质量 | 低 | 中 | 高 | 更高 |-| 速度 | 最快 | 中等 | 较慢,取决于硬件和远端服务 | 最慢,通常比 `high` 消耗更多算力和时间 |-| 本地硬件要求 | 无特殊硬件要求 | 需要至少 16GB 总内存;CPU 可运行,GPU 可加速 | 需要至少 16GB 总内存,并具备支持的本地加速器和足够的显存或统一内存 | 同 `high` |+| 速度 | 最快 | 中等 | 较慢,取决于硬件和远端服务 | 最慢,通常比 `standard` 消耗更多算力和时间 |+| 本地硬件要求 | 无特殊硬件要求 | 需要至少 16GB 总内存;CPU 可运行,GPU 可加速 | 需要至少 16GB 总内存,并具备支持的本地加速器和足够的显存或统一内存 | 同 `standard` || 是否适合 watch 自动处理 | 是 | 一般不默认使用 | 否 | 否 || 是否适合用户主动阅读 | 仅在用户明确选择时 | 是,默认最低阅读质量 | 是,质量优先场景 | 是,专家质量优先场景 || 典型场景 | 文件发现、快速预览、搜索索引 | 本地隐私解析、普通文档阅读 | 复杂版面、学术论文、高价值文档 | 极高质量要求、专家批处理或自部署 |@@ -54,7 +54,7 @@ MinerU 当前定义四个公开 tier。文档中使用面向用户的显示名### 3.1 无能力列表的场景-启动服务或直接解析时,如果当前入口没有可用 tier 列表可参考,默认 tier 是 `high`。+启动服务或直接解析时,如果当前入口没有可用 tier 列表可参考,默认 tier 是 `standard`。典型场景:@@ -62,36 +62,36 @@ MinerU 当前定义四个公开 tier。文档中使用面向用户的显示名- `mineru-kit parse` local 模式未传 `--tier` / `--backend`。- Tool SDK 直接本地解析且无法做能力发现。-这类场景的默认值不是 `xhigh`。`xhigh` 消耗更多算力和时间,需要用户显式指定,或由具备能力发现上下文的调用方在没有 `high` 时选择。+这类场景的默认值不是 `advanced`。`advanced` 消耗更多算力和时间,需要用户显式指定,或由具备能力发现上下文的调用方在没有 `standard` 时选择。### 3.2 有能力发现上下文的场景-当调用某个 parse-server,或有等价的可用 tier 上下文时,默认选择策略基于当前可发现能力选择实体 tier。MinerU 有 local parse-server,也有 remote parse-server。无论 local 还是 remote,parse-server 都应支持通过 API 发现当前 server 提供了哪些解析 tier。当前代码支持发现 `medium`、`high`、`xhigh` 等质量 tier。+当调用某个 parse-server,或有等价的可用 tier 上下文时,默认选择策略基于当前可发现能力选择实体 tier。MinerU 有 local parse-server,也有 remote parse-server。无论 local 还是 remote,parse-server 都应支持通过 API 发现当前 server 提供了哪些解析 tier。当前代码支持发现 `basic`、`standard`、`advanced` 等质量 tier。这类场景的默认选择顺序是:```text-high -> xhigh -> medium -> 报错+standard -> advanced -> basic -> 报错```-也就是说,`high` 是默认优先档位;`xhigh` 虽然质量最高,但不会在 `high` 同时可用时自动成为默认。只有没有 `high`、但有 `xhigh` 时,默认才选择 `xhigh`。+也就是说,`standard` 是默认优先档位;`advanced` 虽然质量最高,但不会在 `standard` 同时可用时自动成为默认。只有没有 `standard`、但有 `advanced` 时,默认才选择 `advanced`。| 可发现能力 | 默认解析结果 ||------------|-----------------|-| 只支持 `medium` | `medium` |-| 只支持 `high` | `high` |-| 只支持 `xhigh` | `xhigh` |-| 同时支持 `medium` 和 `high` | `high` |-| 同时支持 `high` 和 `xhigh` | `high` |-| 同时支持 `medium` 和 `xhigh`,不支持 `high` | `xhigh` |-| 同时支持 `medium`、`high` 和 `xhigh` | `high` |+| 只支持 `basic` | `basic` |+| 只支持 `standard` | `standard` |+| 只支持 `advanced` | `advanced` |+| 同时支持 `basic` 和 `standard` | `standard` |+| 同时支持 `standard` 和 `advanced` | `standard` |+| 同时支持 `basic` 和 `advanced`,不支持 `standard` | `advanced` |+| 同时支持 `basic`、`standard` 和 `advanced` | `standard` || 只支持 `flash` 或没有可用能力 | 报错 |-PDF/image 默认选择策略不会解析为 `flash`。如果系统找不到 `medium`、`high` 或 `xhigh`,应返回 `quality_tier_unavailable` 或等价结构化错误,而不是擅自用 `flash` 内容替代。错误码见 [错误码体系](errors.md)。+PDF/image 默认选择策略不会解析为 `flash`。如果系统找不到 `basic`、`standard` 或 `advanced`,应返回 `quality_tier_unavailable` 或等价结构化错误,而不是擅自用 `flash` 内容替代。错误码见 [错误码体系](errors.md)。-默认选择策略是请求时的选择逻辑,不是长期缓存语义。任务入队、缓存命中、产物目录和结果 metadata 应使用实际选择的实体 tier(例如 `medium`、`high` 或 `xhigh`),避免默认选择与实体 tier 产生重复缓存。+默认选择策略是请求时的选择逻辑,不是长期缓存语义。任务入队、缓存命中、产物目录和结果 metadata 应使用实际选择的实体 tier(例如 `basic`、`standard` 或 `advanced`),避免默认选择与实体 tier 产生重复缓存。-读取已有缓存时不使用这套解析默认顺序。`mineru read doc:{short_id}` 不带 `/tier:{tier}` 时不会创建新解析,应在已缓存的非 `flash` 结果中选择最高质量 tier,顺序为 `xhigh` -> `high` -> `medium`;没有非 `flash` 缓存时返回错误。+读取已有缓存时不使用这套解析默认顺序。`mineru read doc:{short_id}` 不带 `/tier:{tier}` 时不会创建新解析,应在已缓存的非 `flash` 结果中选择最高质量 tier,顺序为 `advanced` -> `standard` -> `basic`;没有非 `flash` 缓存时返回错误。## 4. Flash@@ -99,41 +99,41 @@ PDF/image 默认选择策略不会解析为 `flash`。如果系统找不到 `med`flash` 的核心用途是支撑大量文件的自动发现和低成本预处理。MinerU 的 watch 机制会发现很多文件;在系统刚看到这些文件时,并不知道每个文件的价值,也不适合立即使用高算力方案处理。因此 watch 默认使用 `flash` 快速提取最基础内容,用于建立搜索索引和后续发现。-P0 不做基于启发式的自动提示或自动排队升级。watch 使用 `flash` 后,如果需要在后台自动解析到 `medium`、`high` 或 `xhigh`,必须来自用户显式配置的 parsing-rules;系统不根据文件名、内容特征、搜索命中或“高价值文档”判断自行升级。+P0 不做基于启发式的自动提示或自动排队升级。watch 使用 `flash` 后,如果需要在后台自动解析到 `basic`、`standard` 或 `advanced`,必须来自用户显式配置的 parsing-rules;系统不根据文件名、内容特征、搜索命中或“高价值文档”判断自行升级。`flash` 不应被当成 PDF/image 默认阅读质量。当 Agent 或用户决定真正读取 PDF/image 文档时,需求已经从“发现它”变成“尽可能准确地理解它”,此时未指定 tier 应使用默认选择策略,并解析到可用的非 `flash` 质量 tier。Office/HTML 这类仅支持 flash tier 的输入没有质量 tier 分层,按 `flash` 语义处理。text 直接读取。只有在用户明确指定 `flash` 时,才返回 `flash` 的解析内容作为最终阅读结果。-## 5. Medium+## 5. Basic-`medium` 是本地主力解析 tier,当前使用 `hybrid-engine` 的 `medium` effort。它需要额外 runtime 依赖,是一系列本地模型串联的解析方案。+`basic` 是基础解析 tier,当前使用 `hybrid-engine` 的 `medium` effort。它需要额外 runtime 依赖,是一系列本地模型串联的解析方案。-`medium` 可以在 CPU 上运行,也可以由 GPU 加速。GPU 和显存不是启用 `medium` 的硬门槛,但会影响速度、吞吐和稳定性。因此 `medium` 是一个算力消耗较低、质量中等、仍然基于模型的解析方案。+`basic` 可以在 CPU 上运行,也可以由 GPU 加速。GPU 和显存不是启用 `basic` 的硬门槛,但会影响速度、吞吐和稳定性。因此 `basic` 是一个算力消耗较低、质量中等、仍然基于模型的解析方案。-`medium` 的核心价值是本地隐私解析:当用户不接受把文档发送到远端解析,同时硬件又不是特别高端时,`medium` 应成为本地可用的最佳默认方案。+`basic` 的核心价值是本地隐私解析:当用户不接受把文档发送到远端解析,同时硬件又不是特别高端时,`basic` 应成为本地可用的最佳默认方案。-本地 managed `medium`、`high` 和 `xhigh` parse server 都要求至少 16GB 总内存。低于该基线时,不建议启用本地 managed 质量 tier;应考虑远端解析,或在用户明确接受低质量时显式使用 `flash`。+本地 managed `basic`、`standard` 和 `advanced` parse server 都要求至少 16GB 总内存。低于该基线时,不建议启用本地 managed 质量 tier;应考虑远端解析,或在用户明确接受低质量时显式使用 `flash`。-## 6. High+## 6. Standard-`high` 是 MinerU 的高质量 tier,也是 `mineru.net/api` 当前提供的解析层级。+`standard` 是 MinerU 的高质量 tier,也是 `mineru.net/api` 当前提供的解析层级。-`high` 代表高质量解析能力。它既可以由 `mineru.net/api` 提供,也可以由本地高端硬件运行。+`standard` 代表高质量解析能力。它既可以由 `mineru.net/api` 提供,也可以由本地高端硬件运行。-本地 managed `high` 需要安装 VLM 相关 runtime 依赖,要求至少 16GB 总内存,并满足以下本地加速器条件之一:+本地 managed `standard` 需要安装 VLM 相关 runtime 依赖,要求至少 16GB 总内存,并满足以下本地加速器条件之一:- Volta 或更新架构的 NVIDIA GPU,且可供 MinerU 使用的 VRAM 至少 8GB。- Apple Silicon,且统一内存至少 16GB。- MinerU 支持的特殊 AI 加速器,例如 `npu`、`gcu`、`musa`、`mlu` 或 `sdaa`。-`high` 适合复杂版面、学术论文、高价值文档和多数高质量解析场景。它的代价是更高的算力、显存、等待时间或远端调用成本。+`standard` 适合复杂版面、学术论文、高价值文档和多数高质量解析场景。它的代价是更高的算力、显存、等待时间或远端调用成本。-## 7. Extra High+## 7. Advanced-`xhigh` 是当前公开 tier 中最高的本地/自部署档位。+`advanced` 是当前公开 tier 中最高的本地/自部署档位。-它适合极高质量要求、专家批处理或自部署服务。`xhigh` 与 `high` 的本地硬件要求相同,也需要 VLM 相关 runtime 依赖;区别是 `xhigh` 会消耗更多算力,通常需要更长解析时间,并可能带来更高运行成本。用户主动指定 `--tier xhigh`,或目标 parse-server 能力发现只暴露/优先暴露 `xhigh` 时,系统可以使用该 tier。+它适合极高质量要求、专家批处理或自部署服务。`advanced` 与 `standard` 的本地硬件要求相同,也需要 VLM 相关 runtime 依赖;区别是 `advanced` 会消耗更多算力,通常需要更长解析时间,并可能带来更高运行成本。用户主动指定 `--tier advanced`,或目标 parse-server 能力发现只暴露/优先暴露 `advanced` 时,系统可以使用该 tier。## 8. 隐私优先与质量优先@@ -149,7 +149,7 @@ MinerU 的 tier 策略同时遵守隐私优先和质量优先。用户或 Agent 主动读取 PDF/image 文档时,默认应解析到可用的非 `flash` 质量 tier。-如果 `medium`、`high` 和 `xhigh` 都不可用,且远端也不可用,系统应报错,而不是擅自把 `flash` 结果作为最终阅读结果返回。+如果 `basic`、`standard` 和 `advanced` 都不可用,且远端也不可用,系统应报错,而不是擅自把 `flash` 结果作为最终阅读结果返回。`flash` 结果可以用于索引、发现、预览和提示用户选择更高 tier;只有用户明确选择 `flash` 时,才可作为最终解析返回。@@ -158,16 +158,16 @@ MinerU 的 tier 策略同时遵守隐私优先和质量优先。| 请求 | 默认执行路径 ||------|--------------|| watch 自动发现文件 | 本地 `flash` |-| `mineru-kit api-server` 未传 `--tier` | 以 `high` 作为服务默认 tier |-| `mineru-kit parse` local 模式未传 `--tier` / `--backend` | PDF/image 直接按 `high` 解析;Office/HTML 按 `flash` 语义处理;text 不作为解析输入 |+| `mineru-kit api-server` 未传 `--tier` | 以 `standard` 作为服务默认 tier |+| `mineru-kit parse` local 模式未传 `--tier` / `--backend` | PDF/image 直接按 `standard` 解析;Office/HTML 按 `flash` 语义处理;text 不作为解析输入 || watch 命中 parsing-rule 且 rule 指定 tier | PDF/image 按 rule 中的 tier、页码范围和 remote 配置执行;Office/HTML 忽略 rule tier 和 remote,按 `flash`;text 只入库和索引 |-| watch 命中 parsing-rule 但 rule 未指定 tier | PDF/image 按 `high` -> `xhigh` -> `medium` -> `flash` 选择;Office/HTML 按 `flash`;text 只入库和索引 |-| 用户主动 parse,未指定 tier;HTTP API 传 JSON `null`;Python SDK 传 `None` | PDF/image 有能力发现上下文时按 `high` -> `xhigh` -> `medium` 选择;Office/HTML 按 [ADR-0024](decisions/0024-file-type-tier-normalization.md) 归一为 `flash`;text 不进入解析 |+| watch 命中 parsing-rule 但 rule 未指定 tier | PDF/image 按 `standard` -> `advanced` -> `basic` -> `flash` 选择;Office/HTML 按 `flash`;text 只入库和索引 |+| 用户主动 parse,未指定 tier;HTTP API 传 JSON `null`;Python SDK 传 `None` | PDF/image 有能力发现上下文时按 `standard` -> `advanced` -> `basic` 选择;Office/HTML 按 [ADR-0024](decisions/0024-file-type-tier-normalization.md) 归一为 `flash`;text 不进入解析 || 用户主动指定 `--tier flash` | 本地 `flash` |-| 用户主动指定 `--tier medium` | 本地 medium;不可用时报错 |-| 用户主动指定 `--tier high` | 本地 high;显式 remote 时使用 `mineru.net/api` high |-| 用户主动指定 `--tier xhigh` | 本地或自部署 Extra High;不可用时报错 |-| 用户显式 `--remote` | 允许上传到 `mineru.net/api`,使用远端 `high` |+| 用户主动指定 `--tier basic` | 本地 basic;不可用时报错 |+| 用户主动指定 `--tier standard` | 本地 standard;显式 remote 时使用 `mineru.net/api` standard |+| 用户主动指定 `--tier advanced` | 本地或自部署 Advanced;不可用时报错 |+| 用户显式 `--remote` | 允许上传到 `mineru.net/api`,使用远端 `standard` |执行路径需要与 [系统架构](architecture.md) 中的 ParseWorker 路由保持一致。@@ -176,10 +176,10 @@ MinerU 的 tier 策略同时遵守隐私优先和质量优先。CLI、API 和 SDK 暴露 tier 时,应遵守同一语义:- 对用户显示 tier,不显示具体 backend 名称作为主要选择项。-- 公开 tier 取值包括 `flash`、`medium`、`high`、`xhigh`。+- 公开 tier 取值包括 `flash`、`basic`、`standard`、`advanced`。- CLI 不传 `--tier`、HTTP API 省略 `tier` 或传 JSON `null`、Python SDK 传 `None`,表示使用当前入口按文件类型定义的默认选择策略。-- 没有能力列表的启动服务或直接解析场景默认使用 `high`。-- PDF/image 有能力发现上下文时,默认选择策略按 `high` -> `xhigh` -> `medium` 解析为非 `flash` 质量 tier。+- 没有能力列表的启动服务或直接解析场景默认使用 `standard`。+- PDF/image 有能力发现上下文时,默认选择策略按 `standard` -> `advanced` -> `basic` 解析为非 `flash` 质量 tier。- PDF/image 默认阅读质量不能静默降级到 `flash`。- 当更高 tier 不可用时,应返回结构化错误和修复建议。- 当用户显式选择 `flash` 时,可以返回 `flash` 内容。diff --git a/docs/next/workflows.md b/docs/next/workflows.mdindex 142a0822..3dc89f7d 100644--- a/docs/next/workflows.md+++ b/docs/next/workflows.md@@ -12,7 +12,7 @@它串联以下专题:- 术语以 [术语表](glossary.md) 为准。-- 默认选择 / `flash` / `medium` / `high` / `xhigh` 的语义以 [解析 Tier](tiers.md) 为准。+- 默认选择 / `flash` / `basic` / `standard` / `advanced` 的语义以 [解析 Tier](tiers.md) 为准。- doclib、worker、SQLite 和 parse-server 的内部结构以 [系统架构](architecture.md) 为准。- CLI 行为以 [CLI 规格](cli.md) 为准。- v1 API 行为以 [Unified API](api.md) 为准。@@ -36,7 +36,7 @@| Doclib SDK | 本地文档库 SDK | 连接 doclib server,使用 parse/search/watch/config 能力。 || Tool SDK | 工具 SDK | 进程内直接解析文件,返回 `ParseResult`。 || doclib server | 本地文档库服务 | 入库、缓存、搜索、watch、配置、任务调度。 |-| parse-server | 解析服务 | 无状态解析服务,提供 v1 Unified API,执行 `medium` / `high` / `xhigh` 等质量 tier。 |+| parse-server | 解析服务 | 无状态解析服务,提供 v1 Unified API,执行 `basic` / `standard` / `advanced` 等质量 tier。 || Local Parse Server | 本地解析服务 | 用户可信环境内的 parse-server。 || Remote Parse Server | 远端解析服务 | `mineru.net/api` 或显式配置的远端兼容服务。 || Backend | 解析后端 | 实际解析实现,例如 `flash`、`pipeline`、`vlm`、`hybrid`。 |@@ -68,7 +68,7 @@├─ mineru parse / Agent 主动读取│ -> doclib ParseService│ -> 查缓存- │ -> 默认选择/flash/medium/high/xhigh 路由+ │ -> 默认选择/flash/basic/standard/advanced 路由│ -> ParseWorker│ -> Tool SDK 或 parse-server│ -> Middle JSON batch JSON@@ -103,7 +103,7 @@ watch 的目标是发现文件、建立基础索引和支持后续搜索,不|------|-----------|| watch 自动发现 | `flash` || parsing-rule 明确指定 | PDF/image 使用 rule 中的 tier;Office/HTML 归一为 `flash`;text 只入库和索引 |-| parsing-rule 未指定 tier | PDF/image 按 `high` -> `xhigh` -> `medium` -> `flash`;Office/HTML 归一为 `flash`;text 只入库和索引 |+| parsing-rule 未指定 tier | PDF/image 按 `standard` -> `advanced` -> `basic` -> `flash`;Office/HTML 归一为 `flash`;text 只入库和索引 |### 5.3 步骤@@ -289,7 +289,7 @@ client.parse("report.pdf")3. 如果文件尚未入库,先同步执行 ingest,得到 `sha256`。4. 确定页码范围、输出格式、等待策略和隐私偏好。5. 如果用户未指定 tier,使用默认选择策略。-6. PDF/image 默认选择策略通过当前可用 parse-server 能力发现,按 `high` -> `xhigh` -> `medium` 选择;Office/HTML 归一为 `flash`;text 直接读取。+6. PDF/image 默认选择策略通过当前可用 parse-server 能力发现,按 `standard` -> `advanced` -> `basic` 选择;Office/HTML 归一为 `flash`;text 直接读取。7. 将任务和缓存键落到实际使用的实体 tier。8. 查询 `(sha256, tier, page_range)` 是否已有可复用结果。9. 缓存命中则直接 render 并返回。@@ -306,13 +306,13 @@ client.parse("report.pdf")| 请求 | 实际行为 ||------|----------|-| 未指定 tier | PDF/image 按 `high` -> `xhigh` -> `medium` 选择可用的非 `flash` tier;Office/HTML 归一为 `flash`;text 直接读取 |+| 未指定 tier | PDF/image 按 `standard` -> `advanced` -> `basic` 选择可用的非 `flash` tier;Office/HTML 归一为 `flash`;text 直接读取 || `tier=flash` | 显式使用本地 `flash` backend |-| `tier=medium` | 使用本地或自部署 parse-server 的 `medium` 能力 |-| `tier=high` | 使用本地 `high` 或 `mineru.net/api` 的 `high` 能力 |-| `tier=xhigh` | 使用本地或自部署 parse-server 的 `xhigh` 能力 |+| `tier=basic` | 使用本地或自部署 parse-server 的 `basic` 能力 |+| `tier=standard` | 使用本地 `standard` 或 `mineru.net/api` 的 `standard` 能力 |+| `tier=advanced` | 使用本地或自部署 parse-server 的 `advanced` 能力 |-结果只需要记录实际使用的 `tier`。如果默认选择最终选择 `high`,产物、缓存和 metadata 使用 `high`。+结果只需要记录实际使用的 `tier`。如果默认选择最终选择 `standard`,产物、缓存和 metadata 使用 `standard`。### 6.5 隐私决策@@ -375,7 +375,7 @@ watch -> flash index -> search result -> Agent chooses document -> mineru parse| 自动发现 | `flash` || 搜索召回 | `flash` || 搜索 snippet | `flash`,但应可标记来源 tier |-| Agent 主动阅读 | `medium`,除非显式选择 `flash` |+| Agent 主动阅读 | `basic`,除非显式选择 `flash` || Agent 引用/citation | 应优先来自质量 tier |### 7.4 Agent marker@@ -383,7 +383,7 @@ watch -> flash index -> search result -> Agent chooses document -> mineru parse当输出被截断或只解析部分页时,应输出可机器理解的 marker:```text-<!-- mineru:next page_range=6~10 tier=high -->+<!-- mineru:next page_range=6~10 tier=standard -->```marker 不应依赖自然语言提示。具体 marker 格式可在 CLI 或 Agent 文档中继续细化。@@ -435,7 +435,7 @@ doclib 可以调用 parse-server,但 parse-server 不依赖 doclib。```pythonfrom mineru.parser import parse-result = parse("report.pdf", tier="medium")+result = parse("report.pdf", tier="basic")```或使用具体 parser:@@ -483,13 +483,13 @@ doclib 解析产物按内容和实际使用的 tier 隔离。`parsed/` 目录下flash/1~5_1710000000000.json98~102_1710000123000.json- medium/+ basic/1~10_1710001234000.json11~20_1710002234000.jsonimages/ # 可选,仅保存解析产生的必要 sidecar- high/+ standard/1~20_1710003234000.json- xhigh/+ advanced/1~20_1710004234000.json```@@ -662,16 +662,16 @@ FTS 更新可以在解析完成后临时从 ParseResult 或 Middle JSON 渲染 M输入:```bash-mineru parse report.pdf --tier medium --wait 60+mineru parse report.pdf --tier basic --wait 60```期望:1. 不上传远端。-2. 使用 Local Parse Server 或本地可用 medium 能力。-3. JSON 产物写入 `parsed/<sha-prefix>/<sha>/medium/<page_range>_<done_at>.json`。+2. 使用 Local Parse Server 或本地可用 Basic 能力。+3. JSON 产物写入 `parsed/<sha-prefix>/<sha>/basic/<page_range>_<done_at>.json`。4. 返回 Markdown 或指定格式;非 JSON 格式从 JSON 转换得到。-5. `tier` 记录为 `medium`。+5. `tier` 记录为 `basic`。### 13.3 主动 parse 默认选择成功@@ -683,13 +683,13 @@ mineru parse report.pdf --wait 60前提:-- 可发现 Local Parse Server 支持 `high`。+- 可发现 Local Parse Server 支持 `standard`。期望:1. 请求未指定 tier,进入默认选择策略。-2. 实际选择 `high`。-3. 任务和 JSON 产物记录 `tier=high`。+2. 实际选择 `standard`。+3. 任务和 JSON 产物记录 `tier=standard`。4. 不记录 `requested_tier` 字段。5. 不创建默认选择专用缓存目录。@@ -732,14 +732,14 @@ mineru parse report.pdf --tier flash输入:```bash-mineru parse report.pdf --tier medium --pages 1~5-mineru parse report.pdf --tier medium --pages 6~10+mineru parse report.pdf --tier basic --pages 1~5+mineru parse report.pdf --tier basic --pages 6~10```期望:1. 两次请求可以生成两个 done parse batch。-2. `parsed/<sha-prefix>/<sha>/medium/` 下保存两个 JSON 文件。+2. `parsed/<sha-prefix>/<sha>/basic/` 下保存两个 JSON 文件。3. 每个 JSON 文件只包含对应页码范围的 `pages`。4. 后续请求 `--pages 1~10` 可以由已完成批次覆盖,不需要重新解析。5. compaction 可以将两个批次合并成更少的 parse row 和 JSON 文件。@@ -750,8 +750,8 @@ mineru parse report.pdf --tier medium --pages 6~10输入:```bash-mineru parse report.pdf --tier medium --pages 1~5-mineru parse report.pdf --tier medium --pages 1~5 --force+mineru parse report.pdf --tier basic --pages 1~5+mineru parse report.pdf --tier basic --pages 1~5 --force```期望:@@ -769,7 +769,7 @@ mineru parse report.pdf --tier medium --pages 1~5 --force输入:```bash-mineru library invalidate report.pdf --tier medium+mineru library invalidate report.pdf --tier basic```期望:@@ -786,12 +786,12 @@ mineru library invalidate report.pdf --tier medium输入:```bash-mineru parse report.pdf --tier high+mineru parse report.pdf --tier standard```前提:-- 本地没有 `high`。+- 本地没有 `standard`。- 未显式 `--remote`。期望:@@ -803,7 +803,7 @@ mineru parse report.pdf --tier high输入:```bash-mineru parse report.pdf --tier high --remote+mineru parse report.pdf --tier standard --remote```期望:diff --git a/docs/plans/2026-06-15-cli-next-command-design.md b/docs/plans/2026-06-15-cli-next-command-design.mdindex 0dce1feb..4124782e 100644--- a/docs/plans/2026-06-15-cli-next-command-design.md+++ b/docs/plans/2026-06-15-cli-next-command-design.md@@ -38,8 +38,8 @@ MVP 还在开发阶段,因此本设计不保留旧命令兼容入口。- parse-server 相关配置使用 `parse_server.*` key,不再提供 `config parse-server` 快捷命令。5. **暂不增加内容读取子命令**- - 暂不加入 `mineru content <sha256> --tier medium --pages 1~5`。- - 暂不加入 `mineru show doc <sha256> --content --tier medium --pages 1~5`。+ - 暂不加入 `mineru content <sha256> --tier basic --pages 1~5`。+ - 暂不加入 `mineru show doc <sha256> --content --tier basic --pages 1~5`。- 解析内容读取继续由 `mineru parse <file>` 的输出行为承担。## 3. 推荐命令树@@ -66,7 +66,7 @@ MVP 还在开发阶段,因此本设计不保留旧命令兼容入口。### 4.1 发起解析```bash-mineru parse <file> [--tier flash|medium|high] [--pages <range>] [--format markdown] [--force] [--remote] [--wait <sec>] [--no-wait] [-o <path>] [--json] [-v]+mineru parse <file> [--tier flash|basic|standard] [--pages <range>] [--format markdown] [--force] [--remote] [--wait <sec>] [--no-wait] [-o <path>] [--json] [-v]```语义:@@ -81,7 +81,7 @@ mineru parse <file> [--tier flash|medium|high] [--pages <range>] [--format markd### 4.2 列出解析任务```bash-mineru list parses [--status pending|parsing|done|failed|superseded] [--tier flash|medium|high] [--limit 50] [--offset 0] [--json]+mineru list parses [--status pending|parsing|done|failed|superseded] [--tier flash|basic|standard] [--limit 50] [--offset 0] [--json]```说明:@@ -279,7 +279,7 @@ mineru config parse-server remote.url https://...```bashmineru config set parse_server.local.mode managed-mineru config set parse_server.local.managed_tier medium+mineru config set parse_server.local.managed_tier basicmineru config set parse_server.local.self_hosted_url http://127.0.0.1:8000mineru config set parse_server.local.self_hosted_api_key <key>mineru config set parse_server.remote.url https://mineru.net/api@@ -350,7 +350,7 @@ MVP 阶段不保留旧 HTTP path 兼容入口,直接把配置子资源从 `/co```json{- "tier": "medium",+ "tier": "basic","page_range": "1~5","format": "markdown","output": "/absolute/or/server-visible/path.md",@@ -363,7 +363,7 @@ MVP 阶段不保留旧 HTTP path 兼容入口,直接把配置子资源从 `/co```json{"sha256": "<sha256>",- "tier": "medium",+ "tier": "basic","output": "/absolute/or/server-visible/path.md"}```@@ -417,8 +417,8 @@ mineru server status [--json]暂不设计:```bash-mineru content <sha256> --tier medium --pages 1~5-mineru show doc <sha256> --content --tier medium --pages 1~5+mineru content <sha256> --tier basic --pages 1~5+mineru show doc <sha256> --content --tier basic --pages 1~5mineru parse listmineru parses ...mineru scan listdiff --git a/docs/plans/2026-06-17-mineru-kit-implementation-plan.md b/docs/plans/2026-06-17-mineru-kit-implementation-plan.mdindex 55444473..1c3ad4ac 100644--- a/docs/plans/2026-06-17-mineru-kit-implementation-plan.md+++ b/docs/plans/2026-06-17-mineru-kit-implementation-plan.md@@ -180,7 +180,7 @@ mineru-kit = "mineru.kit.main:app"重点事项:-- `--tier` 默认 `high`+- `--tier` 默认 `standard`- `--tier` / `--backend` 冲突时提前报错- 不暴露 `--reload`- 保留:diff --git a/docs/zh/quick_start/index.md b/docs/zh/quick_start/index.mdindex 21d571bb..8d9f8709 100644--- a/docs/zh/quick_start/index.md+++ b/docs/zh/quick_start/index.md@@ -53,9 +53,9 @@<tr><th>精度指标<sup>1</sup></th><td style="text-align:center;">86.47</td>- <td style="text-align:center;">95.39(high)<br>95.26(medium)</td>+ <td style="text-align:center;">95.39(effort=high)<br>95.26(effort=medium)</td><td style="text-align:center;">95.30</td>- <td style="text-align:center;">95.39(high)<br>95.26(medium)</td>+ <td style="text-align:center;">95.39(effort=high)<br>95.26(effort=medium)</td><td style="text-align:center;">95.30</td></tr><tr>diff --git a/docs/zh/usage/cli_tools.md b/docs/zh/usage/cli_tools.mdindex 96399ac1..2b736fe7 100644--- a/docs/zh/usage/cli_tools.md+++ b/docs/zh/usage/cli_tools.md@@ -14,14 +14,14 @@ Options:-m, --method [auto|txt|ocr] 解析方法:auto(默认)、txt、ocr(仅用于 hybrid* 后端)-b, --backend [hybrid-engine|hybrid-http-client]解析后端(默认为 hybrid-engine)- --effort [low|medium|high] Hybrid 解析强度(默认:medium)+ --effort [medium|high|xhigh] Hybrid 解析强度(默认:high)-l, --lang [ch|ch_server|korean|ta|te|ka|th|el|arabic|east_slavic|cyrillic|devanagari]指定文档语言(可提升 OCR 准确率,仅用于 hybrid* 后端)-u, --url TEXT 当使用 http-client 时,传给服务端后端的 OpenAI 兼容地址-s, --start INTEGER 开始解析的页码(从 0 开始)-e, --end INTEGER 结束解析的页码(从 0 开始)--image-analysis BOOLEAN 是否启用 hybrid 的图片/图表分析;Hybrid- low 和 medium 强度会自动关闭图片/图表分析(默认开启)+ medium 和 high effort 会自动关闭图片/图表分析(默认开启)--client-side-output-generation BOOLEAN在客户端基于服务端返回的 middle JSON、图片与原文件生成 Markdown 和 content list(默认关闭)diff --git a/docs/zh/usage/model_source.md b/docs/zh/usage/model_source.mdindex 3359d0fd..0683e1a9 100644--- a/docs/zh/usage/model_source.md+++ b/docs/zh/usage/model_source.md@@ -39,13 +39,13 @@ mineru-kit models download --help```或下载全部内置模型包:```bash-mineru-kit models download --tier high+mineru-kit models download --tier standard```> [!NOTE]>- 模型会下载到 `config.model.base_dir` 下,默认路径为 `~/.mineru/models`。>- `mineru-kit models download` 不会把模型路径写入 `mineru.json`。>- 如需自定义模型目录,请先在 `config.yaml` 中设置 `model.base_dir`,再执行下载。->- 如需更新模型文件,可以再次运行 `mineru-kit models download --tier high`;在同一个 `model.base_dir` 下,provider SDK 会尽量复用已有文件做增量更新。+>- 如需更新模型文件,可以再次运行 `mineru-kit models download --tier standard`;在同一个 `model.base_dir` 下,provider SDK 会尽量复用已有文件做增量更新。>- `mineru-kit models download` 必须使用远端模型源执行真实下载;如果当前配置为 `model.source: local`,该命令会仅在本次执行中临时按 `auto` 处理。>- MinerU 会在整仓下载完成后于仓库根目录写入空白 `.mineru_complete`;按指定路径下载时,则分别标记已完成的模型目录。旧版本或中断下载留下但没有相应 marker 的目录,会在使用前通过 provider 增量下载确认;当 `model.source: local` 时,这类目录会报告为未 ready,而不会访问网络。diff --git a/mineru/cli/commands/config.py b/mineru/cli/commands/config.pyindex 86547d84..b7cb3bc2 100644--- a/mineru/cli/commands/config.py+++ b/mineru/cli/commands/config.py@@ -100,7 +100,7 @@ def exclude_rules_remove(rule_id: int = typer.Argument(..., help="Rule id to rem@parsing_rules_app.command("add")def parsing_rules_add(pattern: str = typer.Argument(..., help="Glob pattern to match"),- tier: Tier | None = typer.Option(None, "--tier", help="Parse tier: flash, medium, high, xhigh"),+ tier: Tier | None = typer.Option(None, "--tier", help="Parse tier: flash, basic, standard, advanced"),pages: str | None = typer.Option(None, "--pages", help="Page range, e.g. all or 1~10"),remote: bool = typer.Option(False, "--remote", help="Allow remote parsing"),name: str | None = typer.Option(None, "--name", help="Rule name"),diff --git a/mineru/cli/commands/parse.py b/mineru/cli/commands/parse.pyindex 7cff264b..85b37f85 100644--- a/mineru/cli/commands/parse.py+++ b/mineru/cli/commands/parse.py@@ -85,7 +85,7 @@ def parse_cmd(tier: Tier | None = typer.Option(None,"--tier",- help="Parse tier: flash, medium, high, xhigh (default: server decides)",+ help="Parse tier: flash, basic, standard, advanced (default: server decides)",),pages: str = typer.Option(None, "-p", "--pages", help="Page range, e.g. '1~5' or 'all'"),after: str = typer.Option(None, "--after", help="Continue reading after a content cursor"),diff --git a/mineru/cli/commands/read.py b/mineru/cli/commands/read.pyindex 854d86eb..e7674296 100644--- a/mineru/cli/commands/read.py+++ b/mineru/cli/commands/read.py@@ -23,7 +23,7 @@ class ReadTextOutput:def read_cmd(- locator: str = typer.Argument(..., help="Doclib locator, e.g. doc:ab12cd3/tier:medium/page:4"),+ locator: str = typer.Argument(..., help="Doclib locator, e.g. doc:ab12cd3/tier:basic/page:4"),context: int = typer.Option(0, "--context", help="Read N pages/blocks before and after the locator"),limit: int = typer.Option(30000, "--limit", help="Soft character limit for STDOUT content"),format: Literal["markdown", "image"] = typer.Option("markdown", "-f", "--format", help="Output format: markdown, image"),diff --git a/mineru/cli/commands/search.py b/mineru/cli/commands/search.pyindex bc16545e..420afe06 100644--- a/mineru/cli/commands/search.py+++ b/mineru/cli/commands/search.py@@ -18,11 +18,11 @@ FILE_EXTS = ", ".join(FILE_TYPE_BY_EXTENSION)def search_cmd(query: str = typer.Argument(..., help="Search query"),file_type: str | None = typer.Option(None, "--type", help=f"File type filter: {FILE_TYPES}"),- tier: Tier | None = typer.Option(None, "--tier", help="Exact search index tier: flash, medium, high, xhigh"),+ tier: Tier | None = typer.Option(None, "--tier", help="Exact search index tier: flash, basic, standard, advanced"),min_tier: Tier | None = typer.Option(None,"--min-tier",- help="Minimum search index tier: flash, medium, high, xhigh",+ help="Minimum search index tier: flash, basic, standard, advanced",),limit: int = typer.Option(20, "--limit", "-n", help="Max results"),offset: int = typer.Option(0, "--offset", help="Result offset"),diff --git a/mineru/cli_old/gradio_app.py b/mineru/cli_old/gradio_app.pyindex 10b9844a..3eaa4690 100644--- a/mineru/cli_old/gradio_app.py+++ b/mineru/cli_old/gradio_app.py@@ -239,8 +239,8 @@ STATUS_QUEUED_ON_SERVER = "Queued on server"STATUS_PROCESSING_ON_SERVER = "Processing on server"STATUS_QUEUED_LOCALLY_PREFIX = "Queued locally:"-DEFAULT_GRADIO_TIER = "high"-GRADIO_TIER_CHOICES = ("flash", "medium", "high", "xhigh")+DEFAULT_GRADIO_TIER = "standard"+GRADIO_TIER_CHOICES = ("flash", "basic", "standard", "advanced")STATUS_STEP_DEFINITIONS = [("status_step_prepare", STATUS_PREPARING_REQUEST),("status_step_check", STATUS_CHECKING_SERVER),@@ -409,7 +409,7 @@ def extract_v1_tier_choices(payload) -> tuple[str, ...]:def default_v1_gradio_tier(tier_choices: tuple[str, ...]) -> str:- """选择 Gradio 默认 tier;优先 high,与 API server 的无 tier 请求默认值保持一致。"""+ """选择 Gradio 默认 tier;优先 standard,与 API server 的无 tier 请求默认值保持一致。"""if not tier_choices:raise click.ClickException("MinerU v1 API did not advertise any supported tier.")if DEFAULT_GRADIO_TIER in tier_choices:@@ -599,12 +599,12 @@ def select_tier_info_key(tier_choice: object) -> str:"""根据 Gradio tier 选择说明文案的 i18n key。"""if tier_choice == "flash":return "tier_info_flash"- if tier_choice == "medium":- return "tier_info_medium"- if tier_choice == "high":- return "tier_info_high"- if tier_choice == "xhigh":- return "tier_info_xhigh"+ if tier_choice == "basic":+ return "tier_info_basic"+ if tier_choice == "standard":+ return "tier_info_standard"+ if tier_choice == "advanced":+ return "tier_info_advanced"return "tier_info_default"@@ -1753,9 +1753,9 @@ def main(ctx,"tier": "Tier","tier_info_default": "Select the parsing tier.","tier_info_flash": "Flash tier uses fast local text extraction.",- "tier_info_medium": "Medium tier uses local Hybrid parsing.",- "tier_info_high": "High tier uses higher quality Hybrid parsing.",- "tier_info_xhigh": "Extra High tier uses maximum-quality Hybrid parsing.",+ "tier_info_basic": "Basic tier uses local Hybrid parsing on CPU-capable systems.",+ "tier_info_standard": "Standard tier provides high-quality Hybrid parsing.",+ "tier_info_advanced": "Advanced tier spends more compute on difficult documents.","convert": "Convert","clear": "Clear","doc_preview": "Document preview",@@ -1804,9 +1804,9 @@ def main(ctx,"tier": "解析 tier","tier_info_default": "选择文档解析 tier。","tier_info_flash": "flash 使用快速本地文本提取。",- "tier_info_medium": "medium 使用本地 Hybrid 解析。",- "tier_info_high": "high 使用更高质量的 Hybrid 解析。",- "tier_info_xhigh": "xhigh 使用最高质量的 Hybrid 解析。",+ "tier_info_basic": "基础解析使用可在 CPU 环境运行的本地 Hybrid 解析。",+ "tier_info_standard": "标准解析提供高质量 Hybrid 解析。",+ "tier_info_advanced": "高级解析为困难文档投入更多推理算力。","convert": "转换","clear": "清除","doc_preview": "文档预览",diff --git a/mineru/doclib/config_defaults.py b/mineru/doclib/config_defaults.pyindex fbfd47ed..49584dbd 100644--- a/mineru/doclib/config_defaults.py+++ b/mineru/doclib/config_defaults.py@@ -8,7 +8,7 @@ ConfigSource = Literal["default", "override"]CONFIG_DEFAULTS: dict[str, str] = {"parse_server.local.mode": "disabled",- "parse_server.local.managed_tier": "high",+ "parse_server.local.managed_tier": "standard","parse_server.local.self_hosted_url": "","parse_server.local.self_hosted_api_key": "","parse_server.remote.url": "https://mineru.net/api",diff --git a/mineru/doclib/config_schema.py b/mineru/doclib/config_schema.pyindex c7129719..bd3f0036 100644--- a/mineru/doclib/config_schema.py+++ b/mineru/doclib/config_schema.py@@ -8,7 +8,7 @@ from ..errors import InvalidRequestErrorfrom .config_defaults import CONFIG_DEFAULTSLOCAL_PARSE_SERVER_MODES = ("disabled", "managed", "self_hosted")-MANAGED_PARSE_SERVER_TIERS = ("medium", "high", "xhigh")+MANAGED_PARSE_SERVER_TIERS = ("basic", "standard", "advanced")URL_CONFIG_KEYS = ("parse_server.remote.url", "parse_server.local.self_hosted_url")diff --git a/mineru/doclib/locators.py b/mineru/doclib/locators.pyindex 60d978dd..f287a3c8 100644--- a/mineru/doclib/locators.py+++ b/mineru/doclib/locators.py@@ -9,7 +9,7 @@ from ..types import Tier_CURSOR_RE = re.compile(r"^doc:(?P<short_id>[0-9a-fA-F]+)"- r"/tier:(?P<tier>flash|medium|high|xhigh)"+ r"/tier:(?P<tier>flash|basic|standard|advanced)"r"/page:(?P<page_no>[1-9][0-9]*)"r"(?:/block:(?P<block_no>[1-9][0-9]*)(?:/char:(?P<char_offset>0|[1-9][0-9]*))?)?$")diff --git a/mineru/doclib/server.py b/mineru/doclib/server.pyindex fe425ee7..197b134d 100644--- a/mineru/doclib/server.py+++ b/mineru/doclib/server.py@@ -1469,7 +1469,7 @@ class DoclibServer(AsyncDoclibInterface):_READ_LOCATOR_RE = re.compile(r"^doc:(?P<short_id>[0-9a-fA-F]+)"- r"(?:/tier:(?P<tier>flash|medium|high|xhigh)"+ r"(?:/tier:(?P<tier>flash|basic|standard|advanced)"r"(?:/page:(?P<page_no>[1-9][0-9]*)"r"(?:/block:(?P<block_no>[1-9][0-9]*)(?:/char:(?P<char_offset>0|[1-9][0-9]*))?)?)?)?$")@@ -1648,10 +1648,10 @@ def _format_missing_model_repo(repo: ModelRepo, missing_paths: list[str]) -> strdef _validate_managed_parse_server_tier(value: str, param: str) -> Tier:- if value not in ("medium", "high", "xhigh"):+ if value not in ("basic", "standard", "advanced"):raise InvalidRequestError("invalid_config_value",- "parse_server.local.managed_tier must be one of: medium, high, xhigh.",+ "parse_server.local.managed_tier must be one of: basic, standard, advanced.",param,)return cast(Tier, value)@@ -2065,7 +2065,7 @@ def _page_markdown_blocks(data_dir: str = "",sha256: str = "",short_id: str = "",- tier: Tier = "high",+ tier: Tier = "standard",) -> list[tuple[int, str]]:backend = page._backendresult: list[tuple[int, str]] = []diff --git a/mineru/doclib/services/parse_svc.py b/mineru/doclib/services/parse_svc.pyindex d8c2cf3b..a05f9e0b 100644--- a/mineru/doclib/services/parse_svc.py+++ b/mineru/doclib/services/parse_svc.py@@ -740,7 +740,7 @@ class ParseService:if remote and tier == "flash":raise InvalidRequestError("tier_unsupported_for_remote",- "--remote does not support tier 'flash'; use --tier medium, --tier high, or --tier xhigh.",+ "--remote does not support tier 'flash'; use --tier basic, --tier standard, or --tier advanced.","tier",)if tier in QUALITY_TIERS and ext not in TIERED_PARSE_EXTENSIONS:@@ -1402,7 +1402,7 @@ class ParseService:def _resolve_default_tier(remote: bool = False) -> Tier:- """从健康检查中选择默认质量 tier,顺序为 high > xhigh > medium。"""+ """从健康检查中选择默认质量 tier,顺序为 standard > advanced > basic。"""from ..background.parse_server_health import get_healthhealth = get_health()@@ -1429,12 +1429,12 @@ def _resolve_default_tier(remote: bool = False) -> Tier:actions.append("explicitly pass --tier flash for text-only preview")raise ParseFailure("quality_tier_unavailable",- f"No medium, high, or xhigh engine available. You can {_format_action_list(actions)}.",+ f"No basic, standard, or advanced engine available. You can {_format_action_list(actions)}.",)def _resolve_parsing_rule_default_tier(remote: bool = False) -> Tier:- """Parsing-rule 是后台批量策略,允许 high -> xhigh -> medium -> flash。"""+ """Parsing-rule 是后台批量策略,允许 standard -> advanced -> basic -> flash。"""from ..background.parse_server_health import get_healthhealth = get_health()diff --git a/mineru/doclib/telemetry/constants.py b/mineru/doclib/telemetry/constants.pyindex 5e9d488b..4891951f 100644--- a/mineru/doclib/telemetry/constants.py+++ b/mineru/doclib/telemetry/constants.py@@ -54,12 +54,12 @@ DIM_TIER_VALUES = frozenset({"default","flash",- "medium",- "high",- "xhigh",- "medium(default)",- "high(default)",- "xhigh(default)",+ "basic",+ "standard",+ "advanced",+ "basic(default)",+ "standard(default)",+ "advanced(default)","unknown",})@@ -70,7 +70,20 @@ DIM_CONTENT_MODE_VALUES = frozenset({"read", "parse_output", "export", "unknown"DIM_OUTPUT_FORMAT_VALUES = frozenset({"markdown", "image", "other"})DIM_TRIGGER_VALUES = frozenset({"parse", "scan", "watch", "show", "background", "unknown"})DIM_RESULT_VALUES = frozenset(- {"seen", "refreshed", "new", "changed", "deleted", "unreachable", "error", "unsupported", "excluded", "hit", "miss", "unknown"}+ {+ "seen",+ "refreshed",+ "new",+ "changed",+ "deleted",+ "unreachable",+ "error",+ "unsupported",+ "excluded",+ "hit",+ "miss",+ "unknown",+ })DIM_ERROR_CODE_VALUES = frozenset({@@ -199,7 +212,9 @@ METRIC_SPECS: dict[str, MetricSpec] = {"find.results_bucket.count": MetricSpec(REQ_CONTEXT | BUCKET),"content.request.count": MetricSpec(REQ_CONTEXT | frozenset({"content_mode", "output_format"})),"content.finished.count": MetricSpec(REQ_CONTEXT | STATUS | TIER | frozenset({"content_mode", "output_format"})),- "content.duration_bucket.count": MetricSpec(REQ_CONTEXT | STATUS | TIER | BUCKET | frozenset({"content_mode", "output_format"})),+ "content.duration_bucket.count": MetricSpec(+ REQ_CONTEXT | STATUS | TIER | BUCKET | frozenset({"content_mode", "output_format"})+ ),"scan.request.count": MetricSpec(REQ_CONTEXT),"scan.finished.count": MetricSpec(STATUS),"scan.duration_bucket.count": MetricSpec(STATUS | BUCKET),diff --git a/mineru/kit/commands/api_server.py b/mineru/kit/commands/api_server.pyindex e758d88e..6b790010 100644--- a/mineru/kit/commands/api_server.py+++ b/mineru/kit/commands/api_server.py@@ -10,7 +10,7 @@ from ...utils.ocr_language import PUBLIC_OCR_LANGUAGES, validate_public_ocr_langfrom ..errors import exit_with_messageAPI_SERVER_LANGUAGES = PUBLIC_OCR_LANGUAGES-API_SERVER_TIERS = ("flash", "medium", "high", "xhigh")+API_SERVER_TIERS = ("flash", "basic", "standard", "advanced")def _normalize_tier_options(tier: Sequence[str] | str | None) -> list[str]:diff --git a/mineru/kit/commands/models.py b/mineru/kit/commands/models.pyindex 81ff46c4..245354ec 100644--- a/mineru/kit/commands/models.py+++ b/mineru/kit/commands/models.py@@ -63,7 +63,7 @@ def _format_repo_status(repo: ModelRepo) -> str:@app.command("download")def download_cmd(repo: str | None = typer.Argument(None, help="Model repo: PDF-Extract-Kit-1.0 or MinerU2.5-Pro-2605-1.2B"),- tier: str | None = typer.Option(None, "--tier", help="Tier to prepare: flash, medium, high, or xhigh"),+ tier: str | None = typer.Option(None, "--tier", help="Tier to prepare: flash, basic, standard, or advanced"),source: str | None = typer.Option(None, "--source", "-s", help="Model source: auto, huggingface, or modelscope"),verbose: bool = typer.Option(False, "--verbose", "-v", help="Verbose output"),) -> None:@@ -107,7 +107,7 @@ def show_cmd() -> None:print_info(f" {_format_repo_status(repo)}")print_info("Tiers:")- for tier in ("flash", "medium", "high", "xhigh"):+ for tier in ("flash", "basic", "standard", "advanced"):repos = model_repos_for_tier(validate_tier(tier))names = ", ".join(repo.name for repo in repos) or "(none)"print_info(f" {tier}: {names}")@@ -116,7 +116,7 @@ def show_cmd() -> None:@app.command("verify")def verify_cmd(repo: str | None = typer.Argument(None, help="Optional model repo name"),- tier: str | None = typer.Option(None, "--tier", help="Optional tier: flash, medium, high, or xhigh"),+ tier: str | None = typer.Option(None, "--tier", help="Optional tier: flash, basic, standard, or advanced"),) -> None:"""Verify local model repos and required paths."""repos = MODEL_REPOS if repo is None and tier is None else _select_target_repos(repo, tier)diff --git a/mineru/kit/commands/parse.py b/mineru/kit/commands/parse.pyindex 8cbdf420..f7f9caae 100644--- a/mineru/kit/commands/parse.py+++ b/mineru/kit/commands/parse.py@@ -91,7 +91,7 @@ def parse_cmd(path_effort = DEFAULT_HYBRID_EFFORTelse:path_tier, path_backend = effective_local_tier_and_backend(tier, normalized_backend)- if path_tier in {"medium", "high", "xhigh"}:+ if path_tier in {"basic", "standard", "advanced"}:path_effort = effort_for_tier(path_tier)return local_parse(path,diff --git a/mineru/kit/common.py b/mineru/kit/common.pyindex 63f352f4..626d7996 100644--- a/mineru/kit/common.py+++ b/mineru/kit/common.py@@ -95,10 +95,10 @@ def effective_local_tier_and_backend(tier: Tier | None, backend: str | None) ->from ..parser.tier import backend_for_tier, resolve_tier_and_backendif tier is None and backend is None:- return "high", backend_for_tier("high")+ return "standard", backend_for_tier("standard")resolved_tier, resolved_backend = resolve_tier_and_backend(tier=tier, backend=backend)if tier is None and backend is None:- resolved_backend = backend_for_tier("high")+ resolved_backend = backend_for_tier("standard")return resolved_tier, resolved_backenddiff --git a/mineru/kit/main.py b/mineru/kit/main.pyindex 56b72bd5..df0c4068 100644--- a/mineru/kit/main.py+++ b/mineru/kit/main.py@@ -42,7 +42,7 @@ def parse_command(pages: str | None = typer.Option(None, "-p", "--pages", help="Page range, e.g. '1~5' or 'all'"),format: str = typer.Option("markdown", "-f", "--format", help="Output format: markdown, middle_json, zip"),verbose: bool = typer.Option(False, "-v", "--verbose", help="Verbose output"),- tier: str | None = typer.Option(None, "--tier", help="Parse tier: flash, medium, high, xhigh"),+ tier: str | None = typer.Option(None, "--tier", help="Parse tier: flash, basic, standard, advanced"),backend: str | None = typer.Option(None, "--backend", help="Expert backend override"),remote: bool = typer.Option(False, "--remote", help="Use mineru.net official remote parse service"),remote_url: str | None = typer.Option(None, "--remote-url", help="Use a custom remote parse service URL"),@@ -83,7 +83,7 @@ def api_server_command(tier: list[str] | None = typer.Option(None,"--tier",- help="Server tier: flash, medium, high, xhigh; repeat to expose multiple tiers",+ help="Server tier: flash, basic, standard, advanced; repeat to expose multiple tiers",),concurrency: int = typer.Option(1, "--concurrency", help="Maximum concurrent parse jobs"),url_timeout: int = typer.Option(60, "--url-timeout", help="Timeout for URL source downloads"),diff --git a/mineru/parser/api_client.py b/mineru/parser/api_client.pyindex cab747a9..3209d564 100644--- a/mineru/parser/api_client.py+++ b/mineru/parser/api_client.py@@ -58,12 +58,12 @@ class MinerUApiParser(DocumentParser):# local deployment — uses ``local`` source only when the server advertises it.# Start the local server with --allow-local-source to skip upload.- parser = MinerUApiParser(api_url="http://localhost:8000", tier="medium")+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="basic")# cloud (remote)parser = MinerUApiParser(api_url="https://mineru.net/api", api_key="sk_...",- tier="high",+ tier="standard",)result = parser.parse("report.pdf")@@ -71,7 +71,7 @@ class MinerUApiParser(DocumentParser):Constructor parameters:- - ``tier`` → v1 ``tier`` (``"flash"`` / ``"medium"`` / ``"high"`` / ``"xhigh"``); ``None`` omits the field+ - ``tier`` → v1 ``tier`` (``"flash"`` / ``"basic"`` / ``"standard"`` / ``"advanced"``); ``None`` omits the field- ``page_range`` → per-file v1 ``page_range``"""diff --git a/mineru/parser/api_server.py b/mineru/parser/api_server.pyindex b9faa3ed..3e8a35cc 100644--- a/mineru/parser/api_server.py+++ b/mineru/parser/api_server.py@@ -61,8 +61,8 @@ from .tier import (runtime_options_for_tier,)-_API_SERVER_TIERS: tuple[Tier, ...] = ("flash", "medium", "high", "xhigh")-_DEFAULT_API_SERVER_TIER: Tier = "high"+_API_SERVER_TIERS: tuple[Tier, ...] = ("flash", "basic", "standard", "advanced")+_DEFAULT_API_SERVER_TIER: Tier = "standard"_API_SERVER_LANGUAGES = PUBLIC_OCR_LANGUAGES_MANAGED_PARSE_SERVER_ENV = "MINERU_MANAGED_PARSE_SERVER"_MAX_INLINE_BYTES_DEFAULT = 1024 * 1024@@ -1809,7 +1809,7 @@ async def create_job(error_type="engine_error",code="quality_tier_unavailable",message=(- "No medium, high, or xhigh tier available in this server. "+ "No basic, standard, or advanced tier available in this server. ""Pass tier='flash' explicitly for flash parsing."),)@@ -1984,27 +1984,27 @@ def _model_ids_and_tiers_for_server_tier(tier: Tier) -> tuple[list[str], list[Ti"current_model": "flash",},]- if tier == "medium":- return ["Hybrid-Medium", "MinerU-HTML"], [+ if tier == "basic":+ return ["Hybrid-Basic", "MinerU-HTML"], [{- "id": "medium",- "description": "Hybrid medium parsing with local lightweight models.",- "current_model": "hybrid-medium",+ "id": "basic",+ "description": "Basic parsing with local lightweight models.",+ "current_model": "hybrid-basic",},]- if tier == "xhigh":+ if tier == "advanced":return ["MinerU2.5-Pro-2605-1.2B", "MinerU-HTML"], [{- "id": "xhigh",- "description": "Hybrid maximum-accuracy parsing.",+ "id": "advanced",+ "description": "Advanced parsing for difficult documents.","current_model": "MinerU2.5-Pro-2605-1.2B",},]return ["MinerU2.5-Pro-2605-1.2B", "MinerU-HTML"], [{- "id": "high",- "description": "Hybrid high-accuracy parsing.",+ "id": "standard",+ "description": "Standard parsing for most documents.","current_model": "MinerU2.5-Pro-2605-1.2B",},]@@ -2067,8 +2067,8 @@ def create_app(upload_dir:Directory for uploaded files and parse artifacts.tier:- Server parsing tier. ``"flash"`` selects flash parsing; ``"medium"``,- ``"high"`` and ``"xhigh"`` map to Hybrid efforts.+ Server parsing tier. ``"flash"`` selects flash parsing; ``"basic"``,+ ``"standard"`` and ``"advanced"`` map to Hybrid efforts.concurrency:Maximum concurrent parse jobs (default 1).url_timeout:@@ -2240,7 +2240,7 @@ def create_app(type=click.Choice(list(_API_SERVER_TIERS)),help=("Server parsing tier; repeat to expose multiple tiers. "- "Defaults to flash, medium, high, and xhigh; requests without tier default to high."+ "Defaults to flash, basic, standard, and advanced; requests without tier default to standard."),)@click.option(diff --git a/mineru/parser/pdf.py b/mineru/parser/pdf.pyindex fde0566f..2690118f 100644--- a/mineru/parser/pdf.py+++ b/mineru/parser/pdf.py@@ -301,20 +301,20 @@ class PdfHybridParser(PdfBaseParser):class PdfPipelineParser(PdfHybridParser):- """保留旧 SDK 类名,内部统一委托 Hybrid medium 解析。"""+ """保留旧 SDK 类名,内部统一委托 Hybrid medium effort 解析。"""def __init__(self, **kwargs: Any) -> None:- """将旧 PdfPipelineParser 构造参数归一到 Hybrid medium,避免继续加载旧 backend。"""+ """将旧 PdfPipelineParser 构造参数归一到 Hybrid medium effort,避免继续加载旧 backend。"""kwargs.pop("backend", None)kwargs.pop("effort", None)super().__init__(backend=CANONICAL_HYBRID_ENGINE, effort=LOCAL_HYBRID_EFFORT, **kwargs)class PdfVlmParser(PdfHybridParser):- """保留旧 SDK 类名,内部统一委托 Hybrid xhigh 解析。"""+ """保留旧 SDK 类名,内部统一委托 Hybrid xhigh effort 解析。"""def __init__(self, **kwargs: Any) -> None:- """将旧 PdfVlmParser 构造参数归一到 Hybrid xhigh,避免继续暴露独立 VLM backend。"""+ """将旧 PdfVlmParser 构造参数归一到 Hybrid xhigh effort,避免继续暴露独立 VLM backend。"""backend = kwargs.pop("backend", "vlm-engine")kwargs.pop("effort", None)resolved_backend, resolved_effort = resolve_backend_and_effort(backend, MAX_HYBRID_EFFORT)diff --git a/mineru/parser/tier.py b/mineru/parser/tier.pyindex 2f3bdb03..65dad2f5 100644--- a/mineru/parser/tier.py+++ b/mineru/parser/tier.py@@ -19,6 +19,7 @@ from ..utils.backend_options import (is_hybrid_backend,normalize_backend,resolve_backend_and_effort,+ tier_for_effort,)__all__ = [@@ -38,7 +39,7 @@ __all__ = [PARSER_BACKENDS = SUPPORTED_BACKENDS-_MEDIUM_REQUIRED_MODULES = [+_BASIC_REQUIRED_MODULES = ["ftfy","shapely","pyclipper",@@ -47,15 +48,15 @@ _MEDIUM_REQUIRED_MODULES = ["torchvision","transformers",]-_HIGH_REQUIRED_MODULES_COMMON = [- *_MEDIUM_REQUIRED_MODULES,+_STANDARD_REQUIRED_MODULES_COMMON = [+ *_BASIC_REQUIRED_MODULES,"accelerate",]-_HIGH_REQUIRED_MODULES_BY_PLATFORM = {+_STANDARD_REQUIRED_MODULES_BY_PLATFORM = {"linux": ["vllm"],"win32": ["lmdeploy", "qwen_vl_utils"],}-_APPLE_SILICON_HIGH_REQUIRED_MODULES = ["mlx", "mlx_vlm"]+_APPLE_SILICON_STANDARD_REQUIRED_MODULES = ["mlx", "mlx_vlm"]class TierDependencyError(RuntimeError):@@ -93,9 +94,9 @@ def backend_for_tier(tier: Tier) -> str:tier = validate_tier(tier)mapping = {"flash": "flash",- "medium": CANONICAL_HYBRID_ENGINE,- "high": CANONICAL_HYBRID_ENGINE,- "xhigh": CANONICAL_HYBRID_ENGINE,+ "basic": CANONICAL_HYBRID_ENGINE,+ "standard": CANONICAL_HYBRID_ENGINE,+ "advanced": CANONICAL_HYBRID_ENGINE,}return mapping[tier]@@ -104,14 +105,14 @@ def tier_for_backend(backend: str) -> Tier:"""根据旧 backend 专家输入推断等价 tier,仅服务本地 parser 兼容入口。"""raw_backend = (backend or "").strip()if raw_backend in LEGACY_PIPELINE_BACKEND_ALIASES:- return "medium"+ return "basic"if raw_backend in LEGACY_VLM_BACKEND_ALIASES:- return "xhigh"+ return "advanced"normalized_backend = normalize_backend(backend)if normalized_backend == "flash":return "flash"if is_hybrid_backend(normalized_backend):- return DEFAULT_HYBRID_EFFORT # type: ignore[return-value]+ return _tier_for_effort(DEFAULT_HYBRID_EFFORT)raise ValueError(f"Unsupported backend '{backend}'. Supported backends: {', '.join(PARSER_BACKENDS)}")@@ -120,28 +121,28 @@ def _backend_supports_tier(backend: str, tier: Tier) -> bool:normalized_backend = normalize_backend(backend)if tier == "flash":return normalized_backend == "flash"- if tier == "medium":+ if tier == "basic":return raw_backend in LEGACY_PIPELINE_BACKEND_ALIASES or (is_hybrid_backend(normalized_backend) and raw_backend not in LEGACY_VLM_BACKEND_ALIASES)- if tier == "high":+ if tier == "standard":return (is_hybrid_backend(normalized_backend)and raw_backend not in LEGACY_PIPELINE_BACKEND_ALIASESand raw_backend not in LEGACY_VLM_BACKEND_ALIASES)- if tier == "xhigh":+ if tier == "advanced":return is_hybrid_backend(normalized_backend) and raw_backend not in LEGACY_PIPELINE_BACKEND_ALIASESreturn Falsedef _tier_for_effort(effort: str) -> Tier:- return validate_tier(effort)+ return validate_tier(tier_for_effort(effort))def resolve_tier_and_backend(tier: Tier | None = None, backend: str | None = None) -> tuple[Tier, str]:"""将公开 tier 和本地专家 backend 解析为可执行 parser backend。"""- resolved_tier: Tier = validate_tier(tier) if tier is not None else "high"+ resolved_tier: Tier = validate_tier(tier) if tier is not None else "standard"if backend:normalized_backend = normalize_backend(backend)if tier is None:@@ -206,14 +207,14 @@ def runtime_options_for_tier(def required_modules_for_tier(tier: Tier) -> list[str]:tier = validate_tier(tier)- if tier == "medium":- return list(_MEDIUM_REQUIRED_MODULES)- if tier in {"high", "xhigh"}:- platform_modules = list(_HIGH_REQUIRED_MODULES_BY_PLATFORM.get(sys.platform, []))+ if tier == "basic":+ return list(_BASIC_REQUIRED_MODULES)+ if tier in {"standard", "advanced"}:+ platform_modules = list(_STANDARD_REQUIRED_MODULES_BY_PLATFORM.get(sys.platform, []))if sys.platform == "darwin" and platform.machine() == "arm64":- platform_modules.extend(_APPLE_SILICON_HIGH_REQUIRED_MODULES)+ platform_modules.extend(_APPLE_SILICON_STANDARD_REQUIRED_MODULES)return [- *_HIGH_REQUIRED_MODULES_COMMON,+ *_STANDARD_REQUIRED_MODULES_COMMON,*platform_modules,]return []diff --git a/mineru/types.py b/mineru/types.pyindex b878b2ca..ca972eff 100644--- a/mineru/types.py+++ b/mineru/types.py@@ -10,33 +10,33 @@ T = TypeVar("T", bound="_DocElement")Tier = Literal["flash",- "medium",- "high",- "xhigh",+ "basic",+ "standard",+ "advanced",]TIERS: set[Tier] = {"flash",- "medium",- "high",- "xhigh",+ "basic",+ "standard",+ "advanced",}TIER_ORDER: dict[Tier, int] = {"flash": 0,- "medium": 1,- "high": 2,- "xhigh": 3,+ "basic": 1,+ "standard": 2,+ "advanced": 3,}-QUALITY_TIER_SELECTION_ORDER: tuple[Tier, ...] = ("high", "xhigh", "medium")+QUALITY_TIER_SELECTION_ORDER: tuple[Tier, ...] = ("standard", "advanced", "basic")QUALITY_TIERS: frozenset[Tier] = frozenset(QUALITY_TIER_SELECTION_ORDER)-CACHED_TIER_SELECTION_ORDER: tuple[Tier, ...] = ("xhigh", "high", "medium", "flash")+CACHED_TIER_SELECTION_ORDER: tuple[Tier, ...] = ("advanced", "standard", "basic", "flash")PARSING_RULE_TIER_SELECTION_ORDER: tuple[Tier, ...] = (*QUALITY_TIER_SELECTION_ORDER, "flash")def validate_tier(tier: str | None) -> Tier:- """校验公开 tier 取值,保证入口只接受 flash/medium/high/xhigh。"""+ """校验公开 tier 取值,保证入口只接受 flash/basic/standard/advanced。"""normalized = (tier or "").strip().lower()if normalized in TIERS:return normalized # type: ignore[return-value]diff --git a/mineru/utils/backend_options.py b/mineru/utils/backend_options.pyindex 14dd15f3..8511fe8c 100644--- a/mineru/utils/backend_options.py+++ b/mineru/utils/backend_options.py@@ -27,10 +27,11 @@ HYBRID_EFFORT_CHOICES: Final[tuple[str, ...]] = (MAX_HYBRID_EFFORT,)HYBRID_EFFORT_BY_TIER: Final[dict[str, str]] = {- LOCAL_HYBRID_EFFORT: LOCAL_HYBRID_EFFORT,- LAYOUT_HYBRID_EFFORT: LAYOUT_HYBRID_EFFORT,- "xhigh": MAX_HYBRID_EFFORT,+ "basic": LOCAL_HYBRID_EFFORT,+ "standard": LAYOUT_HYBRID_EFFORT,+ "advanced": MAX_HYBRID_EFFORT,}+TIER_BY_HYBRID_EFFORT: Final[dict[str, str]] = {effort: tier for tier, effort in HYBRID_EFFORT_BY_TIER.items()}BACKEND_SCHEMA_EXTRA: Final[dict[str, list[str]]] = {"enum": list(PUBLIC_BACKEND_CHOICES)}HYBRID_EFFORT_SCHEMA_EXTRA: Final[dict[str, list[str]]] = {"enum": list(HYBRID_EFFORT_CHOICES)}@@ -92,6 +93,12 @@ def effort_for_tier(tier: str | None) -> str:raise ValueError(f"Unsupported tier '{tier}'. Supported hybrid tiers: {supported_tiers}")+def tier_for_effort(effort: str | None) -> str:+ """将 Hybrid effort 映射回公开 tier,避免把内部 effort 当作 tier 校验。"""+ normalized = validate_effort(effort)+ return TIER_BY_HYBRID_EFFORT[normalized]++def resolve_backend_and_effort(backend: str | None, effort: str | None = None) -> tuple[str, str]:"""同时解析 backend 与 effort,旧 pipeline/VLM backend 分别统一转为 Hybrid medium/xhigh。"""raw_backend = (backend or "").strip()diff --git a/mineru/utils/model_registry.py b/mineru/utils/model_registry.pyindex 0b16c5cc..f51c8e7c 100644--- a/mineru/utils/model_registry.py+++ b/mineru/utils/model_registry.py@@ -122,9 +122,9 @@ MODEL_REPOS_BY_NAME: dict[str, ModelRepo] = {repo.name: repo for repo in MODEL_RREPOS_FOR_TIER: dict[Tier, tuple[ModelRepo, ...]] = {"flash": (),- "medium": (PDF_EXTRACT_KIT,),- "high": (PDF_EXTRACT_KIT, MINERU_2_5_PRO_2605_1_2B),- "xhigh": (PDF_EXTRACT_KIT, MINERU_2_5_PRO_2605_1_2B),+ "basic": (PDF_EXTRACT_KIT,),+ "standard": (PDF_EXTRACT_KIT, MINERU_2_5_PRO_2605_1_2B),+ "advanced": (PDF_EXTRACT_KIT, MINERU_2_5_PRO_2605_1_2B),}diff --git a/pyproject.toml b/pyproject.tomlindex e854bb38..19d89de4 100644--- a/pyproject.toml+++ b/pyproject.toml@@ -77,14 +77,14 @@ dev = ["lxml-stubs",]test = [- "mineru[xhigh]",+ "mineru[advanced]","pytest","pytest-cov","coverage","fuzzywuzzy","tomli; python_version < '3.11'",]-medium = [+basic = ["ftfy>=6.3.1,<7","shapely>=2.0.7,<3","pyclipper>=1.3.0,<2",@@ -94,8 +94,8 @@ medium = ["transformers>=4.57.3,<5.0.0","safetensors>=0.4.0,<1",]-high = [- "mineru[medium]",+standard = [+ "mineru[basic]","accelerate>=1.5.1","vllm>=0.10.1.1,<0.22.0 ; sys_platform == 'linux'","lmdeploy>=0.10.2,<0.12 ; sys_platform == 'win32'",@@ -103,15 +103,15 @@ high = ["mlx<=0.31.1 ; sys_platform == 'darwin' and platform_machine == 'arm64'","mlx-vlm>=0.3.3,<0.4 ; sys_platform == 'darwin' and platform_machine == 'arm64'",]-xhigh = [- "mineru[high]",+advanced = [+ "mineru[standard]",]gradio = ["gradio>=5.49.1,!=6.0.0,!=6.0.1,!=6.0.2,!=6.1.0,!=6.2.0,!=6.3.0,!=6.4.0,!=6.5.0,!=6.5.1,!=6.6.0,!=6.7.0,<6.9.0","gradio-pdf>=0.0.22",]all = [- "mineru[high]",+ "mineru[standard]","mineru[gradio]",]diff --git a/skills/mineru/SKILL.md b/skills/mineru/SKILL.mdindex f250c88c..a0a9656b 100644--- a/skills/mineru/SKILL.md+++ b/skills/mineru/SKILL.md@@ -92,7 +92,7 @@ Then answer from `content.content`. If `next_request` exists and the question ne```bashmineru parse "book.pdf" --pages 1~10 --limit 12000 --json-mineru read "doc:ab12cd3/tier:high/page:11" --limit 12000 --json+mineru read "doc:ab12cd3/tier:standard/page:11" --limit 12000 --json```Continue with returned `next_request.locator`.@@ -100,15 +100,15 @@ Continue with returned `next_request.locator`.### Read or inspect a known location```bash-mineru read "doc:ab12cd3/tier:high/page:42" --context 1 --json-mineru read "doc:ab12cd3/tier:high/page:12/block:5" --format image --output ./page12-block5.png+mineru read "doc:ab12cd3/tier:standard/page:42" --context 1 --json+mineru read "doc:ab12cd3/tier:standard/page:12/block:5" --format image --output ./page12-block5.png```### Search local library, then read```bash-mineru search "liquidated damages" --min-tier medium --json-mineru read "doc:ab12cd3/tier:high/page:18" --json+mineru search "liquidated damages" --min-tier basic --json+mineru read "doc:ab12cd3/tier:standard/page:18" --json```## Installation And Setup@@ -269,14 +269,14 @@ MinerU has four tiers:| Tier | Quality and speed | Local requirements | Local model download | Use for ||---|---|---|---|---|| `flash` | Lowest quality; fastest | No special hardware | None | Discovery, preview, and indexing; never default final reading quality |-| `medium` | Medium quality; moderate speed | At least 16 GB total memory; CPU works, GPU can accelerate | About 2 GB | Private local reading or lower-resource local parsing |-| `high` | High quality; similar speed to `medium` on suitable hardware | At least 16 GB total memory plus a supported accelerator | About 4 GB | Default for normal active reading and complex documents |-| `xhigh` | Highest quality; slowest | Same as high, with greater compute use | About 4 GB | Maximum-quality work when the user accepts a longer wait |+| `basic` | Basic quality; moderate speed | At least 16 GB total memory; CPU works, GPU can accelerate | About 2 GB | Private local reading or lower-resource local parsing |+| `standard` | Standard high quality; similar speed to `basic` on suitable hardware | At least 16 GB total memory plus a supported accelerator | About 4 GB | Default for normal active reading and complex documents |+| `advanced` | Standard quality on ordinary documents and better quality on difficult documents; slowest | Same as Standard, with greater compute use | About 4 GB | Difficult documents and maximum-quality work when the user accepts a longer wait |Default tier behavior:- Omit `--tier` when the user wants normal reading quality.-- For parse-server based parsing, MinerU chooses `high`, then `xhigh`, then `medium`; `flash` is not a default final reading tier.+- For parse-server based parsing, MinerU chooses `standard`, then `advanced`, then `basic`; `flash` is not a default final reading tier.- For `mineru read doc:{short_id}`, MinerU reads the best cached result rather than starting a new parse.- If normal reading quality is unavailable, inspect `mineru server status --json`, then present the applicable choices to the user:- Use remote parsing with `--remote`, which uploads the document and requires explicit permission.@@ -291,9 +291,9 @@ Examples:```bashmineru parse "paper.pdf"-mineru parse "paper.pdf" --tier medium-mineru parse "paper.pdf" --tier high-mineru parse "paper.pdf" --tier xhigh+mineru parse "paper.pdf" --tier basic+mineru parse "paper.pdf" --tier standard+mineru parse "paper.pdf" --tier advancedmineru parse "paper.pdf" --tier flash```@@ -330,7 +330,7 @@ Agent rules:## Local Parse Server-Use a local parse server when the user wants `medium`, `high`, or `xhigh` quality without sending the document to remote parsing.+Use a local parse server when the user wants `basic`, `standard`, or `advanced` quality without sending the document to remote parsing.### Assess Local Hardware@@ -345,12 +345,12 @@ Use available read-only system commands to inspect the OS, architecture, total mClassify each local quality tier as `hardware-supported`, `hardware-unsupported`, or `hardware-unknown`. These labels describe hardware suitability only, not whether the required dependencies and models are installed or the tier is currently available:-- `medium`: `hardware-supported` with at least 16 GB total memory. A CPU is sufficient, but warn that CPU-only parsing may be slow and GPU acceleration can materially reduce parsing time.-- `high` and `xhigh`: `hardware-supported` with at least 16 GB total memory and either a Volta-or-newer NVIDIA GPU with at least 8 GB available VRAM or Apple Silicon with at least 16 GB unified memory.-- For `high` and `xhigh`, an `npu`, `gcu`, `musa`, `mlu`, or `sdaa` qualifies as `hardware-supported` only when MinerU compatibility with the exact device and runtime can be verified; otherwise report `hardware-unknown`.+- `basic`: `hardware-supported` with at least 16 GB total memory. A CPU is sufficient, but warn that CPU-only parsing may be slow and GPU acceleration can materially reduce parsing time.+- `standard` and `advanced`: `hardware-supported` with at least 16 GB total memory and either a Volta-or-newer NVIDIA GPU with at least 8 GB available VRAM or Apple Silicon with at least 16 GB unified memory.+- For `standard` and `advanced`, an `npu`, `gcu`, `musa`, `mlu`, or `sdaa` qualifies as `hardware-supported` only when MinerU compatibility with the exact device and runtime can be verified; otherwise report `hardware-unknown`.- Report `hardware-unsupported` when a requirement is clearly not met. If a required property cannot be verified, report `hardware-unknown`.-Before asking the user to choose a tier, summarize the detected hardware and identify each local tier's hardware status. Recommend local `high` when `hardware-supported`, otherwise local `medium` when `hardware-supported`, otherwise offer remote `high` when privacy rules allow or explicit `flash`. Mention `xhigh` only when the user wants maximum quality and accepts the extra time. Do not install dependencies, download models, change config, or restart services without approval.+Before asking the user to choose a tier, summarize the detected hardware and identify each local tier's hardware status. Recommend local `standard` when `hardware-supported`, otherwise local `basic` when `hardware-supported`, otherwise offer remote `standard` when privacy rules allow or explicit `flash`. Mention `advanced` only when the user wants maximum quality and accepts the extra time. Do not install dependencies, download models, change config, or restart services without approval.### Configure Managed Local Parsing@@ -362,40 +362,40 @@ The following examples assume the current install tool is `uv tool`. If `mineru`Installing extras with `uv tool install --force --prerelease allow` can reinstall or upgrade the `mineru` package. Restart the MinerU server after installing extras so the CLI client, doclib server, and managed parse server use the same installed version.-Managed local `medium`, `high`, and `xhigh` all require downloaded model files. Download the target tier models before switching `parse_server.local.mode` to `managed`.+Managed local `basic`, `standard`, and `advanced` all require downloaded model files. Download the target tier models before switching `parse_server.local.mode` to `managed`.-Enable managed local parsing for `medium`:+Enable managed local parsing for `basic`:```bash-uv tool install --force --prerelease allow "mineru[medium]"-mineru-kit models download --tier medium-mineru-kit models verify --tier medium+uv tool install --force --prerelease allow "mineru[basic]"+mineru-kit models download --tier basic+mineru-kit models verify --tier basicmineru server restart-mineru config set parse_server.local.managed_tier medium+mineru config set parse_server.local.managed_tier basicmineru config set parse_server.local.mode managedmineru server status --json```-Enable managed local parsing for `high`:+Enable managed local parsing for `standard`:```bash-uv tool install --force --prerelease allow "mineru[high]"-mineru-kit models download --tier high-mineru-kit models verify --tier high+uv tool install --force --prerelease allow "mineru[standard]"+mineru-kit models download --tier standard+mineru-kit models verify --tier standardmineru server restart-mineru config set parse_server.local.managed_tier high+mineru config set parse_server.local.managed_tier standardmineru config set parse_server.local.mode managedmineru server status --json```-Enable managed local parsing for `xhigh`:+Enable managed local parsing for `advanced`:```bash-uv tool install --force --prerelease allow "mineru[xhigh]"-mineru-kit models download --tier xhigh-mineru-kit models verify --tier xhigh+uv tool install --force --prerelease allow "mineru[advanced]"+mineru-kit models download --tier advanced+mineru-kit models verify --tier advancedmineru server restart-mineru config set parse_server.local.managed_tier xhigh+mineru config set parse_server.local.managed_tier advancedmineru config set parse_server.local.mode managedmineru server status --json```@@ -407,7 +407,7 @@ Rules:- After installing extras, restart the MinerU server to avoid CLI/server version mismatch.- Set `parse_server.local.managed_tier` before `parse_server.local.mode=managed`.- Poll `mineru server status --json` and use managed parsing only after the target tier is healthy.-- If local `medium`, `high`, or `xhigh` cannot start, do not add `--remote` automatically; ask the user first.+- If local `basic`, `standard`, or `advanced` cannot start, do not add `--remote` automatically; ask the user first.## First Read From A File@@ -470,7 +470,7 @@ Rules:MinerU output may include a command to continue reading:```text-<!-- Next: mineru read doc:ab12cd3/tier:high/page:11 -->+<!-- Next: mineru read doc:ab12cd3/tier:standard/page:11 -->```or:@@ -507,10 +507,10 @@ doc:{short_id}/tier:{tier}/page:{page_no}/block:{block_no}/char:{offset}Examples:```bash-mineru read "doc:ab12cd3/tier:high/page:4"-mineru read "doc:ab12cd3/tier:high/page:4/block:7"-mineru read "doc:ab12cd3/tier:high/page:4/block:7" --context 2-mineru read "doc:ab12cd3/tier:high/page:4" --limit 8000 --json+mineru read "doc:ab12cd3/tier:standard/page:4"+mineru read "doc:ab12cd3/tier:standard/page:4/block:7"+mineru read "doc:ab12cd3/tier:standard/page:4/block:7" --context 2+mineru read "doc:ab12cd3/tier:standard/page:4" --limit 8000 --json```Rules:@@ -525,9 +525,9 @@ Rules:Use image output only when the user needs visual inspection, layout evidence, cropped figures, page screenshots, or block-level visual verification.```bash-mineru read "doc:ab12cd3/tier:high/page:4" --format image-mineru read "doc:ab12cd3/tier:high/page:4/block:7" --format image-mineru read "doc:ab12cd3/tier:high/page:4/block:7" --format image --output ./block-7.png+mineru read "doc:ab12cd3/tier:standard/page:4" --format image+mineru read "doc:ab12cd3/tier:standard/page:4/block:7" --format image+mineru read "doc:ab12cd3/tier:standard/page:4/block:7" --format image --output ./block-7.png```Rules:@@ -553,7 +553,7 @@ Use `search` for parsed document content:```bashmineru search "revenue recognition"mineru search "transformer architecture" --type pdf-mineru search "appendix" --min-tier medium --limit 10 --json+mineru search "appendix" --min-tier basic --limit 10 --json```Rules:@@ -624,8 +624,8 @@ Watch rules:Use parsing rules only when the user wants automatic parse policy for paths:```bash-mineru config parsing-rules add "*/papers/*" --tier high --pages all-mineru config parsing-rules add "*/contracts/*" --tier high --remote+mineru config parsing-rules add "*/papers/*" --tier standard --pages all+mineru config parsing-rules add "*/contracts/*" --tier standard --remotemineru config parsing-rules listmineru config parsing-rules remove 3```@@ -681,7 +681,7 @@ Invalidate cached parse results:```bashmineru invalidate "report.pdf"-mineru invalidate "report.pdf" --tier high+mineru invalidate "report.pdf" --tier standard```Rules:@@ -829,11 +829,11 @@ When answering after reading a document:Citation style examples:```text-The warranty period is 24 months (doc:ab12cd3/tier:high/page:7/block:3).+The warranty period is 24 months (doc:ab12cd3/tier:standard/page:7/block:3).``````text-The method is described across pages 4-5; I checked doc:ab12cd3/tier:high/page:4 and doc:ab12cd3/tier:high/page:5.+The method is described across pages 4-5; I checked doc:ab12cd3/tier:standard/page:4 and doc:ab12cd3/tier:standard/page:5.```## Operating Rulesdiff --git a/tests/unittest/test_cli_next_command_design.py b/tests/unittest/test_cli_next_command_design.pyindex 76acd25f..88370675 100644--- a/tests/unittest/test_cli_next_command_design.py+++ b/tests/unittest/test_cli_next_command_design.py@@ -196,8 +196,8 @@ def test_print_error_uses_single_rich_render(monkeypatch: Any) -> None:monkeypatch.setattr(output_mod, "stderr_console", _Console())output_mod.print_error(- "No medium, high, or xhigh engine available. You can start a local parse-server, use --remote, or explicitly pass "- "--tier flash for text-only preview."+ "No basic, standard, or advanced engine available. You can start a local parse-server, "+ "use --remote, or explicitly pass --tier flash for text-only preview.")assert len(calls) == 1@@ -235,7 +235,7 @@ def test_search_results_render_as_list_without_table() -> None:SearchResult(sha256="a" * 64,short_id="aaaaaaa",- tier="medium",+ tier="basic",snippet="Python\nengineer",files=[SearchFile(path="/tmp/resume.pdf", filename="resume.pdf", ext="pdf", status="active")],)@@ -244,7 +244,7 @@ def test_search_results_render_as_list_without_table() -> None:)assert "Search results (1 total)" in rendered- assert "1. Document aaaaaaa Tier: medium" in rendered+ assert "1. Document aaaaaaa Tier: basic" in renderedassert " Files:\n /tmp/resume.pdf" in renderedassert " Python engineer" in renderedassert "Snippet:" not in rendered@@ -306,7 +306,7 @@ def test_search_results_render_active_files_then_inactive_fallback_and_orphan()sha256="a" * 64,short_id="aaaaaaa",title="Active document",- tier="high",+ tier="standard",snippet="active",files=[SearchFile(path="/tmp/deleted.pdf", filename="deleted.pdf", ext="pdf", status="deleted"),@@ -316,7 +316,7 @@ def test_search_results_render_active_files_then_inactive_fallback_and_orphan()SearchResult(sha256="b" * 64,short_id="bbbbbbb",- tier="medium",+ tier="basic",snippet="inactive",files=[SearchFile(@@ -352,7 +352,7 @@ def test_list_renderers_return_tables(monkeypatch: Any) -> None:id=7,sha256="a" * 64,short_id="aaaaaaa",- tier="medium",+ tier="basic",page_range="1~2",status="done",privacy="local",@@ -400,7 +400,7 @@ def test_list_renderers_return_tables(monkeypatch: Any) -> None:docs_table = list_resources._render_list_docs(ListDocsResponse(docs=[doc], total=1, limit=50))assert parses_table.title == "Parses (1 total)"- assert ("7", "done", "medium", "1~2", "aaaaaaa") in parses_table.rows+ assert ("7", "done", "basic", "1~2", "aaaaaaa") in parses_table.rowsassert scans_table.title == "Scans (1 total)"assert ("8", "done", "manual", "/tmp/docs", "3", "2", "1") in scans_table.rowsassert files_table.title == "Files (1 total)"@@ -413,7 +413,7 @@ def test_config_and_rule_renderers_return_tables(monkeypatch: Any) -> None:monkeypatch.setattr(config, "Table", _FakeTable)config_table = config._render_config(- ConfigResponse(config={"parse.default_tier": "medium"}, sources={"parse.default_tier": "override"})+ ConfigResponse(config={"parse.default_tier": "basic"}, sources={"parse.default_tier": "override"}))exclude_table = config._render_exclude_rules(ExcludeRuleListResponse(rules=[ExcludeRuleInfo(id=3, pattern="*.tmp", priority=10)])@@ -421,17 +421,17 @@ def test_config_and_rule_renderers_return_tables(monkeypatch: Any) -> None:parsing_table = config._render_parsing_rules(ParsingRuleListResponse(rules=[- ParsingRuleInfo(id=4, pattern="*.pdf", tier="medium", page_range="1~2", remote=True, name="pdfs")+ ParsingRuleInfo(id=4, pattern="*.pdf", tier="basic", page_range="1~2", remote=True, name="pdfs")]))assert config_table.title == "Config"- assert ("parse.default_tier", "medium", "override") in config_table.rows+ assert ("parse.default_tier", "basic", "override") in config_table.rowsassert exclude_table.title == "Exclude Rules"assert ("3", "*.tmp", "10") in exclude_table.rowsassert parsing_table.title == "Parsing Rules"- assert ("4", "*.pdf", "medium", "1~2", "yes", "pdfs") in parsing_table.rows+ assert ("4", "*.pdf", "basic", "1~2", "yes", "pdfs") in parsing_table.rowsdef test_watch_list_renderer_returns_table(monkeypatch: Any) -> None:@@ -451,7 +451,7 @@ def test_show_detail_renderers_return_tables(monkeypatch: Any) -> None:id=9,sha256="a" * 64,short_id="aaaaaaa",- tier="high",+ tier="standard",page_range="1",status="done",privacy="local",@@ -486,7 +486,7 @@ def test_show_detail_renderers_return_tables(monkeypatch: Any) -> None:doc_table = show._render_doc_info(doc)assert parse_table.title == "Parse 9: done"- assert ("Tier", "high") in parse_table.rows+ assert ("Tier", "standard") in parse_table.rowsassert scan_table.title == "Scan 10: done"assert ("Seen", "4") in scan_table.rowsassert doc_table.title == "Doc ddddddd"@@ -686,13 +686,13 @@ def test_list_parses_passes_filters_to_doclib_client(monkeypatch: Any) -> None:result = runner.invoke(app,- ["list", "parses", "--status", "pending", "--tier", "medium", "--limit", "10", "--offset", "5", "--json"],+ ["list", "parses", "--status", "pending", "--tier", "basic", "--limit", "10", "--offset", "5", "--json"],)assert result.exit_code == 0assert calls[-1] == ("list_parses",- {"status": "pending", "tier": "medium", "limit": 10, "offset": 5},+ {"status": "pending", "tier": "basic", "limit": 10, "offset": 5},)@@ -705,7 +705,7 @@ def test_parse_wait_ignores_failed_rows_outside_wait_ids(monkeypatch: Any, tmp_pid=2,sha256="a" * 64,short_id="aaaaaaa",- tier="high",+ tier="standard",page_range="1~10",status="failed",privacy="remote",@@ -718,7 +718,7 @@ def test_parse_wait_ignores_failed_rows_outside_wait_ids(monkeypatch: Any, tmp_pid=3,sha256="a" * 64,short_id="aaaaaaa",- tier="high",+ tier="standard",page_range="1~10",status="done",privacy="remote",@@ -735,7 +735,7 @@ def test_parse_wait_ignores_failed_rows_outside_wait_ids(monkeypatch: Any, tmp_pdef ensure_parse(self, request: Any) -> ParseResponse:return ParseResponse(sha256="a" * 64,- tier="high",+ tier="standard",page_range="1~10",status="pending",wait_parse_ids=[3],@@ -750,7 +750,7 @@ def test_parse_wait_ignores_failed_rows_outside_wait_ids(monkeypatch: Any, tmp_preturn DocContentResponse(sha256="a" * 64,short_id="aaaaaaa",- tier="high",+ tier="standard",format="markdown",content="parsed",request_scope=ContentRequestScope(page_range="1~10", after=None, limit=30000),@@ -777,7 +777,7 @@ def test_parse_wait_json_maps_invalid_api_key_param(monkeypatch: Any, tmp_path:id=3,sha256="a" * 64,short_id="aaaaaaa",- tier="high",+ tier="standard",page_range="1~1",status="failed",privacy="remote",@@ -794,7 +794,7 @@ def test_parse_wait_json_maps_invalid_api_key_param(monkeypatch: Any, tmp_path:def ensure_parse(self, request: Any) -> ParseResponse:return ParseResponse(sha256="a" * 64,- tier="high",+ tier="standard",page_range="1~1",status="pending",wait_parse_ids=[3],@@ -1155,14 +1155,14 @@ def test_parse_next_marker_omits_default_parse_context(monkeypatch: Any, tmp_patdef ensure_parse(self, request: Any) -> ParseResponse:assert request.tier is Noneassert request.remote is False- return ParseResponse(sha256="a" * 64, tier="medium", page_range="1~10", status="done", cache_hit=True)+ return ParseResponse(sha256="a" * 64, tier="basic", page_range="1~10", status="done", cache_hit=True)def get_doc_content(self, *args: Any, **kwargs: Any) -> DocContentResponse:assert kwargs["limit"] == 30000return DocContentResponse(sha256="a" * 64,short_id="aaaaaaa",- tier="medium",+ tier="basic",format="markdown",content="parsed",request_scope=ContentRequestScope(page_range="1~10", limit=30000),@@ -1219,7 +1219,7 @@ def test_parse_no_wait_text_prints_parse_id_tracking_hint(monkeypatch: Any, tmp_def ensure_parse(self, request: Any) -> ParseResponse:return ParseResponse(sha256="a" * 64,- tier="high",+ tier="standard",page_range="1~1",status="pending",wait_parse_ids=[4686],@@ -1228,11 +1228,11 @@ def test_parse_no_wait_text_prints_parse_id_tracking_hint(monkeypatch: Any, tmp_monkeypatch.setattr(parse, "DoclibClient", _Client)- result = runner.invoke(app, ["parse", str(source), "--tier", "high", "--remote", "--no-wait"])+ result = runner.invoke(app, ["parse", str(source), "--tier", "standard", "--remote", "--no-wait"])assert result.exit_code == 0assert result.output == (- "Parse still in progress (tier=high).\n"+ "Parse still in progress (tier=standard).\n""Parse ID: 4686\n""Check status: mineru show parse 4686\n")@@ -1249,7 +1249,7 @@ def test_parse_no_wait_text_prints_multiple_parse_id_tracking_hints(monkeypatch:def ensure_parse(self, request: Any) -> ParseResponse:return ParseResponse(sha256="a" * 64,- tier="high",+ tier="standard",page_range="1~2",status="pending",wait_parse_ids=[4686, 4687],@@ -1259,11 +1259,11 @@ def test_parse_no_wait_text_prints_multiple_parse_id_tracking_hints(monkeypatch:monkeypatch.setattr(parse, "DoclibClient", _Client)- result = runner.invoke(app, ["parse", str(source), "--tier", "high", "--remote", "--no-wait"])+ result = runner.invoke(app, ["parse", str(source), "--tier", "standard", "--remote", "--no-wait"])assert result.exit_code == 0assert result.output == (- "Parse still in progress (tier=high).\n"+ "Parse still in progress (tier=standard).\n""Parse IDs: 4686, 4687\n""Check status:\n"" mineru show parse 4686\n"@@ -1577,7 +1577,7 @@ def test_parse_json_error_output_is_machine_readable(monkeypatch: Any, tmp_path:def ensure_parse(self, request: Any) -> ParseResponse:raise RuntimeError(- "('quality_tier_unavailable', 'No medium, high, or xhigh engine available. Use --tier flash.', None)"+ "('quality_tier_unavailable', 'No basic, standard, or advanced engine available. Use --tier flash.', None)")monkeypatch.setattr(parse, "DoclibClient", _Client)@@ -1587,7 +1587,7 @@ def test_parse_json_error_output_is_machine_readable(monkeypatch: Any, tmp_path:assert result.exit_code == 1payload = json.loads(result.output)assert payload["error"]["code"] == "quality_tier_unavailable"- assert "No medium, high, or xhigh engine available" in payload["error"]["message"]+ assert "No basic, standard, or advanced engine available" in payload["error"]["message"]@pytest.mark.parametrize("json_mode", [False, True])@@ -1633,7 +1633,7 @@ def test_parse_invalid_after_cursor_json_error_is_validation_error(monkeypatch:assert timeout == 31def ensure_parse(self, request: Any) -> ParseResponse:- return ParseResponse(sha256="a" * 64, tier="medium", page_range="1", status="done")+ return ParseResponse(sha256="a" * 64, tier="basic", page_range="1", status="done")def get_doc_content(self, *args: Any, **kwargs: Any) -> DocContentResponse:raise RuntimeError(@@ -1956,7 +1956,7 @@ def test_invalidate_normalizes_user_path_before_request(monkeypatch: Any, tmp_pamonkeypatch.setenv("HOME", str(home))monkeypatch.setattr(invalidate, "DoclibClient", _Client)- result = runner.invoke(app, ["invalidate", "~/docs/../docs/demo.pdf", "--tier", "medium"])+ result = runner.invoke(app, ["invalidate", "~/docs/../docs/demo.pdf", "--tier", "basic"])assert result.exit_code == 0assert calls == [os.path.normpath(os.path.abspath(os.path.expanduser("~/docs/../docs/demo.pdf")))]@@ -2234,7 +2234,7 @@ def test_read_passes_locator_parameters_to_doclib_client(monkeypatch: Any) -> Noreturn DocContentResponse(sha256="a" * 64,short_id="ab12cd3",- tier="medium",+ tier="basic",format="markdown",content="hello",request_scope=ContentRequestScope(locator=locator, context=kwargs["context"], limit=kwargs["limit"]),@@ -2244,13 +2244,13 @@ def test_read_passes_locator_parameters_to_doclib_client(monkeypatch: Any) -> Noresult = runner.invoke(app,- ["read", "doc:ab12cd3/tier:medium/page:4", "--context", "2", "--limit", "123", "--format", "markdown"],+ ["read", "doc:ab12cd3/tier:basic/page:4", "--context", "2", "--limit", "123", "--format", "markdown"],)assert result.exit_code == 0assert calls == [(- "doc:ab12cd3/tier:medium/page:4",+ "doc:ab12cd3/tier:basic/page:4",{"context": 2, "limit": 123, "format": "markdown", "no_marker": False},)]@@ -2266,20 +2266,20 @@ def test_read_json_output_preserves_locator_next_request(monkeypatch: Any) -> Noreturn DocContentResponse(sha256="a" * 64,short_id="ab12cd3",- tier="medium",+ tier="basic",format="markdown",content="hello",request_scope=ContentRequestScope(locator=locator, context=0, limit=30000),- next_request=ContentNextRequest(locator="doc:ab12cd3/tier:medium/page:5"),+ next_request=ContentNextRequest(locator="doc:ab12cd3/tier:basic/page:5"),)monkeypatch.setattr(read, "DoclibClient", _Client)- result = runner.invoke(app, ["read", "doc:ab12cd3/tier:medium/page:4", "--json"])+ result = runner.invoke(app, ["read", "doc:ab12cd3/tier:basic/page:4", "--json"])assert result.exit_code == 0payload = json.loads(result.output)- assert payload["next_request"]["locator"] == "doc:ab12cd3/tier:medium/page:5"+ assert payload["next_request"]["locator"] == "doc:ab12cd3/tier:basic/page:5"def test_read_markdown_output_separates_next_marker_with_blank_line(monkeypatch: Any) -> None:@@ -2291,19 +2291,19 @@ def test_read_markdown_output_separates_next_marker_with_blank_line(monkeypatch:return DocContentResponse(sha256="a" * 64,short_id="ab12cd3",- tier="medium",+ tier="basic",format="markdown",content="hello",request_scope=ContentRequestScope(locator=locator, context=0, limit=30000),- next_request=ContentNextRequest(locator="doc:ab12cd3/tier:medium/page:5"),+ next_request=ContentNextRequest(locator="doc:ab12cd3/tier:basic/page:5"),)monkeypatch.setattr(read, "DoclibClient", _Client)- result = runner.invoke(app, ["read", "doc:ab12cd3/tier:medium/page:4"])+ result = runner.invoke(app, ["read", "doc:ab12cd3/tier:basic/page:4"])assert result.exit_code == 0- assert "hello\n\n<!-- Next: mineru read doc:ab12cd3/tier:medium/page:5 -->" in result.output+ assert "hello\n\n<!-- Next: mineru read doc:ab12cd3/tier:basic/page:5 -->" in result.outputdef test_read_json_error_output_is_machine_readable(monkeypatch: Any) -> None:@@ -2316,7 +2316,7 @@ def test_read_json_error_output_is_machine_readable(monkeypatch: Any) -> None:monkeypatch.setattr(read, "DoclibClient", _Client)- result = runner.invoke(app, ["read", "doc:ab12cd3/tier:medium/page:4", "--json"])+ result = runner.invoke(app, ["read", "doc:ab12cd3/tier:basic/page:4", "--json"])assert result.exit_code == 1payload = json.loads(result.output)@@ -2365,7 +2365,7 @@ def test_read_json_output_writes_markdown_file_and_returns_output_object(monkeypreturn DocContentResponse(sha256="a" * 64,short_id="ab12cd3",- tier="medium",+ tier="basic",format="markdown",content="hello",request_scope=ContentRequestScope(locator=locator, context=0, limit=30000),@@ -2373,7 +2373,7 @@ def test_read_json_output_writes_markdown_file_and_returns_output_object(monkeypmonkeypatch.setattr(read, "DoclibClient", _Client)- result = runner.invoke(app, ["read", "doc:ab12cd3/tier:medium/page:4", "--output", str(output), "--json"])+ result = runner.invoke(app, ["read", "doc:ab12cd3/tier:basic/page:4", "--output", str(output), "--json"])assert result.exit_code == 0payload = json.loads(result.output)@@ -2397,7 +2397,7 @@ def test_read_json_output_writes_image_file_and_returns_output_object(monkeypatcreturn DocContentResponse(sha256="a" * 64,short_id="ab12cd3",- tier="medium",+ tier="basic",format="image",content="",request_scope=ContentRequestScope(locator=locator, context=0, limit=30000),@@ -2406,7 +2406,7 @@ def test_read_json_output_writes_image_file_and_returns_output_object(monkeypatcmonkeypatch.setattr(read, "DoclibClient", _Client)- result = runner.invoke(app, ["read", "doc:ab12cd3/tier:medium/page:4", "--format", "image", "--output", str(output), "--json"])+ result = runner.invoke(app, ["read", "doc:ab12cd3/tier:basic/page:4", "--format", "image", "--output", str(output), "--json"])assert result.exit_code == 0payload = json.loads(result.output)@@ -2441,7 +2441,7 @@ def test_read_image_output_extension_selects_server_image_format(return DocContentResponse(sha256="a" * 64,short_id="ab12cd3",- tier="medium",+ tier="basic",format="image",content="",request_scope=ContentRequestScope(locator=locator, context=0, limit=30000),@@ -2450,7 +2450,7 @@ def test_read_image_output_extension_selects_server_image_format(monkeypatch.setattr(read, "DoclibClient", _Client)- result = runner.invoke(app, ["read", "doc:ab12cd3/tier:medium/page:4", "--format", "image", "--output", str(output)])+ result = runner.invoke(app, ["read", "doc:ab12cd3/tier:basic/page:4", "--format", "image", "--output", str(output)])assert result.exit_code == 0assert output.read_bytes() == b"image-bytes"@@ -2467,7 +2467,7 @@ def test_read_image_output_rejects_unsupported_output_extension_before_client_camonkeypatch.setattr(read, "DoclibClient", _Client)output = output_arg if output_arg == "-" else str(tmp_path / output_arg)- result = runner.invoke(app, ["read", "doc:ab12cd3/tier:medium/page:4", "--format", "image", "--output", output, "--json"])+ result = runner.invoke(app, ["read", "doc:ab12cd3/tier:basic/page:4", "--format", "image", "--output", output, "--json"])assert result.exit_code == 1payload = json.loads(result.output)@@ -2489,7 +2489,7 @@ def test_read_json_image_output_missing_asset_reports_error_envelope(monkeypatchreturn DocContentResponse(sha256="a" * 64,short_id="ab12cd3",- tier="medium",+ tier="basic",format="image",content="",request_scope=ContentRequestScope(locator=locator, context=0, limit=30000),@@ -2498,7 +2498,7 @@ def test_read_json_image_output_missing_asset_reports_error_envelope(monkeypatchmonkeypatch.setattr(read, "DoclibClient", _Client)- result = runner.invoke(app, ["read", "doc:ab12cd3/tier:medium/page:4", "--format", "image", "--output", str(output), "--json"])+ result = runner.invoke(app, ["read", "doc:ab12cd3/tier:basic/page:4", "--format", "image", "--output", str(output), "--json"])assert result.exit_code == 1payload = json.loads(result.output)@@ -2522,7 +2522,7 @@ def test_read_image_output_copies_server_asset_locally(monkeypatch: Any, tmp_patreturn DocContentResponse(sha256="a" * 64,short_id="ab12cd3",- tier="medium",+ tier="basic",format="image",content="",request_scope=ContentRequestScope(locator=locator, context=0, limit=30000),@@ -2531,7 +2531,7 @@ def test_read_image_output_copies_server_asset_locally(monkeypatch: Any, tmp_patmonkeypatch.setattr(read, "DoclibClient", _Client)- result = runner.invoke(app, ["read", "doc:ab12cd3/tier:medium/page:4", "--format", "image", "--output", str(output)])+ result = runner.invoke(app, ["read", "doc:ab12cd3/tier:basic/page:4", "--format", "image", "--output", str(output)])assert result.exit_code == 0assert output.read_bytes() == b"png-bytes"@@ -2545,7 +2545,7 @@ def test_search_json_error_output_is_machine_readable(monkeypatch: Any) -> None:assert timeout == 10def search(self, *args: Any, **kwargs: Any) -> Any:- raise RuntimeError("('quality_tier_unavailable', 'No medium, high, or xhigh engine available.', 'tier')")+ raise RuntimeError("('quality_tier_unavailable', 'No basic, standard, or advanced engine available.', 'tier')")monkeypatch.setattr(search_mod, "DoclibClient", _Client)diff --git a/tests/unittest/test_doclib_app_startup.py b/tests/unittest/test_doclib_app_startup.pyindex 60144758..2e8ad743 100644--- a/tests/unittest/test_doclib_app_startup.py+++ b/tests/unittest/test_doclib_app_startup.py@@ -55,11 +55,11 @@ def test_doclib_runtime_dependencies_are_in_base_install() -> None:assert "watchfiles" in dependency_names-def test_medium_extra_includes_preflight_runtime_dependencies() -> None:+def test_basic_extra_includes_preflight_runtime_dependencies() -> None:pyproject_path = Path(__file__).resolve().parents[2] / "pyproject.toml"pyproject = tomllib.loads(pyproject_path.read_text(encoding="utf-8"))- medium_dependencies = pyproject["project"]["optional-dependencies"]["medium"]- dependency_names = {dependency.split(">", 1)[0].split("=", 1)[0].lower() for dependency in medium_dependencies}+ basic_dependencies = pyproject["project"]["optional-dependencies"]["basic"]+ dependency_names = {dependency.split(">", 1)[0].split("=", 1)[0].lower() for dependency in basic_dependencies}module_to_distribution = {"ftfy": "ftfy","pyclipper": "pyclipper",@@ -72,7 +72,7 @@ def test_medium_extra_includes_preflight_runtime_dependencies() -> None:missing = [module_name- for module_name in parser_tier.required_modules_for_tier("medium")+ for module_name in parser_tier.required_modules_for_tier("basic")if module_to_distribution[module_name] not in dependency_names]@@ -116,7 +116,7 @@ def test_config_set_managed_tier_rejects_missing_models(monkeypatch: pytest.Monkcfg = PatchedConfig(doclib={"data_dir": str(tmp_path), "sqlite": {"path": str(tmp_path / "doclib.db")}})with TestClient(doclib_app.create_app(cfg)) as client:- response = client.put("/api/v1/configs/parse_server.local.managed_tier", json={"value": "medium"})+ response = client.put("/api/v1/configs/parse_server.local.managed_tier", json={"value": "basic"})config_response = client.get("/api/v1/configs/parse_server.local.managed_tier")assert response.status_code == 400@@ -124,8 +124,8 @@ def test_config_set_managed_tier_rejects_missing_models(monkeypatch: pytest.Monkassert payload["error"]["code"] == "parse_server_model_not_ready"assert payload["error"]["param"] == "parse_server.local.managed_tier"assert "PDF-Extract-Kit-1.0" in payload["error"]["message"]- assert "mineru-kit models download --tier medium" in payload["error"]["message"]- assert config_response.json()["value"] == "high"+ assert "mineru-kit models download --tier basic" in payload["error"]["message"]+ assert config_response.json()["value"] == "standard"assert config_response.json()["source"] == "default"@@ -148,7 +148,7 @@ def test_config_set_managed_mode_rejects_missing_models_for_current_tier(payload = response.json()assert payload["error"]["code"] == "parse_server_model_not_ready"assert payload["error"]["param"] == "parse_server.local.mode"- assert "mineru-kit models download --tier high" in payload["error"]["message"]+ assert "mineru-kit models download --tier standard" in payload["error"]["message"]assert config_response.json()["value"] == "disabled"assert config_response.json()["source"] == "default"@@ -491,7 +491,7 @@ def test_managed_parse_server_startup_clears_invalid_tier_override(monkeypatch,def _popen(*args: object, **kwargs: object) -> _Proc:cmd = args[0]assert "--tier" in cmd- assert cmd[cmd.index("--tier") + 1] == "high"+ assert cmd[cmd.index("--tier") + 1] == "standard"return _Proc()def _skip_background_task(*args, **kwargs):@@ -522,8 +522,8 @@ def test_managed_parse_server_startup_clears_invalid_tier_override(monkeypatch,config_response = client.get("/api/v1/configs/parse_server.local.managed_tier")status_response = client.get("/api/v1/server/status")- assert config_response.json()["value"] == "high"- assert status_response.json()["parse_server"]["local"]["managed_tier"] == "high"+ assert config_response.json()["value"] == "standard"+ assert status_response.json()["parse_server"]["local"]["managed_tier"] == "standard"def test_managed_parse_server_shutdown_uses_health_proc(monkeypatch, tmp_path) -> None:diff --git a/tests/unittest/test_doclib_cache_semantics.py b/tests/unittest/test_doclib_cache_semantics.pyindex 6ade6f87..f60dd342 100644--- a/tests/unittest/test_doclib_cache_semantics.py+++ b/tests/unittest/test_doclib_cache_semantics.py@@ -270,7 +270,7 @@ def _text_page(text: str) -> PageInfo:def test_load_pages_from_done_batches_keeps_newest_page_idx(tmp_path: Path) -> None:sha256 = "a" * 64- tier = "high"+ tier = "standard"older_page = {"page_idx": 1, "page_size": [100, 100], "para_blocks": []}older_duplicate = {"page_idx": 2, "page_size": [100, 100], "para_blocks": []}newer_duplicate = {"page_idx": 2, "page_size": [200, 200], "para_blocks": []}@@ -292,26 +292,26 @@ def test_load_pages_from_done_batches_keeps_newest_page_idx(tmp_path: Path) -> Ndef test_parser_tier_backend_mapping_is_parser_layer_only() -> None:assert backend_for_tier("flash") == "flash"- assert backend_for_tier("medium") == "hybrid-engine"- assert backend_for_tier("high") == "hybrid-engine"- assert backend_for_tier("xhigh") == "hybrid-engine"- assert resolve_tier_and_backend(tier=None) == ("high", "hybrid-engine")- assert resolve_tier_and_backend(tier="xhigh", backend="vlm-auto-engine") == ("xhigh", "hybrid-engine")+ assert backend_for_tier("basic") == "hybrid-engine"+ assert backend_for_tier("standard") == "hybrid-engine"+ assert backend_for_tier("advanced") == "hybrid-engine"+ assert resolve_tier_and_backend(tier=None) == ("standard", "hybrid-engine")+ assert resolve_tier_and_backend(tier="advanced", backend="vlm-auto-engine") == ("advanced", "hybrid-engine")def test_managed_api_server_args_use_tier_and_selected_port_for_process_start() -> None:- assert api_server_args_for_tier("high", host="127.0.0.1", port=16580) == [+ assert api_server_args_for_tier("standard", host="127.0.0.1", port=16580) == ["--tier",- "high",+ "standard","--host","127.0.0.1","--port","16580","--allow-local-source",]- assert api_server_args_for_tier("xhigh", host="127.0.0.2", port=16581) == [+ assert api_server_args_for_tier("advanced", host="127.0.0.2", port=16581) == ["--tier",- "xhigh",+ "advanced","--host","127.0.0.2","--port",@@ -356,7 +356,7 @@ def test_managed_parse_server_port_selection_tries_configured_range(monkeypatch:def test_default_tier_error_mentions_remote_when_remote_is_healthy(monkeypatch: pytest.MonkeyPatch) -> None:health = ParseServerHealth(local=ProbeState(probe=ProbeResult(tiers=["flash"])),- remote=ProbeState(probe=ProbeResult(healthy=True, tiers=["high", "xhigh"])),+ remote=ProbeState(probe=ProbeResult(healthy=True, tiers=["standard", "advanced"])),)monkeypatch.setattr("mineru.doclib.background.parse_server_health.get_health", lambda: health)@@ -415,13 +415,13 @@ def test_self_hosted_default_tier_preserves_probe_invalid_api_key(monkeypatch: pdef test_parsing_rule_default_tier_allows_flash_fallback(monkeypatch: pytest.MonkeyPatch) -> None:- health = ParseServerHealth(local=ProbeState(probe=ProbeResult(tiers=["medium", "xhigh"])))+ health = ParseServerHealth(local=ProbeState(probe=ProbeResult(tiers=["basic", "advanced"])))monkeypatch.setattr("mineru.doclib.background.parse_server_health.get_health", lambda: health)- assert _resolve_parsing_rule_default_tier() == "xhigh"+ assert _resolve_parsing_rule_default_tier() == "advanced"- health.local.probe = ProbeResult(tiers=["medium", "high", "xhigh"])- assert _resolve_parsing_rule_default_tier() == "high"+ health.local.probe = ProbeResult(tiers=["basic", "standard", "advanced"])+ assert _resolve_parsing_rule_default_tier() == "standard"health.local.probe = ProbeResult(tiers=["flash"])assert _resolve_parsing_rule_default_tier() == "flash"@@ -432,11 +432,11 @@ def test_read_without_tier_uses_highest_cached_tier() -> None:async def fetchall(self, sql: str, params: tuple[Any, ...]) -> list[dict[str, str]]:assert sql == "SELECT tier FROM parses WHERE sha256=? AND status=? GROUP BY tier"assert params == ("a" * 64, "done")- return [{"tier": "flash"}, {"tier": "medium"}, {"tier": "high"}, {"tier": "xhigh"}]+ return [{"tier": "flash"}, {"tier": "basic"}, {"tier": "standard"}, {"tier": "advanced"}]server = DoclibServer(SimpleNamespace(db=_DB()))- assert asyncio.run(server._default_read_tier("a" * 64)) == "xhigh"+ assert asyncio.run(server._default_read_tier("a" * 64)) == "advanced"def test_managed_local_parse_server_url_uses_health_managed_url() -> None:@@ -452,7 +452,7 @@ def test_parse_server_health_probe_disables_env_proxy_for_local_urls(monkeypatchstatus_code = 200def json(self) -> dict[str, list[dict[str, str]]]:- return {"data": [{"id": "high"}]}+ return {"data": [{"id": "standard"}]}class _AsyncClient:def __init__(self, *, timeout: int, trust_env: bool) -> None:@@ -470,8 +470,8 @@ def test_parse_server_health_probe_disables_env_proxy_for_local_urls(monkeypatchmonkeypatch.setattr("mineru.doclib.background.parse_server_health.httpx.AsyncClient", _AsyncClient)checker = ParseServerHealthCheck(None, interval_sec=1, probe_timeout_sec=2, startup_grace_sec=3, stop_timeout_sec=4)- assert asyncio.run(checker._probe("http://127.0.0.1:16580")) == ProbeResult(healthy=True, tiers=["high"])- assert asyncio.run(checker._probe("https://mineru.net/api")) == ProbeResult(healthy=True, tiers=["high"])+ assert asyncio.run(checker._probe("http://127.0.0.1:16580")) == ProbeResult(healthy=True, tiers=["standard"])+ assert asyncio.run(checker._probe("https://mineru.net/api")) == ProbeResult(healthy=True, tiers=["standard"])assert calls == [False, True]@@ -520,7 +520,7 @@ def test_start_managed_parse_server_selects_port_and_writes_logs(monkeypatch: pypopen_calls.append({"args": args, "kwargs": kwargs})cmd = args[0]assert "--tier" in cmd- assert cmd[cmd.index("--tier") + 1] == "high"+ assert cmd[cmd.index("--tier") + 1] == "standard"assert "--host" in cmdassert cmd[cmd.index("--host") + 1] == "127.0.0.2"assert "--port" in cmd@@ -542,7 +542,7 @@ def test_start_managed_parse_server_selects_port_and_writes_logs(monkeypatch: pymonkeypatch.setattr("mineru.doclib.background.parse_server_health.subprocess.Popen", _popen)proc, url = start_managed_parse_server(- tier="high",+ tier="standard",managed_cfg=ManagedParseServerConfig(host="127.0.0.2", port=16580, port_probe_count=3),log_cfg=LogConfig(parse_server_stdout_path=str(parse_stdout_log_path),@@ -600,7 +600,7 @@ def test_managed_parse_server_restart_writes_stdout_and_stderr_logs(monkeypatch:class _ConfigSvc:async def get(self, key: str) -> str:assert key == "parse_server.local.managed_tier"- return "high"+ return "standard"class _Proc:pid = 12345@@ -676,7 +676,7 @@ def test_managed_parse_server_restart_clears_invalid_tier_override(monkeypatch:def _popen(*args: Any, **kwargs: Any) -> _Proc:cmd = args[0]assert "--tier" in cmd- assert cmd[cmd.index("--tier") + 1] == "high"+ assert cmd[cmd.index("--tier") + 1] == "standard"events.append("start")return _Proc()@@ -703,7 +703,7 @@ def test_managed_parse_server_restart_clears_invalid_tier_override(monkeypatch:assert events == ["start"]assert config_svc.unset_keys == ["parse_server.local.managed_tier"]- assert health.running_managed_tier == "high"+ assert health.running_managed_tier == "standard"def test_managed_parse_server_restart_stops_recorded_proc_before_start(monkeypatch: pytest.MonkeyPatch) -> None:@@ -713,7 +713,7 @@ def test_managed_parse_server_restart_stops_recorded_proc_before_start(monkeypatclass _ConfigSvc:async def get(self, key: str) -> str:assert key == "parse_server.local.managed_tier"- return "high"+ return "standard"class _Proc:pid = 67890@@ -782,14 +782,14 @@ def test_managed_parse_server_tier_change_detection_triggers_restart(monkeypatchcalls.append((reason, marker or "", count_restart))monkeypatch.setattr(checker, "_try_restart_managed", _restart)- health = ParseServerHealth(running_managed_tier="high")+ health = ParseServerHealth(running_managed_tier="standard")- restarted = asyncio.run(checker._try_restart_managed_for_tier_change(health, "xhigh"))- unchanged = asyncio.run(checker._try_restart_managed_for_tier_change(health, "high"))+ restarted = asyncio.run(checker._try_restart_managed_for_tier_change(health, "advanced"))+ unchanged = asyncio.run(checker._try_restart_managed_for_tier_change(health, "standard"))assert restarted is Trueassert unchanged is False- assert calls == [("tier-change", "tier change high->xhigh", False)]+ assert calls == [("tier-change", "tier change standard->advanced", False)]def test_managed_parse_server_tier_change_restart_uses_desired_tier(monkeypatch: pytest.MonkeyPatch) -> None:@@ -799,7 +799,7 @@ def test_managed_parse_server_tier_change_restart_uses_desired_tier(monkeypatch:class _ConfigSvc:async def get(self, key: str) -> str:assert key == "parse_server.local.managed_tier"- return "xhigh"+ return "advanced"class _Proc:pid = 24680@@ -811,10 +811,10 @@ def test_managed_parse_server_tier_change_restart_uses_desired_tier(monkeypatch:events.append("stop")def _start(*, tier: Tier, managed_cfg: ManagedParseServerConfig, log_cfg: LogConfig | None, marker: str) -> tuple[_Proc, str]:- assert tier == "xhigh"+ assert tier == "advanced"assert managed_cfg.host == "127.0.0.2"assert log_cfg is None- assert marker == "tier change high->xhigh"+ assert marker == "tier change standard->advanced"events.append("start")return _Proc(), "http://127.0.0.2:16582"@@ -829,20 +829,20 @@ def test_managed_parse_server_tier_change_restart_uses_desired_tier(monkeypatch:stop_timeout_sec=4,managed_parse_server=ManagedParseServerConfig(host="127.0.0.2", port=16580, port_probe_count=3),)- health = ParseServerHealth(managed_proc=old_proc, running_managed_tier="high", restart_count=2)+ health = ParseServerHealth(managed_proc=old_proc, running_managed_tier="standard", restart_count=2)asyncio.run(checker._try_restart_managed(health,reason="tier-change",- marker="tier change high->xhigh",+ marker="tier change standard->advanced",count_restart=False,))assert events == ["stop", "start"]assert health.managed_proc.pid == 24680- assert health.running_managed_tier == "xhigh"+ assert health.running_managed_tier == "advanced"assert health.restart_count == 2@@ -951,7 +951,7 @@ def test_remote_api_target_prefers_config_api_key_over_env(monkeypatch: pytest.Mparse_lock_timeout_sec=1800,)- base_url, api_key, via = await service._resolve_api_target("remote", "high")+ base_url, api_key, via = await service._resolve_api_target("remote", "standard")assert base_url == "https://mineru.net/api"assert api_key == "config-key"@@ -987,7 +987,7 @@ def test_remote_api_target_preserves_probe_invalid_api_key(monkeypatch: pytest.M)with pytest.raises(ParseFailure) as exc_info:- await service._resolve_api_target("remote", "high")+ await service._resolve_api_target("remote", "standard")assert exc_info.value.code == "invalid_api_key"assert exc_info.value.message == "Remote parse-server authentication failed: Invalid or missing API key"@@ -1024,7 +1024,7 @@ def test_self_hosted_api_target_preserves_probe_invalid_api_key(monkeypatch: pyt)with pytest.raises(ParseFailure) as exc_info:- await service._resolve_api_target("local", "high")+ await service._resolve_api_target("local", "standard")assert exc_info.value.code == "invalid_api_key"assert exc_info.value.message == "Local self-hosted parse-server authentication failed: Invalid or missing API key"@@ -1077,7 +1077,7 @@ def test_remote_parse_server_default_url_is_declared_once() -> None:def test_compaction_uses_configured_data_dir(tmp_path: Path) -> None:sha256 = "b" * 64- tier = "high"+ tier = "standard"older_page = {"page_idx": 0, "content": "old"}older_duplicate = {"page_idx": 1, "content": "old"}newer_duplicate = {"page_idx": 1, "content": "new"}@@ -1103,12 +1103,12 @@ def test_compaction_uses_configured_data_dir(tmp_path: Path) -> None:def test_invalidate_deletes_fts_when_no_done_batches_remain(tmp_path: Path) -> None:sha256 = "c" * 64- parses = [{"sha256": sha256, "tier": "high", "page_range": "1", "status": "done", "done_at": 1000}]+ parses = [{"sha256": sha256, "tier": "standard", "page_range": "1", "status": "done", "done_at": 1000}]db = _FakeDB(parses=parses, file_row={"sha256": sha256, "status": "active", "filename": "doc.pdf"})fts = _FakeFTS()service = ParseService(db=db, fts=fts, config_svc=None, data_dir=str(tmp_path), parse_lock_timeout_sec=1800)- count = asyncio.run(service.invalidate(sha256, "high"))+ count = asyncio.run(service.invalidate(sha256, "standard"))assert count == 1assert parses[0]["status"] == "superseded"@@ -1119,16 +1119,16 @@ def test_invalidate_deletes_fts_when_no_done_batches_remain(tmp_path: Path) -> Ndef test_invalidate_rebuilds_fts_from_highest_remaining_done_tier(tmp_path: Path) -> None:sha256 = "d" * 64_write_batch(tmp_path, sha256, "flash", "1", 1000, [{"page_idx": 1, "page_size": [100, 100], "para_blocks": []}])- _write_batch(tmp_path, sha256, "high", "1", 2000, [{"page_idx": 1, "page_size": [200, 200], "para_blocks": []}])+ _write_batch(tmp_path, sha256, "standard", "1", 2000, [{"page_idx": 1, "page_size": [200, 200], "para_blocks": []}])parses = [{"sha256": sha256, "tier": "flash", "page_range": "1", "status": "done", "done_at": 1000},- {"sha256": sha256, "tier": "high", "page_range": "1", "status": "done", "done_at": 2000},+ {"sha256": sha256, "tier": "standard", "page_range": "1", "status": "done", "done_at": 2000},]db = _FakeDB(parses=parses, file_row={"sha256": sha256, "status": "active", "filename": "doc.pdf"})fts = _FakeFTS()service = ParseService(db=db, fts=fts, config_svc=None, data_dir=str(tmp_path), parse_lock_timeout_sec=1800)- count = asyncio.run(service.invalidate(sha256, "high"))+ count = asyncio.run(service.invalidate(sha256, "standard"))assert count == 1assert fts.deleted == []@@ -1233,7 +1233,7 @@ def test_request_parse_explicit_image_ingests_and_queues_parse(tmp_path: Path, m@pytest.mark.parametrize("ext", ["html", "docx", "pptx", "xlsx"])[email protected]("tier", ["high", "xhigh"])[email protected]("tier", ["standard", "advanced"])def test_request_parse_rejects_quality_tiers_for_non_pdf_image_inputs(tmp_path: Path,monkeypatch: pytest.MonkeyPatch,@@ -1283,7 +1283,7 @@ def test_request_parse_rejects_quality_tiers_for_non_pdf_image_inputs(@pytest.mark.parametrize(("ext", "expected_tier", "expected_privacy"),[- ("pdf", "high", "remote"),+ ("pdf", "standard", "remote"),("html", "flash", "local"),],)@@ -1296,7 +1296,7 @@ def test_refresh_file_applies_parsing_rule_effective_tier_and_privacy() -> None:class _RuleConfig:async def match_rules(self, path: str, rule_type: str) -> list[dict[str, Any]]:- return [{"tier": "high", "page_range": "1", "remote": True}]+ return [{"tier": "standard", "page_range": "1", "remote": True}]async def _run() -> None:db = DatabaseManager(str(tmp_path / "doclib.db"))@@ -1383,7 +1383,7 @@ def test_request_parse_rejects_remote_for_non_pdf_image_inputs([(None, False, False),("flash", True, False),- ("high", False, False),+ ("standard", False, False),(None, False, True),],)@@ -1599,7 +1599,7 @@ def test_force_request_reuses_active_and_creates_only_uncovered_parse(tmp_path:{"id": 10,"sha256": sha256,- "tier": "high",+ "tier": "standard","page_range": "1~5","status": "done","priority": 0,@@ -1609,7 +1609,7 @@ def test_force_request_reuses_active_and_creates_only_uncovered_parse(tmp_path:{"id": 11,"sha256": sha256,- "tier": "high",+ "tier": "standard","page_range": "6~8","status": "pending","priority": 0,@@ -1634,7 +1634,7 @@ def test_force_request_reuses_active_and_creates_only_uncovered_parse(tmp_path:)service = ParseService(db=db, fts=_FakeFTS(), config_svc=None, data_dir=str(tmp_path), parse_lock_timeout_sec=1800)- result = asyncio.run(service.request_parse(path, tier="high", page_range="1~10", force=True))+ result = asyncio.run(service.request_parse(path, tier="standard", page_range="1~10", force=True))assert isinstance(result, ParseResponse)assert result.wait_parse_ids == [11, 12]@@ -1650,11 +1650,11 @@ def test_force_request_reuses_active_and_creates_only_uncovered_parse(tmp_path:def test_list_parse_records_by_ids_returns_precise_status(tmp_path: Path) -> None:parses = [- {"id": 1, "sha256": "f" * 64, "tier": "high", "page_range": "1~5", "status": "done", "done_at": 1000},+ {"id": 1, "sha256": "f" * 64, "tier": "standard", "page_range": "1~5", "status": "done", "done_at": 1000},{"id": 2,"sha256": "f" * 64,- "tier": "high",+ "tier": "standard","page_range": "6~10","status": "failed","error_code": "parse_failed",@@ -1670,7 +1670,7 @@ def test_list_parse_records_by_ids_returns_precise_status(tmp_path: Path) -> Non{"id": 2,"sha256": "f" * 64,- "tier": "high",+ "tier": "standard","page_range": "6~10","status": "failed","done_at": None,@@ -1681,7 +1681,7 @@ def test_list_parse_records_by_ids_returns_precise_status(tmp_path: Path) -> Non{"id": 1,"sha256": "f" * 64,- "tier": "high",+ "tier": "standard","page_range": "1~5","status": "done","done_at": 1000,@@ -2110,9 +2110,9 @@ def test_search_filters_by_tier_min_tier_and_file_type(tmp_path: Path) -> None:now = 1000docs = [("1" * 64, "flash", "pdf", "flash.pdf", 2),- ("2" * 64, "high", "pdf", "high.pdf", 12),+ ("2" * 64, "standard", "pdf", "standard.pdf", 12),("3" * 64, "flash", "docx", "flash.docx", 23),- ("4" * 64, "xhigh", "pdf", "xhigh.pdf", 34),+ ("4" * 64, "advanced", "pdf", "advanced.pdf", 34),("5" * 64, None, "text", "note.txt", 1),]@@ -2130,23 +2130,23 @@ def test_search_filters_by_tier_min_tier_and_file_type(tmp_path: Path) -> None:await fts.replace(sha256=sha256, tier=tier, text="needle content", title="", author="")all_results, all_total = await service.search("needle")- exact_results, exact_total = await service.search("needle", tier="high")+ exact_results, exact_total = await service.search("needle", tier="standard")flash_results, flash_total = await service.search("needle", tier="flash")- min_results, min_total = await service.search("needle", min_tier="high")+ min_results, min_total = await service.search("needle", min_tier="standard")min_flash_results, min_flash_total = await service.search("needle", min_tier="flash")type_results, type_total = await service.search("needle", file_type="docx")text_results, text_total = await service.search("needle", file_type="text")assert all_total == 5- assert {row["tier"] for row in all_results} == {None, "flash", "high", "xhigh"}+ assert {row["tier"] for row in all_results} == {None, "flash", "standard", "advanced"}assert exact_total == 1- assert [row["tier"] for row in exact_results] == ["high"]+ assert [row["tier"] for row in exact_results] == ["standard"]assert [row["short_id"] for row in exact_results] == ["2" * 7]assert [row["page_count"] for row in exact_results] == [12]assert flash_total == 2assert {row["short_id"] for row in flash_results} == {"1" * 7, "3" * 7}assert min_total == 2- assert {row["tier"] for row in min_results} == {"high", "xhigh"}+ assert {row["tier"] for row in min_results} == {"standard", "advanced"}assert min_flash_total == 4assert None not in {row["tier"] for row in min_flash_results}assert type_total == 1@@ -2177,7 +2177,7 @@ def test_content_search_does_not_match_filename_but_find_does(tmp_path: Path) ->"VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)",(str(tmp_path / "filenameonly.pdf"), "filenameonly.pdf", "pdf", 10, now, sha256, "active", now, now),)- await fts.replace(sha256=sha256, tier="high", text="body content", title="", author="")+ await fts.replace(sha256=sha256, tier="standard", text="body content", title="", author="")await fts.upsert_filename(file_id, "filenameonly.pdf", "pdf")content_results, content_total = await service.search("filenameonly")@@ -2208,7 +2208,7 @@ def test_search_returns_all_files_in_reverse_insertion_order(tmp_path: Path) ->"VALUES (?, ?, ?, ?, ?, ?, ?)",(sha256, sha256[:7], 10, "pdf", 7 if sha256 == sha_active else 9, now, now),)- await fts.replace(sha256=sha256, tier="high", text="fallback needle", title="", author="")+ await fts.replace(sha256=sha256, tier="standard", text="fallback needle", title="", author="")await db.execute("INSERT INTO files (path, filename, ext, size_bytes, mtime_ms, sha256, status, first_seen_at, updated_at) "@@ -2949,7 +2949,7 @@ def test_doclib_server_list_responses_include_pagination_metadata(tmp_path: Path)await db.execute("INSERT INTO parses (sha256, tier, page_range, status, created_at, updated_at) VALUES (?, ?, ?, ?, ?, ?)",- (sha256, "high", "1", "pending", now, now),+ (sha256, "standard", "1", "pending", now, now),)await db.execute("INSERT INTO scans (path, kind, source, status, created_at, updated_at) VALUES (?, ?, ?, ?, ?, ?)",@@ -3021,12 +3021,12 @@ def test_doclib_server_accepts_short_id_for_sha256_doc_inputs(tmp_path: Path) ->await db.execute("INSERT INTO parses (sha256, tier, page_range, status, privacy, done_at, created_at, updated_at) ""VALUES (?, ?, ?, ?, ?, ?, ?, ?)",- (sha256, "high", "1", "done", "local", now, now, now),+ (sha256, "standard", "1", "done", "local", now, now, now),)_write_batch(tmp_path,sha256,- "high",+ "standard","1",now,ParseResult([_text_page("hello short id")]).to_dict(skip_defaults=True)["pages"],@@ -3037,13 +3037,13 @@ def test_doclib_server_accepts_short_id_for_sha256_doc_inputs(tmp_path: Path) ->parses_by_short_id = await server.list_parses(doc_ref=short_id)parses_by_sha256 = await server.list_parses(doc_ref=sha256)missing_parses = await server.list_parses(doc_ref="ccccccc")- content = await server.get_doc_content(short_id, tier="high", page_range="1")+ content = await server.get_doc_content(short_id, tier="standard", page_range="1")export_path = tmp_path / "out.md"exported = await server.export_doc_content(short_id,- DocContentExportRequest(tier="high", page_range="1", output=str(export_path)),+ DocContentExportRequest(tier="standard", page_range="1", output=str(export_path)),)- invalidated = await server.invalidate(InvalidateRequest(doc_ref=short_id, tier="high"))+ invalidated = await server.invalidate(InvalidateRequest(doc_ref=short_id, tier="standard"))assert doc_by_short_id.sha256 == sha256assert doc_by_short_id.short_id == short_id@@ -3144,7 +3144,7 @@ def test_doc_content_invalid_after_cursor_returns_invalid_locator(tmp_path: Path)try:with pytest.raises(InvalidRequestError) as exc_info:- await server.get_doc_content(short_id, tier="high", after="invalid-cursor-for-param-test")+ await server.get_doc_content(short_id, tier="standard", after="invalid-cursor-for-param-test")assert exc_info.value.code == "invalid_locator"assert exc_info.value.param == "after"@@ -3635,12 +3635,12 @@ def test_server_status_includes_watch_stats_and_error_summary(tmp_path: Path) ->)await db.execute("INSERT INTO parses (sha256, tier, page_range, status, privacy, created_at, updated_at) VALUES (?, ?, ?, ?, ?, ?, ?)",- (sha_done, "high", "1", "done", "local", now, now),+ (sha_done, "standard", "1", "done", "local", now, now),)await db.execute("INSERT INTO parses (sha256, tier, page_range, status, privacy, error_code, created_at, updated_at) ""VALUES (?, ?, ?, ?, ?, ?, ?, ?)",- (sha_pending, "high", "1", "failed", "local", "parse_failed", now, now),+ (sha_pending, "standard", "1", "failed", "local", "parse_failed", now, now),)for index in range(6):await db.execute(@@ -3728,9 +3728,9 @@ def test_forget_path_deletes_file_row_and_filename_fts_without_deleting_doc(tmp_)await db.execute("INSERT INTO parses (sha256, tier, page_range, status, privacy, created_at, updated_at) VALUES (?, ?, ?, ?, ?, ?, ?)",- (sha256, "high", "1", "done", "local", now, now),+ (sha256, "standard", "1", "done", "local", now, now),)- await db.execute("INSERT INTO fts_contents (sha256, tier, text) VALUES (?, ?, ?)", (sha256, "high", "content"))+ await db.execute("INSERT INTO fts_contents (sha256, tier, text) VALUES (?, ?, ?)", (sha256, "standard", "content"))await db.execute("INSERT INTO files (path, filename, ext, size_bytes, mtime_ms, sha256, status, first_seen_at, updated_at) ""VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)",@@ -3961,7 +3961,7 @@ def test_process_doc_preserves_remote_api_error_code(tmp_path: Path) -> None:task = {"id": 1,"sha256": sha256,- "tier": "high",+ "tier": "standard","page_range": "1","status": "parsing","privacy": "remote",@@ -4047,7 +4047,7 @@ def test_parse_via_api_maps_transport_errors_by_type(monkeypatch.setattr("mineru.parser.api_client.MinerUApiParser", _FakeApiParser)with pytest.raises(ParseFailure) as exc_info:- asyncio.run(service._parse_via_api({"path": "/tmp/doc.pdf"}, "high", "1", "remote"))+ asyncio.run(service._parse_via_api({"path": "/tmp/doc.pdf"}, "standard", "1", "remote"))assert exc_info.value.code == expected_codeassert "job polling" in exc_info.value.message@@ -4090,7 +4090,7 @@ def test_parse_via_api_requests_image_cache_only_for_office() -> None:assert api_url == "http://localhost:8000/api"assert api_key == "test-key"- assert tier == "high"+ assert tier == "standard"calls.append(include_images)async def parse_async(self, _path: str, *, page_range: str = "") -> ParseResult:@@ -4105,7 +4105,7 @@ def test_parse_via_api_requests_image_cache_only_for_office(result, via = asyncio.run(service._parse_via_api({"path": path},- "high",+ "standard","1","local",)@@ -4227,7 +4227,7 @@ def test_process_doc_writes_cached_image_sidecars(tmp_path: Path) -> None:def test_load_pages_from_done_batches_keeps_existing_image_sidecar(tmp_path: Path) -> None:sha256 = "e" * 64- tier = "high"+ tier = "standard"page = _image_page("figures/existing.jpg")_write_batch(tmp_path, sha256, tier, "1", 1000, ParseResult([page]).to_dict(skip_defaults=True)["pages"])sidecar = tmp_path / "parsed" / sha256[:2] / sha256 / tier / "images" / "figures" / "existing.jpg"@@ -4242,12 +4242,12 @@ def test_load_pages_from_done_batches_keeps_existing_image_sidecar(tmp_path: Patdef test_locator_after_uses_resolved_tier_when_locator_tier_is_absent() -> None:locator = _LocatorParts(short_id="eeeeeee", tier=None, page_no=1, block_no=2, char_offset=8)- assert _locator_after(locator, "xhigh") == "doc:eeeeeee/tier:xhigh/page:1/block:2/char:8"+ assert _locator_after(locator, "advanced") == "doc:eeeeeee/tier:advanced/page:1/block:2/char:8"def test_progressive_markdown_uses_readable_pdf_block_locator(tmp_path: Path) -> None:sha256 = "e" * 64- tier = "high"+ tier = "standard"page = _image_page("figures/rendered.jpg")_write_batch(tmp_path, sha256, tier, "1", 1000, ParseResult([page]).to_dict(skip_defaults=True)["pages"])db = _FakeDB(@@ -4279,7 +4279,7 @@ def test_progressive_markdown_uses_readable_pdf_block_locator(tmp_path: Path) ->response = asyncio.run(server._execute_read_plan(plan))- assert "" in response.content+ assert "" in response.contentassert "figures/rendered.jpg" not in response.content@@ -4293,7 +4293,7 @@ def test_doc_content_marker_uses_document_page_count_only(expected_marker: str,) -> None:sha256 = "e" * 64- tier = "high"+ tier = "standard"page = _text_page("selected page")page.page_idx = 4_write_batch(tmp_path, sha256, tier, "5", 1000, ParseResult([page]).to_dict(skip_defaults=True)["pages"])@@ -4336,12 +4336,12 @@ def test_doclib_image_renderer_uses_type_label_and_canonical_locator(data_dir=str(tmp_path),sha256="e" * 64,short_id="eeeeeee",- tier="high",+ tier="standard",page_no=2,)block = Block(index=3, type=block_type, bbox=(1, 2, 30, 40))- assert renderer(block) == f""+ assert renderer(block) == f""def test_doclib_image_renderer_rejects_non_finite_bbox(tmp_path: Path) -> None:@@ -4349,7 +4349,7 @@ def test_doclib_image_renderer_rejects_non_finite_bbox(tmp_path: Path) -> None:data_dir=str(tmp_path),sha256="e" * 64,short_id="eeeeeee",- tier="high",+ tier="standard",page_no=1,)block = Block(index=0, type=BlockType.IMAGE, bbox=(0, 0, float("nan"), 10))@@ -4372,7 +4372,7 @@ def test_find_block_by_no_ignores_conflicting_child_indexes() -> None:@pytest.mark.parametrize(("sidecar_exists", "expected_target"),- [(True, "doc:eeeeeee/tier:high/page:1/block:1"), (False, "")],+ [(True, "doc:eeeeeee/tier:standard/page:1/block:1"), (False, "")],)def test_progressive_markdown_uses_sidecar_availability_for_bboxless_blocks(tmp_path: Path,@@ -4380,7 +4380,7 @@ def test_progressive_markdown_uses_sidecar_availability_for_bboxless_blocks(expected_target: str,) -> None:sha256 = "e" * 64- tier = "high"+ tier = "standard"page = _image_page("figures/rendered.jpg")page._backend = "office"page.para_blocks[0].bbox = (0, 0, 0, 0)@@ -4416,7 +4416,7 @@ def test_progressive_markdown_uses_sidecar_availability_for_bboxless_blocks(def test_doclib_office_image_asset_reads_cached_sidecar(tmp_path: Path) -> None:sha256 = "f" * 64- tier = "high"+ tier = "standard"image_dir = Path(parse_image_sidecar_dir(str(tmp_path), sha256, tier))image_path = "figures/office.png"sidecar = image_dir / image_path@@ -4441,7 +4441,7 @@ def test_doclib_office_image_asset_reads_cached_sidecar(tmp_path: Path) -> None:tier=tier,page_range=None,after=None,- locator="doc:fffffff/tier:high/page:1/block:1",+ locator="doc:fffffff/tier:standard/page:1/block:1",context=0,limit=30000,format="image",@@ -4474,7 +4474,7 @@ def test_doclib_visual_block_asset_reads_cached_sidecar(content_type: str,) -> None:sha256 = "f" * 64- tier = "high"+ tier = "standard"image_path = f"figures/{block_type}.png"sidecar = Path(parse_image_sidecar_dir(str(tmp_path), sha256, tier)) / image_pathsidecar.parent.mkdir(parents=True)@@ -4496,7 +4496,7 @@ def test_doclib_visual_block_asset_reads_cached_sidecar(tier=tier,page_range=None,after=None,- locator="doc:fffffff/tier:high/page:1/block:1",+ locator="doc:fffffff/tier:standard/page:1/block:1",context=0,limit=30000,format="image",@@ -4515,7 +4515,7 @@ def test_doclib_visual_block_asset_reads_cached_sidecar(def test_doclib_pdf_block_locator_crops_source_pdf(tmp_path: Path) -> None:sha256 = "a" * 64- tier = "high"+ tier = "standard"source_path = tmp_path / "source.pdf"Image.new("RGB", (100, 100), color="white").save(source_path, "PDF")page = _image_page("internal/not-persisted.png")@@ -4531,7 +4531,7 @@ def test_doclib_pdf_block_locator_crops_source_pdf(tmp_path: Path) -> None:tier=tier,page_range=None,after=None,- locator="doc:aaaaaaa/tier:high/page:1/block:1",+ locator="doc:aaaaaaa/tier:standard/page:1/block:1",context=0,limit=30000,format="image",@@ -4552,7 +4552,7 @@ def test_doclib_pdf_block_locator_crops_source_pdf(tmp_path: Path) -> None:def test_doclib_image_block_locator_crops_source_image_at_original_resolution(tmp_path: Path) -> None:sha256 = "b" * 64- tier = "high"+ tier = "standard"source_path = tmp_path / "source.png"Image.new("RGB", (1000, 500), color="white").save(source_path)page = _image_page("internal/not-persisted.png")@@ -4570,7 +4570,7 @@ def test_doclib_image_block_locator_crops_source_image_at_original_resolution(tmtier=tier,page_range=None,after=None,- locator="doc:bbbbbbb/tier:high/page:1/block:1",+ locator="doc:bbbbbbb/tier:standard/page:1/block:1",context=0,limit=30000,format="image",@@ -4589,7 +4589,7 @@ def test_doclib_image_block_locator_crops_source_image_at_original_resolution(tmdef test_doclib_office_image_asset_transcodes_to_requested_format(tmp_path: Path) -> None:sha256 = "f" * 64- tier = "high"+ tier = "standard"image_dir = Path(parse_image_sidecar_dir(str(tmp_path), sha256, tier))image_path = "figures/office.png"sidecar = image_dir / image_path@@ -4614,7 +4614,7 @@ def test_doclib_office_image_asset_transcodes_to_requested_format(tmp_path: Pathtier=tier,page_range=None,after=None,- locator="doc:fffffff/tier:high/page:1/block:1",+ locator="doc:fffffff/tier:standard/page:1/block:1",context=0,limit=30000,format="image",@@ -4634,7 +4634,7 @@ def test_doclib_office_image_asset_transcodes_to_requested_format(tmp_path: Pathdef test_doclib_office_image_asset_missing_sidecar_reports_asset_not_available(tmp_path: Path) -> None:sha256 = "f" * 64- tier = "medium"+ tier = "basic"image_path = "figures/missing.png"image_span = Span(type=ContentType.IMAGE, bbox=(1, 1, 20, 20), image_path=image_path)body = Block(@@ -4652,7 +4652,7 @@ def test_doclib_office_image_asset_missing_sidecar_reports_asset_not_available(ttier=tier,page_range=None,after=None,- locator="doc:fffffff/tier:medium/page:1/block:1",+ locator="doc:fffffff/tier:basic/page:1/block:1",context=0,limit=30000,format="image",diff --git a/tests/unittest/test_doclib_interface_contract.py b/tests/unittest/test_doclib_interface_contract.pyindex ad4ccf85..b201ac35 100644--- a/tests/unittest/test_doclib_interface_contract.py+++ b/tests/unittest/test_doclib_interface_contract.py@@ -425,7 +425,7 @@ def test_core_doclib_schemas_are_instantiable() -> None:keywords="a,b",page_count=3,is_image_based=0,- meta_tier="high",+ meta_tier="standard",first_seen_at=40,updated_at=50,files=[file_info],@@ -435,7 +435,7 @@ def test_core_doclib_schemas_are_instantiable() -> None:id=1,sha256="abc",short_id="abc",- tier="high",+ tier="standard",page_range="1~2",status="pending",priority=10,@@ -447,7 +447,7 @@ def test_core_doclib_schemas_are_instantiable() -> None:error_code="parse_failed",error_msg="failed",)- tier_info = TierParseInfo(tier="high", page_range="1~2", status="pending")+ tier_info = TierParseInfo(tier="standard", page_range="1~2", status="pending")info = FileInfoResponse(file=file_info,doc=doc_info,@@ -456,7 +456,7 @@ def test_core_doclib_schemas_are_instantiable() -> None:)watch = WatchInfo(id=1, path="/tmp", recursive=True, status="active", last_scan_at=100, last_scan_files=3)exclude_rule = ExcludeRuleInfo(id=2, pattern="*.tmp", hit_count=4)- parsing_rule = ParsingRuleInfo(id=3, pattern="*.pdf", tier="high", page_range="1~5", remote=True)+ parsing_rule = ParsingRuleInfo(id=3, pattern="*.pdf", tier="standard", page_range="1~5", remote=True)watches = WatchListResponse(watches=[watch])exclude_rules = ExcludeRuleListResponse(rules=[exclude_rule])parsing_rules = ParsingRuleListResponse(rules=[parsing_rule])@@ -470,7 +470,7 @@ def test_core_doclib_schemas_are_instantiable() -> None:last_probe_at=1000,last_success_at=900,last_failure_at=800,- supported_tiers=["high"],+ supported_tiers=["standard"],),remote=RemoteParseServerStatus(healthy=False,@@ -484,7 +484,7 @@ def test_core_doclib_schemas_are_instantiable() -> None:search_result = SearchResult(sha256="abc",short_id="abc",- tier="high",+ tier="standard",snippet="matched text",files=[SearchFile(path="/tmp/a.pdf", filename="a.pdf", ext="pdf", status="active")],)@@ -494,11 +494,11 @@ def test_core_doclib_schemas_are_instantiable() -> None:config = ConfigResponse(config={"parse_server.local.mode": "managed"}, sources={"parse_server.local.mode": "override"})shutdown_response = ShutdownResponse(accepted=True, message="Server shutting down...")remove_watch_response = RemoveWatchResponse(watch_id=1, removed=True)- export_request = DocContentExportRequest(tier="high", output="/tmp/a.md")+ export_request = DocContentExportRequest(tier="standard", output="/tmp/a.md")remove_exclude_response = RemoveExcludeRuleResponse(rule_id=2, removed=True)remove_parsing_response = RemoveParsingRuleResponse(rule_id=3, removed=True)exclude_rule_request = ExcludeRuleRequest(pattern="*.tmp")- parsing_rule_request = ParsingRuleRequest(pattern="*.pdf", tier="high", page_range="1~5")+ parsing_rule_request = ParsingRuleRequest(pattern="*.pdf", tier="standard", page_range="1~5")error_info = ErrorInfo(type="invalid_request_error", code="file_not_found", message="missing", param="path")error_response = ErrorResponse(error=error_info)@@ -549,7 +549,7 @@ def test_core_doclib_schemas_are_instantiable() -> None:assert remove_exclude_response.rule_id == 2assert remove_parsing_response.rule_id == 3assert exclude_rule_request.pattern == "*.tmp"- assert parsing_rule_request.tier == "high"+ assert parsing_rule_request.tier == "standard"assert error_response.error.code == "file_not_found"diff --git a/tests/unittest/test_doclib_locators.py b/tests/unittest/test_doclib_locators.pyindex a1037097..91168f2b 100644--- a/tests/unittest/test_doclib_locators.py+++ b/tests/unittest/test_doclib_locators.py@@ -5,15 +5,15 @@ from mineru.doclib.locators import block_char_ref, block_ref, locator_for_block,def test_doclib_locator_helpers_use_public_one_based_numbers() -> None:assert locator_for_block(1, 3) == "page:1/block:3"- assert page_ref("ab12cd3", "high", 1) == "doc:ab12cd3/tier:high/page:1"- assert block_ref("ab12cd3", "high", 1, 3) == "doc:ab12cd3/tier:high/page:1/block:3"- assert block_char_ref("ab12cd3", "high", 1, 3, 0) == "doc:ab12cd3/tier:high/page:1/block:3/char:0"+ assert page_ref("ab12cd3", "standard", 1) == "doc:ab12cd3/tier:standard/page:1"+ assert block_ref("ab12cd3", "standard", 1, 3) == "doc:ab12cd3/tier:standard/page:1/block:3"+ assert block_char_ref("ab12cd3", "standard", 1, 3, 0) == "doc:ab12cd3/tier:standard/page:1/block:3/char:0"def test_parse_content_cursor_supports_page_block_and_char_refs() -> None:- page = parse_content_cursor("doc:ab12cd3/tier:high/page:5")- block = parse_content_cursor("doc:ab12cd3/tier:high/page:5/block:18")- char = parse_content_cursor("doc:ab12cd3/tier:high/page:5/block:18/char:32784")+ page = parse_content_cursor("doc:ab12cd3/tier:standard/page:5")+ block = parse_content_cursor("doc:ab12cd3/tier:standard/page:5/block:18")+ char = parse_content_cursor("doc:ab12cd3/tier:standard/page:5/block:18/char:32784")assert page.page_no == 5assert page.block_no is None@@ -26,6 +26,6 @@ def test_content_cursor_rejects_zero_based_public_numbers() -> None:with pytest.raises(ValueError):locator_for_block(0, 1)with pytest.raises(ValueError):- parse_content_cursor("doc:ab12cd3/tier:high/page:0")+ parse_content_cursor("doc:ab12cd3/tier:standard/page:0")with pytest.raises(ValueError):- parse_content_cursor("doc:ab12cd3/tier:high/page:1/block:0")+ parse_content_cursor("doc:ab12cd3/tier:standard/page:1/block:0")diff --git a/tests/unittest/test_doclib_progressive_reading.py b/tests/unittest/test_doclib_progressive_reading.pyindex 88bf8559..e0e96c61 100644--- a/tests/unittest/test_doclib_progressive_reading.py+++ b/tests/unittest/test_doclib_progressive_reading.py@@ -49,7 +49,7 @@ def test_content_page_range_rejects_empty_available_subset() -> None:def test_paginated_page_boundary_truncation_suggests_pages_only() -> None:pages = [_page(index, f"page {index + 1}") for index in range(10)]- rendered = _render_progressive_markdown(pages, short_id="ab12cd3", tier="high", after=None, limit=40, add_markers=False)+ rendered = _render_progressive_markdown(pages, short_id="ab12cd3", tier="standard", after=None, limit=40, add_markers=False)next_request = _next_content_request(rendered=rendered,request_page_range="1~10",@@ -67,7 +67,7 @@ def test_paginated_page_boundary_truncation_suggests_pages_only() -> None:def test_paginated_long_single_page_truncation_keeps_pages_with_after() -> None:pages = [_page(6, "word " * 100)]- rendered = _render_progressive_markdown(pages, short_id="ab12cd3", tier="high", after=None, limit=40, add_markers=False)+ rendered = _render_progressive_markdown(pages, short_id="ab12cd3", tier="standard", after=None, limit=40, add_markers=False)next_request = _next_content_request(rendered=rendered,request_page_range="7~10",@@ -77,7 +77,7 @@ def test_paginated_long_single_page_truncation_keeps_pages_with_after() -> None:)assert rendered.truncated is True- assert rendered.content_ranges[-1].end.startswith("doc:ab12cd3/tier:high/page:7/block:1/char:")+ assert rendered.content_ranges[-1].end.startswith("doc:ab12cd3/tier:standard/page:7/block:1/char:")assert next_request is not Noneassert next_request.page_range == "7~10"assert next_request.after == rendered.content_ranges[-1].end@@ -87,7 +87,7 @@ def test_non_paginated_truncation_can_use_after_only() -> None:rendered = _render_progressive_markdown([_page(0, "block 1", "block 2", "block 3")],short_id="ab12cd3",- tier="high",+ tier="standard",after=None,limit=15,add_markers=False,@@ -110,7 +110,7 @@ def test_non_contiguous_pages_suggest_after_last_requested_page() -> None:rendered = _render_progressive_markdown([_page(0, "page 1"), _page(4, "page 5"), _page(19, "page 20"), _page(24, "page 25")],short_id="ab12cd3",- tier="high",+ tier="standard",after=None,limit=30000,add_markers=False,@@ -131,7 +131,7 @@ def test_truncated_false_can_still_have_next_request() -> None:rendered = _render_progressive_markdown([_page(index, f"page {index + 1}") for index in range(10)],short_id="ab12cd3",- tier="high",+ tier="standard",after=None,limit=30000,add_markers=False,@@ -158,8 +158,8 @@ def test_paginated_next_request_is_never_after_only() -> None:"content_ranges": [ContentRange(page_range="7",- start="doc:ab12cd3/tier:high/page:7/block:1/char:0",- end="doc:ab12cd3/tier:high/page:7/block:1/char:40",+ start="doc:ab12cd3/tier:standard/page:7/block:1/char:0",+ end="doc:ab12cd3/tier:standard/page:7/block:1/char:40",)],"truncated": True,diff --git a/tests/unittest/test_doclib_telemetry_core.py b/tests/unittest/test_doclib_telemetry_core.pyindex 0dcab7c5..fc8e30f2 100644--- a/tests/unittest/test_doclib_telemetry_core.py+++ b/tests/unittest/test_doclib_telemetry_core.py@@ -244,7 +244,7 @@ def test_parse_route_records_request_finished_and_duration_metrics(tmp_path) ->async def request_parse(self, *args, **kwargs) -> dict:return {"sha256": "abc",- "tier": "high",+ "tier": "standard","page_range": "1","status": "pending","cache_hit": False,@@ -261,7 +261,7 @@ def test_parse_route_records_request_finished_and_duration_metrics(tmp_path) ->await telemetry.initialize()server = DoclibServer(SimpleNamespace(parse_svc=_ParseService(), telemetry_svc=telemetry))- await server.ensure_parse(ParseRequest(path="/tmp/a.pdf", tier="high"))+ await server.ensure_parse(ParseRequest(path="/tmp/a.pdf", tier="standard"))body = await telemetry.preview_body()metric_names = {metric["name"] for metric in body["metrics"]}@@ -273,7 +273,7 @@ def test_parse_route_records_request_finished_and_duration_metrics(tmp_path) ->"caller": "unknown","source": "unknown","status": "queued",- "tier": "high",+ "tier": "standard",}asyncio.run(_run())@@ -499,7 +499,7 @@ def test_parse_wait_observation_uses_parse_rows_for_tier_and_pages_bucket(tmp_pa)await db.execute("INSERT INTO parses (sha256, tier, page_range, status, created_at, updated_at) VALUES (?, ?, ?, ?, ?, ?)",- ("sha", "high", "1~3", "done", now, now),+ ("sha", "standard", "1~3", "done", now, now),)row = await db.fetchone("SELECT id FROM parses WHERE sha256=?", ("sha",))@@ -523,7 +523,7 @@ def test_parse_wait_observation_uses_parse_rows_for_tier_and_pages_bucket(tmp_pa"pages_bucket": "2_5","source": "unknown","status": "succeeded",- "tier": "high",+ "tier": "standard",}assert by_name["parse.wait_duration_bucket.count"]["dimensions"]["bucket"] == "1_5s"diff --git a/tests/unittest/test_kit_commands.py b/tests/unittest/test_kit_commands.pyindex f6898e5a..73ece903 100644--- a/tests/unittest/test_kit_commands.py+++ b/tests/unittest/test_kit_commands.py@@ -228,7 +228,7 @@ def test_upload_filename_helper_import_boundary_is_explicit() -> None:assert "normalize_upload_filename" in fast_api_upload_imports-def test_models_download_tier_medium(monkeypatch: Any) -> None:+def test_models_download_tier_basic(monkeypatch: Any) -> None:captured: list[str] = []def fake_download_model_repo(repo: Any, *, source: str | None = None, local_as_auto: bool = False) -> Path:@@ -237,11 +237,11 @@ def test_models_download_tier_medium(monkeypatch: Any) -> None:monkeypatch.setattr(models, "download_model_repo", fake_download_model_repo)- result = runner.invoke(app, ["models", "download", "--tier", "medium"])+ result = runner.invoke(app, ["models", "download", "--tier", "basic"])assert result.exit_code == 0assert captured == ["PDF-Extract-Kit-1.0"]- assert "Downloaded models for tier medium" in result.output+ assert "Downloaded models for tier basic" in result.outputdef test_models_download_repo_uses_explicit_source(monkeypatch: Any) -> None:@@ -371,14 +371,14 @@ def test_api_server_forwards_repeated_tiers(monkeypatch: Any) -> None:monkeypatch.setattr(api_server.parser_api_server.main, "main", _fake_main)- result = runner.invoke(app, ["api-server", "--tier", "medium", "--tier", "xhigh"])+ result = runner.invoke(app, ["api-server", "--tier", "basic", "--tier", "advanced"])assert result.exit_code == 0assert seen["prog_name"] == "mineru-kit api-server"assert seen["standalone_mode"] is Falseassert [seen["args"][index + 1] for index, item in enumerate(seen["args"]) if item == "--tier"] == [- "medium",- "xhigh",+ "basic",+ "advanced",]@@ -386,7 +386,7 @@ def test_api_server_without_tier_lets_parser_api_apply_all_tier_default(monkeypaseen: dict[str, Any] = {}def _fake_main(*, args: list[str], prog_name: str, standalone_mode: bool) -> None:- """记录 mineru-kit api-server 默认参数,确认不再强制单 high tier。"""+ """记录 mineru-kit api-server 默认参数,确认不再强制单 standard tier。"""seen["args"] = argsseen["prog_name"] = prog_nameseen["standalone_mode"] = standalone_mode@@ -790,10 +790,10 @@ def test_parse_rejects_single_office_input_with_quality_tier(monkeypatch: Any, tmonkeypatch.setattr(parse, "local_parse", _fake_local_parse)- result = runner.invoke(app, ["parse", str(source), "-o", str(output), "--tier", "high"])+ result = runner.invoke(app, ["parse", str(source), "-o", str(output), "--tier", "standard"])assert result.exit_code == 1- assert "Tier 'high' is only supported for PDF and image files" in " ".join(result.output.split())+ assert "Tier 'standard' is only supported for PDF and image files" in " ".join(result.output.split())def test_parse_batch_normalizes_office_quality_tier_to_flash(monkeypatch: Any, tmp_path: Path) -> None:@@ -824,11 +824,11 @@ def test_parse_batch_normalizes_office_quality_tier_to_flash(monkeypatch: Any, tmonkeypatch.setattr(parse, "local_parse", _fake_local_parse)- result = runner.invoke(app, ["parse", str(pdf), str(html), "-o", str(output), "--tier", "high"])+ result = runner.invoke(app, ["parse", str(pdf), str(html), "-o", str(output), "--tier", "standard"])assert result.exit_code == 0assert [(call["path"].name, call["tier"], call["backend"]) for call in calls] == [- ("demo.pdf", "high", "hybrid-engine"),+ ("demo.pdf", "standard", "hybrid-engine"),("page.html", "flash", "flash"),]@@ -879,7 +879,7 @@ def test_parse_remote_requests_image_cache(monkeypatch: Any, tmp_path: Path) ->"--api-key","test-key","--tier",- "high",+ "standard","--pages","1",],@@ -890,7 +890,7 @@ def test_parse_remote_requests_image_cache(monkeypatch: Any, tmp_path: Path) ->assert seen == {"api_url": "http://localhost:8000/api","api_key": "test-key",- "tier": "high",+ "tier": "standard","include_images": True,"path": source,"page_range": "1",@@ -947,18 +947,18 @@ def test_parse_rejects_removed_ch_lite_language(tmp_path: Path) -> None:def test_gradio_tier_selection_derives_v1_runtime() -> None:from mineru.cli_old import gradio_app- assert gradio_app.resolve_gradio_runtime_options("medium").as_kwargs() == {- "tier": "medium",+ assert gradio_app.resolve_gradio_runtime_options("basic").as_kwargs() == {+ "tier": "basic","backend": "hybrid-engine","effort": "medium",}- assert gradio_app.resolve_gradio_runtime_options("high").as_kwargs() == {- "tier": "high",+ assert gradio_app.resolve_gradio_runtime_options("standard").as_kwargs() == {+ "tier": "standard","backend": "hybrid-engine","effort": "high",}- assert gradio_app.resolve_gradio_runtime_options("xhigh").as_kwargs() == {- "tier": "xhigh",+ assert gradio_app.resolve_gradio_runtime_options("advanced").as_kwargs() == {+ "tier": "advanced","backend": "hybrid-engine","effort": "xhigh",}@@ -970,16 +970,16 @@ def test_gradio_extracts_supported_tiers_from_v1_tiers_payload() -> None:payload = {"data": [{"id": "flash"},- {"id": "xhigh"},+ {"id": "advanced"},{"id": "experimental"},- {"id": "medium"},- {"id": "high"},- {"id": "xhigh"},+ {"id": "basic"},+ {"id": "standard"},+ {"id": "advanced"},]}- assert gradio_app.extract_v1_tier_choices(payload) == ("flash", "xhigh", "medium", "high")- assert gradio_app.default_v1_gradio_tier(("flash", "xhigh", "medium", "high")) == "high"+ assert gradio_app.extract_v1_tier_choices(payload) == ("flash", "advanced", "basic", "standard")+ assert gradio_app.default_v1_gradio_tier(("flash", "advanced", "basic", "standard")) == "standard"def test_gradio_rejects_v1_tiers_payload_without_supported_tiers() -> None:@@ -1357,7 +1357,7 @@ def test_cli_old_legacy_vlm_branch_maps_to_hybrid_xhigh(monkeypatch: Any, tmp_pamonkeypatch.setattr(common, "get_vlm_engine", lambda inference_engine="auto", is_async=False: "vllm-engine")def _fake_process_hybrid(*args: Any, **kwargs: Any) -> None:- """记录 legacy VLM 输入最终进入 Hybrid xhigh 分支。"""+ """记录 legacy VLM 输入最终进入 Hybrid advanced 分支。"""seen["backend"] = args[3]seen["hybrid_backend"] = args[5]seen["kwargs"] = kwargs@@ -1435,11 +1435,11 @@ def test_cli_old_hybrid_medium_skips_vlm_engine_resolution(monkeypatch: Any, tmpmonkeypatch.setattr(common, "ensure_backend_dependencies", lambda backend: None)def fail_get_vlm_engine(*_args: Any, **_kwargs: Any) -> str:- """Hybrid medium 不应触发 VLM engine 解析。"""+ """Hybrid basic 不应触发 VLM engine 解析。"""raise AssertionError("medium effort should not resolve VLM engine")def _fake_process_hybrid(*args: Any, **kwargs: Any) -> None:- """记录 Hybrid medium 仍进入 Hybrid 处理分支。"""+ """记录 Hybrid basic 仍进入 Hybrid 处理分支。"""seen["backend"] = args[5]seen["langs"] = list(args[3])seen["pdf_count"] = len(args[2])@@ -1472,7 +1472,7 @@ def test_process_hybrid_medium_calls_analyzer_per_file(monkeypatch: Any, tmp_patoutputs: list[tuple[str, str, str]] = []def fake_doc_analyze(pdf_bytes: bytes, **kwargs: Any) -> tuple[list[PageInfo], list[object], bool]:- """记录每个文件独立进入 Hybrid medium analyzer。"""+ """记录每个文件独立进入 Hybrid basic analyzer。"""calls.append(pdf_bytes)languages.append(kwargs["language"])analyzer_kwargs.append(kwargs)@@ -1534,7 +1534,7 @@ def test_cli_old_async_legacy_vlm_branch_maps_to_hybrid_xhigh(monkeypatch: Any,monkeypatch.setattr(common, "get_vlm_engine", lambda inference_engine="auto", is_async=True: "vllm-async-engine")async def _fake_async_process_hybrid(*args: Any, **kwargs: Any) -> None:- """记录异步 legacy VLM 输入最终进入 Hybrid xhigh 分支。"""+ """记录异步 legacy VLM 输入最终进入 Hybrid advanced 分支。"""seen["backend"] = args[3]seen["hybrid_backend"] = args[5]seen["kwargs"] = kwargsdiff --git a/tests/unittest/test_parser_api_contract.py b/tests/unittest/test_parser_api_contract.pyindex 263f5c15..bceb6212 100644--- a/tests/unittest/test_parser_api_contract.py+++ b/tests/unittest/test_parser_api_contract.py@@ -60,7 +60,7 @@ def _stub_api_server_dependency_preflight(monkeypatch: pytest.MonkeyPatch) -> Nodef test_hybrid_analyze_import_does_not_require_vlm_utils() -> None:- """校验 Hybrid medium 所需模块导入阶段不再强依赖 VLM 工具包。"""+ """校验 Hybrid basic 所需模块导入阶段不再强依赖 VLM 工具包。"""repo_root = Path(__file__).resolve().parents[2]code = """import importlib.abc@@ -69,7 +69,7 @@ import sysclass BlockVlmUtilsFinder(importlib.abc.MetaPathFinder):def find_spec(self, fullname, path=None, target=None):- # 阻断 mineru_vl_utils 导入,用来验证 Hybrid medium 的 lazy import 边界。+ # 阻断 mineru_vl_utils 导入,用来验证 Hybrid basic 的 lazy import 边界。if fullname == "mineru_vl_utils" or fullname.startswith("mineru_vl_utils."):raise ModuleNotFoundError(f"blocked VLM utility import: {fullname}")return None@@ -133,13 +133,17 @@ def test_validate_effort_rejects_low_and_maps_legacy_backends() -> None:HYBRID_EFFORT_CHOICES,effort_for_tier,resolve_backend_and_effort,+ tier_for_effort,validate_effort,)assert HYBRID_EFFORT_CHOICES == ("medium", "high", "xhigh")- assert effort_for_tier("medium") == "medium"- assert effort_for_tier("high") == "high"- assert effort_for_tier("xhigh") == "xhigh"+ assert effort_for_tier("basic") == "medium"+ assert effort_for_tier("standard") == "high"+ assert effort_for_tier("advanced") == "xhigh"+ assert tier_for_effort("medium") == "basic"+ assert tier_for_effort("high") == "standard"+ assert tier_for_effort("xhigh") == "advanced"with pytest.raises(ValueError, match="Unsupported effort 'low'"):validate_effort("low")with pytest.raises(ValueError, match="Unsupported tier 'ultra'"):@@ -157,28 +161,28 @@ def test_tier_runtime_options_map_hybrid_effort() -> None:"backend": "flash","effort": "medium",}- assert runtime_options_for_tier("medium").as_kwargs() == {- "tier": "medium",+ assert runtime_options_for_tier("basic").as_kwargs() == {+ "tier": "basic","backend": "hybrid-engine","effort": "medium",}- assert runtime_options_for_tier("high").as_kwargs() == {- "tier": "high",+ assert runtime_options_for_tier("standard").as_kwargs() == {+ "tier": "standard","backend": "hybrid-engine","effort": "high",}- assert runtime_options_for_tier("xhigh").as_kwargs() == {- "tier": "xhigh",+ assert runtime_options_for_tier("advanced").as_kwargs() == {+ "tier": "advanced","backend": "hybrid-engine","effort": "xhigh",}-def test_public_tier_literals_include_xhigh() -> None:+def test_public_tier_literals_match_product_contract() -> None:from mineru.parser.tier import runtime_options_for_tier- assert "xhigh" in TIERS- assert validate_tier("xhigh") == "xhigh"+ assert TIERS == {"flash", "basic", "standard", "advanced"}+ assert validate_tier("advanced") == "advanced"with pytest.raises(ValueError, match="Unsupported tier 'ultra'"):runtime_options_for_tier("ultra")@@ -187,7 +191,7 @@ def test_api_client_builds_file_page_range_without_options(tmp_path: Path) -> Nopdf = tmp_path / "demo.pdf"pdf.write_bytes(b"%PDF-1.7\n")- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high")+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard")payload = parser._build_payload({"type": "local", "path": str(pdf)}, "1,3~5")assert payload["output_formats"] == ["middle_json"]@@ -201,7 +205,7 @@ def test_api_client_uses_file_id_when_local_server_does_not_advertise_local_sour) -> None:pdf = tmp_path / "demo.pdf"pdf.write_bytes(b"%PDF-1.7\n")- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high")+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard")monkeypatch.setattr(parser, "_upload", lambda _path: "file_1")class _Response:@@ -236,7 +240,7 @@ def test_api_client_uses_file_id_when_local_server_does_not_advertise_local_sourdef test_api_client_uses_local_source_when_health_advertises_it(tmp_path: Path, monkeypatch: pytest.MonkeyPatch) -> None:pdf = tmp_path / "demo.pdf"pdf.write_bytes(b"%PDF-1.7\n")- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high")+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard")monkeypatch.setattr(parser, "_upload", lambda _path: pytest.fail("local source should not upload"))class _Response:@@ -272,7 +276,7 @@ def test_async_api_client_uses_file_id_when_local_server_does_not_advertise_loca) -> None:pdf = tmp_path / "demo.pdf"pdf.write_bytes(b"%PDF-1.7\n")- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high")+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard")async def _async_upload(_path: Path) -> str:return "file_1"@@ -312,7 +316,7 @@ def test_api_client_can_request_zip_for_model_output(tmp_path: Path) -> None:pdf = tmp_path / "demo.pdf"pdf.write_bytes(b"%PDF-1.7\n")- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high", include_model_output=True)+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard", include_model_output=True)payload = parser._build_payload({"type": "local", "path": str(pdf)}, "")assert payload["output_formats"] == ["zip"]@@ -324,7 +328,7 @@ def test_api_client_can_request_zip_for_image_cache(tmp_path: Path) -> None:parser = MinerUApiParser(api_url="http://localhost:8000",- tier="high",+ tier="standard",include_images=True,)payload = parser._build_payload({"type": "local", "path": str(pdf)}, "")@@ -335,7 +339,7 @@ def test_api_client_can_request_zip_for_image_cache(tmp_path: Path) -> None:def test_api_client_uses_zip_for_official_api_when_model_output_requested() -> None:parser = MinerUApiParser(api_url="https://mineru.net/api",- tier="xhigh",+ tier="advanced",include_model_output=True,)@@ -345,7 +349,7 @@ def test_api_client_uses_zip_for_official_api_when_model_output_requested() -> Ndef test_api_client_uses_zip_for_official_api_when_image_cache_requested() -> None:parser = MinerUApiParser(api_url="https://mineru.net/api",- tier="xhigh",+ tier="advanced",include_images=True,)@@ -356,10 +360,10 @@ def test_api_client_uses_tier_without_backend_semantics(tmp_path: Path) -> None:pdf = tmp_path / "demo.pdf"pdf.write_bytes(b"%PDF-1.7\n")- parser = MinerUApiParser(api_url="http://localhost:8000", tier="xhigh")+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="advanced")payload = parser._build_payload({"type": "local", "path": str(pdf)}, "")- assert payload["tier"] == "xhigh"+ assert payload["tier"] == "advanced"assert not hasattr(parser, "backend")@@ -370,7 +374,7 @@ def test_api_client_rejects_invalid_tier_names(tier: str) -> None:def test_api_client_uses_middle_json_format_for_official_api() -> None:- parser = MinerUApiParser(api_url="https://mineru.net/api", tier="xhigh")+ parser = MinerUApiParser(api_url="https://mineru.net/api", tier="advanced")assert parser._output_formats() == ["middle_json"]@@ -378,7 +382,7 @@ def test_api_client_uses_middle_json_format_for_official_api() -> None:def test_api_client_uses_env_api_key_when_no_api_key_argument(monkeypatch: pytest.MonkeyPatch) -> None:monkeypatch.setenv("MINERU_API_KEY", "env-key")- parser = MinerUApiParser(api_url="https://mineru.net/api", tier="high")+ parser = MinerUApiParser(api_url="https://mineru.net/api", tier="standard")assert parser._headers()["Authorization"] == "Bearer env-key"@@ -460,7 +464,7 @@ def test_api_client_ignores_legacy_detail_error_envelope() -> None:def test_api_client_reads_image_cache_from_zip_and_preserves_pdf_mapping(monkeypatch: pytest.MonkeyPatch) -> None:- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high", include_images=True)+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard", include_images=True)middle_json = {"schema_version": "1.0.0","_pdf_retained_page_indices": [0, 2],@@ -515,7 +519,7 @@ def test_api_client_reads_image_cache_from_zip_and_preserves_pdf_mapping(monkeypdef test_api_client_downloads_model_output_from_zip(monkeypatch: pytest.MonkeyPatch) -> None:- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high", include_model_output=True)+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard", include_model_output=True)middle_json = {"schema_version": "1.0.0","pages": [{"page_idx": 0, "page_size": [100, 200]}],@@ -551,7 +555,7 @@ def test_api_client_downloads_model_output_from_zip(monkeypatch: pytest.MonkeyPadef test_api_client_reads_official_layout_json_and_model_output_from_zip(monkeypatch: pytest.MonkeyPatch) -> None:parser = MinerUApiParser(api_url="https://mineru.net/api",- tier="high",+ tier="standard",include_images=True,include_model_output=True,)@@ -603,7 +607,7 @@ def test_api_client_reads_official_layout_json_and_model_output_from_zip(monkeypdef test_api_client_async_downloads_model_output_from_zip(monkeypatch: pytest.MonkeyPatch) -> None:- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high", include_model_output=True)+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard", include_model_output=True)middle_json = {"schema_version": "1.0.0","pages": [{"page_idx": 0, "page_size": [100, 200]}],@@ -640,7 +644,7 @@ def test_api_client_async_downloads_model_output_from_zip(monkeypatch: pytest.Modef test_api_client_include_images_downloads_single_zip(monkeypatch: pytest.MonkeyPatch) -> None:parser = MinerUApiParser(api_url="http://localhost:8000",- tier="high",+ tier="standard",include_images=True,include_model_output=True,)@@ -689,7 +693,7 @@ def test_api_client_include_images_downloads_single_zip(monkeypatch: pytest.Monkdef test_api_client_does_not_read_image_cache_from_zip_unless_requested(monkeypatch: pytest.MonkeyPatch) -> None:- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high", include_model_output=True)+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard", include_model_output=True)zip_ref = {"file_id": "file-zip", "bytes": 10}middle_json = {"schema_version": "1.0.0",@@ -738,7 +742,7 @@ def test_api_client_does_not_read_image_cache_from_zip_unless_requested(monkeypadef test_api_client_async_include_images_downloads_single_zip(monkeypatch: pytest.MonkeyPatch) -> None:parser = MinerUApiParser(api_url="http://localhost:8000",- tier="high",+ tier="standard",include_images=True,include_model_output=True,)@@ -780,7 +784,7 @@ def test_api_client_async_include_images_downloads_single_zip(monkeypatch: pytesdef test_api_client_include_images_rejects_unsafe_image_entries(monkeypatch: pytest.MonkeyPatch) -> None:- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high", include_images=True)+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard", include_images=True)zip_ref = {"file_id": "file-zip", "bytes": 10}middle_json = {"schema_version": "1.0.0",@@ -822,7 +826,7 @@ def test_api_client_include_images_rejects_unsafe_image_entries(monkeypatch: pytdef test_api_client_accepts_remote_pdf_info_middle_json(monkeypatch: pytest.MonkeyPatch) -> None:- parser = MinerUApiParser(api_url="https://mineru.net/api", tier="high")+ parser = MinerUApiParser(api_url="https://mineru.net/api", tier="standard")middle_json = {"_backend": "hybrid","_version_name": "remote",@@ -848,7 +852,7 @@ def test_api_client_accepts_remote_pdf_info_middle_json(monkeypatch: pytest.Monkdef test_async_api_client_accepts_remote_pdf_info_middle_json(monkeypatch: pytest.MonkeyPatch) -> None:- parser = MinerUApiParser(api_url="https://mineru.net/api", tier="high")+ parser = MinerUApiParser(api_url="https://mineru.net/api", tier="standard")middle_json = {"_backend": "hybrid","pdf_info": [{"page_idx": 0, "page_size": [100, 200]}],@@ -878,7 +882,7 @@ def test_async_api_client_accepts_remote_pdf_info_middle_json(monkeypatch: pytesdef test_api_client_rejects_legacy_json_output_file_key() -> None:- parser = MinerUApiParser(api_url="https://mineru.net/api", tier="high")+ parser = MinerUApiParser(api_url="https://mineru.net/api", tier="standard")with pytest.raises(api_client._V1APIError) as exc_info:_parse_result_from_job(@@ -896,7 +900,7 @@ def test_api_client_rejects_legacy_json_output_file_key() -> None:def test_api_client_rejects_output_reference_without_file_id() -> None:- parser = MinerUApiParser(api_url="https://mineru.net/api", tier="high")+ parser = MinerUApiParser(api_url="https://mineru.net/api", tier="standard")with pytest.raises(api_client._V1APIError) as exc_info:api_client._download_bytes(parser, {"url": "https://example.invalid/output.json", "bytes": 10})@@ -906,7 +910,7 @@ def test_api_client_rejects_output_reference_without_file_id() -> None:def test_async_api_client_rejects_output_reference_without_file_id() -> None:- parser = MinerUApiParser(api_url="https://mineru.net/api", tier="high")+ parser = MinerUApiParser(api_url="https://mineru.net/api", tier="standard")async def _run() -> None:await api_client._async_download_bytes(parser, {"url": "https://example.invalid/output.json", "bytes": 10})@@ -923,7 +927,7 @@ def test_api_client_include_images_rejects_unsafe_zip_image_sidecar_paths(monkeypatch: pytest.MonkeyPatch,image_path: str,) -> None:- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high", include_images=True)+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard", include_images=True)zip_ref = {"file_id": "file-zip", "bytes": 10}middle_json = {"schema_version": "1.0.0",@@ -965,7 +969,7 @@ def test_api_client_include_images_rejects_unsafe_zip_image_sidecar_paths(def test_async_api_client_include_images_rejects_unsafe_zip_image_sidecar_paths(monkeypatch: pytest.MonkeyPatch) -> None:- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high", include_images=True)+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard", include_images=True)zip_ref = {"file_id": "file-zip", "bytes": 10}middle_json = {"schema_version": "1.0.0",@@ -1051,7 +1055,7 @@ def test_api_client_passes_trust_env_from_api_url(monkeypatch: pytest.MonkeyPatcdef test_api_client_poll_uses_fixed_one_second_interval(monkeypatch: pytest.MonkeyPatch) -> None:"""验证同步 v1 job 轮询使用固定 1 秒间隔,避免指数退避放大本地等待。"""- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high")+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard")statuses = iter(["pending", "processing", "completed"])sleep_delays: list[int] = []@@ -1080,7 +1084,7 @@ def test_api_client_poll_uses_fixed_one_second_interval(monkeypatch: pytest.Monkdef test_async_api_client_poll_uses_fixed_one_second_interval(monkeypatch: pytest.MonkeyPatch) -> None:"""验证异步 v1 job 轮询也使用固定 1 秒间隔,保持 Gradio 路径一致。"""- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high")+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard")statuses = iter(["pending", "processing", "completed"])sleep_delays: list[int] = []@@ -1113,7 +1117,7 @@ def test_api_client_poll_timeout_budget_is_one_hour() -> None:def test_api_client_retries_transient_poll_transport_errors(monkeypatch: pytest.MonkeyPatch) -> None:- parser = MinerUApiParser(api_url="https://mineru.net/api", tier="high")+ parser = MinerUApiParser(api_url="https://mineru.net/api", tier="standard")calls = 0sleep_delays: list[float] = []@@ -1136,7 +1140,7 @@ def test_api_client_retries_transient_poll_transport_errors(monkeypatch: pytest.def test_async_api_client_retries_transient_poll_transport_errors(monkeypatch: pytest.MonkeyPatch) -> None:- parser = MinerUApiParser(api_url="https://mineru.net/api", tier="high")+ parser = MinerUApiParser(api_url="https://mineru.net/api", tier="standard")calls = 0sleep_delays: list[float] = []@@ -1190,7 +1194,7 @@ def test_api_client_retries_upload_content_put(monkeypatch: pytest.MonkeyPatch)def test_api_client_recovers_completed_upload_after_lost_complete_response() -> None:- parser = MinerUApiParser(api_url="https://mineru.net/api", tier="high")+ parser = MinerUApiParser(api_url="https://mineru.net/api", tier="standard")complete_calls = 0status_calls = 0@@ -1218,7 +1222,7 @@ def test_api_client_recovers_completed_upload_after_lost_complete_response() ->def test_async_api_client_recovers_completed_upload_after_lost_complete_response() -> None:- parser = MinerUApiParser(api_url="https://mineru.net/api", tier="high")+ parser = MinerUApiParser(api_url="https://mineru.net/api", tier="standard")complete_calls = 0status_calls = 0@@ -1320,14 +1324,14 @@ def test_api_client_omits_page_range_when_unspecified(tmp_path: Path) -> None:pdf = tmp_path / "demo.pdf"pdf.write_bytes(b"%PDF-1.7\n")- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high")+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard")payload = parser._build_payload({"type": "local", "path": str(pdf)}, "")assert payload["files"] == [{"source": {"type": "local", "path": str(pdf)}}]def test_api_client_surfaces_failed_job_error() -> None:- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high")+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard")with pytest.raises(Exception, match="upstream failed"):_parse_result_from_job(@@ -1342,7 +1346,7 @@ def test_api_client_surfaces_failed_job_error() -> None:def test_api_client_surfaces_failed_file_error_when_job_has_no_top_level_error() -> None:- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high")+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard")with pytest.raises(api_client._V1APIError) as exc_info:_parse_result_from_job(@@ -1370,7 +1374,7 @@ def test_api_client_surfaces_failed_file_error_when_job_has_no_top_level_error()def test_api_client_rejects_missing_middle_json_output() -> None:- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high")+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard")with pytest.raises(Exception, match="did not return middle_json output"):_parse_result_from_job(@@ -1385,7 +1389,7 @@ def test_api_client_rejects_missing_middle_json_output() -> None:def test_api_client_rejects_json_underscore_output_alias() -> None:- parser = MinerUApiParser(api_url="http://localhost:8000", tier="high")+ parser = MinerUApiParser(api_url="http://localhost:8000", tier="standard")with pytest.raises(api_client._V1APIError) as exc_info:api_client._download_json(parser, {"json_": {"file_id": "file-json", "bytes": 10}})@@ -1645,7 +1649,7 @@ def test_api_server_unhandled_exceptions_use_error_envelope(tmp_path: Path, monkdef test_create_app_does_not_read_runtime_settings_from_env(tmp_path: Path, monkeypatch: pytest.MonkeyPatch) -> None:_stub_api_server_dependency_preflight(monkeypatch)- monkeypatch.setenv("MINERU_TIER", "xhigh")+ monkeypatch.setenv("MINERU_TIER", "advanced")monkeypatch.setenv("MINERU_BACKEND", "hybrid-auto-engine")monkeypatch.setenv("MINERU_CONCURRENCY", "9")monkeypatch.setenv("MINERU_URL_TIMEOUT", "99")@@ -1658,7 +1662,7 @@ def test_create_app_does_not_read_runtime_settings_from_env(tmp_path: Path, monkapp = create_app(upload_dir=str(tmp_path))- assert app.state.tier == "high"+ assert app.state.tier == "standard"assert app.state.backend == "hybrid-engine"assert app.state.concurrency == 1assert app.state.url_timeout == 60@@ -1776,7 +1780,7 @@ def test_api_server_rendered_outputs_do_not_return_image_sidecars(request = CreateJobRequest.model_validate({"files": [{"source": {"type": "local", "path": str(source)}}],- "tier": "high",+ "tier": "standard","output_formats": [output_format],})@@ -1819,7 +1823,7 @@ def test_api_server_run_job_normalizes_lightweight_file_tier_to_flash(request = CreateJobRequest.model_validate({"files": [{"source": {"type": "local", "path": str(source)}}],- "tier": "high",+ "tier": "standard","output_formats": ["middle_json"],})@@ -1840,11 +1844,11 @@ def test_api_server_run_job_normalizes_lightweight_file_tier_to_flash()assert [(call["tier"], call["backend"], call["effort"]) for call in calls] == [("flash", "flash", "medium")]- assert rec.tier == "high"+ assert rec.tier == "standard"assert rec.files[0].status == "completed"[email protected](("request_tier", "response_tier"), [("high", "high"), (None, "flash")])[email protected](("request_tier", "response_tier"), [("standard", "standard"), (None, "flash")])def test_api_server_accepts_lightweight_job_without_requested_quality_runtime(monkeypatch: pytest.MonkeyPatch,tmp_path: Path,@@ -1903,7 +1907,7 @@ def test_api_server_middle_json_preserves_backend_for_client_rendering(request = CreateJobRequest.model_validate({"files": [{"source": {"type": "local", "path": str(source)}}],- "tier": "high",+ "tier": "standard","output_formats": ["middle_json"],})@@ -1954,7 +1958,7 @@ def test_api_server_zip_includes_model_output_when_parse_result_has_it(request = CreateJobRequest.model_validate({"files": [{"source": {"type": "local", "path": str(source)}}],- "tier": "high",+ "tier": "standard","output_formats": ["zip"],})@@ -2018,7 +2022,7 @@ def test_api_server_zip_is_self_contained_when_only_zip_requested(request = CreateJobRequest.model_validate({"files": [{"source": {"type": "local", "path": str(source)}}],- "tier": "high",+ "tier": "standard","output_formats": ["zip"],})@@ -2075,7 +2079,7 @@ def test_api_server_zip_rejects_unsafe_image_sidecar_path(request = CreateJobRequest.model_validate({"files": [{"source": {"type": "local", "path": str(source)}}],- "tier": "high",+ "tier": "standard","output_formats": ["zip"],})@@ -2119,7 +2123,7 @@ def test_api_server_zip_skips_model_output_when_parse_result_has_none(request = CreateJobRequest.model_validate({"files": [{"source": {"type": "local", "path": str(source)}}],- "tier": "high",+ "tier": "standard","output_formats": ["zip"],})@@ -2182,7 +2186,7 @@ def test_api_server_sanitizes_surrogates_in_text_outputs(request = CreateJobRequest.model_validate({"files": [{"source": {"type": "local", "path": str(source)}}],- "tier": "high",+ "tier": "standard","output_formats": ["markdown", "middle_json", "content_list", "structured_content"],})@@ -2235,7 +2239,7 @@ def test_api_server_logs_traceback_when_job_file_fails(request = CreateJobRequest.model_validate({"files": [{"source": {"type": "local", "path": str(source)}}],- "tier": "high",+ "tier": "standard","output_formats": ["middle_json"],})@@ -2312,81 +2316,81 @@ def test_api_contract_uses_parser_version_not_backend_version() -> None:def test_api_server_tier_selects_compatible_backend(tmp_path: Path, monkeypatch: pytest.MonkeyPatch) -> None:_stub_api_server_dependency_preflight(monkeypatch)flash_app = create_app(upload_dir=str(tmp_path / "flash"), tier="flash")- medium_app = create_app(upload_dir=str(tmp_path / "medium"), tier="medium")- high_app = create_app(upload_dir=str(tmp_path / "high"), tier="high")- xhigh_app = create_app(upload_dir=str(tmp_path / "xhigh"), tier="xhigh")+ basic_app = create_app(upload_dir=str(tmp_path / "basic"), tier="basic")+ standard_app = create_app(upload_dir=str(tmp_path / "standard"), tier="standard")+ advanced_app = create_app(upload_dir=str(tmp_path / "advanced"), tier="advanced")assert flash_app.state.tier == "flash"assert flash_app.state.backend == "flash"assert [tier["id"] for tier in flash_app.state.tiers] == ["flash"]- assert medium_app.state.tier == "medium"- assert medium_app.state.backend == "hybrid-engine"- assert medium_app.state.effort == "medium"- assert [tier["id"] for tier in medium_app.state.tiers] == ["medium"]- assert high_app.state.tier == "high"- assert high_app.state.backend == "hybrid-engine"- assert high_app.state.effort == "high"- assert [tier["id"] for tier in high_app.state.tiers] == ["high"]- assert xhigh_app.state.tier == "xhigh"- assert xhigh_app.state.backend == "hybrid-engine"- assert xhigh_app.state.effort == "xhigh"- assert [tier["id"] for tier in xhigh_app.state.tiers] == ["xhigh"]+ assert basic_app.state.tier == "basic"+ assert basic_app.state.backend == "hybrid-engine"+ assert basic_app.state.effort == "medium"+ assert [tier["id"] for tier in basic_app.state.tiers] == ["basic"]+ assert standard_app.state.tier == "standard"+ assert standard_app.state.backend == "hybrid-engine"+ assert standard_app.state.effort == "high"+ assert [tier["id"] for tier in standard_app.state.tiers] == ["standard"]+ assert advanced_app.state.tier == "advanced"+ assert advanced_app.state.backend == "hybrid-engine"+ assert advanced_app.state.effort == "xhigh"+ assert [tier["id"] for tier in advanced_app.state.tiers] == ["advanced"]def test_api_server_defaults_to_all_quality_tiers(tmp_path: Path, monkeypatch: pytest.MonkeyPatch) -> None:_stub_api_server_dependency_preflight(monkeypatch)app = create_app(upload_dir=str(tmp_path))- assert app.state.tier == "high"- assert app.state.default_tier == "high"+ assert app.state.tier == "standard"+ assert app.state.default_tier == "standard"assert app.state.backend == "hybrid-engine"assert app.state.effort == "high"- assert [tier["id"] for tier in app.state.tiers] == ["flash", "medium", "high", "xhigh"]+ assert [tier["id"] for tier in app.state.tiers] == ["flash", "basic", "standard", "advanced"]assert app.state.tier_runtime_options["flash"].as_kwargs() == {"tier": "flash","backend": "flash","effort": "medium",}- assert app.state.tier_runtime_options["medium"].as_kwargs() == {- "tier": "medium",+ assert app.state.tier_runtime_options["basic"].as_kwargs() == {+ "tier": "basic","backend": "hybrid-engine","effort": "medium",}- assert app.state.tier_runtime_options["high"].as_kwargs() == {- "tier": "high",+ assert app.state.tier_runtime_options["standard"].as_kwargs() == {+ "tier": "standard","backend": "hybrid-engine","effort": "high",}- assert app.state.tier_runtime_options["xhigh"].as_kwargs() == {- "tier": "xhigh",+ assert app.state.tier_runtime_options["advanced"].as_kwargs() == {+ "tier": "advanced","backend": "hybrid-engine","effort": "xhigh",}def test_api_server_multi_tier_state_and_metadata(tmp_path: Path, monkeypatch: pytest.MonkeyPatch) -> None:- """校验同一个 API server 可发布多个 tier,并在包含 high 时以 high 作为默认 tier。"""+ """校验同一个 API server 可发布多个 tier,并在包含 standard 时以 standard 作为默认 tier。"""_stub_api_server_dependency_preflight(monkeypatch)- app = create_app(upload_dir=str(tmp_path), tier=["medium", "high", "xhigh"])+ app = create_app(upload_dir=str(tmp_path), tier=["basic", "standard", "advanced"])- assert app.state.tier == "high"- assert app.state.default_tier == "high"+ assert app.state.tier == "standard"+ assert app.state.default_tier == "standard"assert app.state.backend == "hybrid-engine"assert app.state.effort == "high"- assert [tier["id"] for tier in app.state.tiers] == ["medium", "high", "xhigh"]- assert app.state.model_ids == ["Hybrid-Medium", "MinerU-HTML", "MinerU2.5-Pro-2605-1.2B"]- assert app.state.tier_runtime_options["medium"].as_kwargs() == {- "tier": "medium",+ assert [tier["id"] for tier in app.state.tiers] == ["basic", "standard", "advanced"]+ assert app.state.model_ids == ["Hybrid-Basic", "MinerU-HTML", "MinerU2.5-Pro-2605-1.2B"]+ assert app.state.tier_runtime_options["basic"].as_kwargs() == {+ "tier": "basic","backend": "hybrid-engine","effort": "medium",}- assert app.state.tier_runtime_options["high"].as_kwargs() == {- "tier": "high",+ assert app.state.tier_runtime_options["standard"].as_kwargs() == {+ "tier": "standard","backend": "hybrid-engine","effort": "high",}- assert app.state.tier_runtime_options["xhigh"].as_kwargs() == {- "tier": "xhigh",+ assert app.state.tier_runtime_options["advanced"].as_kwargs() == {+ "tier": "advanced","backend": "hybrid-engine","effort": "xhigh",}@@ -2395,18 +2399,18 @@ def test_api_server_multi_tier_state_and_metadata(tmp_path: Path, monkeypatch: pdef test_api_server_multi_tier_http_metadata(tmp_path: Path, monkeypatch: pytest.MonkeyPatch) -> None:"""校验 /v1/tiers 与 /v1/models 返回启动时声明的全部 tier 能力。"""_stub_api_server_dependency_preflight(monkeypatch)- app = create_app(upload_dir=str(tmp_path), tier=["flash", "medium", "high", "xhigh"])+ app = create_app(upload_dir=str(tmp_path), tier=["flash", "basic", "standard", "advanced"])with TestClient(app) as client:tiers_response = client.get("/v1/tiers")models_response = client.get("/v1/models")assert tiers_response.status_code == 200- assert [tier["id"] for tier in tiers_response.json()["data"]] == ["flash", "medium", "high", "xhigh"]+ assert [tier["id"] for tier in tiers_response.json()["data"]] == ["flash", "basic", "standard", "advanced"]assert models_response.status_code == 200assert [model["id"] for model in models_response.json()["data"]] == ["MinerU-Flash",- "Hybrid-Medium",+ "Hybrid-Basic","MinerU-HTML","MinerU2.5-Pro-2605-1.2B",]@@ -2425,7 +2429,7 @@ def test_api_server_multi_tier_jobs_use_requested_tier_runtime(tmp_path: Path, mmonkeypatch.setattr("mineru.parser.api_server.parse_async", fake_parse_async)source = tmp_path / "demo.pdf"source.write_bytes(b"%PDF-1.7\n")- app = create_app(upload_dir=str(tmp_path / "api"), tier=["medium", "high"], allow_local_source=True)+ app = create_app(upload_dir=str(tmp_path / "api"), tier=["basic", "standard"], allow_local_source=True)file_store = FileStore(tmp_path / "api-files")job_store = api_server.JobStore()@@ -2457,21 +2461,21 @@ def test_api_server_multi_tier_jobs_use_requested_tier_runtime(tmp_path: Path, m}))- medium_response = asyncio.run(+ basic_response = asyncio.run(run_request({"files": [{"source": {"type": "local", "path": str(source)}}],- "tier": "medium",+ "tier": "basic","output_formats": ["middle_json"],}))- assert default_response["tier"] == "high"- assert medium_response["tier"] == "medium"+ assert default_response["tier"] == "standard"+ assert basic_response["tier"] == "basic"assert [(call["tier"], call["backend"], call["effort"]) for call in calls] == [- ("high", "hybrid-engine", "high"),- ("medium", "hybrid-engine", "medium"),+ ("standard", "hybrid-engine", "high"),+ ("basic", "hybrid-engine", "medium"),]@@ -2480,22 +2484,22 @@ def test_api_server_single_tier_rejects_unavailable_tier(tmp_path: Path, monkeyp_stub_api_server_dependency_preflight(monkeypatch)source = tmp_path / "demo.pdf"source.write_bytes(b"%PDF-1.7\n")- app = create_app(upload_dir=str(tmp_path / "api"), tier="high")+ app = create_app(upload_dir=str(tmp_path / "api"), tier="standard")with TestClient(app) as client:response = client.post("/v1/parse/jobs",json={"files": [{"source": {"type": "local", "path": str(source)}}],- "tier": "xhigh",+ "tier": "advanced",},)assert response.status_code == 400- assert "Tier 'xhigh' not available in this server" in response.text+ assert "Tier 'advanced' not available in this server" in response.text-def test_api_server_preflights_medium_tier_dependencies(monkeypatch: pytest.MonkeyPatch, tmp_path: Path) -> None:+def test_api_server_preflights_basic_tier_dependencies(monkeypatch: pytest.MonkeyPatch, tmp_path: Path) -> None:imported_modules: list[str] = []def fake_import_module(module_name: str):@@ -2504,7 +2508,7 @@ def test_api_server_preflights_medium_tier_dependencies(monkeypatch: pytest.Monkmonkeypatch.setattr(importlib, "import_module", fake_import_module)- create_app(upload_dir=str(tmp_path), tier="medium")+ create_app(upload_dir=str(tmp_path), tier="basic")assert imported_modules == ["ftfy",@@ -2517,7 +2521,7 @@ def test_api_server_preflights_medium_tier_dependencies(monkeypatch: pytest.Monk]-def test_api_server_preflights_xhigh_tier_dependencies_for_platform(+def test_api_server_preflights_advanced_tier_dependencies_for_platform(monkeypatch: pytest.MonkeyPatch, tmp_path: Path) -> None:imported_modules: list[str] = []@@ -2530,7 +2534,7 @@ def test_api_server_preflights_xhigh_tier_dependencies_for_platform(monkeypatch.setattr(parser_tier.sys, "platform", "darwin")monkeypatch.setattr(parser_tier.platform, "machine", lambda: "arm64")- create_app(upload_dir=str(tmp_path), tier="xhigh")+ create_app(upload_dir=str(tmp_path), tier="advanced")assert imported_modules == ["ftfy",@@ -2546,7 +2550,7 @@ def test_api_server_preflights_xhigh_tier_dependencies_for_platform(]-def test_api_server_preflights_xhigh_tier_dependencies_skip_mlx_on_intel_macos(+def test_api_server_preflights_advanced_tier_dependencies_skip_mlx_on_intel_macos(monkeypatch: pytest.MonkeyPatch, tmp_path: Path) -> None:imported_modules: list[str] = []@@ -2559,7 +2563,7 @@ def test_api_server_preflights_xhigh_tier_dependencies_skip_mlx_on_intel_macos(monkeypatch.setattr(parser_tier.sys, "platform", "darwin")monkeypatch.setattr(parser_tier.platform, "machine", lambda: "x86_64")- create_app(upload_dir=str(tmp_path), tier="xhigh")+ create_app(upload_dir=str(tmp_path), tier="advanced")assert imported_modules == ["ftfy",@@ -2582,8 +2586,8 @@ def test_api_server_preflight_rejects_missing_tier_dependency(monkeypatch: pytesmonkeypatch.setattr(importlib, "import_module", fake_import_module)monkeypatch.setattr(parser_tier.importlib_metadata, "packages_distributions", lambda: {"mineru": ["mineru"]})- with pytest.raises(api_server.ParseServerStartupError, match="tier 'medium'.*torch.*mineru\\[medium\\]"):- create_app(upload_dir=str(tmp_path), tier="medium")+ with pytest.raises(api_server.ParseServerStartupError, match="tier 'basic'.*torch.*mineru\\[basic\\]"):+ create_app(upload_dir=str(tmp_path), tier="basic")def test_api_server_create_app_rejects_backend_and_effort_parameters(tmp_path: Path) -> None:@@ -2637,12 +2641,12 @@ def test_pdf_pipeline_parser_compat_delegates_to_hybrid_medium() -> None:def test_pdf_hybrid_medium_parser_skips_vlm_backend_resolution(monkeypatch: pytest.MonkeyPatch) -> None:- """校验 Hybrid medium 直接进入本地分支,不解析 VLM engine。"""+ """校验 Hybrid basic 直接进入本地分支,不解析 VLM engine。"""seen: dict[str, object] = {}fake_module = types.ModuleType("mineru.backend.hybrid.hybrid_analyze")def fake_doc_analyze(_pdf_bytes: bytes, **kwargs: object) -> tuple[list[PageInfo], list[object], bool]:- """记录 medium 分支收到的参数,并返回 Hybrid middle-json 形态。"""+ """记录 basic 分支收到的参数,并返回 Hybrid middle-json 形态。"""seen.update(kwargs)return [PageInfo(page_idx=0, _backend="hybrid")], [], False@@ -2650,7 +2654,7 @@ def test_pdf_hybrid_medium_parser_skips_vlm_backend_resolution(monkeypatch: pytemonkeypatch.setitem(sys.modules, "mineru.backend.hybrid.hybrid_analyze", fake_module)def fail_resolve_backend(*_args: object, **_kwargs: object) -> str:- """medium 不应触发 VLM backend resolver。"""+ """basic 不应触发 VLM backend resolver。"""raise AssertionError("medium effort should not resolve VLM backend")monkeypatch.setattr(parser_pdf, "_resolve_hybrid_backend", fail_resolve_backend)@@ -2815,7 +2819,7 @@ def test_api_server_stores_parser_runtime_options(tmp_path: Path, monkeypatch: p_stub_api_server_dependency_preflight(monkeypatch)app = create_app(upload_dir=str(tmp_path),- tier="medium",+ tier="basic",language="en",ocr_mode="ocr",image_analysis=False,@@ -2893,9 +2897,9 @@ def test_api_server_cli_defaults_to_all_quality_tiers(monkeypatch: pytest.Monkeyassert result.exit_code == 0assert seen == {- "tiers": ["flash", "medium", "high", "xhigh"],- "default_tier": "high",- "effort_by_tier": {"flash": "medium", "medium": "medium", "high": "high", "xhigh": "xhigh"},+ "tiers": ["flash", "basic", "standard", "advanced"],+ "default_tier": "standard",+ "effort_by_tier": {"flash": "medium", "basic": "medium", "standard": "high", "advanced": "xhigh"},}@@ -2912,13 +2916,13 @@ def test_api_server_cli_accepts_repeated_tier_list(monkeypatch: pytest.MonkeyPatmonkeypatch.setattr("uvicorn.Server.run", _fake_run)- result = runner.invoke(main, ["--tier", "medium", "--tier", "xhigh", "--host", "0.0.0.0", "--port", "15984"])+ result = runner.invoke(main, ["--tier", "basic", "--tier", "advanced", "--host", "0.0.0.0", "--port", "15984"])assert result.exit_code == 0assert seen == {- "tiers": ["medium", "xhigh"],- "default_tier": "xhigh",- "effort_by_tier": {"medium": "medium", "xhigh": "xhigh"},+ "tiers": ["basic", "advanced"],+ "default_tier": "advanced",+ "effort_by_tier": {"basic": "medium", "advanced": "xhigh"},}@@ -2958,9 +2962,9 @@ def test_api_server_cli_help_exposes_tier_only_runtime_selection() -> None:assert result.exit_code == 0assert "--tier" in normalized_outputassert "flash" in normalized_output- assert "medium" in normalized_output- assert "high" in normalized_output- assert "xhigh" in normalized_output+ assert "basic" in normalized_output+ assert "standard" in normalized_output+ assert "advanced" in normalized_outputassert "--backend" not in normalized_outputassert "--effort" not in normalized_outputassert "hybrid-engine" not in normalized_outputdiff --git a/tests/unittest/test_parser_routing.py b/tests/unittest/test_parser_routing.pyindex 896a0ce6..c70e32e6 100644--- a/tests/unittest/test_parser_routing.py+++ b/tests/unittest/test_parser_routing.py@@ -22,7 +22,7 @@ def test_build_parser_prefers_html_extension_when_content_guess_is_plain_text(assert isinstance(parser, HtmlParser)[email protected]("tier", ["medium", "high", "xhigh"])[email protected]("tier", ["basic", "standard", "advanced"])def test_build_parser_rejects_quality_tier_for_html_input(tmp_path: Path,monkeypatch: pytest.MonkeyPatch,diff --git a/tests/unittest/test_render_image_renderer.py b/tests/unittest/test_render_image_renderer.pyindex 6cff316c..457f2de6 100644--- a/tests/unittest/test_render_image_renderer.py+++ b/tests/unittest/test_render_image_renderer.py@@ -45,11 +45,11 @@ def test_pipeline_markdown_uses_custom_block_image_renderer_and_keeps_caption()rendered = blocks_to_markdown([block],- image_renderer=lambda _block: "",+ image_renderer=lambda _block: "",)assert len(rendered) == 1- assert "" in rendered[0]+ assert "" in rendered[0]assert "Figure caption" in rendered[0]assert "internal/hash.jpg" not in rendered[0]