import type { ContextBudgetMetadata } from "./types/context.js"; import type { ModelProvenanceRecord, TelemetryConsentState } from "./types/model-config.js"; import type { CollaborationFlowRecommendation, MemoryPacket, SkillPlan, SkillRenderTarget, WorkflowTemplateSelection } from "./types/skills.js"; import type { EventEntry, LockEntry, Task, TaskStatus, VerifierContractEntry } from "./types/tasks.js"; export type { ChatActor, ChatActorKind, ChatContent, ChatContentFormat, ChatContentState, ChatDeleteMetadata, ChatDeleteStatus, ChatExportMetadata, ChatExportOptions, ChatExportRecord, ChatExportStatus, ChatHumanActor, ChatListOptions, ChatMessage, ChatMessageListResult, ChatParentAgentActor, ChatProviderAgentActor, ChatProvenance, ChatProvenanceSourceKind, ChatRawPersistence, ChatRedactionMetadata, ChatReference, ChatReferenceKind, ChatRetentionMetadata, ChatRetentionStatus, ChatReviewerActor, ChatRuntimeSource, ChatScope, ChatStorageState, ChatSubagentActor, ChatSystemActor, ChatThread, ChatThreadListResult, ChatWorkflowEventActor, HumanActorSource, SystemActorSource, } from "./types/chat.js"; export type { ContextBudgetMetadata, ContextBudgetSection, } from "./types/context.js"; export type { ContextIndexBuildResult, ContextIndexFileEntry, ContextIndexManifest, ContextIndexSearchMatch, ContextIndexSearchResult, ContextIndexStatus, ContextPackBudget, ContextPackItem, ContextPackResult, ContextPackSnippet, } from "./types/context-index.js"; export type { BudgetLimit, BudgetPolicy, ConfiguredProviderSummary, GitHubConfig, GitHubNotificationConfig, ModelMessage, ModelProvider, ModelProviderCapabilities, ModelProviderError, ModelProvenanceInput, ModelProvenanceRecord, ModelRequest, ModelResponse, ModelStreamEvent, NotificationChannelResult, NotificationsConfig, PhaseExecutionMode, PhaseExecutorPhase, PhaseLlmResult, PhaseOutcome, PhaseStructuredOutput, ProviderFallbackResult, ProviderFailureDetail, ProviderBackedAgentBudget, ProviderBackedAgentCost, ProviderBackedAgentEvidencePolicy, ProviderBackedAgentFallback, ProviderBackedAgentOutcome, ProviderBackedAgentPolicy, ProviderBackedAgentProvenance, ProviderBackedAgentRequest, ProviderBackedAgentResult, ProviderBackedAgentUsage, ProviderCostSource, ProviderDataClass, ProviderProfileSmokeCheck, ProviderProfileSmokeResult, ProviderCredentialConfig, ProviderCredentialsConfig, ProviderPolicyConfig, ProviderRegistryCredentialEnv, ProviderRegistryEntry, ProviderRuntimeProfile, ProviderRuntimeProfileSummary, ProviderRouting, ProviderUsageSource, SlackNotificationConfig, TelemetryConsentState, TelemetryLevel, ToolConfig, WorkflowConfig, WorkflowProvidersConfig, } from "./types/model-config.js"; export type { RuntimeAdapter, RuntimeAdapterCatalogEntry, RuntimeAdapterKind, RuntimeBrief, RuntimeCapacityLimitAction, RuntimeCapacitySchedulerEvent, RuntimeCapacityScope, RuntimeCapacitySnapshot, RuntimeCapacityUnit, RuntimeDelegationAssignment, RuntimeDelegationGuardrailEvaluation, RuntimeDelegationGuardrailStatus, RuntimeDelegationGuardrails, RuntimeDelegationLimitAction, RuntimeDelegationMode, RuntimeDelegationOperationsReport, RuntimeDelegationPacket, RuntimeDelegationPolicy, RuntimeDelegationSessionStatus, RuntimeDelegationSessionSummary, RuntimeClaudeNativeBridgeResult, RuntimeClaudeNativeCallbackMetadata, RuntimeExecutionAdapter, RuntimeExecutionCapabilities, RuntimeExecutionId, RuntimeExecutionPolicy, RuntimeExecutorConfig, RuntimeInvocationPlan, RuntimeLease, RuntimeLifecycleWatcherAdapter, RuntimeLifecycleWatcherDetectionMode, RuntimeLifecycleWatcherSupportLevel, PendingRuntimeParentAction, RuntimeParentAction, RuntimeParentActionEligibility, RuntimeParentActionEligibilityChecked, RuntimeParentActionEligibilityStatus, RuntimeParentActionKind, RuntimeParentActionLifecycleCommands, RuntimeParentActionPayload, RuntimeParentActionSafetyState, RuntimeParentActionSkipReason, RuntimeParentActionSkipReasonCode, RuntimeQueueDecision, RuntimeQueuePolicy, RuntimeQuotaPolicy, RuntimeRegionPreference, RuntimeScheduleDecision, RuntimeScheduleDecisionStatus, RuntimeScheduleReasonCode, RuntimeScheduleRequest, RuntimeSelection, RuntimeSpawnCapability, RuntimeSpawnCapabilityMode, RuntimeSpawnRequest, RuntimeSpawnRequestStatus, RuntimeSubagentCapabilities, RuntimeTenantAffinity, RuntimeWorkerHealth, RuntimeWorkerIsolationMetadata, RuntimeWorkerKind, RuntimeWorkerRecord, RuntimeWorkloadClass, } from "./types/runtime.js"; export type { AgentLesson, AgentLessonInput, CollaborationFlow, CollaborationFlowRecommendation, CollaborationFlowStep, MemoryHookPoint, MemoryLessonSnippet, MemoryPacket, MemoryPromptSnippet, MemorySectionReport, RuntimeSkillPlanRequest, Skill, SkillLoadBudget, SkillPlan, SkillPlanItem, SkillRenderTarget, PhasePlaybook, SkillValidationReport, RenderedWorkflowTemplate, WorkflowTemplate, WorkflowTemplateSelection, } from "./types/skills.js"; export { SIZING_LABELS, type BenchmarkQualitySignals, type BenchmarkResult, type BenchmarkSummary, type BurndownPoint, type BurndownSeries, type CalibrationReport, type CalibrationRoleReport, type EffortBreakdown, type EstimateCalibration, type EstimateConfidence, type EstimateInput, type EstimateRecord, type SizingLabel, type SprintRecord, type SprintVelocity, type SprintVelocityReport, type TaskEstimateBreakdown, type VelocityReport, type VelocityWeek, } from "./types/metrics.js"; export type { NormalizedTranscriptionRequest, TranscriptionConsentStatus, TranscriptionEngineRequest, TranscriptionExecutionMode, TranscriptionFailure, TranscriptionFailureCode, TranscriptionFindings, TranscriptionMediaType, TranscriptionOutput, TranscriptionPolicy, TranscriptionProvenance, TranscriptionReadiness, TranscriptionReadinessStatus, TranscriptionRedactionSummary, TranscriptionRequest, TranscriptionRetentionClass, TranscriptionRuntimeEnvironment, TranscriptionSegment, TranscriptionSource, TranscriptionSourceKind, TranscriptionTimestampQuality, TranscriptionValidationResult, } from "./transcription-types.js"; export { defaultTranscriptionPolicy, evaluateTranscriptionReadiness, normalizeTranscriptionRequest, summarizeTranscriptionRedactions, validateTranscriptionRequest, } from "./transcription-request.js"; export type { AddTaskInput, ArchitectureApproval, ArtifactResult, ClaimLockInput, DecisionInput, DecisionRecord, EventEntry, EventInput, EvidenceInput, EvidenceType, ExternalTaskReferences, HandoffInput, LockEntry, MechanicalOverride, PlaywrightEvidenceInput, QaGateMetadata, ReviewInput, ReviewResult, RiskAcceptance, RiskGateMetadata, RiskImpactArea, SetupAgentsTaskReference, Severity, Task, TaskStatus, TaskWorkflowMetadata, UpdateTaskInput, VerifierContractAssertionType, VerifierContractEntry, VerifierContractSet, VerifierContractSurface, } from "./types/tasks.js"; export type { AutonomousGateMode, AutonomousPhase, AutonomousPhaseStatus, AutonomousRun, AutonomousRunResult, BenchmarkPhaseDuration, ClarificationAnswerInput, ClarificationInput, ClarificationRecord, ClarificationStatus, ClarificationTarget, PhaseProviderProgress, WorkflowContinuationPolicy, WorkflowPhaseExecutionMode, WorkflowPhaseExecutorProvenance, WorkflowGateApprovalInput, WorkflowGateApprovalResult, WorkflowGateDecisionInput, WorkflowGateDecisionRecord, WorkflowGateDecisionResult, WorkflowRunMode, WorkflowStopReason, } from "./types/workflow-run.js"; export type WorkspaceClassificationKind = "project" | "advisory" | "unsafe" | "unknown"; export type WorkspaceWritePolicy = "allow" | "confirm_required" | "blocked"; export interface WorkspaceClassification { root: string; normalizedRoot: string; kind: WorkspaceClassificationKind; confidence: "high" | "medium" | "low"; signals: string[]; reasons: string[]; writePolicy: WorkspaceWritePolicy; recommendedAction: string; supportedTargets: SkillRenderTarget[]; } export interface Role { id: string; name: string; description: string; capabilities: string[]; requiredHandoffFields: string[]; blockingAuthority: string[]; activationCriteria?: string[]; expectedEvidence?: string[]; gateParticipation?: string[]; } export interface Workspace { base: string; roles: Role[]; roleIds: Set; tasks: Task[]; locks: LockEntry[]; } export interface CliOptions { _: string[]; [key: string]: string | boolean | string[]; } export interface CliIo { log(message: string): void; } export interface ReadinessReport { isReady: boolean; missing: string[]; } export interface GateEvaluationContext { task: Task; events: EventEntry[]; locks: LockEntry[]; } export interface GateEvaluationResult { gateId: string; passed: boolean; blocking: boolean; summary: string; missing: string[]; metadata: Record; } export interface WorkflowGate { id: string; description: string; evaluate(context: GateEvaluationContext): GateEvaluationResult; } export interface WorkflowStatus { mode?: "project" | "advisory"; tasks: { total: number; byStatus: Record; blocked: { id: string; title: string; reason: string; }[]; }; locks: { total: number; }; } export interface WorkflowSummary { tasks: Task[]; locks: LockEntry[]; reviews: EventEntry[]; evidence: EventEntry[]; blockers: Task[]; eventCount: number; } export interface PreRunValidationReport { taskId: string; isReady: boolean; isBypassed: boolean; allowed: boolean; activeOrchestraContext: boolean; missingActiveContext: string[]; missing: string[]; advisoryMissing?: string[]; suggestedCommands?: string[]; checks: { task: boolean; estimate: boolean; workflowRun: boolean; evidence: boolean; review: boolean; }; bypassDecisionArtifact?: string; } export interface DependencyStatus { id: string; status: TaskStatus; isComplete: boolean; } export interface DependencyReport { taskId: string; isSatisfied: boolean; dependencies: DependencyStatus[]; incomplete: DependencyStatus[]; } export interface TaskGraphReadyItem { id: string; title: string; status: TaskStatus; ownerRole: string; } export interface TaskGraphBlockedItem extends TaskGraphReadyItem { incomplete: DependencyStatus[]; } export interface TaskGraphLockInfo { id: string; path: string; conflictPath?: string; ownerRole: string; reason: string; } export interface TaskGraphLockedItem extends TaskGraphReadyItem { locks: TaskGraphLockInfo[]; } export interface TaskGraphCompleteItem { id: string; title: string; status: TaskStatus; ownerRole: string; } export interface TaskGraphPlan { ready: TaskGraphReadyItem[]; blocked: TaskGraphBlockedItem[]; locked: TaskGraphLockedItem[]; complete: TaskGraphCompleteItem[]; } export type TaskGraphDryRunMode = "run-next" | "run-ready"; export interface TaskGraphDryRunItem { id: string; title: string; status: TaskStatus; ownerRole: string; provider: string; model: string; fallbacks: string[]; budget?: BudgetCheckResult; } export interface TaskGraphDryRunPreview { mode: TaskGraphDryRunMode; dryRun: true; wouldMutate: false; selectedTaskIds: string[]; tasks: TaskGraphDryRunItem[]; locked: TaskGraphLockedItem[]; blocked: TaskGraphBlockedItem[]; } export interface PullRequestReviewAnalysis { behaviorSummary: string; changedFiles: string[]; testEvidence: string[]; unresolvedQuestions: string[]; requiredReviewers: string[]; missingReviewers: string[]; checklist: string[]; evidenceGaps: string[]; mergeBlocked: boolean; mergeBlockers: string[]; } export interface PullRequestSummary { task: Task; handoffs: EventEntry[]; reviews: EventEntry[]; evidence: EventEntry[]; gates: EventEntry[]; locks: LockEntry[]; risks: string[]; rollout: string; rollback: string; review: PullRequestReviewAnalysis; } export interface PlaywrightScenario { name: string; source: string; pageObject: string; selectors: string[]; assertions: string[]; evidence: string[]; } export interface PlaywrightTestPlan { taskId: string; title: string; targetUser: string; scenarios: PlaywrightScenario[]; fixtures: string[]; notes: string[]; } export type DelegationRecommendation = "local" | "single_delegate" | "parallel_delegate" | "review_delegate" | "no_delegation"; export type DelegationMode = "execute" | "review"; export interface DelegationAssignment { role: string; mode: DelegationMode; rationale: string[]; writeScopes: string[]; expectedOutputs: string[]; } export interface DelegationDecision { taskId: string; recommendation: DelegationRecommendation; complexityScore: number; urgency: "normal" | "high"; rationale: string[]; blockingConditions: string[]; contextBundle: string[]; expectedOutputs: string[]; delegates: DelegationAssignment[]; disjointWriteScopes: boolean; } export interface TaskContext { task: Task; dependencies: DependencyReport; locks: LockEntry[]; decisions: EventEntry[]; handoffs: EventEntry[]; reviews: EventEntry[]; evidence: EventEntry[]; gates: EventEntry[]; modelProvenance: ModelProvenanceRecord[]; skills: SkillPlan; memory: MemoryPacket; telemetry: TelemetryConsentState; risks: string[]; delegation?: DelegationDecision; collaborationFlow: CollaborationFlowRecommendation | null; workflowTemplates: WorkflowTemplateSelection[]; verifierContracts: VerifierContractEntry[]; contextBudget: ContextBudgetMetadata; } export interface ExecutionPlanStep { id: string; role: string; action: string; dependsOn: string[]; gate?: string; } export interface ExecutionPlan { taskId: string; steps: ExecutionPlanStep[]; } export interface ExecutionRunStep { id: string; role: string; status: "completed" | "failed"; provider: string; model: string; responseId?: string; artifact?: string; error?: string; } export interface ExecutionRun { taskId: string; provider: string; model: string; steps: ExecutionRunStep[]; budgetEscalation?: BudgetEscalationResult; } export interface TaskGraphBatchFailure { taskId: string; error: string; } export interface TaskGraphBatchRun { selectedTaskIds: string[]; runs: ExecutionRun[]; locked: TaskGraphLockedItem[]; failure?: TaskGraphBatchFailure; artifact?: string; } export interface UsageBreakdown { key: string; requests: number; inputTokens: number; outputTokens: number; totalTokens: number; estimatedCostUsd: number; } export interface UsageReport { taskId?: string; totals: UsageBreakdown; byRole: UsageBreakdown[]; byProvider: UsageBreakdown[]; byTenant: UsageBreakdown[]; byWorkspace: UsageBreakdown[]; byActor: UsageBreakdown[]; byInitiator: UsageBreakdown[]; byPhase: UsageBreakdown[]; } export interface BudgetViolation { scope: string; metric: string; actual: number; limit: number; } export interface BudgetCheckResult { taskId?: string; passed: boolean; usage: UsageReport; appliedBudgets: string[]; violations: BudgetViolation[]; } export interface BudgetThresholdWarning { scope: string; metric: "estimatedCostUsd"; actual: number; limit: number; thresholdPercent: number; } export interface BudgetEstimatePreflight { taskId: string; estimatedCostUsd: number; passed: boolean; warnings: BudgetThresholdWarning[]; budget: BudgetCheckResult; } export interface BudgetFallbackProposal { fromProvider: string; fromModel: string; toProvider: string; toModel: string; violations: BudgetViolation[]; artifact?: string; } export interface BudgetEscalationDecision { approved: boolean; approver?: string; rationale?: string; } export interface BudgetEscalationResult { status: "not_required" | "approved" | "rejected"; proposal?: BudgetFallbackProposal; approver?: string; rationale?: string; approvalId?: string; approvalSource?: "explicit" | "stored"; } export interface ApprovalRecord { id: string; taskId?: string; artifact: string; status: "pending" | "approved" | "rejected"; summary: string; requestedAt?: string; decidedAt?: string; approver?: string; rationale?: string; } export interface ApprovalDecisionInput { id: string; approver: string; rationale: string; } export type ActionRiskTier = "routine" | "elevated" | "major" | "destructive"; export interface ActionPolicyConfig { requireApprovalFor: ActionRiskTier[]; routineCommands: string[]; elevatedPatterns: string[]; majorPatterns: string[]; destructivePatterns: string[]; }