klieo-memory-graph-rag
Graph-first RAG composer over klieo-memory-graph::KnowledgeGraph +
klieo-core::LongTermMemory.
Status: stable at 3.x. Trait freeze contract recorded in ADR-039.
Layers
klieo-core(Layer 0) — frozen at 3.2.0klieo-memory-graph(Layer 1) —KnowledgeGraphtraitklieo-memory-graph-neo4j(Layer 2) — Neo4j backendklieo-memory-qdrant(Layer 1) — vector store withFilterableLongTermMemoryklieo-memory-graph-rag(Layer 2) — this crate
What's in the crate
BuiltinExtractor(regex + caller-hint dedup)FallbackExtractor(primary → secondary on empty)LlmEntityExtractor(klieo-core::llm + JSON-array prompt)NullProvenancestub (M4 replaces with aklieo-provenancebridge)GraphAwareLongTerm— drop-inLongTermMemoryimplKnowledgeIngestionPipeline+ImportSourceextension point
Quickstart — builder facade
GraphAwareLongTerm::builder() defaults the extractor
(BuiltinExtractor) and the metrics counter (RecallMetrics::default())
so callers only supply the two mandatory backends — the authoritative
vector store and the graph index:
use Arc;
use ;
use GraphAwareLongTerm;
#
Override defaults via the builder's setters:
use Arc;
use RecallMetrics;
use ;
# # where
# V: FilterableLongTermMemory + 'static,
# G: KnowledgeGraph + 'static,
#
Read metrics.snapshot() from an ops/metrics endpoint to see graph
hit-rate vs vector-fallback rate.
Full M2 wiring
use Arc;
use GraphAwareLongTerm;
use Neo4jKnowledgeGraph;
use MemoryNeo4j;
use MemoryQdrant;
# async
Advanced wiring — direct constructor
GraphAwareLongTerm::new(vector, graph, extractor, metrics) stays
available for callers that want explicit control over every component.
For ingest from external sources (Confluence pages, regulatory texts,
…) implement ImportSource in your own crate and pass it to
KnowledgeIngestionPipeline::new.
License
MIT.