Disable the cache by default and make it experimental

This commit is contained in:
Louis Dureuil 2025-03-13 14:54:31 +01:00
parent 1876132172
commit e2d372823a
No known key found for this signature in database
14 changed files with 101 additions and 34 deletions

View file

@ -75,9 +75,10 @@ impl EmbedderOptions {
}
impl Embedder {
pub fn new(options: EmbedderOptions) -> Result<Self, NewEmbedderError> {
pub fn new(options: EmbedderOptions, cache_cap: usize) -> Result<Self, NewEmbedderError> {
let rest_embedder = match RestEmbedder::new(
options.into_rest_embedder_config()?,
cache_cap,
super::rest::ConfigurationSource::Ollama,
) {
Ok(embedder) => embedder,