@badliveware/pi-model-catalog 0.1.0 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +48 -59
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
# pi-model-catalog
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Adds a `list_pi_models` tool that lets agents inspect Pi's current model registry before choosing or recommending a model.
|
|
4
|
+
|
|
5
|
+
Use it when model choice should depend on what is actually available in your Pi setup: auth status, local support notes, enabled/cycling preferences, context size, capabilities, quota guidance, and optional price data.
|
|
4
6
|
|
|
5
7
|
## Install
|
|
6
8
|
|
|
@@ -8,77 +10,68 @@ Exposes Pi's model registry to the agent as a tool so model choice can be based
|
|
|
8
10
|
pi install npm:@badliveware/pi-model-catalog
|
|
9
11
|
```
|
|
10
12
|
|
|
11
|
-
|
|
13
|
+
No external services or credentials are required beyond the model credentials already configured in Pi.
|
|
12
14
|
|
|
13
|
-
|
|
14
|
-
pi -e /path/to/pi/agent/extensions/public/model-catalog
|
|
15
|
-
```
|
|
15
|
+
## Quick use
|
|
16
16
|
|
|
17
|
-
|
|
17
|
+
Ask the agent to call `list_pi_models` before choosing a model, or use the UI command:
|
|
18
18
|
|
|
19
|
-
|
|
19
|
+
```text
|
|
20
|
+
/models-guide mini
|
|
21
|
+
/models-guide --pricing --relative-to openai-codex/gpt-5.4-mini codex
|
|
22
|
+
```
|
|
20
23
|
|
|
21
|
-
|
|
24
|
+
Tool example:
|
|
22
25
|
|
|
23
|
-
|
|
26
|
+
```json
|
|
27
|
+
{
|
|
28
|
+
"query": "sonnet",
|
|
29
|
+
"includePricing": true,
|
|
30
|
+
"relativeTo": "openai-codex/gpt-5.4-mini"
|
|
31
|
+
}
|
|
32
|
+
```
|
|
24
33
|
|
|
25
|
-
|
|
26
|
-
- `includeUnavailable` — include models without configured auth; defaults to `false`
|
|
27
|
-
- `includeDetails` — include verbose use/avoid guidance; defaults to `false`
|
|
28
|
-
- `includePricing` — include numeric registry prices in $/million tokens; defaults to `false`
|
|
29
|
-
- `relativeTo` — optional baseline model id such as `openai-codex/gpt-5.4`; with `includePricing`, adds relative input/output/blended ratios
|
|
30
|
-
- `unsupported` — how to handle locally unsupported models: `exclude` (default), `include`, or `only`
|
|
34
|
+
## What it returns
|
|
31
35
|
|
|
32
|
-
Default
|
|
36
|
+
Default output is intentionally compact:
|
|
33
37
|
|
|
34
|
-
- full model id
|
|
38
|
+
- full model id, with `*` on the current model
|
|
35
39
|
- `auth`, `support`, and `enabled` status
|
|
36
40
|
- context and max output tokens
|
|
37
|
-
-
|
|
38
|
-
- price
|
|
39
|
-
-
|
|
40
|
-
- quota guidance tier
|
|
41
|
+
- capability marker: `text`, `think`, `img`, or `think+img`
|
|
42
|
+
- price tier and rough relative cost
|
|
43
|
+
- quota/scarcity guidance
|
|
41
44
|
|
|
42
|
-
|
|
45
|
+
Pass `includeDetails: true` for verbose use/avoid guidance. Pass `includePricing: true` for numeric input/output prices and relative ratios.
|
|
43
46
|
|
|
44
|
-
|
|
45
|
-
- verbose use/avoid guidance with `includeDetails`
|
|
47
|
+
## Tool parameters
|
|
46
48
|
|
|
47
|
-
|
|
49
|
+
| Parameter | What it does |
|
|
50
|
+
| --- | --- |
|
|
51
|
+
| `query` | Optional substring filter such as `mini`, `codex`, or `sonnet`. |
|
|
52
|
+
| `includeUnavailable` | Include models without configured auth. Default: `false`. |
|
|
53
|
+
| `includeDetails` | Include verbose use/avoid guidance. Default: `false`. |
|
|
54
|
+
| `includePricing` | Include numeric registry prices in $/million tokens. Default: `false`. |
|
|
55
|
+
| `relativeTo` | Baseline model id for relative price ratios. |
|
|
56
|
+
| `unsupported` | `exclude`, `include`, or `only` locally unsupported models. Default: `exclude`. |
|
|
48
57
|
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
| Tier | Rule |
|
|
52
|
-
| --- | ---: |
|
|
53
|
-
| `free/local` | locally run model; no metered API cost |
|
|
54
|
-
| `unknown/sub` | no numeric input/output price |
|
|
55
|
-
| `low` | `<= $1/M` blended |
|
|
56
|
-
| `medium` | `<= $8/M` blended |
|
|
57
|
-
| `high` | `<= $30/M` blended |
|
|
58
|
-
| `premium` | `> $30/M` blended |
|
|
59
|
-
| `premium-speed` | `-spark` models, special-cased |
|
|
58
|
+
## Command
|
|
60
59
|
|
|
61
|
-
|
|
60
|
+
| Command | What it does |
|
|
61
|
+
| --- | --- |
|
|
62
|
+
| `/models-guide [query]` | Show the concise available-model table. |
|
|
63
|
+
| `/models-guide --verbose [query]` | Include verbose use/avoid guidance. |
|
|
64
|
+
| `/models-guide --pricing --relative-to <model> [query]` | Include numeric pricing and ratios. |
|
|
62
65
|
|
|
63
|
-
|
|
66
|
+
## Local support notes
|
|
64
67
|
|
|
65
|
-
|
|
68
|
+
Some providers report a model as authenticated even when a specific account cannot use it. Add local unsupported-model notes in:
|
|
66
69
|
|
|
67
|
-
```
|
|
68
|
-
|
|
69
|
-
"query": "openai-codex gpt-5.4",
|
|
70
|
-
"includePricing": true,
|
|
71
|
-
"relativeTo": "openai-codex/gpt-5.4"
|
|
72
|
-
}
|
|
70
|
+
```text
|
|
71
|
+
~/.pi/agent/model-catalog.json
|
|
73
72
|
```
|
|
74
73
|
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
Some models can appear in Pi's registry and pass auth checks but still fail for a specific account/provider pairing. Public package defaults do not mark any account-specific model as unsupported; add local entries when your provider/account has known incompatibilities.
|
|
78
|
-
|
|
79
|
-
Locally unsupported models are excluded by default so agents do not choose them accidentally. Call `list_pi_models` with `unsupported: "include"` to show them with a `support: no` column and reason, or `unsupported: "only"` to inspect only unsupported entries.
|
|
80
|
-
|
|
81
|
-
You can add local unsupported entries in `~/.pi/agent/model-catalog.json`:
|
|
74
|
+
Example:
|
|
82
75
|
|
|
83
76
|
```json
|
|
84
77
|
{
|
|
@@ -91,12 +84,8 @@ You can add local unsupported entries in `~/.pi/agent/model-catalog.json`:
|
|
|
91
84
|
}
|
|
92
85
|
```
|
|
93
86
|
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
- `/models-guide [query]` — show the concise available-model table in the UI
|
|
97
|
-
- `/models-guide --verbose [query]` — include verbose use/avoid guidance
|
|
98
|
-
- `/models-guide --pricing --relative-to openai-codex/gpt-5.4 openai-codex gpt-5` — include numeric pricing and ratios in the UI table
|
|
87
|
+
Unsupported models are excluded by default so agents do not choose them accidentally.
|
|
99
88
|
|
|
100
|
-
##
|
|
89
|
+
## Price and quota caveats
|
|
101
90
|
|
|
102
|
-
|
|
91
|
+
`price-tier`, numeric prices, and quota labels are guidance from Pi's local model registry, not live billing or remaining quota. For subscription-backed providers, numeric prices may be nominal weights rather than direct billing.
|