io.github.rog0x/perf
Benchmark, memory, Big O analysis for AI agents
Ask AI about io.github.rog0x/perf
Powered by Claude Β· Grounded in docs
I know everything about io.github.rog0x/perf. Ask me about installation, configuration, usage, or troubleshooting.
0/500
Reviews
Documentation
mcp-perf-tools
Performance analysis tools for AI agents, exposed via the Model Context Protocol (MCP).
Tools
benchmark
Benchmark JavaScript code execution. Run a snippet N times and measure min/max/avg/median/p95/p99 latency and operations per second. Optionally compare two implementations side by side.
Parameters:
code(string) β JavaScript code to benchmarkiterations(number, default 1000) β Number of iterationscompareCode(string, optional) β Second implementation to comparelabelA/labelB(string) β Labels for comparison output
memory_analyze
Analyze Node.js memory usage: heap used/total, RSS, external memory, and array buffers. Takes snapshots over time and uses linear regression to detect trends and potential memory leaks.
Parameters:
actionβ"snapshot"|"analyze"|"clear"
big_o_estimate
Estimate Big O complexity from empirical timing data. Fits measurements against O(1), O(log n), O(n), O(n log n), O(n^2), O(n^3), and O(2^n) using R-squared scoring. Includes an ASCII growth curve visualization.
Parameters:
inputSizes(number[]) β Array of input sizesexecutionTimesMs(number[]) β Corresponding execution times in ms
bundle_analyze
Analyze a JavaScript bundle file: raw size, gzip compressed estimate, detected module count, largest modules, and tree-shaking opportunities (side effects, duplicates).
Parameters:
filePath(string) β Absolute path to the bundle file
load_test
Simple HTTP load tester. Sends N requests at a given concurrency level and reports response time percentiles, error rate, throughput (req/sec), and status code distribution.
Parameters:
url(string) β Target URLtotalRequests(number, default 100) β Total requests to sendconcurrency(number, default 10) β Concurrent request countmethod(string, default "GET") β HTTP methodheaders(object, optional) β HTTP headersbody(string, optional) β Request bodytimeoutMs(number, default 30000) β Request timeout
Setup
npm install
npm run build
Usage with Claude Desktop
Add to your claude_desktop_config.json:
{
"mcpServers": {
"perf-tools": {
"command": "node",
"args": ["D:/products/mcp-servers/mcp-perf-tools/dist/index.js"]
}
}
}
License
MIT
