-
Notifications
You must be signed in to change notification settings - Fork 238
Open
Description
Describe the bug
Microsoft.Extensions.AI.DataContent message type is not supported with OnnxRuntimeGenAIChatClient client.
To Reproduce
Steps to reproduce the behavior:
using var onnxChatClient = new OnnxRuntimeGenAIChatClient(model);
byte[] imageBytes = File.ReadAllBytes(@"path.jpg");
var message = new(ChatRole.User, [
new TextContent(query),
new DataContent(imageBytes, "image/jpeg")
])
var response = onnxChatClient.GetResponseAsync([message]))
or
using var onnxChatClient = new OnnxRuntimeGenAIChatClient(model);
var message = new(ChatRole.User, [
new TextContent(query),
new UriContent(new Uri(@"https://path/to/image"), "image/jpeg")
]),
var response = onnxChatClient.GetResponseAsync([message]))
non-text content is not processed.
I'm expecting the model to "see" the attached image.
Desktop (please complete the following information):
- OS: [Win/Linux]
- Version [Microsoft.ML.OnnxRuntimeGenAI.Cuda 0.11.1]
Metadata
Metadata
Assignees
Labels
No labels