Skip to content

Commit 39b6e25

Browse files
authored
Merge pull request #53 from FormulaMonks/feat/image-data-message
feat: add `imageData` option to `KurtMessage`
2 parents 31c051a + 342c390 commit 39b6e25

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

packages/kurt/src/Kurt.ts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -197,6 +197,27 @@ export type KurtMessage = {
197197
*/
198198
text: string
199199

200+
/**
201+
* When present, this is an image data message, with a base64-encoded image.
202+
* This is often used with "multi-modal" LLMs that support image mode input.
203+
*
204+
* Not all LLM providers or underlying models support this kind of message.
205+
* Check your LLM provider's documentation for confirmaton.
206+
*/
207+
imageData: {
208+
/**
209+
* The IANA standard MIME type of the inline image data.
210+
*
211+
* Not all MIME types are supported by all LLM providers.
212+
* "image/png" and "image/jpeg" are the most commonly supported.
213+
* Check your LLM provider's documentation for the right list.
214+
*/
215+
mimeType: string
216+
217+
/** Base64-encoded image data, as a string. */
218+
base64Data: string
219+
}
220+
200221
/**
201222
* When present, this is a tool call message, with structured data input
202223
* in the `args` object, and structured data output in the `result` object.

0 commit comments

Comments
 (0)