import type { ToolSpec } from "@sema-agent/core"; import { type SandboxImageResolver } from "../per-task-image.js"; import type { ImageViewer, ImageIndexEntry, ImageListFilter } from "../plugins/store-contracts.js"; /** The catalog slice the tool needs: fail-closed resolution + the viewer-scoped published listing. */ export interface EnvironmentCatalog extends SandboxImageResolver { list(filter: ImageListFilter): Promise<{ entries: ImageIndexEntry[]; nextCursor: string | null; }>; } /** Session-keyed selected PROFILE (intent). Mirrors PerTaskImageRegistry's bounded-eviction shape, but holds * the profile string so every subsequent task re-resolves fail-closed (re-admit discipline). In-memory — * honest v1 boundary: a worker restart drops the selection (the model can re-select; nothing fails closed * the wrong way, the session just falls back to the worker default image). */ export declare class SessionEnvironmentSelection { private readonly bounded; constructor(maxEntries?: number); set(sessionId: string, profile: string): void; get(sessionId: string | undefined): string | undefined; } export declare function selectEnvironmentTool(deps: { catalog: EnvironmentCatalog; selection: SessionEnvironmentSelection; /** Trusted viewer scope derived from the AUTH channel at spec-prep (never from tool args/ctx besides the * read-only ctx.principal the Runner threads) — built per-execute so operator/tenant scoping stays live. */ viewerFor: (principal: string | undefined) => ImageViewer; }): ToolSpec; //# sourceMappingURL=select-environment-tool.d.ts.map