diff options
| -rwxr-xr-x | bin/kaagum | 4 | ||||
| -rw-r--r-- | kaagum/openai.scm | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/bin/kaagum b/bin/kaagum index 8e2a189..b8ee084 100755 --- a/bin/kaagum +++ b/bin/kaagum @@ -61,7 +61,7 @@ to invoke kaagum." Run kaagum AI agent. --api-base-uri=URI base API URI of LLM provider - (default: \"https://openrouter.ai\") + (default: \"https://openrouter.ai/api\") --api-key-command=COMMAND command to run to get API key --model=MODEL LLM model name to start new sessions with (default: \"anthropic/claude-opus-4.6\") @@ -93,7 +93,7 @@ Run kaagum AI agent. invalid-option invalid-argument '((model . "anthropic/claude-opus-4.6") - (api-base-uri . "https://openrouter.ai"))))) + (api-base-uri . "https://openrouter.ai/api"))))) (when (assq-ref args 'help) (print-usage program) (exit #t)) diff --git a/kaagum/openai.scm b/kaagum/openai.scm index 64bda72..937a1de 100644 --- a/kaagum/openai.scm +++ b/kaagum/openai.scm @@ -71,7 +71,7 @@ and need not be specified in @var{headers}. Return JSON response." is the API key for authentication. @var{model} is a supported LLM model. @var{messages} and @var{tools} are respectively lists of JSON messages and tools compatible with the OpenAI API specification." - (json-post (uri-join base-uri "/api/v1/chat/completions") + (json-post (uri-join base-uri "/v1/chat/completions") #:headers `((authorization . ,(string-append "Bearer " api-key))) #:json `(("model" . ,model) |
