On this page

Model configuration

Last updated: 2026-11-22

Keragi’s AI capabilities are provided by agix. Each user adds their own model key in the client under Settings → AI assistant → Model key configuration; it is stored in agix’s per-account provider config. Server .env files do not hold model keys. This page uses placeholders only. Never put real keys into documentation, screenshots or tickets.

Deployment note (important): text, vision, images, video, music, TTS and ASR work on both native and WASM deployments. WASM media requires AGIX_WASM_MEDIA and outbound HTTP from the host. The models actually available depend on the keys and upstream quota configured by the operator. Knowledge-base retrieval is still maturing, and AI conversation history differs by deployment form.

1. Model categories

CategoryTypical useMain configurationCurrent wasm deployment
Text / chatAI conversations, AI takeoverDeepSeek, QianwenAvailable
Image generationText-to-imageQianwen (Bailian)Available (configured qwen-image)
Video generationText-to-video, image-to-videoQianwen, Volcano Ark Seedance 2.5 / 2.5 FlashAvailable (native + WASM)
Voice / musicTTS, ASR, music generationQianwen, DeepSeek, StabilityAvailable (native + WASM)

2. General rules

3. Text / chat models

AGIX_DEFAULT_MODEL=deepseek-flash
AGIX_DEEPSEEK_URL=https://api.deepseek.com/v1

Qianwen can also serve as a text provider:

AGIX_QIANWEN_URL=https://dashscope.aliyuncs.com/compatible-mode/v1

4. Image generation

Image generation uses Qianwen (Alibaba Cloud Bailian):

AGIX_QIANWEN_URL=https://dashscope.aliyuncs.com/compatible-mode/v1
AGIX_DASHSCOPE_URL=https://dashscope.aliyuncs.com/api/v1

Once configured, image models appear under /agix/v1/models. Generated media is stored in the server media directory and shown or downloaded by the client.

5. Video generation

There are two video paths. Both native and WASM deployments support video; WASM requires AGIX_WASM_MEDIA and outbound HTTP from the host.

Qianwen (Bailian)

AGIX_DASHSCOPE_URL=https://dashscope.aliyuncs.com/api/v1

Volcano Ark Seedance

AGIX_ARK_BASE_URL=https://ark.cn-beijing.volces.com/api/v3
AGIX_SEEDANCE_MODEL=<SEEDANCE_MODEL_ID>
AGIX_SEEDANCE_FLASH_MODEL=<SEEDANCE_FLASH_MODEL_ID>

seedance and seedance-flash share the Ark key and base URL; AGIX_SEEDANCE_MODEL / AGIX_SEEDANCE_FLASH_MODEL override their model IDs, defaulting to doubao-seedance-2-5-260628 and doubao-seedance-2-5-flash-261115.

Video jobs are asynchronous; adjust polling and timeout with:

AGIX_VIDEO_POLL_INTERVAL_MS=5000
AGIX_VIDEO_TIMEOUT_MS=300000

6. Voice and music

TTS/ASR can use DeepSeek’s native voice tools (deepseek-tts / deepseek-asr, reusing the same DeepSeek provider and AGIX_DEEPSEEK_URL), or Qianwen. Voice and music work on both native and WASM deployments; WASM requires AGIX_WASM_MEDIA and outbound HTTP from the host.

AGIX_DASHSCOPE_URL=https://dashscope.aliyuncs.com/api/v1

Music generation uses Stability Stable Audio (optional):

AGIX_STABLE_AUDIO_URL=https://api.stability.ai/v2beta
AGIX_STABLE_AUDIO_MODEL=stable-audio-2.5

Polling and timeout:

AGIX_MUSIC_POLL_INTERVAL_MS=2000
AGIX_MUSIC_TIMEOUT_MS=300000

7. Metering and quota

AGIX_DEFAULT_DAILY_QUOTA=1000000
AGIX_DB_CONFIG_TTL_MS=5000

8. Verification

  1. Restart the host.
  2. Sign in as an administrator and check Settings → AI assistant for available models.
  3. Or query the model list and send a minimal request:
curl -H "Authorization: Bearer <token>" http://127.0.0.1:3001/agix/v1/models
curl -X POST http://127.0.0.1:3001/agix/v1/responses \
  -H "Authorization: Bearer <token>" -H 'Content-Type: application/json' \
  -d '{"model":"deepseek-flash","input":"Reply with exactly OK"}'
  1. If image/video/voice models are missing, confirm the provider key, model id and (for WASM) AGIX_WASM_MEDIA.

9. Security