/** * AgentDB Client Implementation * * Provides a stable wrapper API (HNSW-style vector search, incident * storage, ReflexionMemory, QUIC sync) over a swappable backend. * * The original implementation delegated directly to `agentdb`'s * `createDatabase()`, but agentdb 3.x is a breaking API change that * removed `createIndex`, `search`, `insert`, `count`, `sync`, etc. * from the database handle. To keep the gateway functional, secure * (0 CVEs), and publishable on npm, we now ship an in-memory store * (`InMemoryStore` in ./memory-store.ts) that satisfies the call * shape this wrapper expects. A persistent backend (agentdb v3 * wrapper or sqlite-vec) is scheduled for a follow-up. */ import { ThreatMatch, ThreatIncident, VectorSearchOptions, AgentDBConfig } from '../types'; import { Logger } from '../utils/logger'; export declare class AgentDBClient { private db; private logger; private config; private syncInterval?; constructor(config: AgentDBConfig, logger: Logger); /** * Initialize AgentDB with HNSW index and QUIC sync */ initialize(): Promise; /** * Fast vector search with HNSW and MMR diversity * Target: <2ms for k=10 */ vectorSearch(embedding: number[], options?: VectorSearchOptions): Promise; /** * Store security incident in ReflexionMemory for learning */ storeIncident(incident: ThreatIncident): Promise; /** * Synchronize with peer nodes using QUIC */ syncWithPeers(): Promise; /** * Get statistics about stored data */ getStats(): Promise<{ incidents: number; patterns: number; memoryEntries: number; memoryUsage: number; }>; /** * Clean up old entries based on TTL */ cleanup(): Promise; /** * Shutdown and cleanup resources */ shutdown(): Promise; private createCollections; private initializeQuicSync; private applyMMR; private cosineSimilarity; private calculateThreatLevel; private updateThreatPattern; private generateFeedback; private updateCausalGraph; } //# sourceMappingURL=client.d.ts.map