Skip to content

Commit

Permalink
Update pydantic_ai_slim/pydantic_ai/models/cohere.py
Browse files Browse the repository at this point in the history
Co-authored-by: David Montague <35119617+dmontagu@users.noreply.github.com>
  • Loading branch information
Kludex and dmontagu authored Feb 24, 2025
1 parent 23aa147 commit a226969
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pydantic_ai_slim/pydantic_ai/models/cohere.py
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ def _map_user_message(cls, message: ModelRequest) -> Iterable[ChatMessageV2]:
if isinstance(part.content, str):
yield UserChatMessageV2(role='user', content=part.content)
else:
raise RuntimeError('Only string as user prompt is supported for Cohere.')
raise RuntimeError('Cohere does not yet support multi-modal inputs.')
elif isinstance(part, ToolReturnPart):
yield ToolChatMessageV2(
role='tool',
Expand Down

0 comments on commit a226969

Please sign in to comment.