agentfootprint
Version:
The explainable agent framework — backtrack a wrong answer to the exact context that caused it (evidence, not guesses). Built on footprintjs.
19 lines (18 loc) • 1.08 kB
TypeScript
import type { MemoryFlavor } from '../../memory/define.types.js';
import type { ActiveInjection } from '../../injection-engine/types.js';
/**
* What a memory needs to be bridged: its id, and the claim its block is
* making. A bare string keeps the historical call shape working.
*/
export interface MemoryRecallSource {
readonly id: string;
/** `'rag'` composes as `source: 'rag'`; anything else as `'memory'`. */
readonly flavor?: MemoryFlavor;
}
/** Build recall ActiveInjections from the per-id recall keys in `parent`. */
export declare function memoryRecallInjections(parent: Record<string, unknown>, memories: readonly (string | MemoryRecallSource)[]): ActiveInjection[];
/**
* Append memory recalls to the active-injection set a slot-fork inputMapper hands to
* the system / messages slot subflows. No-op when the agent has no memories.
*/
export declare function withMemoryRecall(activeInjections: readonly ActiveInjection[] | undefined, parent: Record<string, unknown>, memories: readonly (string | MemoryRecallSource)[]): readonly ActiveInjection[];