From 631073fed051da7ceca42aad197dd0d8be004fb3 Mon Sep 17 00:00:00 2001 From: Sakurasan <1173092237@qq.com> Date: Sun, 28 May 2023 22:59:58 +0800 Subject: [PATCH] update --- README.md | 2 ++ router/router.go | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index dd89b79..3fc9ad2 100644 --- a/README.md +++ b/README.md @@ -63,6 +63,8 @@ wget https://github.com/mirrors2/opencatd-open/raw/main/docker/docker-compose.ym - [Fly.io](https://fly.io/) - 或者其他 +修改openai的endpoint地址?使用任意上游地址(套娃代理) + - 设置环境变量 openai_endpoint # License [GNU General Public License v3.0](License) \ No newline at end of file diff --git a/router/router.go b/router/router.go index 7f0e132..af58cf4 100644 --- a/router/router.go +++ b/router/router.go @@ -93,7 +93,7 @@ type ChatCompletionResponse struct { func init() { if openai_endpoint := os.Getenv("openai_endpoint"); openai_endpoint != "" { - log.Println("replace %s to %s", baseUrl, openai_endpoint) + log.Println(fmt.Sprintf("replace %s to %s", baseUrl, openai_endpoint)) baseUrl = openai_endpoint } }