WIP refactor(model): unify config-driven retry across VLM and embedding#926
Open
WIP refactor(model): unify config-driven retry across VLM and embedding#926
Conversation
Move retry behavior into shared model-call utilities and config defaults so VLM and embedding providers handle transient failures consistently. Co-Authored-By: Claude Opus 4.6
|
Failed to generate code suggestions for PR |
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.
Description
Unify retry handling for model calls by moving transient-error retry into shared utilities and config-driven defaults for both VLM and embedding providers.
Related Issue
Fixes #922
Type of Change
Changes Made
vlm.max_retriesdefault to3, add top-levelembedding.max_retries, and wire embedding factories/providers to honor config-driven retryTesting
Checklist
Screenshots (if applicable)
N/A
Additional Notes
Targeted verification completed with:
python -m pytest --override-ini addopts='' tests/models/test_vlm_strip_think_tags.py tests/unit/test_vlm_response_formats.py tests/unit/test_extra_headers_vlm.py tests/unit/test_stream_config_vlm.py tests/unit/test_extra_headers_embedding.py tests/unit/test_jina_embedder.py tests/unit/test_voyage_embedder.py tests/unit/test_minimax_embedder_simple.py tests/unit/test_model_retry.py -qpython -m compileall openviking openviking_cli tests/unitI did not run the server test setup because local imports there require
argon2, which is not installed in this environment. There is also an existing unrelated failure intests/unit/test_openai_embedder.pythat was not introduced by this change.