-
Notifications
You must be signed in to change notification settings - Fork 318
Open
Description
Description
Embedding dimensions are hardcoded to 1536 (OpenAI standard) in both the pgvector schema and provider wiring. Self-hosted providers like Ollama with models that output different native dimensions (e.g. qwen3-embedding:8b at 4096) cannot be used for embeddings even though:
- The
WithDimensions()plumbing already exists onOpenAIEmbeddingProvider - Ollama's OpenAI-compatible endpoint supports the
dimensionsparameter for Matryoshka truncation - The DB registry fallback path (
createEmbeddingProvider→ registry) creates providers withoutWithDimensions()
Root Cause
Commit 4db5259 added WithDimensions(1536) only for the Gemini case. The registry-based provider path (commit 1b99406) doesn't call WithDimensions() because all initial providers (OpenAI, OpenRouter) natively output 1536.
Affected Files
internal/config/config.go—MemoryConfigstruct missingEmbeddingDimensionsfieldcmd/gateway_agents.go—createEmbeddingProvider()registry path doesn't apply dimensions
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels