TemporalCommunity.Extensions.Agents
0.8.1-preview.18
Prefix Reserved
See the version list below for details.
dotnet add package TemporalCommunity.Extensions.Agents --version 0.8.1-preview.18
NuGet\Install-Package TemporalCommunity.Extensions.Agents -Version 0.8.1-preview.18
<PackageReference Include="TemporalCommunity.Extensions.Agents" Version="0.8.1-preview.18" />
<PackageVersion Include="TemporalCommunity.Extensions.Agents" Version="0.8.1-preview.18" />
<PackageReference Include="TemporalCommunity.Extensions.Agents" />
paket add TemporalCommunity.Extensions.Agents --version 0.8.1-preview.18
#r "nuget: TemporalCommunity.Extensions.Agents, 0.8.1-preview.18"
#:package TemporalCommunity.Extensions.Agents@0.8.1-preview.18
#addin nuget:?package=TemporalCommunity.Extensions.Agents&version=0.8.1-preview.18&prerelease
#tool nuget:?package=TemporalCommunity.Extensions.Agents&version=0.8.1-preview.18&prerelease
TemporalAgents
Temporal .NET SDK integrations for building durable AI applications. Two packages, two levels of abstraction:
| Package | Description |
|---|---|
TemporalCommunity.Extensions.AI |
Make any IChatClient durable — no Agent Framework required |
TemporalCommunity.Extensions.Agents |
Durable agent sessions built on Microsoft Agent Framework |
Both packages give AI workloads durability by default — conversation history, LLM calls, and tool invocations are persisted in Temporal's event history and replayed deterministically after crashes or restarts.
Overview
TemporalCommunity.Extensions.AI
A lightweight middleware layer for Microsoft.Extensions.AI (MEAI). Wraps any IChatClient with Temporal durability via a DelegatingChatClient middleware. No agent framework, no heavy abstractions — just MEAI pipelines made crash-resilient.
Start here if: you are already using MEAI's IChatClient directly and want Temporal durability without adopting the full Agent Framework.
dotnet add package TemporalCommunity.Extensions.AI
TemporalCommunity.Extensions.Agents
A Temporal integration for Microsoft Agent Framework (Microsoft.Agents.AI). Each AIAgent session maps to a long-lived Temporal workflow with full session management: history, StateBag persistence, HITL approval gates, LLM-powered routing, and parallel agent fan-out.
Start here if: you are building with the Microsoft Agent Framework and want durable, stateful, multi-agent sessions.
dotnet add package TemporalCommunity.Extensions.Agents
How It Works
Both packages share the same core pattern: LLM calls run inside Temporal activities (never directly in workflows), and conversation turns are delivered via Temporal Updates — a durable, acknowledged request/response primitive that eliminates polling.
External Caller
│
│ WorkflowUpdate (chat turn / agent message)
▼
Temporal Workflow ←── persists history, serializes turns, handles ContinueAsNew
│
│ ExecuteActivityAsync
▼
Activity ←── calls real IChatClient / AIAgent — retried automatically on failure
Prerequisites
- .NET 10 SDK or later
- A running Temporal server:
temporal server start-dev - An LLM provider (e.g., Azure OpenAI, OpenAI, Ollama)
Samples
| Sample | Package | Description |
|---|---|---|
| DurableChat | Extensions.AI |
Multi-turn durable chat with DurableChatSessionClient and tool functions |
| DurableTools | Extensions.AI |
Per-tool activity dispatch with AsDurable() and AddDurableTools |
| OpenTelemetry | Extensions.AI |
OTel tracing — span hierarchy, ActivitySource names, and token attributes |
| HumanInTheLoop | Extensions.AI |
HITL approval gates via RequestApprovalAsync and SubmitApprovalAsync |
| DurableEmbeddings | Extensions.AI |
IEmbeddingGenerator wrapped for durable per-chunk activity dispatch |
| BasicAgent | Extensions.Agents |
External caller pattern — send messages to an agent from a console app |
| SplitWorkerClient | Extensions.Agents |
Worker and client in separate processes |
| WorkflowOrchestration | Extensions.Agents |
Sub-agent orchestration inside a Temporal workflow |
| EvaluatorOptimizer | Extensions.Agents |
Generator + evaluator loop pattern |
| MultiAgentRouting | Extensions.Agents |
LLM-powered routing, parallel execution, and OpenTelemetry |
| HumanInTheLoop | Extensions.Agents |
HITL approval gates via [WorkflowUpdate] |
Sample credentials
API keys are managed with dotnet user-secrets — stored outside the repo in ~/.microsoft/usersecrets/ and loaded automatically by Host.CreateApplicationBuilder() in the Development environment.
Set OPENAI_API_KEY for each sample project you want to run:
dotnet user-secrets set "OPENAI_API_KEY" "sk-..." --project samples/MEAI/DurableChat
Non-sensitive settings (OPENAI_API_BASE_URL, OPENAI_MODEL, TEMPORAL_ADDRESS) have working defaults in each project's committed appsettings.json and do not need to be set via user-secrets unless you want to override them.
Alternatively, set OPENAI_API_KEY as an environment variable — the samples pick it up automatically via IConfiguration.
# Start Temporal (separate terminal)
temporal server start-dev --namespace default
# Run a sample
dotnet run --project samples/MEAI/DurableChat
dotnet run --project samples/MAF/BasicAgent
Building
just build # Restore + Release build
just test-unit # Unit tests (no server required)
just test # Unit + integration tests (requires temporal server start-dev)
just pack # Build NuGet packages → artifacts/packages/
just ci # Full pipeline: clean → build → test-unit → pack
License
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- Microsoft.Agents.AI (>= 1.12.0)
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.9)
- TemporalCommunity.Extensions.AI (>= 0.8.1-preview.18)
- Temporalio (>= 1.16.0)
- Temporalio.Extensions.Hosting (>= 1.16.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.12.1 | 72 | 8/11/2026 |
| 0.12.0 | 86 | 8/10/2026 |
| 0.10.4 | 80 | 8/9/2026 |
| 0.10.3-preview.11 | 98 | 7/15/2026 |
| 0.8.1-preview.21 | 53 | 7/8/2026 |
| 0.8.1-preview.18 | 58 | 7/8/2026 |
| 0.8.1-preview.11 | 59 | 7/8/2026 |
| 0.8.0 | 129 | 7/8/2026 |