Initialize the embeddings table.
(&self)
| 30 | impl Repository { |
| 31 | /// Initialize the embeddings table. |
| 32 | pub fn init_embeddings(&self) -> Result<(), RepositoryError> { |
| 33 | let mut txn = self |
| 34 | .pristine |
| 35 | .write_txn() |
| 36 | .map_err(|e| RepositoryError::Database(e.to_string()))?; |
| 37 | txn.init_embeddings() |
| 38 | .map_err(|e| RepositoryError::Database(e.to_string()))?; |
| 39 | txn.commit() |
| 40 | .map_err(|e| RepositoryError::Database(e.to_string()))?; |
| 41 | Ok(()) |
| 42 | } |
| 43 | |
| 44 | /// Embed a single vault entry using the provided embedding function. |
| 45 | /// |