@bonginkan/maria
Version:
MARIA OS v5.9.5 – Self-Evolving Organizational Intelligence OS | Speed Improvement Phase 3: LLM Optimization + Command Refactoring | Performance Measurement + Run Evidence System | Zero ESLint/TypeScript Errors | 人とAIが役割を持ち、学び、進化し続けるための仕事のOS | GraphRAG ×
31 lines (29 loc) • 997 B
JavaScript
;
// src/devtools/speed-test.ts
function stringifyInput(input) {
if (typeof input === "string") {
return { s: input, inputType: "string" };
}
try {
return { s: JSON.stringify(input), inputType: typeof input };
} catch {
return { s: String(input), inputType: typeof input };
}
}
async function runSpeedTest(input) {
const startTime = performance.now();
const { s, inputType } = stringifyInput(input);
const duration = performance.now() - startTime;
return `Processed ${s.slice(0, 64)} (len=${s.length}, time=${duration.toFixed(2)}ms, type=${inputType})`;
}
async function legacyRunSpeedTest(input) {
return runSpeedTest(input);
}
async function runSpeedTestWithMetrics(input) {
return runSpeedTest(input);
}
exports.legacyRunSpeedTest = legacyRunSpeedTest;
exports.runSpeedTest = runSpeedTest;
exports.runSpeedTestWithMetrics = runSpeedTestWithMetrics;
//# sourceMappingURL=devtools-speed-test.cjs.map
//# sourceMappingURL=devtools-speed-test.cjs.map