[pull] main from PDFMathTranslate:main#81
Merged
pull[bot] merged 50 commits intopsy-repos-python:mainfrom Mar 22, 2026
Merged
Conversation
Bumps [actions/checkout](https://github.com/actions/checkout) from 4 to 5. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](actions/checkout@v4...v5) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '5' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
Bumps [pypa/gh-action-pypi-publish](https://github.com/pypa/gh-action-pypi-publish) from 1.12.4 to 1.13.0. - [Release notes](https://github.com/pypa/gh-action-pypi-publish/releases) - [Commits](pypa/gh-action-pypi-publish@76f52bc...ed0c539) --- updated-dependencies: - dependency-name: pypa/gh-action-pypi-publish dependency-version: 1.13.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
Bumps [actions/cache](https://github.com/actions/cache) from 4.2.2 to 4.3.0. - [Release notes](https://github.com/actions/cache/releases) - [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md) - [Commits](actions/cache@v4.2.2...v4.3.0) --- updated-dependencies: - dependency-name: actions/cache dependency-version: 4.3.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
Bumps [astral-sh/setup-uv](https://github.com/astral-sh/setup-uv) from 5.3.1 to 7.1.2. - [Release notes](https://github.com/astral-sh/setup-uv/releases) - [Commits](astral-sh/setup-uv@f94ec6b...8585678) --- updated-dependencies: - dependency-name: astral-sh/setup-uv dependency-version: 7.1.2 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 4 to 6. - [Release notes](https://github.com/actions/download-artifact/releases) - [Commits](actions/download-artifact@v4...v6) --- updated-dependencies: - dependency-name: actions/download-artifact dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
- Add GROK_BASE_URL and GROK_STREAM configuration options - Add OPENAI_STREAM configuration option - Add OPENAILIKED_STREAM configuration option - Fix 'str' object has no attribute 'choices' error with non-streaming proxies - Support custom proxies like grok2api - Add documentation for proxy configuration
- Add warning about /v1 suffix requirement for OpenAI-compatible APIs - Update Grok configuration to include GROK_BASE_URL option - Fix typos: GORK_API_KEY -> GROK_API_KEY, GORK_MODEL -> GROK_MODEL - Add grok example to config.json samples
Add MiniMax (https://platform.minimaxi.com/) as a new translation service, using its OpenAI-compatible API. The default model is MiniMax-M2.5 with 204K context window. Changes: - Add MiniMaxTranslator class extending OpenAITranslator - Register in CLI (converter.py) and Web UI (gui.py) - Update documentation in ADVANCED.md and localized READMEs Usage: export MINIMAX_API_KEY="your-key" pdf2zh example.pdf -s minimax Co-Authored-By: octo-patch <octo-patch@users.noreply.github.com>
- Update default model from MiniMax-M2.5 to MiniMax-M2.7 - MiniMax-M2.7 is the latest flagship model with enhanced reasoning and coding - Update all documentation (EN, JA, KO, ZH-TW) to reflect new default
- Update default model from MiniMax-M2.5 to MiniMax-M2.7 - MiniMax-M2.7 is the latest flagship model with enhanced reasoning and coding - Update all documentation (EN, JA, KO, ZH-TW) to reflect new default
Added stop tokens and max tokens configuration options
feat: add MiniMax as a translation service provider (with M2.7 default)
## Summary Refactors the GitHub Actions CI/CD workflows to reduce duplication and improve maintainability, and fixes existing flake8 lint issues so pre-commit passes cleanly. ## Workflow changes - **python-test.yml**: Extracted shared test workflow as a reusable workflow (`workflow_call`), removing duplicated test logic from `python-publish.yml` and `fork-test.yml` - **python-publish.yml**: Replaced inline test job with `uses: ./.github/workflows/python-test.yml`, reducing ~75 lines of duplication - **fork-test.yml**: Simplified to call the shared test workflow - **black.format.yml**: Simplified to call the shared test workflow instead of duplicating steps ## Flake8 fixes - `test/test_cache.py`: Removed 4 unused imports (`threading`, `multiprocessing`, `random`, `string`) - `test/test_translator.py`: Removed trailing whitespace on blank line - `pdf2zh/high_level.py`: Changed `except Exception as e` to `except Exception` (unused variable) - `pdf2zh/doclayout.py`: Removed 3 unused imports (`os.path`, `hf_hub_download`, `ConfigManager`)
- Skip double serialization by loading InferenceSession directly from file path instead of onnx.load → SerializeToString round-trip - Use load_external_data=False for lightweight metadata extraction - Enable ORT_ENABLE_ALL graph optimizations with on-disk caching so subsequent loads use the pre-optimized model - Specify execution providers explicitly to avoid auto-detection overhead - Defer model loading in GUI to first use via lazy proxy, so the UI starts instantly Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
feat: add configurable stream and base_url for Grok/OpenAI translators
…lator Resolve conflict and apply fix from PR #1065 — prompt is now passed through super().__init__() instead of being set separately, consistent with how other translators handle it. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…ons/actions/checkout-5 chore(deps): bump actions/checkout from 4 to 5
…ons/pypa/gh-action-pypi-publish-1.13.0 chore(deps): bump pypa/gh-action-pypi-publish from 1.12.4 to 1.13.0
…ons/actions/cache-4.3.0 chore(deps): bump actions/cache from 4.2.2 to 4.3.0
…ons/astral-sh/setup-uv-7.1.2 chore(deps): bump astral-sh/setup-uv from 5.3.1 to 7.1.2
…ons/actions/download-artifact-6 chore(deps): bump actions/download-artifact from 4 to 6
Fix handling of prompts in HTTP API
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )