borderless / ui /agent /config.py
spagestic's picture
switched to qwen
71a7158
Raw
History Blame Contribute Delete
905 Bytes
# ui/agent/config.py
from __future__ import annotations
import os
from .tool_schemas import TOOL_SCHEMAS
from .tool_schemas import think as THINK_SCHEMA
MODEL_ID = os.environ.get(
"BORDERLESS_MODEL_ID", "Qwen/Qwen3.6-27B:featherless-ai"
)
INFERENCE_MODE = os.environ.get("BORDERLESS_INFERENCE_MODE", "hub").strip().lower()
ENABLE_THINKING = os.environ.get("BORDERLESS_ENABLE_THINKING", "1").strip().lower() in {
"1",
"true",
"yes",
}
GPU_DURATION = max(
30,
min(
300,
int(os.environ.get("BORDERLESS_GPU_DURATION", "60")),
),
)
MAX_TOOL_ROUNDS = int(os.environ.get("BORDERLESS_MAX_TOOL_ROUNDS", "7"))
TOOLS = TOOL_SCHEMAS
THINK_TOOLS = [THINK_SCHEMA]
def local_inference_enabled() -> bool:
return INFERENCE_MODE == "local"
def hub_token_available() -> bool:
return bool(os.environ.get("HF_TOKEN", "").strip())