summaryrefslogtreecommitdiff
path: root/llm.go
diff options
context:
space:
mode:
authorGrail Finder <wohilas@gmail.com>2026-02-17 16:19:33 +0300
committerGrail Finder <wohilas@gmail.com>2026-02-17 16:19:33 +0300
commit7d18a9d77eca3b286849ae0a134f9d7277249bef (patch)
tree737609dbf8099277a1d57a6f360d3e00b3d50fd7 /llm.go
parentb67ae1be98f3131fa8cec9ae01d8f86fd4df8e06 (diff)
Feat: indicator for a message with an image [image: filename]
Diffstat (limited to 'llm.go')
-rw-r--r--llm.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/llm.go b/llm.go
index fffa994..7cce713 100644
--- a/llm.go
+++ b/llm.go
@@ -289,7 +289,7 @@ func (op LCPChat) FormMsg(msg, role string, resume bool) (io.Reader, error) {
// If image processing fails, fall back to simple text message
newMsg = models.NewRoleMsg(role, msg)
} else {
- newMsg.AddImagePart(imageURL)
+ newMsg.AddImagePart(imageURL, localImageAttachmentPath)
}
// Only clear the global image attachment after successfully processing it in this API call
imageAttachmentPath = "" // Clear the attachment after use
@@ -664,7 +664,7 @@ func (or OpenRouterChat) FormMsg(msg, role string, resume bool) (io.Reader, erro
// If image processing fails, fall back to simple text message
newMsg = models.NewRoleMsg(role, msg)
} else {
- newMsg.AddImagePart(imageURL)
+ newMsg.AddImagePart(imageURL, localImageAttachmentPath)
}
// Only clear the global image attachment after successfully processing it in this API call
imageAttachmentPath = "" // Clear the attachment after use