pi-model-picker
v1.0.0
Published
Categorized, keyboard-driven model selector for the pi coding agent
Maintainers
Readme
pi-model-picker
A categorized, keyboard-driven model selector extension for the pi coding agent.
Instead of a flat searchable list, models are grouped by provider in horizontal tabs. Switch categories with Tab or arrow keys, type to filter within a category, and navigate with ↑/↓.
Preview
╔═════════════════════════════════════════════════════════════════╗
║ Select Model ║
╠═════════════════════════════════════════════════════════════════╣
║◀ Anthropic │ Google │ Cliproxyapi │ Ollama ▶ ║
║─────────────────────────────────────────────────────────────────║
║ Search: claude_ ║
║─────────────────────────────────────────────────────────────────║
║▶ Claude Sonnet 4.6 ● 200k thinking ║
║ Claude Opus 4.5 200k thinking ║
║ Claude Haiku 3.5 200k vision ║
║─────────────────────────────────────────────────────────────────║
║ ↑↓ navigate · Tab/← → category · enter select · esc ║
╚═════════════════════════════════════════════════════════════════╝- Active model shown with
●and highlighted in green - Context window shown as
200k,1M, etc. - Capability tags:
thinking(extended reasoning),vision(image input) - Search filters by model name or id within the current category
- Search term preserved per category — switch away and back, your query is still there
- Wraparound navigation —
↑on the first item jumps to the last, and vice versa
Install
Via npm (recommended)
npm install -g pi-model-picker
pi-model-pickerRestart pi after installation.
Via pi package manager
pi install npm:pi-model-pickerVia git
pi install git:github.com/rilham97/pi-model-pickerManual
git clone https://github.com/rilham97/pi-model-picker.git \
~/.pi/agent/extensions/model-pickerRestart pi.
Usage
| Trigger | Description |
|---------|-------------|
| /models | Open the categorized picker |
| Ctrl+Shift+M | Keyboard shortcut |
Note:
/modelis a built-in pi command and cannot be overridden. Use/models(with ans) for this picker. The built-in/model(flat search) continues to work as normal.
Controls
| Key | Action |
|-----|--------|
| ↑ / ↓ | Navigate models (wraps around) |
| Tab / Shift+Tab | Switch provider category |
| ← / → | Switch category (when search field is empty) |
| ← / → | Move cursor in search field (when field has text) |
| Type | Filter models in the current category |
| Enter | Select highlighted model |
| Esc | Cancel |
How it works
The picker calls modelRegistry.refresh() then modelRegistry.getAvailable() — the same data source as pi's built-in /model command. Only models with auth configured (API key or OAuth) are shown. Models are grouped by their provider field and sorted alphabetically within each category, with the currently active model's provider appearing first.
Uninstall
pi remove npm:pi-model-picker
rm -rf ~/.pi/agent/extensions/model-pickerLicense
MIT
