This commit is contained in:
decolua
2026-06-15 18:18:04 +07:00
parent 8ab5af0052
commit b282f05549
66 changed files with 2328 additions and 213 deletions

View File

@@ -38,3 +38,10 @@ export const AI_MODELS = Object.entries(MODELS).flatMap(([alias, models]) =>
);
export const getModelKind = (m, fallback = null) => m?.kind || m?.type || fallback;
// Capacity metadata for UI badges — icon + label + color per capability.
export const CAPACITY_META = {
vision: { icon: "visibility", label: "Vision", desc: "Supports image input", color: "text-blue-500" },
// search: temporarily hidden (feature not wired yet)
reasoning: { icon: "neurology", label: "Reasoning", desc: "Supports reasoning / thinking", color: "text-amber-500" },
};

View File

@@ -1,5 +1,6 @@
// Provider definitions
import REGISTRY from "open-sse/providers/registry/index.js";
import { RISK_NOTICE } from "@/shared/constants/providersDisplay";
const MEDIA_ENTRY_KEYS = [
"serviceKinds", "ttsConfig", "sttConfig", "embeddingConfig",
@@ -15,8 +16,10 @@ function buildProviderEntry(r) {
for (const k of MEDIA_ENTRY_KEYS) {
if (r[k] !== undefined) mediaFields[k] = r[k];
}
const display = { ...(r.display || {}) };
if (display.deprecationNotice === "RISK_NOTICE") display.deprecationNotice = RISK_NOTICE;
return {
...(r.display || {}),
...display,
id: r.id,
alias: r.uiAlias || r.alias,
...(r.hidden ? { hidden: true } : {}),