import { HNSW } from './main'; import { DBSchema, IDBPDatabase } from 'idb'; type SerializedIndex = ReturnType; interface HNSWDB extends DBSchema { 'hnsw-index': { key: string; value: SerializedIndex; }; } export declare class HNSWWithDB extends HNSW { dbName: string; db: IDBPDatabase | null; private constructor(); /** * Creates an IndexedDB-backed HNSW instance. */ static create(M: number, efConstruction: number, dbName: string, efSearch?: number): Promise; private initDB; /** * Closes the current IndexedDB connection if open. */ close(): void; /** * Persists the current graph to IndexedDB. */ saveIndex(): Promise; /** * Loads a persisted graph from IndexedDB if present. */ loadIndex(): Promise; /** * Deletes persisted graph data and re-initializes the backing DB. */ deleteIndex(): Promise; } export {};