Sycophant. Message. Content. Text
(sycophant v0.5.0)
Copy Markdown
Text content part for multimodal messages.
Used when a message contains a mix of text and other content types like images. For text-only messages, pass a plain string to the message constructors instead.
The optional :citations field holds the Sycophant.Citation structs a
provider attached to this span of assistant text (currently Anthropic).
Examples
iex> %Sycophant.Message.Content.Text{text: "Describe this image"}
#Sycophant.Message.Content.Text<"Describe this image">
Summary
Types
@type t() :: %Sycophant.Message.Content.Text{ __type__: binary(), citations: nil | [ %Sycophant.Citation{ __type__: binary(), cited_text: nil | binary(), document_index: nil | integer(), document_title: nil | binary(), end_index: nil | integer(), file_id: nil | binary(), source: nil | binary(), start_index: nil | integer(), title: nil | binary(), type: nil | :page_location | :char_location | :content_block_location | :web_search_result_location | :search_result_location, unit: nil | :page | :char | :block, url: nil | binary() } ], text: binary(), type: binary() }