fix(coding-agent): make models.json model fields optional with defaults
Model definitions now only require 'id'. All other fields have sensible
defaults for local models (Ollama, LM Studio, etc.):
- name: defaults to id
- reasoning: defaults to false
- input: defaults to ["text"]
- cost: defaults to {input: 0, output: 0, cacheRead: 0, cacheWrite: 0}
- contextWindow: defaults to 128000
- maxTokens: defaults to 16384
Existing configs that specify all fields continue to work unchanged.
Fixes #1146
This commit is contained in:
@@ -12,6 +12,7 @@
|
||||
### Fixed
|
||||
|
||||
- Fixed `pi update` not updating npm/git packages when called without arguments ([#1151](https://github.com/badlogic/pi-mono/issues/1151))
|
||||
- Fixed `models.json` validation requiring fields documented as optional. Model definitions now only require `id`; all other fields (`name`, `reasoning`, `input`, `cost`, `contextWindow`, `maxTokens`) have sensible defaults. ([#1146](https://github.com/badlogic/pi-mono/issues/1146))
|
||||
|
||||
## [0.50.9] - 2026-02-01
|
||||
|
||||
|
||||
Reference in New Issue
Block a user