bench
Measure a Python script's runtime across repeated timed runs with warmup, aggregating mean, standard deviation, and minimum plus raw samples for performance comparisons.
Instructions
Run a Python script n times in the user's interpreter and aggregate its timing. Contract: the script prints one JSON line to stdout containing at least {"ms": } and optionally {"ok": } for a correctness check. Returns mean/std/min over the n timed runs plus every raw sample, so a LEADERBOARD row can cite n and seed.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"script": "<script>"
},
"name": "bench"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| n | No | ||
| cwd | No | ||
| args | No | ||
| script | Yes | ||
| warmup | No | ||
| timeout | No |