import type { Usage } from "@earendil-works/pi-ai"; import type { ExtensionContext } from "@earendil-works/pi-coding-agent"; import { type FabricExecutionTraceV1 } from "./audit/trace.js"; import { FabricActivityStore } from "./activity/store.js"; import type { FabricRunDisplay } from "./activity/types.js"; import { type FabricConfig } from "./config.js"; import { ActionRegistry, type FabricCallAudit } from "./core/action-registry.js"; import type { FabricPrewalkExecutionBoundary } from "./prewalk/controller.js"; import { FabricSessionApprovals } from "./core/approval-controller.js"; import { FabricAutoApprovalClassifier } from "./core/auto-approval-classifier.js"; import type { FabricTypeError } from "./runtime/type-checker.js"; import { type FabricEvidenceRef, type FabricGateResult, type FabricRunBudgetSnapshot, type FabricRunEnvelopeV1, type FabricRunTransition } from "./run/context.js"; import type { FabricConsultOutcome, FabricOutcomeInput } from "./outcomes/store.js"; export interface FabricExecutionResult { success: boolean; value: unknown; logs: string[]; audits: FabricCallAudit[]; phases: string[]; trace: FabricExecutionTraceV1; elapsedMs: number; typeErrors?: FabricTypeError[]; error?: string; handoffRequest?: Record; prewalkBoundary?: { ref: string; nestedToolCallId: string; }; usage?: Usage; run?: FabricRunEnvelopeV1; evidence?: FabricEvidenceRef[]; gates?: FabricGateResult[]; transitions?: FabricRunTransition[]; budget?: FabricRunBudgetSnapshot; consult?: FabricConsultOutcome; } interface FabricExecutionPartial { audits: FabricCallAudit[]; phases: string[]; progress?: string | undefined; } export interface FabricExecutionAuthorizer { authorize(ref: string, parentToolCallId: string): Promise; } export interface FabricExecutionOptions { code: string; strings?: Record; signal: AbortSignal | undefined; parentToolCallId: string; context: ExtensionContext; tokenBudget?: number; maxAgentCalls?: number; display?: FabricRunDisplay; prewalk?: FabricPrewalkExecutionBoundary; onPartial(snapshot: FabricExecutionPartial): void; } export declare class FabricExecutionService { #private; readonly registry: ActionRegistry; readonly config: FabricConfig; readonly activity?: FabricActivityStore | undefined; readonly authorizer?: FabricExecutionAuthorizer | undefined; readonly autoApprovalClassifier: FabricAutoApprovalClassifier; readonly sessionApprovals: FabricSessionApprovals; readonly outcomeSink?: { record(input: FabricOutcomeInput): Promise; } | undefined; constructor(registry: ActionRegistry, config: FabricConfig, activity?: FabricActivityStore | undefined, authorizer?: FabricExecutionAuthorizer | undefined, autoApprovalClassifier?: FabricAutoApprovalClassifier, sessionApprovals?: FabricSessionApprovals, outcomeSink?: { record(input: FabricOutcomeInput): Promise; } | undefined); execute(options: FabricExecutionOptions): Promise; } export {}; //# sourceMappingURL=execution-service.d.ts.map