@aksolab/recall
Version:
A memory management package for AI SDK memory functionality
31 lines • 1.51 kB
TypeScript
import { CoreMessage } from 'ai';
import { MemoryState, CoreMemoryEntry, ArchiveEntry } from '../../types';
import { StorageProvider } from '../storage-provider';
export declare class InMemoryProvider implements StorageProvider {
private storage;
private chatHistoryStorage;
private coreMemoryStorage;
private archiveMemoryStorage;
flush(): Promise<void>;
export(memoryKey: string, threadId?: string): Promise<MemoryState>;
getMemoryState(memoryKey: string): Promise<MemoryState | undefined>;
initializeMemoryState(memoryKey: string, threadId: string, previousState?: MemoryState): Promise<MemoryState>;
updateChatHistory({ memoryKey, threadId, messages }: {
memoryKey: string;
threadId: string;
messages: CoreMessage[];
}): Promise<void>;
addChatHistoryMessage({ memoryKey, message, threadId }: {
memoryKey: string;
message: CoreMessage;
threadId: string;
}): Promise<void>;
getCoreMemory(memoryKey: string): Promise<Record<string, CoreMemoryEntry> | null>;
updateCoreMemory(key: string, memory: Record<string, CoreMemoryEntry> | null): Promise<void>;
updateArchiveMemory(key: string, entries: ArchiveEntry[]): Promise<void>;
deleteMemoryState(memoryKey: string): Promise<void>;
getChatHistoryKey(memoryKey: string, threadId?: string): string;
getCoreMemoryKey(memoryKey: string): string;
getArchiveMemoryKey(memoryKey: string): string;
}
//# sourceMappingURL=InMemoryProvider.d.ts.map