From 1a3327cc8da4fe30bcfe12983be026c4903987a1 Mon Sep 17 00:00:00 2001 From: Vinlic Date: Sat, 13 Apr 2024 02:14:28 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=A4=9A=E8=BD=AE?= =?UTF-8?q?=E5=AF=B9=E8=AF=9D=E4=B8=8B=EF=BC=8C=E6=97=A0=E6=B3=95=E9=87=8D?= =?UTF-8?q?=E5=A4=8D=E5=94=A4=E8=B5=B7=E8=81=94=E7=BD=91=E6=A3=80=E7=B4=A2?= =?UTF-8?q?=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/controllers/chat.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/api/controllers/chat.ts b/src/api/controllers/chat.ts index 8050da0..e228a59 100644 --- a/src/api/controllers/chat.ts +++ b/src/api/controllers/chat.ts @@ -392,7 +392,7 @@ function messagesPrepare(messages: any[]) { return _content + `${message.role || "user"}:${v["text"] || ""}\n`; }, content); } - return content += `${message.role || 'user'}:${wrapUrlsToTags(message.content)}\n`; + return content += `${message.role || 'user'}:${message.role == 'user' ? wrapUrlsToTags(message.content) : message.content}\n`; }, ''); logger.info("\n对话合并:\n" + content); return [ From d14d06207854c0c84e6f38a5cb80897ded8b88d9 Mon Sep 17 00:00:00 2001 From: Vinlic Date: Sat, 13 Apr 2024 02:14:48 +0800 Subject: [PATCH 2/2] Release 0.0.26 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 8a71d6f..852936b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "kimi-free-api", - "version": "0.0.25", + "version": "0.0.26", "description": "Kimi Free API Server", "type": "module", "main": "dist/index.js",