MCPcopy Create free account
hub / github.com/CheMiguel23/MemoryMesh / readGraph

Method readGraph

src/application/managers/SearchManager.ts:128–138  ·  view source on GitHub ↗

* Reads and returns the entire knowledge graph.

()

Source from the content-addressed store, hash-verified

126 * Reads and returns the entire knowledge graph.
127 */
128 async readGraph(): Promise<Graph> {
129 try {
130 this.emit('beforeReadGraph', {});
131 const graph = await this.storage.loadGraph();
132 this.emit('afterReadGraph', graph);
133 return graph;
134 } catch (error) {
135 const message = error instanceof Error ? error.message : 'Unknown error occurred';
136 throw new Error(`Failed to read graph: ${message}`);
137 }
138 }
139
140 /**
141 * Initializes the search manager.

Callers

nothing calls this directly

Calls 2

emitMethod · 0.80
loadGraphMethod · 0.65

Tested by

no test coverage detected