Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions agent/auxiliary_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -1703,6 +1703,25 @@ def _finalize(resolved_provider: str, sync_client: Any, default_model: Optional[
)
return _finalize(
main_provider, rpc_client, rpc_model or vision_model)
# Exotic provider (DeepSeek, Alibaba, named custom, etc.)
# Skip providers that don't use OpenAI-compatible endpoints
# (e.g. Bedrock uses Converse API via boto3, not OpenAI SDK).
if main_provider in ("bedrock",):
logger.debug(
"Vision auto-detect: skipping non-OpenAI provider %s, "
"falling back to aggregators",
main_provider,
)
else:
rpc_client, rpc_model = resolve_provider_client(
main_provider, main_model)
if rpc_client is not None:
logger.info(
"Vision auto-detect: using active provider %s (%s)",
main_provider, rpc_model or main_model,
)
return _finalize(
main_provider, rpc_client, rpc_model or main_model)

# Fall back through aggregators.
for candidate in _VISION_AUTO_PROVIDER_ORDER:
Expand Down
Loading