Workflow Streams provides a durable abstraction for real-time, interactive communication within Temporal applications. It enables applications to publish ordered sequences of typed events to topics scoped to a Workflow, allowing both the Workflow itself and external clients to publish and subscribe. This feature leverages Temporal's core primitives (Workflows, Signals, Updates, and Queries) to offer exactly-once semantics and seamless integration with AI agent frameworks and other streaming use cases. This post details the implementation using Signals for external publishing and Updates for subscriber polling, including handling batching, deduplication, and Continue-as-New transitions. Integrations with AI agent frameworks like OpenAI Agents SDK and Google ADK are also covered, along with a complete example demonstrating Server-Sent Events for UI updates.
All Temporal trails