Module storage

Module storage 

Source
Expand description

Storage layer abstraction.

This module provides a three-layer storage architecture:

  • Persistence: Authoritative storage (SQLite, PostgreSQL, Filesystem)
  • Index: Full-text search (SQLite + FTS5, PostgreSQL, RediSearch)
  • Vector: Embedding similarity search (usearch, pgvector, Redis)

Re-exports§

pub use bulkhead::BulkheadIndexBackend;
pub use bulkhead::BulkheadPersistenceBackend;
pub use bulkhead::BulkheadVectorBackend;
pub use bulkhead::StorageBulkheadConfig;
pub use context_template::ContextTemplateBackendType;
pub use context_template::ContextTemplateDbStats;
pub use context_template::ContextTemplateStorage;
pub use context_template::ContextTemplateStorageFactory;
pub use context_template::SqliteContextTemplateStorage;
pub use index::get_user_data_dir;
pub use prompt::FilesystemPromptStorage;
pub use prompt::PostgresPromptStorage;
pub use prompt::PromptBackendType;
pub use prompt::PromptStorage;
pub use prompt::PromptStorageFactory;
pub use prompt::RedisPromptStorage;
pub use prompt::SqlitePromptStorage;
pub use resilience::ResilientIndexBackend;
pub use resilience::ResilientPersistenceBackend;
pub use resilience::ResilientVectorBackend;
pub use resilience::StorageResilienceConfig;
pub use resilience::is_retryable_storage_error;
pub use resilience::retry_connection;
pub use traits::IndexBackend;
pub use traits::PersistenceBackend;
pub use traits::VectorBackend;
pub use group::GroupBackend;
pub use group::GroupBackendType;
pub use group::GroupStorageFactory;
pub use group::SqliteGroupBackend;

Modules§

bulkhead
Bulkhead pattern implementation for storage operations.
context_template
Context template storage backends.
graph
Graph storage backends for knowledge graph operations.
group
Group storage backends.
index
Index backend implementations.
migrations
PostgreSQL migration system for schema management.
persistence
Persistence backend implementations.
prompt
Prompt storage backends.
resilience
Storage resilience wrapper with circuit breaking.
traits
Storage backend traits.
vector
Vector backend implementations.

Structs§

CompositeStorage
Composite storage combining all three layers.