Repository navigation
v2.4.0
modelInfoAliases for models.dev lookups
Added modelsDiscovery.modelInfoAliases (Record<string, string>), allowing providers that expose renamed or plan-specific model IDs to map directly to canonical models.dev catalog keys:
- Applies to
"models.dev"and"aiproxy"(which composesmodels.devmetadata); provider-specific formats remain unaffected. - Matches exact discovered IDs and
:tag-stripped IDs; an explicit alias replaces the lookup without falling back to the original ID, while inline provider-advertised limits still take precedence. - On OpenCode v2, changing an alias invalidates cached enrichments for that provider; reordering the same entries does not.
- Validated in OpenCode v1 (
validateConfig) and parsed defensively in OpenCode v2 (parseProviderDiscoveryOptions).
New & enhanced modelInfoFormat options
Three new formats bring the total to 13. Existing litellm configurations keep their original behavior; omniroute users should note the filtering change below. See the configuration guide for examples.
"gproxy": Inline-first GPROXY metadata enricher supporting limits, modalities, tool parameters, and reasoning levels, with an optional single-request catalog supplement whenmodelInfoEndpointis configured."localai": Enriches models from LocalAI's/v1/models/capabilitiesendpoint (context_size, input/output modalities, andchat/vision/tools/thinkingcapability flags)."litellm-inline": Combines/v1/modelsinlinemodeand token limits with/v1/model/infocapability flags (supports_vision,supports_reasoning,supports_function_calling) andoutputlimit fallback, keeping"litellm"unchanged for existing setups."omniroute"enhancements: Falls back tomax_input_tokensfor the context window. WithfilterNonChatenabled (the default), entries declaring a non-chatmodeare skipped; entries without a mode are kept. SetfilterNonChat: falseto keep non-chat entries too.
Documentation & Acknowledgments
- Documented all 13
modelInfoFormatoptions, capability mappings, andmodelInfoAliasesacrossREADME.md,docs/configuration.md, and/models-discovery:config. - Added an Acknowledgments section in
README.mdcreditingopencode-lmstudio.
Dependency & CI updates
- Updated development tooling:
eslint@10.16.0,typescript-eslint@8.74.0,vitest@5.1.2,@vitest/coverage-v8@5.1.2,@types/node@26.6.11. - Updated
hashgraph-online/ai-plugin-scanner-actionto1.2.821. - The runtime still bundles
@opencode/plugin@2.3.2; the v1 SDK (@opencode-ai/plugin) is used for types only.
Compatibility
- On OpenCode v2, discovery no longer forces
compatibility.reasoningFieldtoreasoning_contentfor reasoning models. This lets the host replay the gateway's reasoning fields (including structured reasoning or signatures) in subsequent turns. Reasoning capabilities and effort variants are unchanged (#243). - Existing OpenCode v1 configurations remain supported.
- OpenCode v2 remains the primary supported integration.
- The package continues to publish with no runtime or peer dependencies.