zhou zhou
15 小时以前 b0728aba5c01842e24da3cff04e44be06c6bb655
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
package com.vincent.rsf.server.ai.service;
 
import com.vincent.rsf.server.ai.dto.AiChatMemoryDto;
import com.vincent.rsf.server.ai.dto.AiChatMessageDto;
import com.vincent.rsf.server.ai.dto.AiChatSessionDto;
import com.vincent.rsf.server.ai.dto.AiChatSessionPinRequest;
import com.vincent.rsf.server.ai.dto.AiChatSessionRenameRequest;
import com.vincent.rsf.server.ai.entity.AiChatSession;
 
import java.util.List;
 
public interface AiChatMemoryService {
 
    AiChatMemoryDto getMemory(Long userId, Long tenantId, String promptCode, Long sessionId);
 
    List<AiChatSessionDto> listSessions(Long userId, Long tenantId, String promptCode, String keyword);
 
    AiChatSession resolveSession(Long userId, Long tenantId, String promptCode, Long sessionId, String titleSeed);
 
    void saveRound(AiChatSession session, Long userId, Long tenantId, List<AiChatMessageDto> memoryMessages, String assistantContent);
 
    void removeSession(Long userId, Long tenantId, Long sessionId);
 
    AiChatSessionDto renameSession(Long userId, Long tenantId, Long sessionId, AiChatSessionRenameRequest request);
 
    AiChatSessionDto pinSession(Long userId, Long tenantId, Long sessionId, AiChatSessionPinRequest request);
 
    void clearSessionMemory(Long userId, Long tenantId, Long sessionId);
 
    void retainLatestRound(Long userId, Long tenantId, Long sessionId);
}