import { ReactElement } from 'react'; import { a as AgentHostAgentSessionComposerSettings } from './agentSession.d-4jwjFmc1.js'; import { d as PlanIssueBudgetPreset } from './planImplementationPresentation.d-BxVOLt6A.js'; interface AgentGUINodeData { provider: AgentGUIProvider; agentTargetId?: string | null; lastActiveAgentSessionId: string | null; lastActiveAgentSessionIdByAgentTargetId?: Record | null; conversationCount?: number | null; conversationRailWidthPx?: number | null; conversationRailCollapsed?: boolean | null; composerOverrides?: AgentHostAgentSessionComposerSettings | null; composerOverridesByAgentTargetId?: Record | null; composerOverridesByProvider?: Partial> | null; /** Remembered defaults for provider Plan decomposition review. */ planIssueBudgetPreset?: PlanIssueBudgetPreset | null; } /** * Open runtime metadata reported by an Agent Target. * * Built-in providers still use AgentProvider, while externally installed ACP * extensions use namespaced values such as `acp:gemini`. */ type AgentGUIProvider = string; /** * Stable identifiers for the starter entries shown below the empty new-session * composer. Hosts can pass these values to `AgentGUI.disabled` to hide entries * that should not be available in their integration. */ type AgentGUIHomeSuggestionId = "meet-tutti" | "clone-github-repository" | "task-breakdown" | "quality-review" | "agent-interaction" | "import-session"; type AgentGUIAgentAvailabilityStatus = "ready" | "checking" | "coming_soon" | "not_installed" | "auth_required" | "unavailable"; type AgentGUIAgentAvailabilityAction = "install" | "login" | "refresh"; interface AgentGUIAgentAvailability { status: AgentGUIAgentAvailabilityStatus; reason?: string | null; pendingAction?: AgentGUIAgentAvailabilityAction | null; } interface AgentGUIAgentOwner { userId?: string | null; name?: string | null; avatarUrl?: string | null; } /** Host-authoritative ownership classification for Agent directory entries. */ type AgentGUIAgentOwnership = "self" | "shared"; interface AgentGUISharedAgentQuota { unit: "runs" | "tokens"; remaining: number; limit?: number; resetAt?: string | null; } interface AgentGUISharedAgentConcurrency { active: number; limit: number; } interface AgentGUISharedAgentCostQuota { currency: string; remainingMicros: number; limitMicros?: number; } interface AgentGUISharedAgentAllowedModel { modelPlanId?: string | null; model: string; } interface AgentGUISharedAgentPolicyPermissions { consult: boolean; review: boolean; delegate: boolean; upgrade: boolean; } /** Credential-free access snapshot supplied by the shared-Agent control plane. */ interface AgentGUISharedAgentAccess { grantId: string; ownerUserId: string; ownerOnline: boolean; auditRequired: boolean; quota?: AgentGUISharedAgentQuota | null; concurrency?: AgentGUISharedAgentConcurrency | null; costQuota?: AgentGUISharedAgentCostQuota | null; allowedModels?: readonly AgentGUISharedAgentAllowedModel[] | null; policyPermissions?: AgentGUISharedAgentPolicyPermissions | null; } /** * Host-projected entry from the workspace `/agents` directory. * * `agentTargetId` is the only UI and launch identity. `provider` remains * execution metadata for provider-native composer/runtime policy and must not * be used to group, deduplicate, name, or select entries. */ interface AgentGUIAgent { agentTargetId: string; name: string; iconUrl: string; /** Single-color artwork rendered through the conversation rail CSS mask. */ maskIconUrl?: string | null; heroImageUrl?: string | null; description?: string | null; /** Host-resolved display name of the device that owns this Agent target. */ ownerDeviceLabel?: string | null; owner?: AgentGUIAgentOwner | null; ownership?: AgentGUIAgentOwnership | null; sharedAccess?: AgentGUISharedAgentAccess | null; availability: AgentGUIAgentAvailability; provider: AgentGUIProvider; /** * False when this exact target routes model access through a Host-owned * Model Plan, so the Runtime provider's native account usage is unrelated. * Omitted values preserve the ordinary provider account-usage behavior. */ providerAccountUsageApplicable?: boolean; setupKind?: "target_runtime" | null; } type AgentGUIAgentDirectoryStatus = "idle" | "loading" | "ready" | "error"; interface AgentGUIAgentDirectorySnapshot { agents: readonly AgentGUIAgent[]; capturedAtUnixMs: number | null; error: string | null; status: AgentGUIAgentDirectoryStatus; } interface AgentGUIAllAgentsPresentation { iconUrl?: string | null; } interface AgentGUIAgentTargetRef { kind: string; provider: AgentGUIProvider; [key: string]: unknown; } interface AgentGUIAgentTargetBadge { iconUrl: string; label?: string; } interface AgentGUIAgentTarget { targetId: string; agentTargetId?: string | null; provider: AgentGUIProvider; ref: AgentGUIAgentTargetRef; label: string; description?: string; iconUrl?: string | null; maskIconUrl?: string | null; heroImageUrl?: string | null; badge?: AgentGUIAgentTargetBadge | null; ownerLabel?: string; ownerDeviceLabel?: string; ownership?: AgentGUIAgentOwnership; availability?: AgentGUIAgentAvailability; /** Host projection of whether provider-native account usage applies here. */ providerAccountUsageApplicable?: boolean; disabled?: boolean; unavailableReason?: string; } /** * Product-neutral surfaces where a Host may enrich an exact Agent target. * AgentGUI owns the trigger, positioning, and interaction behavior; the Host * owns only the rendered information. */ type AgentGUIAgentTargetInfoSurface = "provider-rail" | "conversation-rail" | "workbench-header"; interface AgentGUIAgentTargetInfoRenderContext { surface: AgentGUIAgentTargetInfoSurface; target: AgentGUIAgentTarget; } /** * Renders Host-owned presentation for an exact Agent target. * * AgentGUI invokes this renderer lazily only while its tooltip content is * mounted. Returning null preserves the built-in target-label fallback. */ type AgentGUIAgentTargetInfoRenderer = (context: AgentGUIAgentTargetInfoRenderContext) => ReactElement | null; type AgentGUITargetConnectionStatus = "connected" | "connecting" | "unavailable"; interface AgentGUITargetConnectionState { status: AgentGUITargetConnectionStatus; retryAttempt: number; } /** * Host-owned, ephemeral device transport state keyed by exact Agent target. * * This capability gates new-conversation and ordinary Composer writes. When an * Interaction-readiness source is present for the displayed prompt, that exact * readiness result has precedence over this target-level state for Interaction * presentation and admission. */ interface AgentGUITargetConnectionSource { getConnectionState(agentTargetId: string): AgentGUITargetConnectionState | null; subscribe(listener: () => void): () => void; } /** * Caller-side presentation gap for one exact Session Turn. * * The canonical Turn remains authoritative and active. Hosts expose this only * while their projection may be stale so AgentGUI can pause live presentation * until the exact Turn has caught up again. */ interface AgentGUIObservationGap { startedAtUnixMs: number; /** * Optional Host-owned presentation classification. Older Hosts may omit it * and retain the frozen-duration fallback. */ presentationState?: "peer-offline" | "synchronizing"; } interface AgentGUIObservationGapSource { getObservationGap(agentSessionId: string, turnId: string): AgentGUIObservationGap | null; subscribe(listener: () => void): () => void; } /** Exact canonical Interaction identity used for Host write admission. */ interface AgentGUIInteractionReadinessIdentity { workspaceId: string; agentSessionId: string; turnId: string; requestId: string; } type AgentGUIInteractionReadinessReason = "synchronizing" | "owner_offline" | "binding_revoked"; type AgentGUIInteractionReadiness = { status: "ready"; } | { status: "blocked"; reason: AgentGUIInteractionReadinessReason; }; /** * Host-owned, ephemeral write readiness for an exact pending Interaction. * * When this capability is supplied, a missing exact record is unresolved and * consumers fail closed as `blocked(synchronizing)`. Omit the whole source to * preserve the default local-host admission behavior. For a displayed exact * pending Interaction, this source is the sole transport-presentation and * early-admission authority; target connection and Turn observation gaps must * not override it. */ interface AgentGUIInteractionReadinessSource { getInteractionReadiness(identity: AgentGUIInteractionReadinessIdentity): AgentGUIInteractionReadiness | null; subscribe(listener: () => void): () => void; } interface AgentGUIProviderRailAllPresentation { iconUrl?: string | null; } /** * How the provider rail composes the target list. * - "catalog" (default): host-provided targets are augmented with the static * local provider catalog, disabled placeholders (nexight/hermes/openclaw), * and coming-soon markers. When no targets are provided, the full local * catalog is shown. * - "exact": the rail renders exactly the provided targets — no static catalog * fallback, no disabled placeholders, no coming-soon injection. When the list * is empty (and not loading) the host-provided empty renderer is shown. Use * this when the list is fully orchestrated externally (e.g. shared agents, * custom /agents). */ type AgentGUIProviderRailMode = "catalog" | "exact"; type AgentGUIProviderReadinessGateStatus = "checking" | "coming_soon" | "not_installed" | "auth_required" | "runtime_selection" | "unavailable"; type AgentGUIProviderReadinessGateAction = "install" | "login" | "refresh" | "choose"; interface AgentGUIProviderReadinessGate { status: AgentGUIProviderReadinessGateStatus; pendingAction?: AgentGUIProviderReadinessGateAction | null; /** * Opens the host-owned model-plan setup route for this blocked provider. * Absent stays hidden; non-Tutti hosts should omit the capability. */ onModelPlanSetup?: () => void; onAction?: (provider: AgentGUIProvider, action: AgentGUIProviderReadinessGateAction) => void; } interface Size { width: number; height: number; } interface Point { x: number; y: number; } interface NodeFrame { position: Point; size: Size; } export type { AgentGUIAgent as A, NodeFrame as N, Point as P, AgentGUIAgentDirectorySnapshot as a, AgentGUIAgentOwnership as b, AgentGUIAgentTarget as c, AgentGUIAgentTargetInfoRenderer as d, AgentGUIAllAgentsPresentation as e, AgentGUIHomeSuggestionId as f, AgentGUIInteractionReadinessSource as g, AgentGUINodeData as h, AgentGUIObservationGapSource as i, AgentGUIProvider as j, AgentGUIProviderRailAllPresentation as k, AgentGUIProviderRailMode as l, AgentGUIProviderReadinessGate as m, AgentGUITargetConnectionSource as n };