snapshot: preserve central wiki state 2026-08-15 (7 modified + 1 new file)

This commit is contained in:
Tony0410
2026-08-15 22:11:30 +08:00
commit 92e8028bb8
71 changed files with 9897 additions and 0 deletions
+47
View File
@@ -0,0 +1,47 @@
---
title: Model Routing
type: concept
status: active
created: 2026-07-22
updated: 2026-07-22
verified_on: 2026-07-22
confidence: high
tags: [routing, model, inference]
sources: [raw/configs/hermes-config-sanitized.txt, current-profile.md]
---
# Model Routing
## Purpose
How Hermes selects providers, applies combos, and enforces context limits.
## Current Flow
- Main path: `custom:litellm``http://litellm:4000/v1`
- Default model: `freellmapi-auto`
- OmniRoute used for auxiliary roles: vision, skills_hub, approval, mcp, title_generation, web_extract, compression
## Context Enforcement
- Three layers: model native → combo `data.config.context_length` → Hermes client cap
- Effective context is the minimum of the three
## Combo Behavior
- `priority` retries same provider up to `maxRetries`, then errors; it does NOT fall through
- `fill-first` walks the list on failure
- `auto`/`lkgp` recalculates per request using health scoring
- Same-provider entries in a combo share rate-limit buckets
- Session affinity caches provider in `session_model_history`
## Aliases and Mappings
- Model aliases resolved via `key_value` table (`modelAliases` namespace)
- Wildcard mappings via `model_combo_mappings`
- OpenCode/Zen entries may resolve back to `opencode-zen` provider internally
## History
- User-provided: OpenRouter was used previously; provider lists now centered on LiteLLM + OmniRoute
- User-provided: `persist_switch_by_default=false`; `/model` is per-session unless `--global` used
- Inferred: Configuration undergoes periodic corrections related to vision, model fallback, and browser backend tuning
## Related
- [[model-providers]]
- [[systems/omniroute]]
- [[openrouter]]