From e2b9ae67bb134cf8094362a85dd6d134ac72c0d9 Mon Sep 17 00:00:00 2001 From: Dru Jensen Date: Sat, 7 Dec 2024 10:07:27 -0800 Subject: fix: grok xai blocks without user agent --- py/utils.py | 1 + 1 file changed, 1 insertion(+) diff --git a/py/utils.py b/py/utils.py index 264c0c4..5500033 100644 --- a/py/utils.py +++ b/py/utils.py @@ -214,6 +214,7 @@ def openai_request(url, data, options): enable_auth=options['enable_auth'] headers = { "Content-Type": "application/json", + "User-Agent": "VimAI", } if enable_auth: (OPENAI_API_KEY, OPENAI_ORG_ID) = load_api_key(options['token_file_path']) -- cgit v1.2.3