feat(message): the image content block
Providers map images to per-backend content blocks, so the block rides the message seam beside the tool blocks and round-trips through session checkpoints. Untagged serde keeps old payloads loading; the new variant sits last so the field sets disambiguate. Exhaustive matches on Content across the adapters and views gained a mechanical Image arm; sending images is a later effort.
This commit is contained in:
1 parent
18d58ea8a4
commit
5405e3c5b0
2 files changed
+2
-2
No files matched your search
@@ -503,7 +503,7 @@ pub(crate) fn final_text(message: &Message) -> Option<String> {
|
||||
.iter()
|
||||
.filter_map(|content| match content {
|
||||
Content::Text(text) => Some(text.as_str()),
|
||||
Content::ToolCall(_) | Content::ToolResult(_) => None,
|
||||
Content::ToolCall(_) | Content::ToolResult(_) | Content::Image(_) => None,
|
||||
})
|
||||
.collect::<Vec<_>>()
|
||||
.join("");
|
||||
|
||||
@@ -474,7 +474,7 @@ fn final_text(message: &Message) -> Option<String> {
|
||||
.iter()
|
||||
.filter_map(|content| match content {
|
||||
Content::Text(text) => Some(text.as_str()),
|
||||
Content::ToolCall(_) | Content::ToolResult(_) => None,
|
||||
Content::ToolCall(_) | Content::ToolResult(_) | Content::Image(_) => None,
|
||||
})
|
||||
.collect::<Vec<_>>()
|
||||
.join("");
|
||||
|
||||
Reference in new issue
Block a user