Skip to content

Commit 4fadfdd

Browse files
committed
Document that path-backed Image/Audio message content reads the file (Raises: OSError)
No-Verification-Needed: docstring-only change
1 parent 6015f97 commit 4fadfdd

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

  • src/mcp/server/mcpserver/prompts

src/mcp/server/mcpserver/prompts/base.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,11 @@ class Message(BaseModel):
2626
"""Base class for all prompt messages.
2727
2828
`content` may be a plain string (wrapped in `TextContent`), an `Image` or `Audio`
29-
helper (converted to `ImageContent` / `AudioContent`), or any ready-made content block.
29+
helper (converted to `ImageContent` / `AudioContent`, reading the file for path-backed
30+
helpers), or any ready-made content block.
31+
32+
Raises:
33+
OSError: If a path-backed `Image` or `Audio` cannot be read.
3034
"""
3135

3236
role: Literal["user", "assistant"]

0 commit comments

Comments
 (0)