MCPcopy Create free account
hub / github.com/Roy3838/Observer / getAgentImageMemory

Function getAgentImageMemory

app/src/utils/agent_database.ts:326–340  ·  view source on GitHub ↗
(agentId: string)

Source from the content-addressed store, hash-verified

324
325// Get agent image memory
326export async function getAgentImageMemory(agentId: string): Promise<string[]> {
327 const db = await openDB();
328
329 return new Promise((resolve, reject) => {
330 const tx = db.transaction(IMAGE_MEMORY_STORE, 'readonly');
331 const store = tx.objectStore(IMAGE_MEMORY_STORE);
332 const request = store.get(agentId);
333
334 request.onsuccess = () => {
335 const result = request.result;
336 resolve(result ? result.images : []);
337 };
338 request.onerror = () => reject(request.error);
339 });
340}
341
342// Get all image memory entries
343export async function getAllImageMemories(): Promise<Array<{ id: string; images: string[] }>> {

Callers 8

loadImageMemoryFunction · 0.90
loadImagesFunction · 0.90
handleMemoryUpdateFunction · 0.90
pre-processor.tsFile · 0.90
executeJavaScriptFunction · 0.90
createApiFunction · 0.90
installE2EHooksFunction · 0.90
appendAgentImageMemoryFunction · 0.85

Calls 1

openDBFunction · 0.85

Tested by

no test coverage detected