Skip to main content
Share selected persistent stores when multiple Agents need the same verified user’s facts. In v4, TeamConfig.memory is present in the public type, but the Team implementation does not wire a shared memory manager into members. Configure memory on the member Agents explicitly.

How It Works

Agents using the same appropriately scoped storage can read records saved by the same memory subsystem. That does not mean all records become globally visible: user facts use user IDs, sessions use session IDs, and learned/procedural records have their own sharing rules. Background extraction may still be pending when another member starts.

Configuration

This host factory accepts a storage driver that is already scoped to the authorized tenant. Each Agent receives its own memory manager backed by that same driver. The host initializes shared storage before use and closes it once after the members drain.
Call team.run(input, { sessionId, userId, tenantId }) with verified identity and an owned session. The Team derives separate member session IDs. The returned close() drains the members; it deliberately leaves host-owned storage open.

What Is Shared vs. Per-Agent

Overriding Memory per Agent

Give a member a different storage driver or narrower feature set when it needs separate state. Sharing a connection is not a reason to share all namespaces. A host should avoid concurrent unsynchronized mutation of the same records by different memory-manager instances; use an application scheduling or storage contract appropriate to that workload.

Verify sharing

Write a reviewed fact for Alice through one member, await persistence, and read it through the other. Repeat as Bob and as a different tenant. Test session history separately from cross-session facts. Model answers alone are a weak isolation test; inspect the scoped records and context as well. For facts that must be visible immediately, write them explicitly in host code rather than depending on asynchronous model extraction. Continue with isolation and Agent memory.