summaryrefslogtreecommitdiffstats
path: root/g4f
diff options
context:
space:
mode:
authorHeiner Lohaus <hlohaus@users.noreply.github.com>2024-04-20 20:11:09 +0200
committerHeiner Lohaus <hlohaus@users.noreply.github.com>2024-04-20 20:11:09 +0200
commitdb00480153283a3bf76e6398fd7240e943cf15bb (patch)
tree01b7677bfd51667e6b8bebe0ac72921aa48cba58 /g4f
parentImprove cli argparser, Improve curl_cffi websocket support (diff)
downloadgpt4free-db00480153283a3bf76e6398fd7240e943cf15bb.tar
gpt4free-db00480153283a3bf76e6398fd7240e943cf15bb.tar.gz
gpt4free-db00480153283a3bf76e6398fd7240e943cf15bb.tar.bz2
gpt4free-db00480153283a3bf76e6398fd7240e943cf15bb.tar.lz
gpt4free-db00480153283a3bf76e6398fd7240e943cf15bb.tar.xz
gpt4free-db00480153283a3bf76e6398fd7240e943cf15bb.tar.zst
gpt4free-db00480153283a3bf76e6398fd7240e943cf15bb.zip
Diffstat (limited to 'g4f')
-rw-r--r--g4f/api/__init__.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/g4f/api/__init__.py b/g4f/api/__init__.py
index 1bdfba48..ed39fc58 100644
--- a/g4f/api/__init__.py
+++ b/g4f/api/__init__.py
@@ -92,7 +92,7 @@ class Api:
return JSONResponse({"error": "The model does not exist."})
@app.post("/v1/chat/completions")
- async def chat_completions(config: ChatCompletionsConfig = None, request: Request = None, provider: str = None):
+ async def chat_completions(config: ChatCompletionsConfig, request: Request = None, provider: str = None):
try:
config.provider = provider if config.provider is None else config.provider
if config.api_key is None and request is not None: