Skip to content

Commit

Permalink
Update Message annotations to support tool calls (#227)
Browse files Browse the repository at this point in the history
  • Loading branch information
Shulyaka authored Jul 29, 2024
1 parent cbf0887 commit 8b694bb
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ollama/_types.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,10 @@ class Message(TypedDict):
Chat message.
"""

role: Literal['user', 'assistant', 'system']
"Assumed role of the message. Response messages always has role 'assistant'."
role: Literal['user', 'assistant', 'system', 'tool']
"Assumed role of the message. Response messages always has role 'assistant' or 'tool'."

content: str
content: NotRequired[str]
'Content of the message. Response messages contains message fragments when streaming.'

images: NotRequired[Sequence[Any]]
Expand Down

0 comments on commit 8b694bb

Please sign in to comment.