Agentic AI
Google's Genkit Agents API Brings Paused Tools and Long-Running Tasks to TypeScript and Go
A new preview API from Google's open-source framework handles multi-turn conversations, human approval workflows, and detached background jobs through a single unified interface.
InfoQ
Google has released a preview Agents API for Genkit, its framework for building full-stack AI applications, bringing several developer-friendly patterns to TypeScript and Go developers.
The API wraps message history, tool execution, streaming, state management, and client communication into a single chat() interface that behaves consistently whether agents run locally or over HTTP. Rather than swap out framework primitives as applications grow, developers use the same abstraction from simple chatbots to complex multi-agent workflows.
Separating State from Artifacts#
Genkit distinguishes between two kinds of data that many frameworks treat interchangeably. Custom state — such as workflow progress, task lists, or entity selections — drives the next conversation turn. Artifacts — reports, code patches, itineraries — are outputs users may examine, save, or version separately. Tools can modify both, and changes stream to clients in real time.
Flexible Persistence Models#
State persistence can follow either a server-managed or client-managed path. Server-managed agents store messages and state as snapshots in Firestore, in-memory stores, or file-based backends, allowing clients to reconnect by session ID. Client-managed agents instead return full state to the client on each turn, reducing server-side storage but increasing payload size as conversations grow. This trade-off has compliance implications: client-managed architectures respect strict data residency requirements that server-side persistence cannot.
Detached Tasks and Human Approval#
Two standout features address practical deployment challenges. Detached turns let a client launch a long-running agent task, disconnect, and poll for results later. The agent continues executing server-side and writes progress snapshots that any client can read—enabling research jobs, multi-step planning, and tool-heavy workflows without WebSockets or a persistent connection.
Interruptible tools add human-in-the-loop control by pausing execution mid-tool and returning the pending action to the user for approval or rejection. The runtime validates any resume request against session history, preventing forgery attacks that could trick tools into executing unintended commands.

