Class swarmauri_core.vector_stores.IVectorStoreSaveLoad.IVectorStoreSaveLoad
swarmauri_core.vector_stores.IVectorStoreSaveLoad.IVectorStoreSaveLoad
Bases: ABC
Interface to abstract the ability to save and load the state of a vector store. This includes saving/loading the vectorizer's model as well as the documents or vectors.
save_store
abstractmethod
save_store(directory_path)
Saves the state of the vector store to the specified directory. This includes both the vectorizer's model and the stored documents or vectors.
Parameters: - directory_path (str): The directory path where the store's state will be saved.
Source code in swarmauri_core/vector_stores/IVectorStoreSaveLoad.py
10 11 12 13 14 15 16 17 18 19 | |
load_store
abstractmethod
load_store(directory_path)
Loads the state of the vector store from the specified directory. This includes both the vectorizer's model and the stored documents or vectors.
Parameters: - directory_path (str): The directory path from where the store's state will be loaded.
Source code in swarmauri_core/vector_stores/IVectorStoreSaveLoad.py
21 22 23 24 25 26 27 28 29 30 | |
save_parts
abstractmethod
save_parts(directory_path, chunk_size=10485760)
Save the model in parts to handle large files by splitting them.
Source code in swarmauri_core/vector_stores/IVectorStoreSaveLoad.py
32 33 34 35 36 37 38 | |
load_parts
abstractmethod
load_parts(directory_path, file_pattern)
Load and combine model parts from a directory.
Source code in swarmauri_core/vector_stores/IVectorStoreSaveLoad.py
40 41 42 43 44 45 46 | |