WikifitaGitHub live67e8de5
projeto · infraestrutura/fitalabs-gateway-modelos

FitaLabs Gateway — Model Configuration

Documentation: FitaLabs Gateway — Model Configuration

Baixar raw

FitaLabs Gateway — Model Configuration

Claude model mapping to real backends (MiMo Token Plan, DeepSeek API).

Mapping Table

ant_aliasmodel_iddisplay_nameproviderapi_baseimage
claude-haiku-4-7[1m]deepseek-v4-flashHaiku Seek FlashDeepSeekapi.deepseek.com/anthropic
claude-sonnet-4-6[1m]mimo-v2.5Monnet v2.5MiMotoken-plan-sgp.xiaomimimo.com/anthropic
claude-opus-4-6[1m]mimo-v2.5-proMopus v2.5 ProMiMotoken-plan-sgp.xiaomimimo.com/anthropic
claude-opus-4.7[1m]deepseek-v4-proDopus ProDeepSeekapi.deepseek.com/anthropic

Provider-Native Models (Agent SDK)

model_iddisplay_nameprovider
deepseek-v4-flash[1m]DeepSeek V4 Flash 1MDeepSeek
mimo-v2.5[1m]MiMo v2.5 1MMiMo
mimo-v2.5-pro[1m]MiMo v2.5 Pro 1MMiMo
deepseek-v4-pro[1m]DeepSeek V4 Pro 1MDeepSeek

Audio

model_idproviderapi_base
tts-1MiMo TTStoken-plan-sgp.xiaomimimo.com/v1
whisper-1MiMo ASRtoken-plan-sgp.xiaomimimo.com/v1

[1m] and non-[1m] Variants

Each Claude alias has TWO entries in config:

  • claude-sonnet-4-6[1m] — 1M context window
  • claude-sonnet-4-6 — normal context

Desktop offers a 1M context toggle. When enabled, it sends model[1m]. When disabled, it sends model without suffix. Both must exist in model_list.

Capabilities per Tier

# Derived from model_id prefix
if "haiku" in model_id:
    effort_levels = {"low", "medium"}
elif "sonnet" in model_id:
    effort_levels = {"low", "medium", "high"}
else:  # opus
    effort_levels = {"low", "medium", "high", "xhigh", "max"}

Desktop uses the prefix (claude-haiku-*, claude-sonnet-*, claude-opus-*) to determine which effort levels to show in the selector.

Other capabilities derived from model_info:

  • supports_visionimage_input, pdf_input
  • supports_1mcompact_20260112

Config YAML (exemplo)

model_list:
  - model_name: claude-sonnet-4-6[1m]
    litellm_params:
      model: xiaomi_mimo/mimo-v2.5[1m]
      api_base: https://token-plan-sgp.xiaomimimo.com/anthropic
      rpm: 30
    model_info:
      mode: chat
      supports_vision: true
      supports_function_calling: true
      supports_1m: true

Anthropic Format in /v1/models

Middleware in gateway.py intercepts the proxy response and translates:

{
  "data": [{
    "id": "claude-sonnet-4-6[1m]",
    "type": "model",
    "display_name": "Monnet v2.5",
    "created_at": "2025-01-01T00:00:00Z",
    "capabilities": {
      "thinking": {"supported": true, "types": {"adaptive": true, "enabled": true}},
      "effort": {"low": true, "medium": true, "high": true, "max": false, "xhigh": false},
      "image_input": {"supported": true},
      "context_management": {"compact_20260112": {"supported": true}}
    }
  }]
}

References