> ## Documentation Index
> Fetch the complete documentation index at: https://docs.zeus.agentspro.cn/llms.txt
> Use this file to discover all available pages before exploring further.

# Models

> Zeus Model Configuration & Management

## Overview

Zeus supports flexible model configuration. Users can connect any OpenAI-compatible model using their own API Key, or use Zeus preset models.

## Configuration Sources

```mermaid theme={null}
graph LR
    user_custom["User Custom Model<br/>Own API Key + Base URL"]
    zeus_preset["Zeus Preset Models<br/>zeus-1.5 / zeus-1.5-pro / zeus-1.5-lite"]
    default["Default Fallback<br/>Zeus System Model"]

    user_custom -->|"Priority 1"| LLM["ChatOpenAI Instance"]
    zeus_preset -->|"Priority 2"| LLM
    default -->|"Priority 3"| LLM
```

Model configuration is selected by the following priority: User custom configuration > Request parameters > System default configuration.

## Zeus Preset Models

Zeus ships with three preset model tiers, each backed by a specific provider and model:

| Preset        | Actual Model             | Provider | Max Tokens | Tier     |
| ------------- | ------------------------ | -------- | ---------- | -------- |
| zeus-1.5      | kimi-k2.5                | Moonshot | 262,144    | Standard |
| zeus-1.5-pro  | claude-opus-4-5-20251101 | UnifyLLM | 200,000    | Pro      |
| zeus-1.5-lite | gemini-2.5-pro           | UnifyLLM | 1,048,576  | Lite     |

Users select a preset tier in the UI; the system automatically routes to the corresponding provider and model. When using presets, no API Key configuration is required.

## LLMManager

The LLM model manager is responsible for creating model instances. `_init_model()` receives the LLM configuration passed from the frontend (including Base URL, API Key, model name, temperature, etc.) and creates a `ChatOpenAI` instance.

It first checks whether a user custom model configuration exists (with their own API Key and Base URL). If not, it checks for Zeus preset model selection, routing to the appropriate provider. As a final fallback, it reads the system default configuration. Supports any OpenAI-compatible API (OpenAI, Anthropic via proxy, local models, etc.).

## Model Profiles

The system includes 200+ built-in model context window configurations, used for `SummarizationMiddleware` trigger threshold calculation:

| Model             | max\_input\_tokens | Summarization Trigger (85%) |
| ----------------- | ------------------ | --------------------------- |
| gpt-4o            | 128,000            | 108,800                     |
| claude-3.5-sonnet | 200,000            | 170,000                     |
| gpt-4-turbo       | 128,000            | 108,800                     |
| Default           | 64,000             | 54,400                      |

When a model is not in the predefined list, default configuration is used.
