36 lines
1.7 KiB
Python
36 lines
1.7 KiB
Python
"""Defaults for the two local LLM servers. Paths and ports can be overridden in settings.json ("ai").
|
|
|
|
Clients reach both through The Kurgan's web server: http://127.0.0.1:8080/strata/v1 and
|
|
http://127.0.0.1:8080/llama/v1 (see kurgan/web/proxy.py). The ports below are where each server
|
|
listens on 127.0.0.1 behind it; clients shouldn't use them directly.
|
|
"""
|
|
|
|
import os
|
|
|
|
BACKENDS = ("strata", "llama") # also each server's path on The Kurgan's web server: /strata/, /llama/
|
|
|
|
# A server nobody has used for this long is stopped; the next request starts it again (0 = never).
|
|
IDLE_STOP_MINUTES = 40
|
|
|
|
# Strata (github.com/Niko1221/Strata), a git clone with its own venv in terminal\.
|
|
STRATA_ROOT = r"D:\AI\Strata"
|
|
STRATA_PORT = 8082
|
|
STRATA_MODELS = { # key: (label, run config in terminal\, model id it serves)
|
|
"q5": ("OrcaRouter Qwen3.8 Flash Next Q5_K_M", "strata-orca-q5_k_m.json",
|
|
"orcarouter-qwen3.8-flash-next-uncensored-q5_k_m"),
|
|
"iq3": ("OrcaRouter Qwen3.8 Flash Next IQ3_XXS", "strata-orca-iq3_xxs.json",
|
|
"orcarouter-qwen3.8-flash-next-uncensored-iq3_xxs"),
|
|
}
|
|
STRATA_DEFAULT_MODEL = "q5"
|
|
STRATA_IDLE_UNLOAD = 2000 # seconds idle before the model leaves VRAM; it reloads on the next request
|
|
|
|
# llama.cpp's llama-server in router mode, with the model defined in a presets file.
|
|
LLAMA_SERVER = os.path.join(os.environ.get("LOCALAPPDATA", ""), "Programs", "llama.cpp", "b12977",
|
|
"llama-server.exe")
|
|
LLAMA_PRESETS = r"D:\AI\models\qwen4-35b-a3b\service\presets.ini"
|
|
LLAMA_MODEL = "qwen4-35b-a3b-q5"
|
|
LLAMA_LABEL = "Qwen4 35B-A3B UD-Q5_K_XL"
|
|
LLAMA_PORT = 8083
|
|
LLAMA_API_KEY = "sk-local"
|
|
LLAMA_PREFIX = "/llama" # --api-prefix: llama-server serves its API and chat page under this path
|