Improve gemma and documentations (#278)

This commit is contained in:
Lianmin Zheng
2024-03-11 04:43:39 -07:00
committed by GitHub
parent 89885b31ef
commit faba293a0d
9 changed files with 56 additions and 35 deletions

View File

@@ -97,7 +97,9 @@ def http_request(url, json=None, stream=False, auth_token=None, verify=None):
"Content-Type": "application/json",
"Authentication": f"Bearer {auth_token}",
}
return requests.post(url, json=json, stream=True, headers=headers, verify=verify)
return requests.post(
url, json=json, stream=True, headers=headers, verify=verify
)
else:
req = urllib.request.Request(url)
req.add_header("Content-Type", "application/json; charset=utf-8")