forked from phoenix/litellm-mirror
fix(anthropic.py): handle multiple system prompts
This commit is contained in:
parent
de1f348453
commit
691a83b7dc
3 changed files with 45 additions and 14 deletions
|
@ -7223,7 +7223,17 @@ def exception_type(
|
|||
message=f"AnthropicException - {original_exception.message}",
|
||||
llm_provider="anthropic",
|
||||
model=model,
|
||||
response=original_exception.response,
|
||||
response=(
|
||||
original_exception.response
|
||||
if hasattr(original_exception, "response")
|
||||
else httpx.Response(
|
||||
status_code=500,
|
||||
request=httpx.Request(
|
||||
method="POST",
|
||||
url="https://docs.anthropic.com/claude/reference/messages_post",
|
||||
),
|
||||
)
|
||||
),
|
||||
)
|
||||
else:
|
||||
exception_mapping_worked = True
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue