singularity-forge/packages
Jeremy McSpadden 155c32e01b fix: strip model variant suffix for API key auth (#1097) (#1099)
* fix: strip model variant suffix for all auth methods, not just OAuth (#1097)

The model ID variant suffix (e.g., `[1m]` in `claude-opus-4-6[1m]`) was
only stripped for OAuth token auth. When using an API key, the suffix was
sent to the Anthropic API as-is, causing a 400 "upstream_error" because
`claude-opus-4-6[1m]` is not a valid API model ID.

The default Anthropic model is `claude-opus-4-6[1m]` (1M context variant),
so every API key user hits this on every request.

Fix: strip `[...]` suffix unconditionally for all auth methods.

* fix: update source-reading tests for post-refactor file locations

triage-dispatch.test.ts: read auto-post-unit.ts (dispatch logic moved
from auto.ts) and update comment string matches to reflect renamed
section headers.

token-profile.test.ts: read preferences-types.ts, preferences-validation.ts,
and preferences-models.ts (GSDPreferences interface and validation logic
split from preferences.ts).
2026-03-17 23:31:40 -06:00
..
native fix: add missing package.json subpath exports and oauth stubs (#1014) 2026-03-17 18:01:56 -06:00
pi-agent-core fix: add exports fields to pi-tui and pi-agent-core packages (#991) 2026-03-17 17:05:47 -06:00
pi-ai fix: strip model variant suffix for API key auth (#1097) (#1099) 2026-03-17 23:31:40 -06:00
pi-coding-agent fix: improve LSP diagnostics when no servers detected (#1082) (#1086) 2026-03-17 21:45:11 -06:00
pi-tui chore: fix chalk version mismatch and document pinned dependency rationale (#1030) 2026-03-17 18:29:31 -06:00