AI Engineer World's Fair 2026
Build a Research Agent with Claude Managed Agents (Part 2 of 4) — Anthropic
Read the talk
Build a Research Agent with Claude Managed Agents (Part 2 of 4)
Priyanka Phatak and Gabe Cemaj build from a console-created joke agent to a research desk that reads SEC filings, delegates analysis, saves memory and grades its own deliverables. The Q&A draws the practical boundaries around credentials, orchestration, shared knowledge and private data.
From a talk by Priyanka Phatak and Gabe Cemaj
At a glance
Ideas worth remembering
A chat interface sends user.message events to a session and relays the API's SSE stream through its backend to the browser.
The Nvidia task produces both a reusable company memory note and a structured scorecard. Specialists return findings; the main agent creates the deliverables.
Outcomes grade session work against a task-specific rubric and permit retries. They do not provide separate subagent outcomes or the per-session spending caps discussed in Q&A.
Vaults substitute real credentials for placeholders at egress only for allowed hosts. Private connectivity can instead use MCP Tunnels or a self-hosted sandbox with internal network access.
Multiple memory stores can accompany a session. Dreaming consolidates transcripts and memories into updated memory; automatic changes to skills, prompts and agent definitions were outside its demonstrated scope.
Create an agent, then give it somewhere to run
A session needs to keep its history without making every new event type a change to the machinery that runs it. Opening this part of the workshop, Anthropic’s Gabe Cemaj explains that the revised storage design separates components and virtualizes interfaces down to the event layer. The purpose is to extend what the system can store without tightly coupling storage to session execution.
Priyanka Phatak then starts with a deliberately small request: “Build me an agent that tells me jokes every time, given a topic.” The console generates a system prompt, name, description and model selection, with access to the agent tool set. Creating the agent saves that definition through the agent endpoint. It does not yet define the sandbox in which the agent will work.
The environment supplies that second piece: a template for the sandbox, including installed packages and network access. This quick demonstration uses unrestricted access; Phatak recommends restricting production access to the required domains or MCP servers. After starting a session, she asks for cat jokes and gets a response. The application-facing model is now simple: start a session, send events and receive events. Anthropic manages the hosting, harness, sandboxes, scaling and event-log storage behind it.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Set up the research desk and its SEC identity
Cemaj’s research desk builds on that foundation in layers: first a chat interface, then SEC-filing skills and specialist subagents, then asynchronous research with structured results. The planned extension is a custom orchestration harness that distributes tickers across separate sessions and aggregates their scores. Recurring work through the deployments API is also introduced as a later step.
The local application starts from the repository’s research desk directory. Install dependencies with npm install or bun i, then run bun run dev and open the setup page. A repository-provided workshop skill guides Claude Code through six acts: workshop start begins the walkthrough, and workshop next advances it. Cemaj asks the coding agent to implement the app while explaining its changes—a useful arrangement when the workshop itself is also being built by an agent.
Setup copies .env.example to .env.local. The developer supplies an API key and an EDGAR identifier containing a name and email, because the SEC requires callers to identify themselves. The coding agent tries to advance too quickly, prompting Cemaj to stop it before continuing. Those prerequisites matter later: the filing-retrieval skill must know both how to call the SEC and which caller identity to use.
Where does the work run? Cemaj describes Anthropic-hosted infrastructure and a Claude Platform offering on AWS. He also distinguishes the sandbox from the managed service: developers can bring a self-hosted sandbox through providers such as Vercel, Modal or Daytona, or run one in Google Cloud or AWS. For this demo, the setup action provisions an environment with access mainly to SEC websites and useful Python packages, plus a basic agent with a prompt and basic tools. Skills and subagent coordination come next.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Build chat by relaying the session event stream
The chat UI is a view over a session’s events. Submitting text sends a user.message event containing the user’s message to the session. The application also listens for the events the agent produces, so the same session supports both incoming instructions and outgoing updates.
What connects the managed session to the browser? The research desk’s backend listens to the API’s server-sent event stream and restreams those events to the frontend, where the UI renders them. This separates session execution from presentation: the backend relays the stream, while the browser decides how to display it. Once the implementation finishes, Cemaj opens the desk tab, says hi and receives a reply.
That is enough for a chat application. The next layer uses the same managed-session foundation for asynchronous work. Cemaj describes tasks lasting hours, days, weeks or months; the financial-research example that follows is a much shorter demonstration of that model.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Add filing expertise, delegation and shared memory
The upgrade adds several distinct capabilities to the agent definition:
- SEC skill. Instructions explain how to use the Python package and supply the EDGAR identity when calling the SEC.
- Specialist subagents. Delegates have their own prompts, tools and permissions.
- Custom dispatch tool. A tool called dispatch analysis receives a schema and prepares the application for coordinating multiple sessions through its own harness.
- Shared memory store. Separate sessions can save and reuse knowledge about financial instruments.
The revised main agent also includes a reference to itself. That permits delegation to another agent with the same prompt when the task does not fit a predefined specialist. The copy includes the prompt, tool descriptions and schemas; it does not inherit the parent session’s transcript. A self-reference therefore reproduces the agent’s configuration, without automatically giving the delegate everything the parent has learned in conversation.
Changing the provisioning code still leaves resources to create. When the expected setup state does not appear, Cemaj discovers an earlier run’s skill, deletes it and asks Claude to reprovision it. The resulting agent has the skill, delegates and memory store needed for the next task. His “cook show” shortcut briefly gets in the way, but the recovery makes the distinction visible: implementation changes and provisioned managed resources are separate steps.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Define completion with a task and a rubric
Research needs a stronger completion condition than an agent saying it is done. Outcomes pair a task with a rubric for evaluating it. The agent performs the work; when it believes it has finished, a grading subagent examines the work against the rubric. A satisfactory result completes the task, while an unsatisfactory result sends it back for another attempt.
The research desk implements this as a user-defined outcome event sent when a ticker analysis starts. It carries the task description, rubric and maximum iterations. This gives the asynchronous session both a requested deliverable and an evaluation standard, with an explicit iteration setting for the self-supervision process.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Trace Nvidia research from memory lookup to deliverables
Cemaj starts an Nvidia analysis, then opens a session from the previous day rather than waiting for the new run, which he estimates will take about ten minutes. The task asks for analysis of the company’s most recent relevant quarterly filing using the supplied EDGAR identity. Before researching, the agent must check memory for earlier analysis and reuse what it already knows.
Completion requires two different artifacts:
- Company memory note. Save knowledge about Nvidia for future sessions.
- Structured scorecard. Write the analysis in the prescribed structured format and save it at a specified file location.
The memory note serves later agent work; the scorecard gives the application a result it can extract and display.
The earlier session finds no notes in memory, checks several places and delegates the research to financial-analysis or extraction expertise and a risk evaluator. How does that delegation become a final result? The console exposes separate subagent threads. Each delegate works on its assignment and returns information to the main agent; the main agent then resumes, combines those results, creates the requested JSON file and updates memory. The specialists contribute findings, while the main agent remains responsible for the deliverables.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Grade the artifacts, then prepare for more tickers
The completed session next starts its grading subagent. What does the grader inspect? It reads the rubric, the session’s work and the generated artifacts, then marks the outcome satisfied: the scorecard was delivered, its numbers were well-defined and the memory update was correct. This is the grader’s judgment in the prior session, rather than an independent validation of the financial analysis; the newly launched run is still in progress during the walkthrough.
Once a session completes, the application can extract and download its scorecard, then store it locally—as this demo does—or put it in a database. Scaling to ten or a hundred tickers introduces a second level of delegation: the proposed server-side harness uses the custom dispatch tool to start a separate session for each ticker and aggregate the results afterward. That is distinct from the specialist subagents collaborating inside one company’s analysis.
Before continuing with orchestration, Cemaj catches a skipped step: updating the SEC skill to handle another form. Skills are live artifacts that can be revised and published; new sessions referencing the skill receive the new information. The demonstrated change concerns future sessions, without establishing that an already-running session adopts the update. Reviewing past sessions can inform those manual skill improvements.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Swap credential placeholders only at allowed destinations
The SEC example supplies a name and email directly in the prompt. Production credentials call for a different mechanism: vaults. A developer defines a secret for an environment variable, but the sandbox receives a placeholder value. When the agent uses that variable in an outgoing request, the service swaps in the real credential at egress only for the host domains permitted for that secret.
Where does the destination restriction take effect? The branching diagram separates the agent’s placeholder-bearing request from the service’s credential substitution. A request to the allowed SEC destination receives the real value; a request to another host, such as anthropic.com in Cemaj’s example, does not trigger the swap. The destination check is part of the egress mechanism, rather than an instruction asking the agent to keep the credential on the right site.
A vault bundles credentials under an ID that the developer attaches to a session. The examples include API credentials for a Google Workspace CLI installed in the sandbox and OAuth credentials for MCP servers, including a Notion example in the console. The session references the vault, and its configured credentials govern authentication and permitted substitution.
Destination-gated credential substitution
Read the diagram as text
- Sandbox request. The environment variable contributes a placeholder value.
- Egress host check. Check the destination against the hosts allowed for this secret.
- Allowed destination. Replace the placeholder with the real credential.
- Other destination. Do not substitute the real credential.
- Sandbox request → Egress host check: Outgoing request with placeholder.
- Egress host check → Allowed destination: Host is allowed.
- Egress host check → Other destination: Host is not allowed.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Understand which controls the managed harness provides
The Agent SDK and Managed Agents offer different operating arrangements. Phatak describes the SDK as a headless Claude Code binary that developers can run wherever they choose. Managed Agents uses its own hosted harness, informed by Claude Code and Agent SDK lessons but rebuilt for more general work. It is not presented as merely the SDK with hosting added.
Hosting does not settle every orchestration policy. Asked whether multiple agents can loop and consume excessive tokens, Cemaj leaves some responsibility with the custom-harness developer. At the time of the workshop, per-session dollar and token caps were being explored but were not offered. The outcome’s maximum-iterations setting therefore should not be read as a general spending limit. A custom harness can also coordinate other providers.
Correction is possible by steering an active session: send another user message, and the system queues it for the agent. Rewinding history and replaying from an earlier point are different capabilities. They were unavailable in this recording; session forking was on the roadmap. The supported intervention adds guidance to the ongoing session rather than creating an alternate history.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Reach private data and prepare reusable environments
The final questions turn to company data and network placement. The access paths depend on where the tools and data can be reached:
- Direct tool access. Expose the required capability through an MCP server and supply authentication through a vault; the discussion also allows CLI access backed by an API.
- MCP Tunnels. Connect the company network to Anthropic’s network without exposing the MCP server to the public internet.
- Self-hosted sandbox. Run a developer-managed sandbox peered with the company network, giving its tools access to internal applications and services.
Environment dependencies are installed at creation time. The service caches that environment and reuses it when reinstantiating the sandbox, so the configured dependencies are prepared before subsequent instances run. The package-installation path described here requires dependencies accessible through registries such as npm, Cargo or pip. Files can also be uploaded directly into a session, or GitHub repositories supplied for installation that way.
The recording ends as an attendee asks about the deployments tab. Recurring scheduled sessions were introduced at the start as a way to keep analysis updating, but their configuration and execution remain for the continuation of the workshop. This part has established the research session’s working pieces: filing access, delegated analysis, saved artifacts, shared memory and a rubric-based completion check.
Suggest correction
This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.
Resources
Related talks
- Beating RL With Reflection: GEPA and Optimize Anything
Extends the discussion of learning from agent traces into explicit optimization of prompts, programs, repository skills and evaluators.
Read the complete timestamped transcript
- 0:12
Thank you for the presentation. Out of curiosity for the design of the session, in, um, first iteration and second iteration, what has changed?
- 0:22
Good question. Gabe, do you wanna take that question on what changed within, uh, the storage of the session between the first and the second iteration?
- 0:31
Um, sure. The, the, the main thing that changed was that we wanted to abstract away as many things and compa-compartmentalize them into different components, um, to make it so that we could extend the storage mechanisms for future events that we wanted to store, uh, without tying them, you know, so tightly coupled to the mechanics of the session work. Um, so we basically applied the same principle of building and virtualizing interfaces all the way down, uh, not only across service boundaries,
- 1:01
but also at the event layer.
- 1:04
All right, thank you. Um, so it sounds like maybe everyone might not be able to follow along, but hopefully, um, we can find a way to share out these slides, and you can try it out at home. Or if you have your phone, maybe you can try to pair it with your hotspot and see if you can follow along. Um, all right, so let, let's try this one more time. We're gonna say, "Build me an agent that tells me jokes every time, given a topic." And then you just
- 1:34
hit Enter.
- 1:39
And you can see Claude is coming up with a system prompt. It came up with a name, a description, chose a model. You can, like, go change this model if you want to, and then, um, gave the agent access to the agent tool set. And then you'll hit, uh, Create Agent. That should basically call the V1 agent's endpoint to create the agent. Okay, that, that got created. Next, we're gonna configure the environment, uh, which is the template for the sandbox.
- 2:12
Uh, we're just gonna create a new one.
- 2:19
And then we'll just give it unrestricted access for this one, but you can... Obviously, when you're bui-building a production agent, you, you wanna tighten the access, control which domains it can, uh, reach out to, or specific MCP servers. So we'll do unrestricted.
- 2:33
Almost like after-
- 2:35
And then here you can see, you can, like, choose packages you wanna install, um, et cetera. And then next, we'll just go and start the session.
- 2:45
All right, now we're gonna go test run our session. Uh, write, "Tell me jokes about cats."
- 2:55
And you'll see the model started thinking,
- 3:01
and it came up with a cat joke. But yeah, that, that was like a-- That, that's how easy it is for you to go build your agent. Now this, uh, agent is up and running in the cloud. All you have to do is start a session with the agent, send events, get back events. Everything else is managed by us. So we're managing all the infrastructure, the hosting, the harness, the sandbox management, the scaling, the storage of your event log, um, and then you can focus on building your product around this. Um, thank you.
- 3:31
I'll now hand it over to Gabe to do the more hands-on bit of the workshop, and hopefully, hopefully we have better wa-luck with wi-Wi-Fi. Thank you.
- 3:47
Can you hear me? Great. I see there's a bunch of people that are kind of squished in the back. There's room here and here, if you wanna come in, uh, so we can fit everybody in. Um, before we start, here's a repo that we're gonna be using. Um, so if you wanna take a picture of the QR code, Git clone that repo, um, CD into the research desk, uh, directory, and then run, uh, NPM install or bun i. Um, I'll let you do that,
- 4:17
and then I'll walk you through, through what we're gonna be building today, uh, together. Um, I still see some phones out. I know you're-- there's Wi-Fi issues. Hopefully you can, you can get, uh, you can get to the repo. Um, okay. Oh, oh, I see you. Okay.
- 4:37
Cool.
- 4:40
All right. So what are we, what are we gonna be building today? We're-- I'm gonna show you how you can use, uh, Claude managed agents to build a variety of different applications. We're gonna start with, uh, building a custom chat-like interface, so that you can talk to an agent. We can say, "Hello." Um, then we're gonna augment that agent into a multi-agent, uh, ecosystem, so that it can delegate tasks, uh, to sub-agents. We're gonna give it skills, uh, specifically a skill to be able to call, um, the SEC website and get
- 5:09
SEC filings for individual tickers, uh, and analyze specific forms. Um, then we're gonna be able to use the, these new enhanced agents to run more asynchronous, um, agentic tasks that can take a long time to run. Um, and then we're gonna bring it all together by enabling the sort of map reduce interface, where we can talk to an agent, and that agent can then delegate to many agents, uh, and do sort of like a map reduce thing, um, showing you how you can build a
- 5:39
custom harness on top of CMA to orchestrate, you know, your own work with custom tools, uh, and manage multi-session, um, kind of interactions. Uh, and then we'll finish up by... I'll show you, uh, our deployments API that allows you to set up recurring work on a schedule, so that you can run, uh, sessions, uh, on a, on a given cadence to run kind of longer term analysis that keeps updating itself. Sound good?
- 6:07
Quiet. Okay, great. Um, all right, so let's switch over to, um, a coding interface. I'm gonna be using, uh, Claude Code for this. You're free to use whatever coding agent you prefer. Uh, I don't think anybody's writing code by hand, so I'm not going to do that either. Um, there is a skill that we've loaded up in your repository that's gonna walk you through the workshop step by step. Um, so if you wanna rerun the workshop after I'm done, uh, later on when you have better Wi-Fi and
- 6:37
better internet access, uh, you're able to do so, um, at home. Um, so the first thing you wanna wanna do is, I assume you've checked out the repository, you've CD'd into the research desk repo, you've run Bun I. We're gonna spin up our, uh, server with, uh, Bun run dev. I'm gonna make this bigger. I'm assuming nobody can see. Okay, is that better? Yeah.
- 7:00
And then if you have questions while Gabe, Gabe is presenting, feel free to raise your hand and I can run to you with the mic.
- 7:06
We, we have helpers, so if you run into issues, raise your hand. People will come, um, help you, help you out. Um, cool. So if you've gone this far, you'll bas- basically be able to load this website. Uh, and the first thing you're gonna wanna do is go to the setup page. Um, everybody with me so far? Yep. Yeah? Okay. Um, now we're gonna... Yeah. Um, okay, once, uh, once, uh, the... he takes a
- 7:35
picture, we're, we're gonna start up, uh, our workshop skill. So in Claude Code, you can type in, uh, workshop start, uh, and it's gonna start running through the workshop for you. We're gonna do it in six acts. Uh, I apologize, there's no intermission in between. Um, I hope that's okay with y'all. Um, but we're gonna go through it. Uh, Claude will... Oh, uh, sure. We're gonna go into auto mode. Um, Claude, Claude is gonna keep track of each of the acts so
- 8:05
that, uh, you can continue on. You can keep typing workshop next so that it, you know, is gonna keep, uh, progressing through the, through the thing. Uh, I'm gonna ask Claude to do it for me, but handhold m- ha- handhold me and teach me what it's doing. Um, and so the first thing, it's gonna basically make sure that our prerequisites are set. Um, it's gonna copy the .env.example file into a .env.local. Um... Oh, no, stop. We're not there yet.
- 8:35
Okay. It's a little eager. Okay. It's gonna copy th- that file. That file, um, has a few values for you to fill in. You're gonna wanna paste in your API key. Um, you're gonna wanna paste in... The SEC wants to know who you are when you're calling their API, so you're gonna have to put in your name and email. Um, this is just so that they know who's calling them. Um, and then that's basically it. Once, um, once you've done all that, um, it's going to... Well, we're gonna move on to the n- to the next thing. So
- 9:05
everybody with me so far? You've put in your API key into your .env.local. You've put in your EDGAR identifier. Show of hands.
- 9:14
Give me a quick show of hands or how, how many of you are able to follow along who might have Wi-Fi or other ways.
- 9:20
Okay. Okay. We got one, one person at least, so
- 9:22
One.
- 9:25
MVP. Pardon?
- 9:29
The repo. Uh, oh, oh, for the repo. This one? That's the one,
- 9:36
yeah.
- 9:36
Uh, Rohan, you wanna hand them the mic?
- 9:38
Credentials.
- 9:39
Yeah. Thank you.
- 9:39
Yeah, the slide with the credential. That's it. The setup one.
- 9:41
This one.
- 9:42
Thank you.
- 9:42
Oh, okay. Sure.
- 9:43
And then, and then given, given people don't have Wi-Fi, ple- please, like, stop us and ask questions so we can at least make this more interactive and help you understand concepts so that you can build with your own time after the workshop.
- 9:58
Okay. Um, I'm... Yeah. I have a-
- 10:04
Is this in the GitHub or where do we have- Yeah. This is the app spinning up, uh, when you clone and CD into research desk and run Bun run dev. This is the website you will, you will get.
- 10:15
Uh, can I ask a question?
- 10:17
Yeah. I don't see you, but
- 10:18
Oh, here. Uh, I'm wondering, like, you know, so when you say Claude handle and manage the agents, where is this running? Is this running on AWS-
- 10:27
Yeah, that's a good question
- 10:28
... after all?
- 10:29
Um, so we, we, we're gonna run it in our own infrastructure. Um, today we, we have, like, a 1P offering, uh, that we run on, but we also have Claude Platform on AWS if you wanna run on AWS using your AWS credits. What we also offer, and maybe we can talk about this after this demo, is self-hosted sandboxes. So if you wanna bring your own sandbox through, uh, c- different providers like Vercel or Modal or Daytona or a bunch of others, you can do that. Uh, even, you know,
- 10:59
through Google Cloud and, and AWS, if you wanna run your sandbox in that, uh, environment, you can. Um, okay. I'm gonna continue with the demo. Um, the, the first thing you want-- The next thing you wanna do is create, push this button, which is gonna create, um, your agent. So it's gonna create two things for us. Um, an environment, which Priyanka talked about, is a template of what the sandbox is gonna look like. Um, for this demo, we're gonna give it access to a few websites that it can reach out to, mainly the
- 11:28
SEC. We're gonna add, uh, some Python packages so that it can reach out to, to, uh, the SEC with, you know, some predefined, uh, Python packages. Um, it's also gonna create, uh, an agent. So it's gonna create this very basic agent. Right now it has no tools. Um, it has, uh, just a prompt. Uh, well, it has the basic tools, but there's no skills, there's no sub-agent coordination, nothing like that. Um, I'm gonna tell Claude to Um,
- 11:59
continue and implement the interface with which we can talk to this agent in our application. Uh, like Priyanka mentioned, the main, uh, way you communicate with a session is through an event stream. So you listen onto that stream for all the events that the agent is pushing back down to you, and you can use that as, uh, an endpoint to push events back up. So really, everything that happens in the communication for these more chat-like applications happens on that stream. So we can see here what Claude is doing is it's,
- 12:30
uh, implementing the section so that when I press enter in my chat box, it's gonna send the user.message event with the content that I'm sending to that session. And then it's gonna route the SSE stream back onto my browser from my back end. So it's gonna listen onto, um, the events that are coming in the s-stream connection to our API and then restream them directly back onto the front end so that I can render them in a nice way. Um, and once Claude has done that, we
- 12:59
should be able to go to this desk tab and just say hi to our agent. Um, and if everything worked...
- 13:10
Hopefully. Great. Um, so we can see here now we're, we're talking to our agent. If you wanted to build a chat-like application, this is where you would stop, um, which is great, but we wanna do more. The whole point of Claude Managed Agents is that you can do long-running asynchronous tasks, um, not just for minutes, but hours, days, weeks, and even months. Um, so let's see what we, we have to do next, right? The next thing that we're gonna wanna do is, um... Oh, Claude is very
- 13:40
eager today. Um, okay. The next thing is we, we wanna augment our agent, right? We wanna give our agent the skills so it can call the SEC. We wanna use multi-agent coordination so that, um, our session can delegate work to subagents that are more specialized and capable of doing some tasks. Um, and we wanna basically move up the ladder of intelligence. Um, so let's do that, um, by saying, uh, workshop next. Um, now what Claude is gonna do
- 14:10
is it's gonna implement the provisioning scheme to upgrade our agent so that it uses, uh, more subagents or any subagents. Um, is we're gonna give it a skill, a skill that lets it, uh, um, talk to the SEC. We've described how to use the Python package. We've described that it has to use the EDGAR identity to call. Um, we've, we've described all of that. And we're gonna give it a custom tool, uh, for later in the workshop. Um, that custom tool is
- 14:40
what we're gonna be able to use to tell our head of research agent to spin off multiple sessions that we will coordinate, uh, for a, a sort of custom harness. So this is what Claude is doing here. Um, it's updating its progress, creating this custom tool called dispatch analysis. We're gonna come back to this in a second. Um, we give it a schema. Um, it's going to update the, the description of the main agent so that it creates a new version of that agent. Uh, this new version will have,
- 15:10
um... Oh, pager duty. Um, uh, this new version will have, uh, a few different subagents, uh, that it can delegate work to, as well as a reference to itself. So if the main agent ever wants to spin off a copy of itself with its same prompt, it can do that. Um, this is important because, uh, sometimes you don't necessarily know what sort of tasks your session's gonna wanna do, but you have a general, uh, idea that you wanna have subagents that, you know, spin up and
- 15:40
do work. Uh, so you can define a self-reference to y-you know, yourself, that Claude can then spin up a subagent for. Um, important-- This question has come up in the past. It doesn't copy the transcript of that session into the subagent. It just copies over the tool description and the schemas, uh, and the prompt, uh, into, into that subagent. Um, cool. So now, if we go into here, we should see that there's a new agent.
- 16:11
Oh, I think I need to provision them. So there should be a button in our setup, uh, that says staff to desk. When I do that, it's actually gonna run... Oh. Uh, uh, okay. I ran this before. Let me delete the skill so that I can recreate it for you. Um, I was trying to do the magic, uh, cook show thing, but that's fine. Um, okay, so we'll delete the skill. We'll ask Claude to reprovision it. Um, it's gonna create all those resources, and then we'll
- 16:41
be able to see here all the subagents, the skill that we created, um, a memory store. So for these sessions, we, we, we also support, um, long-running memory store that can be shared across sessions. Uh, and we're gonna use that so that different sessions can learn about different financial instruments, and they can share that knowledge, uh, with each other. And at the end of this workshop, I'll show you how you can use that memory, long-running memory to keep improving your agents long term over many, many, uh, sessions, days, months, years.
- 17:12
Um, cool. So we should see here that the agent now, right here, um, has the skill that we described. It has subagents, uh, with their own prompts and tools and permissions. Uh, it has a prompt, and it has a model. Um, and I think we're, we're ready to use this new dedicated subagent to do our first asynchronous long-running task. So let's, uh, tell Claude
- 17:42
to move on to the next thing. The next thing that we wanna do is, um, we wanna tell Claude, not in a chat-like application, but a more asynchronous thing, "Hey, research this financial instrument and give me a report in a format that I define and I care about." And we're gonna use something called Outcomes. Outcomes is how we've created self-supervision. So in an Outcome, you tell Claude, "This is your task. This is your rubric to evaluate your task." It's gonna go off and do that work, and then when it thinks it's
- 18:11
completed, it's gonna ask a sub-agent to look at the rubric and the work that it-- Claude did, uh, and evaluate did it do it correctly and did it do it to completion. Uh, if it does, then great, and if it doesn't, it will try again. Um, so here what Claude is implementing for us is basically this user-defined outcome event so that anytime we start a session in our UI that I'll show you for a specific ticker, it's gonna send this user-defined outcome with a specific rubric,
- 18:42
uh, max iterations, um, and a description of the task at hand. And so, then Claude will go run that task for us. Um, and so what does that look like in the UI? If you look to this scorecard, um, I can tell Claude, "Hey, I, I wanna analyze NVIDIA." Oh. Please.
- 19:06
Okay, great. So it's gonna kick off a session to do the analysis on NVIDIA. Um, this is gonna take a while. I'm gonna do the cook show thing and show you a previous session, um, of what, of what happened. Uh, it's gonna take about ten-ish minutes. Um, but here's something I ran yesterday. Uh, the first thing we're telling Claude is, "Here is an outcome. I want you to analyze NVIDIA's most recent, uh, SC-- you know, quarterly filings. Um, you're gonna use EDGAR identities. This is where your EDGAR identities are. Um,
- 19:36
you have memory, so check if you've already done analysis previously and make sure that you use that instead of refiling and researching things that you already know. Um, I want you to find the most, uh, recent form that, that I care about and run any analysis over that. Um, and then I want two deliverables. I want you to write a note in, in my memory, um, for that specific company, and I want you to write a scorecard in a well-defined, structured output, and I want you to save that in
- 20:06
a specific file location." Um, so then Claude went off to work, started calling tools. It didn't find any notes in its memory store. Um, it, uh, looked in a few different places, and then it decided, "Okay, I know what to do. I'm gonna leverage my sub-agents to do the bulk of this work. Um, I'm gonna spin up a financial, um, expert analysis agent, uh, or extractor, and then a risk evaluator analysis." And you can see all of that
- 20:36
in the, uh, console here for full observability. Each of these lines here represents a thread, and a thread represents the work done by a sub-agent. And so each of the sub-agents went off to work, and then when they were done, they let the main agent know, "Hey, this is what you asked of me." Uh, and then the main agent woke up, uh, got that information from the sub-agents, and then, uh, filed everything it needed to do and created the deliverable. It created the JSON file that, you know, we specified, uh, and it made sure to update
- 21:06
the memory. And then the self-supervision started. So it kicked off a sub-agent to verify that the outcome that we define is being met. Um, it looked at the rubric, it analyzed all the work that was done, uh, in the session, and analyzed the artifacts that it created. Uh, and it, uh, decided in the end that this was satisfied. That the s-- you know, scorecard was delivered, uh, that the numbers are well-defined, uh, that the memory update, you know, was correct, um, and everything looked good.
- 21:36
Um, I don't-- I think this is still running, but once that completes, uh, you would see a table here of each of those tickers, um, because we can extract the report, the scorecard from the session and download it. You put it in a database. For this demo, we put it locally, um, but I think you get the idea. Um, okay, this is great, but what if you wanna do a hundred or, or ten tickers at a time? Wouldn't it be great if I could chat with an agent to build a custom harness that could then delegate
- 22:06
work, uh, for each of the tickers into a different session, and then when it's all done, aggregate the results and give me, uh, a bunch of scores? Um, so that's, that's what we're gonna do next. Um, we're gonna leverage that tool, the custom tool that we created to build our custom orchestration harness in our server, um, where when we talk to our main agent, at some point, that main agent is gonna decide, "Hey, I wanna spin up, uh, ten different sessions to do work." Um, we'll get that-- Oh, I
- 22:36
skipped a step. Sorry. Um, for-- We're, we're gonna update the skill, uh, first. Um, so I, I want to show you that these skills are, are live artifacts that you can update. Um, so you can improve the skill. Uh, in this case, uh, we're adding the ability to look at a new form. Uh, and then when you do so, any new sessions that, uh, reference that skill will get that new information. Um, so this is something that you can continuously update. You can look at previous sessions to see how they performed. We're
- 23:06
gonna see that, uh, at the end of this, uh, demo that, that happens with, with something we call dreaming. Um, but yeah, this, this is what is happening. Um, okay, I'm, I'm gonna move on to the orchestration bit. Um, so now that, yeah, that-- basically that skill is published. Um, I think if I go here, we should see-
- 23:28
Any, any questions so far? Um, I know this is a lot to take in. Uh, Travis, there's a question over here. Yeah.
- 23:42
Um, and I, I know someone came up to me asking about, like, how long it takes to get the credits. It should be only five minutes. Um, I know the form says one to two days, but you should see it within five minutes.
- 23:53
Um, I was curious about the, the data access, uh, from the SEC that the, the research agent is grabbing. Does that require some sort of credentials, and are you gonna walk through the part of how the-- how that credential injection or, or brokering works?
- 24:08
Yeah. So for, for the SEC, it just requires your email and your name. Um, for this demo, we just inject that in the prompt. But in a real production application, we would use something called vaults. Uh, the way vaults work is you define a secret, uh, that you wanna u-- inject in an environment variable. And instead of putting the real secret in, what we put is a, is a placeholder. Uh, and then when Claude is doing work and it wants to use that environment variable, um, it just injects the placeholder value. We at egress
- 24:38
swap it out for the real value only on the host domains that you specified are allowed for that secret. So if you say, uh, "My super secret env var can only be used for the SEC," and then Claude tries to use it for anthropic.com, we wouldn't inject, we wouldn't do the swap. But when it tries to call the sec.com, it would do the swap for that.
- 24:59
And Vault is essentially like an API where you can use it on console, where you just go create a Vault, give it a name, you'll get an ID, and then you essentially include that ID in your session as a way for us to authenticate with your MCPs, your CLI. You... For example, you could do like a Google Workspace CLI that you install on your, um, sandbox, and then you can give us like your API key as your environment credential, and again, we'll, we'll kind of follow the same method that, uh-
- 25:23
Well-
- 25:23
... Gabe talked about. So that, that allows us to essentially have that credential.
- 25:26
Well, Vaults also work with OAuth credentials for MCPs.
- 25:29
Yeah.
- 25:29
And they also work-
- 25:30
Gabe, I don't know if you wanna just show it on, on console, like, uh, the, uh, quickly, like the Wal- Vault creation.
- 25:36
Yeah. Um-
- 25:37
As well
- 25:37
... so you can, you can create a Vault here, and then in a Vault you would bundle credentials. Um, so you can have MCP auth. Um, maybe you do Notion. You know, we have a few predefined things for OAuth things. Um, so whenever you reference a session, you inject that Vault ID and it will bundle all the credentials into your session, and whenever it tries to use any of the domains that you specify in your credentials, it will swap for the real, um, credential instead of the placeholder.
- 26:07
Thank you.
- 26:08
Yeah.
- 26:08
Um, quick question. What part of the capabilities in the Claude Agents SDK and what's about it?
- 26:16
Can you... What, what do you, what do you mean?
- 26:18
You, you have the Agent SDK, right? Uh, presumably this is built on top of the Agent SDK. I want to know what part of the capabilities are in the Agent SDK layer, and what's outside of it.
- 26:27
So the, the Agent SDK is packaged for, uh, like m- more, more... It's like a headless Claude code version. So it's actually, we've built a generic version of that. We've tak- taken a lot of inspiration about the benefits and lessons from the Agent SDK, but we've rebuilt, uh, the harness to be a more generic, not just coding specific thing. Um-
- 26:47
So it's sort of a fork?
- 26:49
Uh, yeah.
- 26:50
Yeah. It, it's basically like its own harness. Agent SDK is basically like a Claude code in the form of a binary that you can take and run wherever you want. This is a fully hosted solution running in our cloud, and we have our own harness that's heavily inspired by Claude Code's harness, and we frequently stay, stay in touch for like any enhancements across the board. Uh, I, I saw another hand in the, in the back, uh, over there.
- 27:13
We, we have a question here. Yeah.
- 27:15
A couple more.
- 27:15
Thank you. Uh, I guess the question as you're orchestrating between multiple agents, um, is there some guardrails that those agents would not go into loops and like consume a lot of tokens, um, as they're generating or working together?
- 27:28
Um, some of that we leave up to you to orchestrate and figure out. I mean, we're... If you're building these sort of custom harnesses, there's nothing stopping you from using, uh, like other providers if you wanted to do a sort of multi- uh, multi-provider system. Um, we are exploring the idea of what it means to do like budget, tighter budget controls, so that you can say, "Use no more than this amount of money per session. Use no more than, uh, this amount of tokens per session." Um, but that's not something we offer today.
- 28:00
Um, yeah, go ahead.
- 28:01
Couple more hands.
- 28:03
Question. Uh, earlier you were showing us in console kinda a transcript of the manager and then the sub-agents, and you could kinda go through and see what they were doing. If you were to come across maybe, uh, a mistake or like it was going down the wrong path or you wanted to change history, I mean, obviously that's-
- 28:20
Yeah
- 28:20
... what's happened, is there some way to correct it or to kinda go back to that point in time and kinda start over, try it with some additional guidance? Is there any- anything like that in here?
- 28:30
You can steer it. So I could, I could, uh, I think here if I say, uh, send event, I could send a new user, uh, .message_event and steer the agent. Uh, it'll queue it up. It's, you know, you can send the 10 messages at a time and it's fine. We don't currently have a way for like rewind and roll forward, um, but that's definitely something that, uh, if, if people are interested, we, we would look into.
- 28:52
Yeah. S- session forking is essentially what you're asking for.
- 28:55
Yeah. Yes, yes.
- 28:55
We've, we've had a couple, a, a few customers who have asked around that. It's, it's, it's on our roadmap, so hopefully we'll have it at some point.
- 29:02
Thank you.
- 29:03
Uh, yeah, I see a couple hands here. If you wanna hand... Yeah. Thank you, Rohan.
- 29:08
Oh. S- so-
- 29:11
Where are you? Okay. Okay. Okay. Yeah, go ahead.
- 29:14
Assuming all of this is running in the cloud-
- 29:16
Yeah
- 29:16
... like, like, you know, um, you gu- you guys have any roadmap to get collective knowledge across these agents? Like, like say in this one particular application you have 10 users-
- 29:26
Would, would you mind speaking up? It's a little hard to hear.
- 29:29
Oh. So, so if you... Assuming all of this is running in the cloud-
- 29:33
Mm-hmm
- 29:33
... and this application is being distributed across tens and hundreds of users, and all of them are using it for the purposes of like, you know, doing this financial research, do you have... I, I know you guys have session logs. Is there a collective-
- 29:46
Yeah
- 29:46
... memory that you guys are looking into or even have a roadmap of?
- 29:52
We have it today. We actually used it in this demo. So we use the m- a memory store, um, that allows you to share knowledge across sessions. Uh, and you can see here that what's happening is, um, the agents are each populating individual information about what they've done so far. Um, and then I'll show you at the end how you can consolidate that knowledge over time using dreaming so that you can continuously improve the memory stores as different agents run into different edge cases and collectively learn from each other.
- 30:22
S- s- just to follow up on this, so you're storing this in Anthropic's infrastructure.
- 30:27
That's right.
- 30:28
Let's say if you wanna- delineate that and, and have things running in AWS Bedrock, and I have my own, like, uh, data on our clusters or something for sandboxing. Then you mentioned about self-hosting. How much of a lock-in is this piece versus, like, how flexible is it?
- 30:44
So all of this is API-based, so you, you can extract the memories and put them in different systems if you want to. We don't currently support out of the box other memory providers in the session, but you would just build an MCP or a custom tool to do so. It's the way I would imagine doing it.
- 31:02
A- and also to add to your initial question about, like, having user level org level memory, we do allow for attaching multiple memory stores. So you can imagine having a user level memory store and then having some sort of org-wide memory store, and then you bring both to each session, so you can start collecting user level, uh, as well as org level memories. And then, like Gabe said, n- none of this is locked in. You can, like, take your data and go anywhere else if you wanted to. Ev- everything is an API call.
- 31:29
Yeah.
- 31:29
Um, I had a quick question. As you walked through the agent workflow, I noticed that the, a grader is at the main agent level, right? Like, so how do you grade these sub-agentic tasks that are happening, and then how do you manage memory across those as well?
- 31:45
That's a good question. So, uh, there's two dimensions to this. Sub-agents, in the way that we've built them, are meant to, uh, augment your context and leverage the capabilities of your mo- of your session by collaborating between them. Uh, the outcome definition happens at, like, an overall arching, uh, session level. So you define the outcome, and you say, "This is what I want you to accomplish." The main agent then use it, you know, use the sub-agents to accomplish that work. It collaborates between them, and it eventually
- 32:15
says, uh, "I'm done." Um, there is no currently support for, like, a sub-outcome definition.
- 32:22
Quick follow-up. Like, so as you have this dreaming feature, right? Like, so how do you learn? Like, if the sub-agents have some sort of, you know, uh, you know, off-course sort of actions, then how do you sort of learn from that?
- 32:34
Yeah. Uh, today the dreaming's constrained to, uh, memory stores. So I'll, I'll show you that, uh, uh, in, in a second. But basically the way dreaming works is it will analyze the transcripts and the memories created across multiple sessions, uh, so that it can update its memory so that future agents know what to pull. Um, but you can imagine that we can continue to expand that for skills and for prompts and for agent definitions so that you can... You have this continuous learning, uh, functionality. But right now we just have it for,
- 33:04
for memory stores.
- 33:07
I see a hand here, and then I'll, I'll, I'll go back to-
- 33:10
Hi. Hello.
- 33:11
Yeah.
- 33:12
Here.
- 33:12
Where, where is here?
- 33:13
Here.
- 33:14
Oh, hi.
- 33:15
Thank you. Uh, if you have your, let's say, company data in either, I don't know, traditional store or RAG or whatever, and you want to expose it to these type of agents through a custom CLI or MCP, what would be the safe path to put it in your environment?
- 33:32
Yeah, that's a great question. There's two, two ways to do this. If you are using-- If you can access that, uh, via CLI with an API or via, uh, an MCP, uh, you would just create an MCP, give it, uh, give it the authentication vault, uh, and it would just be able to call your MCP directly. If you don't wanna expose your MCP to the internet, we have a feature called MCP Tunnels, which lets you, uh, create a tunnel from your, um, network into ours so that you don't
- 34:02
expose it to the internet, and we would do it that way. If, if that's, uh, too big a barrier to climb, we do support self-hosted sandboxes so that you can bring your own sandbox, which has-- which is peered with your network and has access to your applications and services, and the agent would just call the sandbox that you manage and host, um, and be, uh, be able to access your, your resources that way.
- 34:27
Yeah.
- 34:28
Um, I had a question on dependencies for the environments. So I saw something you could load in dependencies. Um, is that at runtime or right before, um, it's created?
- 34:40
It- it's at creation time, uh, and then we'll cache it and reuse, uh, that environment across, like, re- reinstantiations of the sandbox.
- 34:49
So can you specify, like, internal dependencies, or do you have to pick NPM package?
- 34:54
Right, right now, uh, they are all-- they all have to be accessible via NPM, Cargo, uh, PIP, whatever. But you can upload files, uh, directly into, um, the session if... or GitHub repos if you wanna install them that way.
- 35:10
Okay. And one more thing, uh, deployments. I see a tab for that.
- 35:13
Yeah, yeah. I, I'm gonna get to it. I'm gonna-
- 35:14
We're gonna get to that
- 35:15
... I'm gonna continue to the-- with the demo, and then we'll, we'll do more questions in a second.