diff --git a/sgpt/app.py b/sgpt/app.py index 7201a6cb..0216116d 100644 --- a/sgpt/app.py +++ b/sgpt/app.py @@ -35,7 +35,7 @@ def main( help="Large language model to use.", ), temperature: float = typer.Option( - 0.0, + cfg.get("DEFAULT_TEMPERATURE", 0.0), min=0.0, max=2.0, help="Randomness of generated output.", diff --git a/sgpt/config.py b/sgpt/config.py index bc083733..704e4756 100644 --- a/sgpt/config.py +++ b/sgpt/config.py @@ -23,6 +23,7 @@ "CACHE_LENGTH": int(os.getenv("CHAT_CACHE_LENGTH", "100")), "REQUEST_TIMEOUT": int(os.getenv("REQUEST_TIMEOUT", "60")), "DEFAULT_MODEL": os.getenv("DEFAULT_MODEL", "gpt-4o"), + "DEFAULT_TEMPERATURE": os.getenv("DEFAULT_TEMPERATURE", 0.0), "DEFAULT_COLOR": os.getenv("DEFAULT_COLOR", "magenta"), "ROLE_STORAGE_PATH": os.getenv("ROLE_STORAGE_PATH", str(ROLE_STORAGE_PATH)), "DEFAULT_EXECUTE_SHELL_CMD": os.getenv("DEFAULT_EXECUTE_SHELL_CMD", "false"),