Expand description
Qdrant-backed implementation of klieo_core::memory::LongTermMemory.
MemoryQdrant::connect(url) is the capability-shaped default —
connects to a Qdrant gRPC URL, ensures the per-scope collection
exists with the embedder’s vector dimension, and returns an
Arc<dyn LongTermMemory> ready to drop into
klieo_core::AgentContext. Defaults to DummyEmbedder and a
standard QdrantConfig.
For a custom QdrantConfig (API key, collection prefix,
plaintext-remote opt-in) or a real Embedder, reach for
MemoryQdrant::new directly.
§Quickstart
use klieo_memory_qdrant::MemoryQdrant;
async fn example() {
let mem = MemoryQdrant::connect("http://127.0.0.1:6334").await.unwrap();
let _ = mem.long_term;
}§Advanced wiring — custom config + embedder
use klieo_memory_qdrant::{MemoryQdrant, QdrantConfig, DummyEmbedder};
use std::sync::Arc;
async fn example() {
let cfg = QdrantConfig::new("http://qdrant.internal:6334")
.with_api_key("supersecret")
.with_collection_prefix("triage");
let mem = MemoryQdrant::new(cfg, Arc::new(DummyEmbedder)).await.unwrap();
let _ = mem.long_term;
}§What’s implemented
Only LongTermMemory. ShortTermMemory and EpisodicMemory are
not Qdrant-shaped — see klieo-memory-sqlite and
klieo-memory-neo4j for those.
Re-exports§
pub use client::QdrantConfig;pub use long_term::QdrantLongTerm;pub use factory::MemoryQdrant;
Modules§
- client
- Qdrant connection configuration + bootstrap helpers.
- embedder
- Re-exports of the shared
Embeddertrait + dummy/fake impls. - error
- Error mapping from
qdrant_clienterrors toklieo_core::error::MemoryError. - factory
MemoryQdrant— convenience factory wrapping theLongTermMemoryhandle in anArc<dyn …>ready forAgentContext.- long_
term QdrantLongTerm—LongTermMemoryover a single Qdrant collection with scope filtering on the payload.
Structs§
- Dummy
Embedder - Default embedder that returns zero vectors.
- Fake
Embedder - Test-only embedder that hashes each input text into a deterministic vector. Identical texts produce identical embeddings, so cosine recall behaves predictably under test.
Traits§
- Embedder
- Compute embeddings for one or more texts.