RuntimeContextSkillRepository
public interface RuntimeContextSkillRepository extends AgentSkillRepository
源码Source
io/agentscope/core/skill/repository/RuntimeContextSkillRepository.java:23–40定义运行时上下文技能仓库契约的接口。位于 io.agentscope.core.skill.repository 包,实现 AgentSkillRepository。核心成员包括 getAllSkills、getSkill。
A skill repository whose visible contents depend on the current request context.
方法摘要Method Summary
| 方法Method | 说明Description |
|---|---|
public List<AgentSkill> getAllSkills(RuntimeContext context) | 获取所有技能。 Returns the skills visible to exactly the supplied request context. |
default public AgentSkill getSkill(String name, RuntimeContext context)default | 获取技能。 Returns the named skill visible to exactly the supplied request context. |
方法详情Method Detail
getAllSkills
public List<AgentSkill> getAllSkills(RuntimeContext context)
获取所有技能。
Returns the skills visible to exactly the supplied request context.
参数Parameters
| 名称Name | 类型Type | 说明Description |
|---|---|---|
context | RuntimeContext | 上下文(类型 `RuntimeContext`)。The context. |
List<AgentSkill>返回列出。Returns list.
源码Source
io/agentscope/core/skill/repository/RuntimeContextSkillRepository.java:26getSkill
default public AgentSkill getSkill(String name, RuntimeContext context)
default
获取技能。
Returns the named skill visible to exactly the supplied request context.
参数Parameters
| 名称Name | 类型Type | 说明Description |
|---|---|---|
name | String | 名称(类型 `String`)。The name. |
context | RuntimeContext | 上下文(类型 `RuntimeContext`)。The context. |
AgentSkill返回AgentSkill。Returns agent skill.
源码Source
io/agentscope/core/skill/repository/RuntimeContextSkillRepository.java:29–39