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 6bc405704..f65ff0cea 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 @@ -288,7 +288,11 @@ public class ModelService { .data(content, MediaType.TEXT_EVENT_STREAM) ); } - result.append(content); + ChatReqVO chatReqVO = JSONObject.parseObject(content, ChatReqVO.class); + if (content!=null){ + result.append(chatReqVO.getContent()); + } + // 心跳检测 if (System.currentTimeMillis() - lastSendTime > 15_000) { emitter.send(SseEmitter.event().comment("heartbeat"));