/** * The subagents a flow's memory scopes hold: one per agent per scope, shared * by every node naming both. * * A subagent is spawned with its tools, so the `submit` tool it answers a * typed node with is fixed for its whole life, and the nodes sharing it must * agree on what they submit. That is read here, from the checked nodes alone: * the check stage refuses a disagreement, and the runner builds the one tool. */ import type { CheckedAgentNode, CheckedNode } from "./checked.ts"; import type { FaultList } from "./fault.ts"; import { type ValueType } from "./type.ts"; /** The key of the subagent `agent` keeps in `scope`, a node id or `flow`. */ export declare function sharedKey(scope: string, agent: string): string; /** The names of the agents a node may run: one, or every agent `among:` names. */ export declare function agentsOf(node: CheckedAgentNode): string[]; /** Every node with a `memory:` scope, by the subagent it shares. */ export declare function sharedSubagents(nodes: readonly CheckedNode[]): Map; /** What a shared subagent submits: the output its typed nodes declare. */ export declare function submitted(sharing: readonly CheckedAgentNode[]): ValueType | undefined; /** Refuses nodes that share a subagent and declare different outputs. */ export declare function checkShared(nodes: readonly CheckedNode[], faults: FaultList): void; //# sourceMappingURL=memory.d.ts.map