AS AgentScopeAPI 手册 / API Reference
类class agentscope.app.hub

SkillCard

class SkillCard(BaseModel)
源码Source agentscope/app/hub/_skill/_card.py:8–134

技能卡片,把智能体接入外部消息渠道与企业平台。位于 agentscope.app.hub 包。

Unlike an :class:MCPCard there is nothing to configure: installing a skill copies its files into the workspace, so no input form and no template substitution are involved.

:attr:id addresses the card on its hub — together with :attr:hub_id it names the card globally; :attr:name is the skill's own name.

属性摘要Attribute Summary

属性Attribute类型Type说明Description值Value
hub_idstr
中心标识字段。
Field(title='Hub ID', description='The id of the hub this card came from.')
idstr
标识字段。
Field(default='', title='ID', description='The identifier addressing this card on its hub. Defaults to ``name`` for registries that expose no separate id.')
namestr
技能名称。
Field(title='Name', description='The skill name.')
descriptionstr
`description` 字段。
Field(default='', title='Description', description='The user-facing description of the skill.')
display_namestr | None
展示名称字段。
Field(default=None, title='Display Name', description='The user-facing name, falling back to ``name``.')
tagslist[str]
标签字段。
Field(default_factory=list, title='Tags', description='The tags categorizing this card.')
versionstr | None
版本字段。
Field(default=None, title='Version', description='The card version reported by the hub.')
updated_atfloat | None
已更新 at字段。
Field(default=None, title='Updated At', description='The last-updated timestamp (Unix epoch seconds).')
authorstr | None
`author` 字段。
Field(default=None, title='Author', description='Who published the skill, when the hub says.')
icon_urlstr | None
`icon_url` 字段。
Field(default=None, title='Icon URL', description='An image representing the skill, for the card and the detail view. ``None`` when the hub offers none — the UI is expected to fall back rather than show a broken image.')
installsint | None
`installs` 字段。
Field(default=None, title='Installs', description='How many times this skill has been installed. ``None`` when the hub does not count installs, which is not the same as zero — render it only when set.')
downloadsint | None
`downloads` 字段。
Field(default=None, title='Downloads', description='How many times this skill has been downloaded. ``None`` when the hub does not count downloads.')
urlstr | None
URL字段。
Field(default=None, title='URL', description="The skill's page on the hub's website, for a 'view on the hub' link. ``None`` when the hub has no web presence.")
markdownstr | None
`markdown` 字段。
Field(default=None, title='Markdown', description='The ``SKILL.md`` body. Left ``None`` when browsing so the catalog does not fetch one file per card; populated by ``get_skill``.')
metadatadict
元数据字段。
Field(default_factory=dict, title='Metadata', description='The hub-specific extra fields carried verbatim.')

属性详情Attribute Detail

hub_id

str = Field(title='Hub ID', description='The id of the hub this card came from.')

中心标识字段。声明为 str。

The id of the hub this card came from.

源码Source agentscope/app/hub/_skill/_card.py:20

id

str = Field(default='', title='ID', description='The identifier addressing this card on its hub. Defaults to ``name`` for registries that expose no separate id.')

标识字段。声明为 str。

The identifier addressing this card on its hub.

源码Source agentscope/app/hub/_skill/_card.py:25

name

str = Field(title='Name', description='The skill name.')

技能名称。

The skill name.

源码Source agentscope/app/hub/_skill/_card.py:34

description

str = Field(default='', title='Description', description='The user-facing description of the skill.')

description 字段。声明为 str。

The user-facing description of the skill.

源码Source agentscope/app/hub/_skill/_card.py:39

display_name

str | None = Field(default=None, title='Display Name', description='The user-facing name, falling back to ``name``.')

展示名称字段。声明为 str | None。

The user-facing name, falling back to name.

源码Source agentscope/app/hub/_skill/_card.py:45

tags

list[str] = Field(default_factory=list, title='Tags', description='The tags categorizing this card.')

标签字段。声明为 list[str]。

The tags categorizing this card.

源码Source agentscope/app/hub/_skill/_card.py:51

version

str | None = Field(default=None, title='Version', description='The card version reported by the hub.')

版本字段。声明为 str | None。

The card version reported by the hub.

源码Source agentscope/app/hub/_skill/_card.py:57

updated_at

float | None = Field(default=None, title='Updated At', description='The last-updated timestamp (Unix epoch seconds).')

已更新 at字段。声明为 float | None。

The last-updated timestamp (Unix epoch seconds).

源码Source agentscope/app/hub/_skill/_card.py:63

author

str | None = Field(default=None, title='Author', description='Who published the skill, when the hub says.')

author 字段。声明为 str | None。

Who published the skill, when the hub says.

源码Source agentscope/app/hub/_skill/_card.py:69

icon_url

str | None = Field(default=None, title='Icon URL', description='An image representing the skill, for the card and the detail view. ``None`` when the hub offers none — the UI is expected to fall back rather than show a broken image.')

icon_url 字段。声明为 str | None。

An image representing the skill, for the card and the detail view.

源码Source agentscope/app/hub/_skill/_card.py:75

installs

int | None = Field(default=None, title='Installs', description='How many times this skill has been installed. ``None`` when the hub does not count installs, which is not the same as zero — render it only when set.')

installs 字段。声明为 int | None。

How many times this skill has been installed.

源码Source agentscope/app/hub/_skill/_card.py:85

downloads

int | None = Field(default=None, title='Downloads', description='How many times this skill has been downloaded. ``None`` when the hub does not count downloads.')

downloads 字段。声明为 int | None。

How many times this skill has been downloaded.

源码Source agentscope/app/hub/_skill/_card.py:95

url

str | None = Field(default=None, title='URL', description="The skill's page on the hub's website, for a 'view on the hub' link. ``None`` when the hub has no web presence.")

URL字段。声明为 str | None。

The skill's page on the hub's website, for a 'view on the hub' link.

源码Source agentscope/app/hub/_skill/_card.py:104

markdown

str | None = Field(default=None, title='Markdown', description='The ``SKILL.md`` body. Left ``None`` when browsing so the catalog does not fetch one file per card; populated by ``get_skill``.')

markdown 字段。声明为 str | None。

The SKILL.md body.

源码Source agentscope/app/hub/_skill/_card.py:113

metadata

dict = Field(default_factory=dict, title='Metadata', description='The hub-specific extra fields carried verbatim.')

元数据字段。声明为 dict。

The hub-specific extra fields carried verbatim.

源码Source agentscope/app/hub/_skill/_card.py:123
基于官方固定版本源码静态生成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.