/** * Shared v3 bot resolution — selector → BotConfig → BotSnapshot. * * The daemon-driven run path (`daemon-run.ts`) and the standalone CLI path * (`cli-run.ts`) both turn a `--bot`/node.bot selector into the `BotSnapshot` * the runtime freezes per node. This module is the single source of that * matching + working-dir fallback so the two entries can't drift. * * (cli-run.ts currently keeps equivalent local copies — codex's runtime file, * which this feature doesn't touch; dedupe it to this module next time that * file is edited.) */ import { type BotConfig } from '../../bot-registry.js'; import { type V3Dag } from './dag.js'; import { type BotSnapshot } from './contract.js'; export declare function resolveBotConfig(selector: string | undefined, bots: BotConfig[]): BotConfig; /** The configured working dir for a bot, before `~` expansion (the pool * expands). An explicit override wins over the bot's configured value. */ export declare function botWorkingDir(bot: BotConfig, override?: string): string; /** BotConfig → BotSnapshot (the runtime-frozen, secret-free per-node identity). */ export declare function botToSnapshot(bot: BotConfig, workingDirOverride?: string): BotSnapshot; /** * Resolve every selector used by a DAG exactly once. Keys intentionally mirror * the runtime contract (`''` means the DAG's default bot); loop-body nodes use * their own selector or inherit the loop selector. */ export declare function freezeDagBotSnapshots(dag: V3Dag, bots: BotConfig[], opts?: { defaultSelector?: string; workingDirOverride?: string; }): Map; /** JSON-safe persisted shape used by `bots.snapshot.json`. */ export declare function serializeFrozenBotSnapshots(snapshots: ReadonlyMap): Record; /** * Validate the secret-free pinned bot snapshot artifact before a retry/resume * can hand it to the runtime. Unknown keys fail closed so credentials or * mutable permission flags cannot quietly creep into this run contract. */ export declare function parseFrozenBotSnapshots(raw: unknown, dag?: V3Dag): Map; //# sourceMappingURL=bot-resolve.d.ts.map