Configure embedding providers for semantic search in Cognee
.env
→ choose providers → handle pruning.Environment Variables
.env
file:EMBEDDING_PROVIDER
— The provider to use (openai, gemini, mistral, ollama, fastembed, custom)EMBEDDING_MODEL
— The specific embedding model to useEMBEDDING_DIMENSIONS
— The vector dimension size (must match your vector store)EMBEDDING_API_KEY
— Your API key (falls back to LLM_API_KEY
if not set)EMBEDDING_ENDPOINT
— Custom endpoint URL (for Azure, Ollama, or custom providers)EMBEDDING_API_VERSION
— API version (for Azure OpenAI)EMBEDDING_MAX_TOKENS
— Maximum tokens per request (optional)OpenAI (Default)
Azure OpenAI Embeddings
Google Gemini
Mistral
Ollama (Local)
Fastembed (Local)
Custom Providers
Rate Limiting
Testing and Development
EMBEDDING_DIMENSIONS
must match your vector store collection schemaEMBEDDING_API_KEY
is not set, Cognee uses LLM_API_KEY
(except for custom providers)HUGGINGFACE_TOKENIZER
for proper token counting