18 lines
581 B
TypeScript
18 lines
581 B
TypeScript
/**
|
|
* Telemetry for compressed tools usage tracking
|
|
* Logs to ~/.local/share/mcp/compressed-tools.jsonl
|
|
*/
|
|
export interface TelemetryEvent {
|
|
timestamp: string;
|
|
tool: "compressed_read" | "compressed_grep" | "compressed_glob";
|
|
inputSize: number;
|
|
outputSize: number;
|
|
compressionRatio: number;
|
|
path?: string;
|
|
pattern?: string;
|
|
success: boolean;
|
|
error?: string;
|
|
}
|
|
export declare function logTelemetry(event: Omit<TelemetryEvent, "timestamp">): void;
|
|
export declare function calculateCompressionRatio(original: number, compressed: number): number;
|