Repository navigation
[Agents] Move the Think samples to Think 0.24 and add Think Context and Sessions pages - #35548
Closed
mattzcarey wants to merge 5 commits into
Closed
mattzcarey wants to merge 5 commits into
mattzcarey wants to merge 5 commits into
Conversation
…nd Sessions pages
mattzcarey
requested review from
a team,
irvinebroque and
rita3ko
as code owners
November 23, 2026 16:19
Contributor
AI Review✅ Reviewed Commands
|
Contributor
This was referenced Nov 23, 2026
Open
🚀 Deploying Preview to Cloudflare 🚀Preview URL: https://docs-agents-think-024-samples.previews.developers.cloudflare.com (commit d42afa2)This URL reflects your latest Preview deploymentPreview Deployments by commit
|
Member
Author
|
Merged as part of #35542: that PR was stacked on this one, and its squash merge brought every change here into production. Closing. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Moves the Think pages to
@cloudflare/think0.24.0 and@cloudflare/computer0.10, and adds two Think pages: Context (context blocks, providers, the frozen prompt, reminders, memory and search, with a note that most agents need skills more than context) and Sessions (compaction, message storage, media eviction, prompt caching). This carries the work of #35055 onto currentproduction.The Think pages still used APIs that Think no longer exports or has deprecated:
defineScheduledTasksanddefineMessengersare gone, so those samples return plain objectsconfigureSession().withContext()chain toconfigureContext()useAgentChatimports from@cloudflare/think/react, andonStepFinishbecomesonStepEndCodemodeBackendandcodemode:host modules from Computer 0.10#35055's "Memory and context" page is split in two so each page covers one thing, and the Context page states what Think does: an overridden
getSystemPrompt()stays above the blocks, and a reminder rides on the newest user message until a refresh.pnpm run buildandpnpm run lint:nimbuspass locally. The Context and Sessions samples compile withtsc --strictagainst@cloudflare/[email protected]and@cloudflare/[email protected]; the other sample changes are #35055's, which were checked against the same versions.