MCPcopy Create free account
hub / github.com/MoonshotAI/kimi-code / outputSize

Function outputSize

apps/vis/web/src/lib/analysis.ts:198–209  ·  view source on GitHub ↗
(output: unknown)

Source from the content-addressed store, hash-verified

196}
197
198function outputSize(output: unknown): number {
199 if (typeof output === 'string') return output.length;
200 if (Array.isArray(output)) {
201 let n = 0;
202 for (const part of output) {
203 const text = (part as { text?: string })?.text;
204 n += typeof text === 'string' ? text.length : JSON.stringify(part ?? null).length;
205 }
206 return n;
207 }
208 return 0;
209}
210
211export function analyzeWire(entries: readonly WireEntry[]): Analysis {
212 const turns: TurnNode[] = [];

Callers 1

analyzeWireFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected