AS AgentScopeAPI 手册 / API Reference

SkillToolGroup

public class SkillToolGroup extends ToolGroup
源码Source io/agentscope/core/tool/SkillToolGroup.java:44–179

技能工具组,让智能体以受控方式调用外部能力。位于 io.agentscope.core.tool 包,继承自 ToolGroup。核心成员包括 getActivateOnSkill、getDescription、copy、skillBuilder。

A ToolGroup that is bound to a specific skill. When the associated skill is in use, this tool group should be activated alongside it.

The #getDescription() method appends a reminder to the base description, informing the model that this tool group must be activated whenever the bound skill is active.

Scope defaults to ToolGroupScope#META so the agent can manage it via reset_equipped_tools.

Usage Example:

`SkillToolGroup group = SkillToolGroup.skillBuilder()
.name("data_analysis_tools")
.description("Tools for data analysis")
.activateOnSkill("data_analysis")
.active(false)
.build();
toolkit.registerToolGroup(group);
`

嵌套类摘要Nested Class Summary

类Class类型Kind说明Description
Builder类class
构建器,用于构建并配置目标实例。
Builder for constructing SkillToolGroup instances.

方法摘要Method Summary

方法Method说明Description
public String getActivateOnSkill()
获取 `getActivateOnSkill`。
Returns the name of the skill that this tool group is bound to.
public String getDescription()
获取 `getDescription`。
Returns the enhanced description that includes a reminder about the skill binding.
public ToolGroup copy()
返回 `copy` 结果。
Returns the copy.
public static Builder skillBuilder()
static
返回技能构建器。
Creates a new builder for constructing SkillToolGroup instances.

方法详情Method Detail

getActivateOnSkill

public String getActivateOnSkill()

获取 getActivateOnSkill。

Returns the name of the skill that this tool group is bound to.

返回Returns String
返回字符串结果。The skill name (never null)
源码Source io/agentscope/core/tool/SkillToolGroup.java:66–68

getDescription

public String getDescription()

获取 getDescription。

Returns the enhanced description that includes a reminder about the skill binding.

返回Returns String
返回字符串结果。The base description plus a skill-activation reminder
源码Source io/agentscope/core/tool/SkillToolGroup.java:75–81

copy

public ToolGroup copy()

返回 copy 结果。

Returns the copy.

返回Returns ToolGroup
返回工具组。Returns tool group.
源码Source io/agentscope/core/tool/SkillToolGroup.java:83–94

skillBuilder

public static Builder skillBuilder()
static

返回技能构建器。

Creates a new builder for constructing SkillToolGroup instances.

返回Returns Builder
一种新的SkillToolGroup 构建器实例。A new SkillToolGroup builder instance
源码Source io/agentscope/core/tool/SkillToolGroup.java:101–103

嵌套类详情Nested Class Detail

Builder

public static class Builder

构建器,用于构建并配置目标实例。位于 io.agentscope.core.tool 包。核心成员包括 name、description、active、activateOnSkill、tools、build。

Builder for constructing SkillToolGroup instances.

继承成员Inherited Members

基于官方固定版本源码静态生成Generated from pinned official sources · Python 2.0.11 · Java 2.0.4
签名与文档为静态抽取;如有疑问请以源码为准。Signatures and docs are extracted statically; verify against the source when in doubt.