Files
OmniRoute/src/lib/db/migrations/119_model_capability_overrides.sql
Xiangzhe 0ad07b4d91 feat(models): add capability override UI (#6727)
* feat(models): add capability override UI

Reconstructed onto release/v3.8.47 to drop unrelated main-drift (deps/electron/proxy
files belong to #6620, not this PR); renumbered the migration 118 -> 119 to resolve the
collision with 118_provider_param_filters.sql already on release/v3.8.47; the author's
i18n/localDb deltas were re-applied cleanly onto the release tip.

Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>

* fix(6727): import model-capability-overrides DB fns directly (not via localDb barrel) to keep localDb under file-size cap; aligns with anti-barrel convention

* chore(db): satisfy known-symbols contract for modelCapabilityOverrides

Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>

---------

Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
Co-authored-by: Diego Rodrigues de Sa e Souza <diegosouza.pw@gmail.com>
2026-07-10 18:47:33 -03:00

17 lines
675 B
SQL

-- 119_model_capability_overrides.sql
-- Manual model capability overrides per provider/model target. The UI stores targets
-- in the same provider/model shape used by combos, so provider-specific model caps do
-- not leak across providers that expose the same model id.
CREATE TABLE IF NOT EXISTS model_capability_overrides (
provider TEXT NOT NULL,
model_id TEXT NOT NULL,
override_key TEXT NOT NULL,
override_value TEXT NOT NULL,
refreshed_at TEXT NOT NULL DEFAULT (datetime('now')),
PRIMARY KEY (provider, model_id, override_key)
) WITHOUT ROWID;
CREATE INDEX IF NOT EXISTS idx_model_capability_overrides_key
ON model_capability_overrides (override_key);