李富豪 7 mesiacov pred
rodič
commit
baaf7b1a72

+ 9 - 4
app/client/platforms/deepSeek.ts

@@ -163,11 +163,16 @@ export class DeepSeekApi implements LLMApi {
           }
           // 获取当前的数据
           const currentData = info.data;
-          const format = '```think' + '' + '```';
-          if (responseText.startsWith(format)) {
-            responseText = responseText.replace(format, '');
+          const formatStart = '```think';
+          const formatEnd = 'think```';
+
+          if (currentData?.startsWith(formatStart)) {
+            remainText += currentData.replace(formatStart, '```think\n');
+          } else if (currentData?.startsWith(formatEnd)) {
+            remainText += currentData.replace(formatEnd, '```');
+          } else {
+            remainText += currentData;
           }
-          remainText += currentData;
         },
         async onclose() {
           finish();

+ 1 - 1
app/components/DeepSeekChat.tsx

@@ -1405,7 +1405,7 @@ function _Chat() {
                       isUser && message.document && message.document.id &&
                       <a style={{ padding: '10px', background: '#f7f7f7', borderRadius: '10px', textDecoration: 'none', color: '#24292f', display: 'flex', alignItems: 'center' }} href={message.document.url} target="_blank">
                         <FileIcon fileName={message.document.name} />
-                        <div style={{ marginLeft: 10 }}>
+                        <div style={{ marginLeft: 8, fontSize: '14px' }}>
                           {message.document.name}
                         </div>
                       </a>

+ 1 - 1
next.config.mjs

@@ -96,7 +96,7 @@ if (mode !== "export") {
       },
       {
         source: "/deepseek-api/:path*",
-        destination: "http://192.168.3.209:80/:path*",
+        destination: "http://117.176.244.35:18078/:path*",
       },
     ];