/** * memory-usage-detection.ts, heuristic reference detection (HOISTED to the SDK). * * Did the model's output plausibly USE an injected memory, or was the memory * merely present in the prompt with no detectable trace? Promoted verbatim from * the agent surface so every consumer shares the SAME two-tier honest signal. * * Exactly two tiers: * - 'referenced': the output overlaps this memory's DISTINCTIVE content * (uncommon tokens or a distinctive two-word phrase), so the memory plausibly * mattered to the answer. * - 'present': the memory was injected but nothing in the output distinctively * overlaps it. * * It is NOT a relevance score and NOT ground truth, distinctive-token overlap * can be coincidental, and a memory can influence an answer without lexical * overlap. Everywhere this signal is shown it must be labelled as heuristic * overlap (see MEMORY_USAGE_SIGNAL_NOTE). The bar requires either two distinctive * tokens, one long distinctive token, or a distinctive adjacent phrase, so common * words alone never count as a reference. */ export type MemoryReferenceTier = 'referenced' | 'present'; export interface MemoryReferenceInput { readonly id: string; readonly summary: string; readonly detail?: string | undefined; } export interface MemoryReferenceResult { readonly referenced: readonly string[]; readonly present: readonly string[]; readonly perId: ReadonlyMap; } export declare function detectReferencedMemoryIds(responseText: string, records: readonly MemoryReferenceInput[]): MemoryReferenceResult; //# sourceMappingURL=memory-usage-detection.d.ts.map