Chapter 22. Hosted Agents: Claude, OpenAI and Open Source
In this section
- Chapter 22. Hosted Agents: Claude, OpenAI and Open SourceMove the AP worker off the builder's laptop and into Brightline's own portal. Someone else runs the loop, the tools and the sandbox. Your product decides which person, which company, which tools and how much a run may spend. Taught through the four resources of a hosted agent, permission policies, a sandbox with one open door, three identities, vaults that hold each person's own token, refresh and its refusal, budgets, schedules and webhooks. Built by coding agents on Claude first, then ported to OpenAI and to an open-source runtime.
- 22.1 The worker leaves the laptopWhat moves when the AP worker's loop runs on someone else's servers, what stays the builder's, and why a hosted agent is not yet an AI Worker.
- 22.2 Four resourcesThe agent definition, the runtime environment, the session and its events: which are made once and shared, and which one names a person.
- 22.3 Reading a session: events and stop reasonsA session's events and its stop reasons, read from the log alone: finished, needs action, or budget reached.
- 22.4 Resources as codeThe agent and its environment kept as reviewed files and applied with a plan and a lock file, so a change made outside the files is refused.
- 22.5 A budget on every runA dollar cap on every session, checked between model calls, and what becomes of the loop's turn and time limits.
- 22.6 What travels: your skills, connectors and pluginsWhich parts of the plugin travel to a hosted worker, its skills and connectors, and which stay with the app they were made for.
- 22.7 The sandbox and its networkEach session's own small computer, with its network limited to the hosts on an allow list, and why every host on the list is a whole open door.
- 22.8 Permission policies: allow, ask, decideAllow, ask and decide for each tool, the defaults for connector and built-in tools, and why only ask puts a person behind the call.
- 22.9 Three identities, never oneThe product, the worker and each person get their own identity, each with only what it needs, and why one identity for everything is the mistake.
- 22.10 A vault per person and companyEach person's own token in a vault per person and company, added to connector calls on the way out, and never seen by the model.
- 22.11 One session, one person, one companyThe server chooses each session's vault from the signed-in person, one vault per connector per session, and a session matrix proves every rule.
- 22.12 The portal's own pagesTwo rules for the portal's pages: a session belongs to the person who started it, and nothing from a session runs in the page.
- 22.13 Keys that expire, and no keys at allStored keys with an end date and a spending cap, and workload identity, where a program proves what it is and no key is stored.
- 22.14 When a refresh is refusedRefresh, rotation and a refusal for good, and how the portal turns a refused refresh into "sign in again" instead of an error.
- 22.15 Schedules and webhooksScheduled runs in a named time zone, and webhooks that are checked, deduplicated, fetched and reconciled.
- 22.16 Loops: check, feedback and stopAn outer loop that prompts the worker for you: a trigger, a check by code, specific feedback, and every way the loop stops.
- 22.17 Patterns, and when to host it yourselfPatterns inside a session, the three places a worker can run, and when to run the loop yourself.
- 22.18 Designing a hosted worker: the four disciplinesContext, harness, graph and loop design on a hosted worker: what hosting runs for you, and what you still decide.
- 22.19 How today's tools realize itHow Claude Managed Agents, OpenAI's Agents API and the open-source Omnara realize the chapter's ideas, and the differences that change a decision.
- Chapter 22 reference: hosted agents, in detailThe companion page to Chapter 22. Beyond this chapter (nervous systems, other organizations' agents, standing assistants), today's products for that section, every word the chapter uses with the kinds of token, and the field guide (F0 to F7) that the lab's tasks point to.
- Lab 22: the AP worker in Brightline's portalThe lab for Chapter 22. Coding agents write every file, and you specify, predict, check and approve. Six sittings, each done right after its part of the chapter. Milestone 1 in about 6 hours 20 minutes, Milestone 2 in about 6 hours more.
- Check yourselfTwenty-four questions with outlines for the whole chapter, the flashcards, and a final quiz round.