优化星尘去重规则
This commit is contained in:
parent
9cd117a8a0
commit
c2bdf95f3b
@ -100,7 +100,7 @@ public class AliYunXingChen {
|
||||
Flowable<ChatResult> response = api.streamOut(chatReqParams);
|
||||
RecordMessage recordMessage = new RecordMessage();
|
||||
response.blockingForEach(m -> {
|
||||
String v = m.getChoices().get(0).getMessages().get(0).getContent().replaceAll(recordMessage.getMsg(), "");
|
||||
String v = m.getChoices().get(0).getMessages().get(0).getContent().substring(recordMessage.getMsg().length());
|
||||
onNext.sendMessage(v);
|
||||
recordMessage.setMsg(m.getChoices().get(0).getMessages().get(0).getContent());
|
||||
if("stop".equals(m.getChoices().get(0).getStopReason())){
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user