MCPcopy Create free account
hub / github.com/apache/maka / textResultSummary

Function textResultSummary

packages/cli/src/pi-transcript-tools.ts:213–219  ·  view source on GitHub ↗
(text: string)

Source from the content-addressed store, hash-verified

211}
212
213function textResultSummary(text: string): CompactToolSummary {
214 if (!text.trim()) return noOutput();
215 return {
216 text: `${linesText(readBodyLineCount(text))} · ${byteLength(text)} bytes`,
217 protect: true,
218 };
219}
220
221function linesText(count: number): string {
222 return `${count} line${count === 1 ? '' : 's'}`;

Callers 1

compactToolSummaryFunction · 0.85

Calls 5

noOutputFunction · 0.85
linesTextFunction · 0.85
readBodyLineCountFunction · 0.85
byteLengthFunction · 0.70
trimMethod · 0.45

Tested by

no test coverage detected