import type { SqliteDatabase } from '../db/adapter.js'; import { type JsonObject } from '../serialization/validate.js'; export declare const MEMORY_CLASSES: readonly ["implementation-pattern", "troubleshooting", "tool-usage", "extension-usage", "configuration", "workflow", "gotcha", "reference", "preference"]; export type MemoryClass = (typeof MEMORY_CLASSES)[number]; export declare const RETRIEVAL_SCOPES: readonly ["project-only", "ecosystem", "global"]; export type RetrievalScope = (typeof RETRIEVAL_SCOPES)[number]; export interface Applicability { languages?: string[]; frameworks?: Array<{ name: string; version?: string; }>; databases?: string[]; runtimes?: string[]; tools?: string[]; platforms?: string[]; } export interface MemorySignals { symbols?: string[]; paths?: string[]; errors?: string[]; packages?: string[]; commands?: string[]; } export interface StructuredMemoryOptions { visibility: 'project' | 'global'; retrievalScope?: RetrievalScope; repositoryId?: string; memoryClass?: MemoryClass; applicability?: Applicability; signals?: MemorySignals; portableReason?: string; } /** Resolve the retrieval policy of a structured scope. */ export declare function effectiveRetrievalScope(scope: Record): RetrievalScope; export declare function hasExplicitApplicability(scope: Record): boolean; export declare function validateApplicability(value: unknown): Applicability; export declare function validateSignals(value: unknown): MemorySignals; export declare function buildStructuredScope(options: StructuredMemoryOptions): JsonObject; export declare function extractEntrySearchSignals(input: { entryId: string; title: string; body: string; summary: string | null; tags: string[]; scope: JsonObject; }): Array<{ type: string; value: string; }>; /** Assert the complete search schema consumed by hybridSearch before mutating a projection. */ export declare function requireHybridSearchProjectionSchema(database: SqliteDatabase): void; export declare function syncEntrySearchSignals(database: SqliteDatabase, input: Parameters[0]): void; /** Refresh every search projection for the entry's current revision. */ export declare function syncEntrySearchProjection(database: SqliteDatabase, input: Parameters[0]): void; //# sourceMappingURL=structured-memory.d.ts.map