Ollama Embedder
Last updated
Last updated
The OllamaEmbedder
can be used to embed text data into vectors locally using Ollama.
The model used for generating embeddings needs to run locally.
cookbook/embedders/ollama_embedder.py
model
str
"openhermes"
The name of the model used for generating embeddings.
dimensions
int
4096
The dimensionality of the embeddings generated by the model.
host
str
-
The host address for the API endpoint.
timeout
Any
-
The timeout duration for API requests.
options
Any
-
Additional options for configuring the API request.
client_kwargs
Optional[Dict[str, Any]]
-
Additional keyword arguments for configuring the API client. Optional.
ollama_client
Optional[OllamaClient]
-
An instance of the OllamaClient to use for making API requests. Optional.