chore: initialize qiming workspace repository
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.xspaceagi</groupId>
|
||||
<artifactId>app-platform-compose</artifactId>
|
||||
<version>0.0.1-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>app-platform-compose-adapter</artifactId>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>17</maven.compiler.source>
|
||||
<maven.compiler.target>17</maven.compiler.target>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.xspaceagi</groupId>
|
||||
<artifactId>app-platform-compose-spec</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.xspaceagi</groupId>
|
||||
<artifactId>app-platform-compose-sdk</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.xspaceagi</groupId>
|
||||
<artifactId>app-platform-agent-core-sdk</artifactId>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
||||
@@ -0,0 +1,21 @@
|
||||
package com.xspaceagi.compose.adapter;
|
||||
|
||||
import com.xspaceagi.agent.core.sdk.dto.AgentInfoDto;
|
||||
|
||||
import java.util.List;
|
||||
/**
|
||||
* 智能体服务适配器
|
||||
*/
|
||||
public interface IAgentRpcServiceAdapter {
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 查询智能体信息列表
|
||||
* @param agentIds 智能体id列表
|
||||
* @return 智能体信息列表
|
||||
*/
|
||||
public List<AgentInfoDto> queryAgentInfoList(List<Long> agentIds);
|
||||
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
package com.xspaceagi.compose.adapter.impl;
|
||||
|
||||
import com.xspaceagi.agent.core.sdk.IAgentRpcService;
|
||||
import com.xspaceagi.agent.core.sdk.dto.AgentInfoDto;
|
||||
import com.xspaceagi.agent.core.sdk.dto.ReqResult;
|
||||
import com.xspaceagi.compose.adapter.IAgentRpcServiceAdapter;
|
||||
|
||||
import jakarta.annotation.Resource;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@Slf4j
|
||||
@Service
|
||||
public class AgentRpcServiceAdapter implements IAgentRpcServiceAdapter {
|
||||
|
||||
|
||||
/**
|
||||
* 智能体服务
|
||||
*/
|
||||
@Resource
|
||||
private IAgentRpcService agentRpcService;
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public List<AgentInfoDto> queryAgentInfoList(List<Long> agentIds) {
|
||||
ReqResult<List<AgentInfoDto>> agentListResult = agentRpcService.queryAgentInfoList(agentIds);
|
||||
return agentListResult.getData();
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user