BerriAI/litellm · error · BadRequestError
Model name '{requested_model}' matches deployments from mult
Error message
Model name '{requested_model}' matches deployments from multiple teams. Specify the deployment ID directly to disambiguate. What it means
Raised when a requested model name matches deployments belonging to multiple different teams, making team-scoped routing ambiguous; the caller must pass the specific deployment ID instead of the model name.
Source
Thrown at litellm/router_utils/common_utils.py:137
(deployment.get("model_name"), deployment.get("model_info") or {}) for deployment in healthy_deployments
)
team_ids: Final = frozenset(
team_id
for _, model_info in candidate_deployments
for team_id in [model_info.get("team_id")]
if team_id is not None
)
matches_requested_model: Final = (
isinstance(requested_model, str)
and bool(candidate_deployments)
and all(
model_info.get("team_id") is not None
and (model_name == requested_model or model_info.get("team_public_model_name") == requested_model)
for model_name, model_info in candidate_deployments
)
)
if matches_requested_model and len(team_ids) > 1:
raise BadRequestError(
message=(
f"Model name '{requested_model}' matches deployments from multiple teams. "
"Specify the deployment ID directly to disambiguate."
),
model=requested_model,
llm_provider="",
)
if matches_requested_model:
return healthy_deployments
ids_to_remove: Final = set()
if isinstance(healthy_deployments, dict):
return healthy_deployments
for deployment in healthy_deployments:
_model_info = deployment.get("model_info") or {}
model_team_id = _model_info.get("team_id")
if model_team_id is None:
continueView on GitHub (pinned to 77b7c6c40c)
Solutions
- Specify the deployment ID directly instead of the ambiguous model name.
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at litellm/router_utils/common_utils.py:137 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of BerriAI/litellm@77b7c6c40c (2026-08-18).
Data as JSON: /api/errors/38fe59ff154b68b5.
Report an issue: GitHub.