import { CHAT_EVENTS_SLOT, EvidenceRef, ProducerMessageSource, RpcResult, TaskCheckpoint, TaskContract } from "@klarkxy/dsh-plugin-kit/contracts"; //#region src/contracts.d.ts /** DSH message source identity for this plugin's own messages. */ declare const RECAP_PLUGIN = "@klarkxy/dsh-recap"; declare const RECAP_SOURCE_KIND: "plugin:@klarkxy/dsh-recap"; declare const RECAP_RPC_CHANNEL = "/dsh-recap"; declare const RECAP_DISPLAY_PURPOSE = "recap.display"; declare const RECAP_CHECKPOINT_PURPOSE = "recap.checkpoint"; declare const DEFAULT_IDLE_RETURN_MS: number; declare const MAX_LOG_EVENTS = 256; declare const MAX_EXCERPT_CHARS = 200; declare const MAX_CARD_BODY_CHARS = 4000; declare const MAX_CHECKPOINT_CHARS = 2000; declare const LONG_TASK_MIN_MS = 60000; declare const LONG_TASK_MIN_STEPS = 2; declare const LONG_TASK_MIN_TOOLS = 3; declare const MEANINGFUL_TOOL_DELTA = 3; type RecapSourceStatus = 'completed' | 'failed' | 'cancelled' | 'running'; type RecapTrigger = 'turn-end' | 'idle-return' | 'retry' | 'manual'; type RecapCardKind = 'deterministic' | 'generated' | 'cached'; type RecapGeneration = 'idle' | 'running' | 'failed' | 'cancelled' | 'superseded'; /** Plugin-page model selection. Empty provider/model means "follow the default". */ interface RecapModelRoute { readonly provider: string; readonly model: string; readonly reasoningEffort?: string; } interface RecapSettings { revision: number; cardsEnabled: boolean; checkpointsEnabled: boolean; semanticCheckpointsEnabled: boolean; idleReturnMs: number; /** Model for recap cards (display) and semantic checkpoints, chosen on the plugin page. */ displayModel: RecapModelRoute; checkpointModel: RecapModelRoute; } declare const defaultModelRoute: () => RecapModelRoute; declare const defaultSettings: () => RecapSettings; interface RecapCard { id: string; sessionId: string; sourceVersion: string; fromSeq: number; toSeq: number; trigger: RecapTrigger; sourceStatus: Exclude; title: string; body: string; kind: RecapCardKind; generation: RecapGeneration; receiptId?: string; createdAt: number; updatedAt: number; } interface RecapPersistedState { settings: RecapSettings; cards: RecapCard[]; checkpoints: TaskCheckpoint[]; } interface RecapStore { load(): RecapPersistedState; save(state: RecapPersistedState): Promise; } interface RecapStatus { settings: RecapSettings; cards: RecapCard[]; checkpoints: TaskCheckpoint[]; storageFailed: boolean; } interface RecapLogEvent { seq: number; type: string; time: number; data: unknown; } interface RecapToolFact { name: string; callId?: string; proposedChange: boolean; error?: boolean; seq: number; outcome: 'verified' | 'failed' | 'unverified' | 'missing' | 'cancelled' | 'unknown'; } interface RecapFacts { sessionId: string; fromSeq: number; toSeq: number; sourceVersion: string; sourceStatus: RecapSourceStatus; turn?: number; stepCount: number; userTurns: number; toolCalls: number; toolResults: number; proposals: number; durationMs: number; lastUserExcerpt?: string; tools: RecapToolFact[]; constraints: string[]; } type MoodContractApi = { getContract?(sessionId: string): TaskContract | undefined; }; declare function fail(code: string, message: string): RpcResult; declare function ok(value: T): RpcResult; declare function recapSourceVersion(sessionId: string, toSeq: number): string; declare function parseSessionId(payload: unknown): string | undefined; //#endregion export { CHAT_EVENTS_SLOT, DEFAULT_IDLE_RETURN_MS, type EvidenceRef, LONG_TASK_MIN_MS, LONG_TASK_MIN_STEPS, LONG_TASK_MIN_TOOLS, MAX_CARD_BODY_CHARS, MAX_CHECKPOINT_CHARS, MAX_EXCERPT_CHARS, MAX_LOG_EVENTS, MEANINGFUL_TOOL_DELTA, MoodContractApi, type ProducerMessageSource, RECAP_CHECKPOINT_PURPOSE, RECAP_DISPLAY_PURPOSE, RECAP_PLUGIN, RECAP_RPC_CHANNEL, RECAP_SOURCE_KIND, RecapCard, RecapCardKind, RecapFacts, RecapGeneration, RecapLogEvent, RecapModelRoute, RecapPersistedState, RecapSettings, RecapSourceStatus, RecapStatus, RecapStore, RecapToolFact, RecapTrigger, type RpcResult, type TaskCheckpoint, type TaskContract, defaultModelRoute, defaultSettings, fail, ok, parseSessionId, recapSourceVersion }; //# sourceMappingURL=contracts.d.ts.map