import type { DreamNeighborQuery, MemoryVectorIndexManifest } from '../../../contracts/vector_index'; import type { VectorIndexHybridQuery, VectorIndexInspection, VectorIndexMutation, VectorIndexPresetStateMark, VectorIndexReplaceUpsert } from '../worker_protocol'; import { analyzeVectorIndex } from './schema'; interface VectorIndexDatabaseOptions { removeDirectory?: (directory: string) => void; reportWarning?: (warning: Error) => void; analyze?: typeof analyzeVectorIndex; } export declare class LivingMemoryVectorIndexDatabase { private database; private activeDatabaseDirectory; private rebuildDatabaseDirectory; private mode; private readonly removeDatabaseDirectory; private readonly reportWarning; private readonly analyze; private readonly ownershipEndpoint; constructor(options?: VectorIndexDatabaseOptions); open(databaseDirectory: string, previousDatabaseDirectory: string): Promise; private openOwned; upgradeSchema(): Promise<{ schemaVersion: number; }>; inspect(): Promise; openCandidate(databaseDirectory: string): Promise; queryHybrid(query: VectorIndexHybridQuery): Promise; buildDreamAnnIndex(): Promise<{ built: boolean; }>; queryDreamNeighbors(queries: DreamNeighborQuery[], cancellation: Int32Array): Promise; readVectorSnapshot(presetId: string, memoryIds: string[]): Promise; applyMutation(mutation: VectorIndexMutation): Promise<{ indexedCount: number; }>; clearPreset(presetId: string): Promise<{ deletedCount: number; }>; readInventoryPage(presetId: string | null, afterMemoryId: string | null, limit: number): Promise; markPresetState(status: VectorIndexPresetStateMark): Promise; openRebuildDatabase(databaseDirectory: string, manifest: MemoryVectorIndexManifest): Promise; appendRebuildBatch(presetId: string, upserts: VectorIndexReplaceUpsert[]): Promise<{ indexedCount: number; }>; validateAndCloseRebuildDatabase(expectedCount: number): Promise<{ indexedCount: number; }>; closeDatabase(): Promise; abortRebuild(): Promise; dispose(): Promise; private openConnection; private upgradeVectorExtension; private restorePreviousDatabase; private closeConnection; private cleanupDatabaseDirectory; private requireDatabase; private requireActiveDatabase; private requireRebuildDatabase; private requireActiveDatabaseDirectory; private requireRebuildDatabaseDirectory; private readVectorExtensionVersion; } export {};