/** * `/agents`: what can be spawned here, and where each definition came from. * * The same failure `/flows` answers for flows: an agent that lives in one * repository is invisible from another, and until now the only way to find out * what was loaded was to mistype a name and read the error. Scope is half the * answer, so it is what the listing is built around - three sources, most * specific first, each with the directory it was read from. */ import type { Agent, AgentSource } from "../../src/index.ts"; import type { CommandCtx, PiApi } from "../pi.ts"; import { type CommandDeps } from "../deps.ts"; /** One source, with what it contributed to the roster. */ export type AgentGroup = { source: AgentSource; where: string; agents: Agent[]; }; /** Registers `/agents`. */ export default function registerAgentCommands(pi: PiApi): void; /** * The roster split by source, in precedence order. * * A name defined twice appears once: `loadAgents` already applied precedence, * and the group it lands in is the one that won it. That is the point of * showing the source at all. */ export declare function groupAgents(agents: Agent[], cwd: string): AgentGroup[]; /** * The listing, as lines. * * Kept away from the terminal so it can be asserted on directly, the same split * as `/flows` and the run picture. */ export declare function agentLines(agents: Agent[], cwd: string): string[]; /** `/agents` - what is loaded, and from where. */ export declare function listAgents(ctx: CommandCtx, deps?: CommandDeps): string[]; //# sourceMappingURL=agents.d.ts.map