import type { KnowledgeCapsuleId, KnowledgeSourceId } from "@oscharko-dev/keiko-contracts";
export interface CapsuleRetentionPolicy {
    readonly retainExtractedTextDays?: number;
    readonly retainVectorsDays?: number;
}
export interface RetentionApplyResult {
    readonly capsuleId: KnowledgeCapsuleId;
    readonly deletedVectorCount: number;
    readonly deletedExtractedTextCount: number;
    readonly appliedAt: number;
}
export type CapsuleAuditEvent = CapsuleCreatedEvent | CapsuleDeletedEvent | CapsuleSourceAddedEvent | CapsuleSourceRemovedEvent | IndexingJobStartedEvent | IndexingJobCompletedEvent | IndexingJobFailedEvent | RetentionAppliedEvent | RetrievalPerformedEvent | AnswerContextAssembledEvent | ModelContextSentEvent;
export interface CapsuleCreatedEvent {
    readonly kind: "capsule-created";
    readonly capsuleId: KnowledgeCapsuleId;
    readonly occurredAt: number;
}
export interface CapsuleDeletedEvent {
    readonly kind: "capsule-deleted";
    readonly capsuleId: KnowledgeCapsuleId;
    readonly occurredAt: number;
}
export interface CapsuleSourceAddedEvent {
    readonly kind: "source-added";
    readonly capsuleId: KnowledgeCapsuleId;
    readonly sourceId: KnowledgeSourceId;
    readonly occurredAt: number;
}
export interface CapsuleSourceRemovedEvent {
    readonly kind: "source-removed";
    readonly capsuleId: KnowledgeCapsuleId;
    readonly sourceId: KnowledgeSourceId;
    readonly occurredAt: number;
}
export interface IndexingJobStartedEvent {
    readonly kind: "indexing-job-started";
    readonly capsuleId: KnowledgeCapsuleId;
    readonly jobId: string;
    readonly occurredAt: number;
}
export interface IndexingJobCompletedEvent {
    readonly kind: "indexing-job-completed";
    readonly capsuleId: KnowledgeCapsuleId;
    readonly jobId: string;
    readonly processedDocuments: number;
    readonly failedDocuments: number;
    readonly occurredAt: number;
}
export interface IndexingJobFailedEvent {
    readonly kind: "indexing-job-failed";
    readonly capsuleId: KnowledgeCapsuleId;
    readonly jobId: string;
    readonly errorCode: string;
    readonly occurredAt: number;
}
export interface RetentionAppliedEvent {
    readonly kind: "retention-applied";
    readonly capsuleId: KnowledgeCapsuleId;
    readonly deletedVectorCount: number;
    readonly deletedExtractedTextCount: number;
    readonly occurredAt: number;
}
export interface RetrievalPerformedEvent {
    readonly kind: "retrieval-performed";
    readonly capsuleId: KnowledgeCapsuleId;
    readonly sourceIds: readonly KnowledgeSourceId[];
    readonly chunkIds: readonly string[];
    readonly referenceCount: number;
    readonly noEvidence: boolean;
    readonly occurredAt: number;
}
export interface AnswerContextAssembledEvent {
    readonly kind: "answer-context-assembled";
    readonly capsuleId: KnowledgeCapsuleId;
    readonly sourceIds: readonly KnowledgeSourceId[];
    readonly chunkIds: readonly string[];
    readonly referenceCount: number;
    readonly citationCount: number;
    readonly occurredAt: number;
}
export interface ModelContextSentEvent {
    readonly kind: "model-context-sent";
    readonly capsuleId: KnowledgeCapsuleId;
    readonly sourceIds: readonly KnowledgeSourceId[];
    readonly chunkIds: readonly string[];
    readonly referenceCount: number;
    readonly citationCount: number;
    readonly modelId: string;
    readonly occurredAt: number;
}
export interface AuditEventSink {
    readonly emit: (event: CapsuleAuditEvent) => void;
}
//# sourceMappingURL=types.d.ts.map