MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / readNode

Function readNode

graph-ui/src/traces/trace-schemas.ts:107–123  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

105}
106
107function readNode(value: unknown): TraceNode {
108 const record = isRecord(value) ? value : {};
109 const node: TraceNode = { name: text(record['name']) };
110 const id = num(record['id']);
111 if (id !== undefined) {
112 node.id = id;
113 }
114 const filePath = text(record['file_path']);
115 if (filePath.length > 0) {
116 node.filePath = filePath;
117 }
118 const observed = readObserved(record['observed']);
119 if (observed !== undefined) {
120 node.observed = observed;
121 }
122 return node;
123}
124
125export function readTraceAnswer(raw: unknown): TraceAnswer {
126 const record = isRecord(raw) ? raw : {};

Callers 2

readFlowSummariesFunction · 0.70
readFlowDetailFunction · 0.70

Calls 4

readObservedFunction · 0.85
isRecordFunction · 0.70
textFunction · 0.70
numFunction · 0.70

Tested by

no test coverage detected