microsoft / microsoft/agent-framework-durable-extension
.NET: [Bug]: DurableAIAgentProxy is not compatible with MapAGUI
@javiercn is already working on this.
Since May 28, 2026.
- Dominant language
- Python
- Stars
- 16
- Forks
- 10
- Avg merge
- 3d 9h
- Merged PRs (30d)
- 9
Description
Description
I'm trying to build a ASP.NET Core front door with Durable Task Scheduler behind it for long-running operations and AG-UI.
But according to the source code, the DurableAIAgentProxy does not support streaming; however, MapAGUI uses SSE and requires streaming.
I also opened the dicussion : https://github.com/microsoft/agent-framework/discussions/5900
Code Sample
// Program.cs
using Microsoft.Agents.AI;
using Microsoft.Agents.AI.DurableTask;
using Microsoft.Agents.AI.Hosting.AGUI.AspNetCore;
using Microsoft.Extensions.AI;
using OpenAI;
using System.ClientModel;
var builder = WebApplication.CreateBuilder(args);
builder.Services.AddAGUI();
string dtsConnection = builder.Configuration["DurableTask:ConnectionString"]
?? "Endpoint=http://dts-emulator:8080;TaskHub=default;Authentication=None";
var openAIClient = new OpenAIClient(
new ApiKeyCredential("ollama"),
new OpenAIClientOptions { Endpoint = new Uri("http://localhost:11434/v1") });
IChatClient chatClient = openAIClient
.GetChatClient("gemma4:26b-nvfp4")
.AsIChatClient();
builder.Services.AddSingleton(chatClient);
AIAgent agent = chatClient.AsAIAgent(
name: "OllamaAgent",
instructions: "You are a helpful assistant.");
builder.Services.ConfigureDurableAgents(
options =>
{
options.DefaultTimeToLive = TimeSpan.FromDays(7);
options.AddAIAgent(agent);
},
workerBuilder: b => b.UseDurableTaskScheduler(dtsConnection),
clientBuilder: b => b.UseDurableTaskScheduler(dtsConnection));
var app = builder.Build();
AIAgent durableAgent = agent.AsDurableAgentProxy(app.Services);
// DurableAgent throws NotSupportedException("Streaming is not supported for durable agents.") at the runtime
app.MapAGUI("/chat", durableAgent);
await app.RunAsync();
Error Messages / Stack Traces
Package Versions
Microsoft.Agents.AI: 1.6.2, Microsoft.Agents.AI.Hosting.AGUI.AspNetCore: 1.6.2-preview.260521.1, Microsoft.Agents.AI.DurableTask: 1.6.2-preview.260521.1
.NET Version
.NET 10
Additional Context
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.