Repository navigation
fix(vlm): defer optional local provider imports - #4967
Merged
dolfim-ibm merged 1 commit intoOct 26, 2026
Merged
dolfim-ibm merged 1 commit into
dolfim-ibm merged 1 commit into
Conversation
Keep remote API pipeline setup independent of the HF and MLX provider modules. Cover current and legacy API options and preserve remote-service policy checks. Signed-off-by: YamonBot <141118378+YamonBot@users.noreply.github.com>
Contributor
|
✅ DCO Check Passed Thanks @YamonBot, all your commits are properly signed off. 🎉 |
Contributor
Merge Protections🟢 Merge protection satisfied — ready to merge. Show 1 satisfied protection🟢 Enforce conventional commitMake sure that we follow https://www.conventionalcommits.org/en/v1.0.0/
|
Contributor
AI triage (advisory)Checked commit Warning The AI analysis did not finish. Only the deterministic checks are shown. Topic labels added: CI safety: not assessed. Possibly related pull requests
The |
Merged
3 tasks done
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Remote API VLM pipelines cannot import or initialize in a slim environment without optional local ML dependencies.
VlmPipelineimports the legacy HF and MLX providers before selecting an inference backend, so remote-only setup fails withModuleNotFoundError.Move each import into its existing local-provider branch. This uses the same provider-selection pattern as the VLM engine factory. Local provider arguments, remote-service permission checks, packaging, and conversion output remain unchanged.
Resolves #4966.
Checklist:
Review evidence:
10054ec7bbdc9435ef7ca2ec6be90c782082ae52.docling-slim 2.141.0editable,docling-core 2.103.1, Pillow 12.3.0. Torch, Transformers, and MLX packages are physically absent from the isolated environment. No replacement modules or model weights used.PYTHONDONTWRITEBYTECODE=1 /tmp/docling-remote-provider-py312-dab32661/bin/python -m pytest -p no:tach -p no:cacheprovider tests/test_vlm_pipeline_optional_dependencies.py tests/test_api_vlm_engine.py tests/test_api_image_request.py tests/test_vlm_pipeline_status.py tests/test_vlm_pipeline_streaming.py tests/test_vlm_pipeline_force_backend_text.py tests/test_vlm_enrichment.py tests/test_vlm_convert_prediction_mapping.py tests/test_vlm_utils.py tests/test_vlm_prediction_token_coercion.py -q: 80 passed, 1 skipped after final review.UV_NO_SYNC=1 UV_PROJECT_ENVIRONMENT=/tmp/docling-remote-provider-py312-dab32661 make validate: passed with repository-pinned tools. The flag preserves the deliberately minimal environment.Assisted by Codex. Patch and executable evidence reviewed before submission. DCO sign-off included.