mirror of
https://github.com/tencentmusic/supersonic.git
synced 2025-12-10 11:07:06 +00:00
[improvement][project]Adjust files based on code style.
This commit is contained in:
@@ -125,12 +125,9 @@ public class MemoryReviewTask {
|
||||
if (MemoryReviewResult.POSITIVE.equals(m.getLlmReviewRet())) {
|
||||
m.setStatus(MemoryStatus.ENABLED);
|
||||
}
|
||||
ChatMemoryUpdateReq memoryUpdateReq = ChatMemoryUpdateReq.builder()
|
||||
.id(m.getId())
|
||||
.status(m.getStatus())
|
||||
.llmReviewRet(m.getLlmReviewRet())
|
||||
.llmReviewCmt(m.getLlmReviewCmt())
|
||||
.build();
|
||||
ChatMemoryUpdateReq memoryUpdateReq = ChatMemoryUpdateReq.builder().id(m.getId())
|
||||
.status(m.getStatus()).llmReviewRet(m.getLlmReviewRet())
|
||||
.llmReviewCmt(m.getLlmReviewCmt()).build();
|
||||
memoryService.updateMemory(memoryUpdateReq, User.getDefaultUser());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -73,16 +73,19 @@ public class MemoryServiceImpl implements MemoryService {
|
||||
updateWrapper.set(ChatMemoryDO::getStatus, chatMemoryUpdateReq.getStatus());
|
||||
}
|
||||
if (Objects.nonNull(chatMemoryUpdateReq.getLlmReviewRet())) {
|
||||
updateWrapper.set(ChatMemoryDO::getLlmReviewRet, chatMemoryUpdateReq.getLlmReviewRet().toString());
|
||||
updateWrapper.set(ChatMemoryDO::getLlmReviewRet,
|
||||
chatMemoryUpdateReq.getLlmReviewRet().toString());
|
||||
}
|
||||
if (Objects.nonNull(chatMemoryUpdateReq.getLlmReviewCmt())) {
|
||||
updateWrapper.set(ChatMemoryDO::getLlmReviewCmt, chatMemoryUpdateReq.getLlmReviewCmt());
|
||||
}
|
||||
if (Objects.nonNull(chatMemoryUpdateReq.getHumanReviewRet())) {
|
||||
updateWrapper.set(ChatMemoryDO::getHumanReviewRet, chatMemoryUpdateReq.getHumanReviewRet().toString());
|
||||
updateWrapper.set(ChatMemoryDO::getHumanReviewRet,
|
||||
chatMemoryUpdateReq.getHumanReviewRet().toString());
|
||||
}
|
||||
if (Objects.nonNull(chatMemoryUpdateReq.getHumanReviewCmt())) {
|
||||
updateWrapper.set(ChatMemoryDO::getHumanReviewCmt, chatMemoryUpdateReq.getHumanReviewCmt());
|
||||
updateWrapper.set(ChatMemoryDO::getHumanReviewCmt,
|
||||
chatMemoryUpdateReq.getHumanReviewCmt());
|
||||
}
|
||||
updateWrapper.set(ChatMemoryDO::getUpdatedAt, new Date());
|
||||
updateWrapper.set(ChatMemoryDO::getUpdatedBy, user.getName());
|
||||
|
||||
Reference in New Issue
Block a user