diff --git a/yudao-module-llm/yudao-module-llm-biz/src/main/java/cn/iocoder/yudao/module/llm/service/http/ModelService.java b/yudao-module-llm/yudao-module-llm-biz/src/main/java/cn/iocoder/yudao/module/llm/service/http/ModelService.java
index 092d61202..f4e87c75a 100644
--- a/yudao-module-llm/yudao-module-llm-biz/src/main/java/cn/iocoder/yudao/module/llm/service/http/ModelService.java
+++ b/yudao-module-llm/yudao-module-llm-biz/src/main/java/cn/iocoder/yudao/module/llm/service/http/ModelService.java
@@ -283,24 +283,24 @@ public class ModelService {
}
log.info("接收到的响应行数据: {}", line);
- if (!"data: [DONE]".equals(line)) {
- String jsonData = line.substring(line.indexOf("{"));
- JSONObject jsonObject = JSON.parseObject(jsonData);
- log.info("处理后数据: {}", jsonData);
- if (jsonObject.containsKey("object")&& jsonObject.containsKey("message")&& jsonObject.getString("object").equals("error")){
- emitter.completeWithError(new RuntimeException(jsonObject.getString("message")));
- }
- JSONObject content1 = jsonObject.getJSONArray("choices").getJSONObject(0);
- // 获取delta对象
- JSONObject delta = content1.getJSONObject("delta");
- // 获取content字段
- String contentType = delta.getString("content");
- log.info("返回字符串: {}", contentType);
- if (ObjectUtil.contains(contentType, "")|| ObjectUtil.contains(contentType, "")){
- i++;
- }
- }
- if (i!=1 && i!=2) {
+// if (!"data: [DONE]".equals(line)) {
+// String jsonData = line.substring(line.indexOf("{"));
+// JSONObject jsonObject = JSON.parseObject(jsonData);
+// log.info("处理后数据: {}", jsonData);
+// if (jsonObject.containsKey("object")&& jsonObject.containsKey("message")&& jsonObject.getString("object").equals("error")){
+// emitter.completeWithError(new RuntimeException(jsonObject.getString("message")));
+// }
+// JSONObject content1 = jsonObject.getJSONArray("choices").getJSONObject(0);
+// // 获取delta对象
+// JSONObject delta = content1.getJSONObject("delta");
+// // 获取content字段
+// String contentType = delta.getString("content");
+// log.info("返回字符串: {}", contentType);
+// if (ObjectUtil.contains(contentType, "")|| ObjectUtil.contains(contentType, "")){
+// i++;
+// }
+// }
+// if (i!=1 && i!=2) {
// line = line.replaceAll("\n", " ");
String content = parseStreamLine(line, uuid,groupId);
@@ -315,9 +315,9 @@ public class ModelService {
if (content != null) {
result.append(chatReqVO.getContent());
}
- }else if (i == 2){
- i++;
- }
+// }else if (i == 2){
+// i++;
+// }
// // 心跳检测
// if (System.currentTimeMillis() - lastSendTime > 15_000) {