mirror of
https://github.com/ccmjga/zhilu-admin
synced 2026-03-25 04:43:44 +08:00
add deep seek tool action
This commit is contained in:
@@ -19,6 +19,7 @@ public class AiChatService {
|
||||
private final AiChatAssistant deepSeekChatAssistant;
|
||||
private final AiChatAssistant zhiPuChatAssistant;
|
||||
private final SystemToolAssistant zhiPuToolAssistant;
|
||||
private final SystemToolAssistant deepSeekToolAssistant;
|
||||
private final LlmService llmService;
|
||||
|
||||
public TokenStream chatWithDeepSeek(String sessionIdentifier, String userMessage) {
|
||||
@@ -29,8 +30,13 @@ public class AiChatService {
|
||||
return zhiPuChatAssistant.chat(sessionIdentifier, userMessage);
|
||||
}
|
||||
|
||||
public TokenStream actionExecuteWithZhiPu(String sessionIdentifier, String userMessage) {
|
||||
return zhiPuToolAssistant.ask(sessionIdentifier, userMessage);
|
||||
public TokenStream actionPrecedenceExecuteWith(String sessionIdentifier, String userMessage) {
|
||||
LlmCodeEnum code = getPrecedenceLlmCode();
|
||||
return switch (code) {
|
||||
case ZHI_PU -> zhiPuToolAssistant.ask(sessionIdentifier, userMessage);
|
||||
case DEEP_SEEK -> deepSeekToolAssistant.ask(sessionIdentifier, userMessage);
|
||||
default -> throw new BusinessException(String.format("无效的模型代码 %s", code));
|
||||
};
|
||||
}
|
||||
|
||||
public TokenStream chatPrecedenceLlmWith(String sessionIdentifier, String userMessage) {
|
||||
|
||||
Reference in New Issue
Block a user