Creates a new AgencyRegistry instance.
Optional logger: ILoggerOptional logger for diagnostics
Creates or updates an agency session associated with a workflow.
Upsert payload containing workflow linkage, memory config, and optional metadata.
The upserted agency session.
const session = registry.upsertAgency({
workflowId: 'workflow-123',
conversationId: 'conv-456',
memoryConfig: {
enabled: true,
autoIngestCommunications: true,
},
});
Retrieves an agency session by identifier.
Target Agency identifier.
The matching agency session or undefined when absent.
Resolves the agency session associated with a workflow instance (if any).
Workflow instance identifier.
The agency session mapped to the workflow, if present.
Registers or updates a seat inside the agency.
Seat registration payload.
Updated agency session after the seat registration.
When attempting to register against an unknown agency.
Appends a history entry to the specified seat and returns the updated state.
Merges metadata onto a seat without altering other properties.
Tracks the Agencies (multi-GMI collectives) active inside the AgentOS runtime.
Remarks
The registry is intentionally ephemeral; durable state should be captured via workflow persistence. For shared memory, use AgencyMemoryManager.
Example