From ag-ui-dotnet
Attaches images, audio, PDFs to AG-UI agent messages via .NET SDK. Builds multimodal ChatMessage with inline bytes or URL references.
How this skill is triggered — by the user, by Claude, or both
Slash command
/ag-ui-dotnet:agui-dotnet-multimodalThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Goal: include an image (or other binary content) in a turn so a multimodal model can describe or reason about it.
Goal: include an image (or other binary content) in a turn so a multimodal model can describe or reason about it.
A multimodal message is an ordinary Microsoft.Extensions.AI ChatMessage whose Contents mixes a TextContent with one or more binary parts. AGUIChatClient carries those parts across the AG-UI wire; the server streams the model's reply as usual.
dotnet add package AGUI.Client
Microsoft.Extensions.AI supplies ChatMessage, TextContent, DataContent, and UriContent.
Use DataContent(bytes, mediaType) to embed the data directly in the message:
using AGUI.Client;
using Microsoft.Extensions.AI;
byte[] imageBytes = await File.ReadAllBytesAsync("photo.png");
var messages = new List<ChatMessage>
{
new(ChatRole.User,
[
new TextContent("Describe this image"),
new DataContent(imageBytes, "image/png"),
]),
};
await foreach (var update in client.GetStreamingResponseAsync(messages))
{
Console.Write(update.Text);
}
The media type must match the bytes (image/png, image/jpeg, audio/wav, application/pdf, …) so the model decodes them correctly.
When the asset already lives at a URL, use UriContent(uri, mediaType) instead — the bytes never pass through your process:
new ChatMessage(ChatRole.User,
[
new TextContent("What's in this picture?"),
new UriContent("https://example.com/cat.jpg", "image/jpeg"),
]);
Prefer UriContent to reference an asset already hosted at a URL; use DataContent for local bytes the model host can't reach by URL.
DataContent. Inline binary is base64-encoded into the request, inflating it ~33% and forcing the whole payload through memory on both ends. For anything sizable that is reachable by URL, send UriContent and let the model host fetch it.IChatClient at a vision-capable model/deployment.npx claudepluginhub jasonkneen/ag-ui --plugin ag-ui-dotnet5plugins reuse this skill
First indexed Jun 24, 2026
Attaches images, audio, PDFs to AG-UI agent messages via .NET SDK. Builds multimodal ChatMessage with inline bytes or URL references.
Creates and manages persistent Azure AI agents with threads, messages, runs, and tools via the .NET SDK. Supports agent CRUD, conversation threads, streaming responses, function calling, file search, and code interpreter.
Creates and manages persistent Azure AI agents with threads, messages, runs, and tools using the .NET SDK. Includes polling and streaming execution.