ReqLLM.Message.ContentPart (ReqLLM v1.0.0-rc.5)
View SourceContentPart represents a single piece of content within a message.
Supports multiple content types:
:text
- Plain text content:image_url
- Image from URL:image
- Image from binary data:file
- File attachment:tool_call
- Tool invocation:tool_result
- Tool execution result:thinking
- Chain-of-thought thinking content
See also
ReqLLM.Message
- Multi-modal message composition using ContentPart collections
Summary
Types
@type t() :: %ReqLLM.Message.ContentPart{ data: binary() | nil, filename: String.t() | nil, input: term() | nil, media_type: String.t() | nil, metadata: map(), output: term() | nil, text: String.t() | nil, tool_call_id: String.t() | nil, tool_name: String.t() | nil, type: :text | :image_url | :image | :file | :tool_call | :tool_result | :thinking, url: String.t() | nil }