/** * Memory Bridge — the usage/feedback closed loop: usage capture * (frequency_weight), EWMA feedback weighting with an idempotency ledger, * and feedback records. Split out of memory-bridge.ts, which re-exports the * public symbols. */ import type { SkippedEntry } from './memory-bridge-store.js'; /** Record that these entries were actually USED (returned to and consumed by a * caller) — increments frequency_weight, which feeds the ranking blend. * * Unresolvable ids are REPORTED, not dropped: this used to `continue` past * every id it could not read, so a caller handing it a page of stale ids got * `{success: true, updated: 0}` with nothing to say whether those entries had * been deleted or the writes had failed. Same contract as * `bridgeApplyFeedback`. */ export declare function bridgeRecordUsage(options: { entryIds: string[]; dbPath?: string; }): Promise<{ success: boolean; updated: number; skipped?: SkippedEntry[]; } | null>; /** Apply a usefulness rating to the entries that produced an answer: * EWMA feedback_weight' = w + alpha*(score - w), clipped [0,1] (cognee's * apply_feedback_weights). `ledgerKey` makes application idempotent — a * daemon retry or duplicate MCP call must never compound the update. */ export declare function bridgeApplyFeedback(options: { entryIds: string[]; score: number; ledgerKey?: string; alpha?: number; dbPath?: string; }): Promise<{ success: boolean; applied: number; /** Ids that trained nothing, with why — so `applied: 0` is never a silent * success. `not_found` means the id resolved to no entry (it was deleted, or * it predates the in-place upsert fix and was orphaned by a re-ingest); * `error` means the entry existed but could not be updated. */ skipped?: { id: string; reason: 'not_found' | 'error'; }[]; alreadyApplied?: boolean; error?: string; } | null>; export declare function bridgeRecordFeedback(options: { taskType: string; action: string; outcome: 'success' | 'failure' | 'partial'; confidence?: number; metadata?: Record; dbPath?: string; }): Promise<{ success: boolean; id: string; error?: string; } | null>; //# sourceMappingURL=memory-bridge-feedback.d.ts.map