Skip to Content

eagerEmbedContent

eagerEmbedContent(content: string, embeddingOptions: MemoryEngineEmbeddingOptions, cache: VaultEmbeddingCache, vaultCtx?: VaultMemoryOperationsContext, memoryId?: string, updatedAt?: Date): Promise<void>

Defined in: src/lib/memoryVault/searchTool.ts:1298 

Eagerly embed a single piece of content and store it in the cache. Call this when a vault memory is created or updated.

Parameters

ParameterTypeDescription

content

string

‐

embeddingOptions

MemoryEngineEmbeddingOptions

‐

cache

VaultEmbeddingCache

‐

vaultCtx?

VaultMemoryOperationsContext

‐

memoryId?

string

‐

updatedAt?

Date

updatedAt of the committed row this content belongs to. When given, the cache entry is tied to that row version; without it the entry is unversioned and a search re-resolves it from the stored column instead of trusting it (see vectorVersion.ts).

Returns

Promise<void>

Last updated on