Summary of changes:
┌──────┬──────────────────────────────────────────────────────────────────┬──────────┐
│ Step │ Change │ Result │
├──────┼──────────────────────────────────────────────────────────────────┼──────────┤
│ 1 │ Removed duplicate llm-performance-metrics.test.ts │ 14 tests │
├──────┼──────────────────────────────────────────────────────────────────┼──────────┤
│ 2 │ Added rawTimestamps assertions to toLogEntry test │ 14 tests │
├──────┼──────────────────────────────────────────────────────────────────┼──────────┤
│ 3 │ Added rawTimestamps assertions to single-turn aggregate test │ 14 tests │
├──────┼──────────────────────────────────────────────────────────────────┼──────────┤
│ 4 │ Added rawTimestamps assertions to multi-turn aggregate test │ 14 tests │
├──────┼──────────────────────────────────────────────────────────────────┼──────────┤
│ 5 │ Added negative TTFT filtering test │ 15 tests │
├──────┼──────────────────────────────────────────────────────────────────┼──────────┤
│ 6 │ Added "first turn missing TTFT, later turns have it" test │ 16 tests │
├──────┼──────────────────────────────────────────────────────────────────┼──────────┤
│ 7 │ Added sanity check tests (warn on >500 tok/s, no warn otherwise) │ 18 tests │
└──────┴──────────────────────────────────────────────────────────────────┴──────────┘
This is what it looks like now when I run `pi`
📊 Performance: llama.cpp/Qwen3.6-35B-A3B-MXFP4_MOE.gguf
Prefill: 15,460 tokens @ 20104.0 tok/s
Generation: 12,179 tokens @ 52.6 tok/s
Combined: 27,639 tokens @ 118.9 tok/s (3.9m total)
TTFT: 769ms
Turns: 36
monotonic-pi-extensions
Experimental monorepo for Pi coding agent extensions.
Extensions
pi-turn-limit
Limits the number of turns (agent round-trips) in a Pi session. When the limit is reached, the user is prompted to continue or abort.
- Default limit: 25 turns
- Override: set
PI_MAX_TURNSenvironment variable to a positive integer - Unlimited: set
PI_MAX_TURNS=unlimitedor run theturn-limit unlimitedcommand to disable the boundary check entirely (the counter still increments for observability) - Re-enable: switch from unlimited back to a number via
turn-limit <N>; the counter resets to 0
See packages/pi-turn-limit/README.md for details and the Allium spec.
Installation
This is an early release — not on npm yet. To install from source:
# Clone the repo
git clone <repo-url>
cd pi-extensions
# Install dependencies
pnpm install
# Link the extension (or reference it directly in your Pi config)
Starting pi in this repository will load the turn-limit extension. Make sure you sandbox it properly, e.g. with 'nono', Docker or a VM. Extensions have not been security checked etc.
Repository Status
Experimental. APIs and behavior may change without notice. Feedback welcome.
Languages
TypeScript
100%