from os import getenv
from pprint import pprint

from dotenv import load_dotenv
from openai import OpenAI

from srs2std.llms.llm import LLM, Prompt

load_dotenv()
client = OpenAI(base_url=getenv("GPTOSS_BASE_URL"), api_key="EMPTY", timeout=10)


class GPT_OSS(LLM):
    client = client
    model = "gpt-oss:20b"
    max_completion_tokens = 128_000
    max_retries = 10
    temperature = 0.75
    reasoning_effort = "low"  # for rapid response


if __name__ == "__main__":
    gpt_oss = GPT_OSS()
    response = gpt_oss.ask(Prompt(system="", user="Explain AI in short."))
    pprint(response)
