Commit 82b99f01 authored by alex yao's avatar alex yao

feat:预览应用,多模型聊天

parent b75b68a2
...@@ -7,11 +7,20 @@ import java.util.List; ...@@ -7,11 +7,20 @@ import java.util.List;
public class AgentApplicationPreviewDto implements Serializable { public class AgentApplicationPreviewDto implements Serializable {
private String modelNickName;
private String agentId; private String agentId;
private List<Message> messages; private List<Message> messages;
public String getModelNickName() {
return modelNickName;
}
public void setModelNickName(String modelNickName) {
this.modelNickName = modelNickName;
}
public String getAgentId() { public String getAgentId() {
return agentId; return agentId;
} }
......
...@@ -162,8 +162,11 @@ public class AgentApplicationInfoRestImpl implements AgentApplicationInfoRest { ...@@ -162,8 +162,11 @@ public class AgentApplicationInfoRestImpl implements AgentApplicationInfoRest {
tools.add(tool); tools.add(tool);
} }
//获取模型
String model = StringUtils.isNotBlank(dto.getModelNickName()) ? dto.getModelNickName() : infoEntity.getLargeModel();
//调用应用服务 //调用应用服务
agentApplicationInfoService.callAgentApplication(agentId, infoEntity.getLargeModel(), infoEntity.getUnitIds() agentApplicationInfoService.callAgentApplication(agentId, model, infoEntity.getUnitIds()
, infoEntity.getAgentSystem(), kdIds.toArray(new Integer[0]), infoEntity.getCommunicationTurn(), infoEntity.getTopP(), infoEntity.getTemperature() , infoEntity.getAgentSystem(), kdIds.toArray(new Integer[0]), infoEntity.getCommunicationTurn(), infoEntity.getTopP(), infoEntity.getTemperature()
, dto.getMessages(), tools, httpServletResponse); , dto.getMessages(), tools, httpServletResponse);
} catch (Exception e) { } catch (Exception e) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment