orchestrata_ultimate.semantic_graph

Reference › orchestrata_ultimate › semantic_graph

Semantic graph repository abstraction for RAG / GraphRAG.

The semantic_graph package is the retrieval layer for RAG and GraphRAG over the codebase and its specs. It owns the shared semantic graph, the memgraph database on Memgraph Community, and is distinct from the operational knowledge graph (orchkg on orchgraph) maintained by knowledge_graph. The two meet only in semantic_bridge and in architecture_twin, which reads the operational graph and writes the semantic one.

The parts, by role:

Callers obtain a backend from create_semantic_graph, ingest chunks and entities, and later query with retrieve or the ingester's search. The public classes are re-exported by init. The command-line entry point in this package is ha_controller_cli; the ingestion and enrichment pipelines are driven by repository scripts. Start reading with interfaces, then adapters/memory, then ingestion. The narrative is on the semantic_graph module page.

Curated narrative

The hand-written story of this package: orchestrata_ultimate.semantic_graph.

20 modules, 5,437 lines of code.

Subpackages

Package Modules LOC
adapters 3 1,378

Modules

Module Summary LOC
__init__ Semantic graph repository abstraction for RAG / GraphRAG. 79
_freshness Content-hash based freshness tracking for semantic-graph re-ingestion. 132
architecture_twin Memgraph semantic twin of the ratified architecture ontology (ruling 4). 353
config Configuration for semantic graph backends. 132
embedder_factory Which embedding backend — a choice, where it used to be a constant. 212
embedders Embedding backends for the semantic graph. 400
exceptions Exceptions for the semantic_graph package. 23
ha_controller High-availability controller for Memgraph Community replication. 588
ha_controller_cli CLI entry point for the Memgraph HA controller. 185
ingestion Source-code ingestion into a semantic graph. 494
interfaces Repository interfaces for semantic graph / RAG / GraphRAG. 85
main_discovery Client-side discovery of the current Memgraph MAIN data-instance bolt URI. 162
models Data models for semantic graph / RAG / GraphRAG. 70
repository Repository factory for semantic graph backends. 53
rerankers Reranking backend for semantic graph retrieval. 144
spec_trace_enricher Enrich the semantic graph with spec, story, requirement, and trace entities. 455
spec_trace_parser Parse Orchestrata specs and @traces annotations into structured data. 492

Dependency diagram

Package dependency diagram orchestrata_ultimate.semantic_graph