project-rag 0.1.0

RAG-based codebase indexing and semantic search - dual purpose library and MCP server
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
mod fastembed_manager;

pub use fastembed_manager::FastEmbedManager;

use anyhow::Result;

/// Trait for embedding generation
pub trait EmbeddingProvider: Send + Sync {
    /// Generate embeddings for a batch of text
    fn embed_batch(&self, texts: Vec<String>) -> Result<Vec<Vec<f32>>>;

    /// Get the dimension of the embeddings
    fn dimension(&self) -> usize;

    /// Get the model name
    fn model_name(&self) -> &str;
}