Skip to content

[Agents] Add Sub-agents, Sessions, and Think reference docs#29882

Merged
threepointone merged 1 commit intoproductionfrom
think-sessions-sub-agents
Apr 15, 2026
Merged

[Agents] Add Sub-agents, Sessions, and Think reference docs#29882
threepointone merged 1 commit intoproductionfrom
think-sessions-sub-agents

Conversation

@threepointone
Copy link
Copy Markdown
Contributor

@threepointone threepointone commented Apr 15, 2026

Summary

Adds three new API reference pages for the Agents SDK, covering experimental features that were previously undocumented in cloudflare-docs:

  • Sub-agents — Documents Agent.subAgent(), abortSubAgent(), deleteSubAgent(), SubAgentStub<T> typing, storage isolation, naming, patterns (parallel, nested, callback streaming), and limitations.
  • Sessions — Documents the experimental Session API: builder pattern, tree-structured messages, branching, context blocks (4 provider types), AI tools, compaction, SessionManager, forking, cross-session search, storage tables, and custom providers.
  • Think — Comprehensive reference for @cloudflare/think: quick start, Think vs AIChatAgent comparison, configuration, session integration, tools (7-layer merge order, workspace, code execution, browser/CDP, extensions), all 8 lifecycle hooks, client tools, message concurrency, sub-agent RPC via chat(), programmatic turns, chat recovery, and stability detection.

Also updates three existing pages with cross-links:

  • agents-api.mdx — added Sub-agents, Sessions, Think rows to the API reference table
  • long-running-agents.mdx — added link from "Delegating to sub-agents" to the new API reference
  • chat-agents.mdx — added note in "Subagent delegation" distinguishing in-process AI SDK subagents from Durable Object sub-agents

Source material adapted from the agents-repo internal docs (docs/think/, docs/sessions.md).

Documentation checklist

  • The change adheres to the documentation style guide.
  • If a larger change - such as adding a new page- an issue has been opened in relation to any incorrect or out of date information that this PR fixes.

Made with Cursor


Open with Devin

Add new API reference pages for Sessions, Sub-agents, and Think (persistent session storage, child Durable Object agents with RPC, and the Think opinionated chat framework). Update the Agents API index to include Sub-agents, Sessions, and Think. Clarify subagent delegation in chat-agents (note about in-process ToolLoopAgent vs Durable Object sub-agents). Rename/standardize chat recovery flag in durable-execution (unstable_chatRecovery → chatRecovery) and update related links/reference text. Also include minor related adjustments in long-running agents documentation.
@github-actions github-actions Bot added product:agents Build and deploy AI-powered Agents on Cloudflare that can act autonomously. size/xl labels Apr 15, 2026
@threepointone threepointone marked this pull request as ready for review April 15, 2026 06:22
@github-actions
Copy link
Copy Markdown
Contributor

This pull request requires reviews from CODEOWNERS as it changes files that match the following patterns:

Pattern Owners
/src/content/docs/agents/ @irvinebroque, @rita3ko, @elithrar, @thomasgauvin, @threepointone, @whoiskatrin, @cloudflare/pcx-technical-writing, @cloudflare/product-owners, @cloudflare/ai-agents, @cloudflare/dev-plat-leads

Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 3 additional findings.

Open in Devin Review

@github-actions
Copy link
Copy Markdown
Contributor

@threepointone threepointone merged commit 3279139 into production Apr 15, 2026
18 checks passed
@threepointone threepointone deleted the think-sessions-sub-agents branch April 15, 2026 08:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

product:agents Build and deploy AI-powered Agents on Cloudflare that can act autonomously. size/xl

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants