Commit 5771b7c
authored
Release v1.2.1 (#24)
* fix: correct DEFAULT_CONTEXT_LIMIT from 4096 to 128000
OmniRoute 3.7.9 does not expose contextWindow/context_length/max_input_tokens
in /v1/models responses. When these fields are missing, the plugin falls back
to DEFAULT_CONTEXT_LIMIT.
The previous value of 4096 was incorrect - that's a reasonable output token
limit, but context windows for modern LLMs are 128K+. This caused OpenCode
to display 4096 token context windows for models like kmc/kimi-k2.6.
Changed DEFAULT_CONTEXT_LIMIT to 128000 to match the plugin's own default
models (gpt-4o, gpt-4o-mini, llama-3.1-405b all use 128000).
Fixes #19
* feat(models.dev): improve enrichment reliability with retries and stale cache fallback
- Increase default timeout from 1000ms to 5000ms
- Add bounded retry loop (max 3 attempts, backoff 250ms/500ms)
- Add stale in-memory cache fallback when live refresh fails
- Add structured failure classification (timeout, network, http_retryable,
http_non_retryable, parse, invalid_structure)
- Add improved logging for fetch attempts, failures, and fallback decisions
- Keep all changes localized to src/models-dev.ts
- Add 8 focused tests covering fresh cache, retries, stale fallback,
fail-fast, and integration paths
All 50 tests pass (0 regressions).
* chore: remove opencode test config
* chore(release): bump version to 1.4.1 and update changelog
- Update package.json version from 1.2.0 to 1.4.1
- Add CHANGELOG.md entry for v1.4.1
- Add docs/release-notes-v1.4.1.md with release highlights and verification steps
* fix(review): address PR #22 code review feedback
- Cache isolation: key models.dev cache by URL (Map) to prevent cross-config
data leakage when different configs specify different modelsDev.url values
- Update outdated JSDoc comment for timeoutMs default (1000ms -> 5000ms)
- Eliminate real setTimeout sleeps from tests by using cacheTtl: 0 for
stale-cache scenarios instead of waiting for TTL expiry
- Document worst-case cold-start latency (~15.75s) in fetchModelsDevData JSDoc
- Update package-lock.json version to 1.4.1 (file is .gitignored but kept
in sync locally)
- Update CHANGELOG.md and release notes with code review fixes section
All 50 tests pass (0 regressions).
* docs: add model variant support fix design spec
* feat: model variant support fix — grouping, xhigh🧠, synthetic bases 🎸, getModelFamily🧑🧑🧒🧒 fix (#23)
* docs: add model variant support fix design spec
* feat(types,models): add variant grouping and xhigh support
- Add variants field to OmniRouteModel interface
- Add xhigh to reasoningEffort type
- Implement groupVariantModels() pure function
- Integrate grouping into fetchModels() pipeline between dedup and enrich
* feat(plugin): use model.variants in toProviderModel and fix getModelFamily
- toProviderModel() now prioritizes pre-populated model.variants over generated defaults
- getModelFamily() strips provider prefix before extracting family name
- Fixes incorrect family extraction for provider-prefixed versioned models
* test(plugin): add variant grouping tests and fix cache isolation
- Add cache clearing (clearModelCache, clearModelsDevCache) to afterEach
- Add test: provider hook groups variant models under base model
- Add test: provider hook creates synthetic base model when only variants are returned
- Prevents cross-test contamination from mutable in-memory caches
* docs: update CHANGELOG and release notes for model variant support fix
- Add Model Variant Support Fix section to CHANGELOG.md (grouped under Added/Fixed)
- Update docs/release-notes-v1.4.1.md with:
- New highlight for variant grouping
- Detailed Model Variant Support Fix section with edge cases table
- getModelFamily() fix for provider-prefixed models
- Updated test count (52 tests)
- New design spec reference
* refactor(models): remove redundant toLowerCase and drop docs/superpowers
- Remove redundant suffix.toLowerCase() in groupVariantModels() — suffix is
already lowercased when extracted from the model ID via slice() at line 184.
Replaced with direct string literal comparison which also narrows the type
for TypeScript. (gemini-code-assist review feedback)
- Remove docs/superpowers/ directory from repository — design specs are
development artifacts that don't need to be in the source tree.
- Update release notes to remove design spec file references.
* chore(release): keep superpowers artifacts local
* chore(release): correct version to 1.2.1
* fix(review): address release PR feedback1 parent 4362383 commit 5771b7c
18 files changed
Lines changed: 882 additions & 2468 deletions
File tree
- .opencode
- docs
- superpowers
- plans
- specs
- src
- test
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
43 | 43 | | |
44 | 44 | | |
45 | 45 | | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
This file was deleted.
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
5 | 61 | | |
6 | 62 | | |
7 | 63 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
0 commit comments