Engram::Embedder
Computes text embeddings via an OpenAI-compatible /v1/embeddings HTTP
endpoint (Ollama, OpenAI, etc). Embeddings are entirely optional: sync
only ever gets one when the caller loaded an EmbedderConfig, and any
transport failure is warned once and swallowed so a dead endpoint never
blocks sync.
Constructors
new(config : EmbedderConfig, &transport : Transport)
Builds an embedder for config using transport to actually fetch vectors.
new(config : EmbedderConfig) : Embedder
Builds an embedder that calls the real OpenAI-compatible HTTP endpoint in config.
Class methods
Instance methods
dimension
SourceEmbeds text into a packed Float32 BLOB, or nil if embedding is
unavailable this sync (either the transport already failed once, or it
fails now). Never raises: a dead endpoint must never block sync.
warned?
Source