Expand description
Chat message types exchanged between the agent runtime and model providers.
These types replace the subset of rig’s message model that this project
actually uses. Their JSON representations are byte-compatible with the
rig types they replace (rig 0.31), because persisted conversation
histories embed them — do not change serde attributes without a migration
plan. Fields rig serialized but this project never populated (e.g. tool
call signatures) have been dropped; they deserialize as ignored unknown
fields from old data.
Structs§
- Image
- Image content with its source data and media type.
- Reasoning
- An assistant reasoning (“thinking”) block.
- Text
- A plain text block.
- Tool
Call - A tool invocation requested by the model.
- Tool
Function - The function name and arguments of a
ToolCall. - Tool
Result - The result of executing a tool call, sent back as user content.
Enums§
- Assistant
Content - Content of an assistant message.
- Image
Media Type - Image media type.
- Image
Source - Where an
Image’s data comes from. - Message
- A message in a conversation: one run of user input or assistant output.
- Reasoning
Content - One block of reasoning content.
- Tool
Result Content - Content of a
ToolResult: text or an image. - User
Content - Content of a user message.