agentscope-ai / agentscope-ai/agentscope-java
[Feature]: NacosSkillRepository 在Harness Agent中如何使用?getSkillAll都是返回空数组,那我注册到nacos的技能Harness智能体如何得知?
- Linguagem predominante
- Java
- Estrelas
- 5.6k
- Forks
- 1.3k
- Merge médio
- 4d 12h
- PRs com merge (30d)
- 77
Descrição
目前想引用Nacos+Agentscope生态构建Harness Agent,但当skill在nacos注册后,Harness Agent无法得知命名空间下的skill。
```java
HarnessAgent.Builder builder = HarnessAgent.builder()
.name(config.getName())
.model(DashScopeChatModel.builder()
.baseUrl(baseUrl)
.apiKey(apiKey)
.modelName(config.getModel())
.build())
.maxIters(50)
.maxContextTokens(32000)
.workspace(config.getWorkspacePath())
.skillRepository(new NacosSkillRepository(aiService, environment.getProperty("spring.cloud.nacos.discovery.namespace", "public")))
.distributedStore(RedisDistributedStore.fromJedis(jedis))
.permissionContext(PermissionContextState.builder().mode(PermissionMode.BYPASS).build());
```
源码:io.agentscope.core.nacos.skill.NacosSkillRepository
```java
@Override
public List getAllSkillNames() {
log.warn("NacosSkillRepository is read-only, getAllSkillNames returns empty list");
return Collections.emptyList();
}
@Override
public List getAllSkills() {
log.warn("NacosSkillRepository is read-only, getAllSkills returns empty list");
return Collections.emptyList();
}
```
Guia de contribuição
Avaliação
Esta issue ainda não foi avaliada.