/** * CleoOS Agent Registry — catalog of installed agents across all provider adapters. * * Discovers agents from two sources: * 1. **Seed agents** — canonical SSoT at `packages/agents/seed-agents/` (T889). * 2. **User agents** — installed by individual provider adapters into their * provider-specific agent directories (e.g. `~/.claude/agents/`). * * This module is read-only. It does not install, remove, or modify agents. * Provider adapter logic stays in `packages/adapters/`. CleoOS consumes the * filesystem artifacts that adapters produce. * * @remarks * Long-term: `loadUserAgents()` should call `adapter.paths?.getAgentInstallDir()` * dynamically once T639 exposes the provider-folder contract. For now the 9 paths * are hard-coded from each provider's `AdapterPathProvider` defaults. * * @see ADR-050 — CleoOS Sovereign Harness: Distribution Binding Charter * @task T640 * @epic T636 * @packageDocumentation */ /** * A single agent known to the CleoOS agent catalog. * * Agents are discovered at runtime from seed directories and provider-specific * agent installation folders. The `source` discriminant distinguishes bundled * agents from user-installed ones. */ export interface AgentDefinition { /** Stable unique identifier for this agent (derived from file name sans extension). */ id: string; /** Human-readable display name (defaults to `id` when no metadata is available). */ name: string; /** * Provider that manages this agent's execution context. * * One of the 9 known CLEO provider IDs: `"claude-code"`, `"claude-sdk"`, * `"codex"`, `"cursor"`, `"gemini-cli"`, `"kimi"`, `"openai-sdk"`, * `"opencode"`, `"pi"`. Seed agents use `"cleo-os"`. */ provider: string; /** Absolute path to the agent definition file on disk. */ path: string; /** * Free-form capability tags describing what this agent can do. * * Common values: `"spawn"`, `"orchestrate"`, `"memory"`, `"review"`, `"test"`. * May be empty when no metadata file is available. */ capabilities: string[]; /** * Origin of this agent definition. * * - `"seed"` — canonical SSoT under `packages/agents/seed-agents/` (T889) * - `"user"` — installed by a provider adapter into its agent directory */ source: 'seed' | 'user'; } /** * Read-only catalog of CleoOS agents discovered across all provider adapters. * * Combines seed agents (bundled with CleoOS) with user-installed agents from * each of the 9 provider adapter directories. Results are deduplicated by * `path` — a path present in both sources appears once as `"seed"`. * * @example * ```ts * const registry = new AgentRegistry(); * const all = await registry.listAll(); * console.log(all.length, 'agents discovered'); * ``` */ export declare class AgentRegistry { /** * Load seed agents bundled with CleoOS. * * Reads `packages/agents/seed-agents/` (canonical SSoT post T889) and returns * one `AgentDefinition` per agent file found. Returns an empty array when * the directory is absent or empty. * * @returns Array of seed agent definitions; empty if none are installed. */ loadSeedAgents(): Promise; /** * Load user-installed agents from all known provider agent directories. * * Iterates the 9 provider adapter directories and returns one * `AgentDefinition` per agent file found. Directories that do not exist * or are unreadable are silently skipped. * * @returns Array of user agent definitions across all providers. */ loadUserAgents(): Promise; /** * Return all known agents — seed agents followed by user-installed agents. * * Seed agents take precedence: if the same absolute path appears in both * sources (uncommon but possible in development), the seed entry wins and * the user entry is omitted. * * @returns Deduplicated array of all discovered agent definitions. */ listAll(): Promise; } //# sourceMappingURL=agent-registry.d.ts.map