mirror of
https://github.com/tencentmusic/supersonic.git
synced 2026-04-27 10:54:21 +08:00
(improvement)(Chat) Return agent info after creating agent (#1272)
Co-authored-by: lxwcodemonkey
This commit is contained in:
@@ -221,8 +221,7 @@ public class S2ArtistDemo extends S2BaseDemo {
|
||||
agentConfig.getTools().add(llmParserTool);
|
||||
}
|
||||
agent.setAgentConfig(JSONObject.toJSONString(agentConfig));
|
||||
int id = agentService.createAgent(agent, User.getFakeUser());
|
||||
agent.setId(id);
|
||||
agentService.createAgent(agent, User.getFakeUser());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -167,9 +167,8 @@ public class S2VisitsDemo extends S2BaseDemo {
|
||||
agent.setAgentConfig(JSONObject.toJSONString(agentConfig));
|
||||
MultiTurnConfig multiTurnConfig = new MultiTurnConfig(false);
|
||||
agent.setMultiTurnConfig(multiTurnConfig);
|
||||
int id = agentService.createAgent(agent, User.getFakeUser());
|
||||
agent.setId(id);
|
||||
return agent.getId();
|
||||
Agent agentCreated = agentService.createAgent(agent, User.getFakeUser());
|
||||
return agentCreated.getId();
|
||||
}
|
||||
|
||||
public DomainResp addDomain() {
|
||||
|
||||
Reference in New Issue
Block a user