MCPcopy
hub / github.com/modelcontextprotocol/servers / deleteObservations

Method deleteObservations

src/memory/index.ts:161–170  ·  view source on GitHub ↗
(deletions: { entityName: string; observations: string[] }[])

Source from the content-addressed store, hash-verified

159 }
160
161 async deleteObservations(deletions: { entityName: string; observations: string[] }[]): Promise<void> {
162 const graph = await this.loadGraph();
163 deletions.forEach(d => {
164 const entity = graph.entities.find(e => e.name === d.entityName);
165 if (entity) {
166 entity.observations = entity.observations.filter(o => !d.observations.includes(o));
167 }
168 });
169 await this.saveGraph(graph);
170 }
171
172 async deleteRelations(relations: Relation[]): Promise<void> {
173 const graph = await this.loadGraph();

Callers 2

index.tsFile · 0.80

Calls 2

loadGraphMethod · 0.95
saveGraphMethod · 0.95

Tested by

no test coverage detected