29 lines
890 B
Python
29 lines
890 B
Python
"""Shared configuration loaded from .env for the Minecraft friend agent."""
|
|
|
|
from __future__ import annotations
|
|
|
|
import os
|
|
from dataclasses import dataclass
|
|
|
|
from dotenv import load_dotenv
|
|
|
|
load_dotenv()
|
|
|
|
|
|
@dataclass(frozen=True)
|
|
class Settings:
|
|
groq_api_key: str | None = os.getenv("GROQ_API_KEY")
|
|
main_model: str = os.getenv("MAIN_MODEL", "groq/openai/gpt-oss-120b")
|
|
sub_model: str = os.getenv("SUB_MODEL", "groq/openai/gpt-oss-20b")
|
|
|
|
persona_name: str = os.getenv("PERSONA_NAME", "Spruce")
|
|
poll_seconds: float = float(os.getenv("POLL_SECONDS", "2"))
|
|
idle_chitchat_seconds: float = float(os.getenv("IDLE_CHITCHAT_SECONDS", "90"))
|
|
|
|
mcp_minecraft_host: str = os.getenv("MCP_MINECRAFT_HOST", "127.0.0.1")
|
|
mcp_minecraft_port: int = int(os.getenv("MCP_MINECRAFT_PORT", "25565"))
|
|
bot_username: str = os.getenv("BOT_USERNAME", "Bot1")
|
|
|
|
|
|
SETTINGS = Settings()
|