跳转至

技能规格组件

本页说明仓库维护的兼容 Agent Skills 的技能目录。它告诉读者:人工编写的技能事实在哪里, 每个语义字段由哪个文件拥有,以及目录如何派生出规划器视图、worker 发现能力、A2A Agent Card 技能和运行约束。

概念模型

技能规格是规划器理解有界 worker 动作的语义词表。这个目录刻意由仓库内的技能包 和清单组成,而不是从实时 worker 声明临时拼接出来。worker 可以声明自己支持目录中的哪些技能, 但槽位规则、规范指令模板、公开描述、类别、机器人类型、人类可读标题和超时策略都来自目录本身。

每个公开技能使用稳定的 dotted lift2.* ID,供 OMEGA 规划和分派使用。长自然语言触发短语不能变成 ID: 公开发现文字属于 SKILL.md.description,公开槽位规则属于 references/omega-skill.yaml 的 slot_schema,真正渲染给执行侧的短语属于 instruction_template。

已交付模型有三个主要派生消费方。规划器卡片暴露简洁规划提示和检索指针;worker 发现暴露窄化的 WorkerSkillCapability 条目,但不重新定义技能;A2A Agent Card 暴露 A2A 原生 AgentSkill 条目;运行约束携带 worker 必须遵守的固定执行限制。当前工程预览实现把已提交到仓库的目录作为语义技能编写表面, 同时 deploy/topology/profiles/workers.yaml 只发布公开 skill_allowlist 成员关系。worker-private implementation compatibility 和调用留在 worker 边界下方;它们不是编写目录字段,也不进入公开示例。

实现流程

omega_skill_specs 读取 catalog_manifest.json,解析清单列出的每个技能包目录,加载 SKILL.md,再加载 metadata.omega-contract 指向的 OMEGA 契约文件。该包保留清单顺序, 拒绝重复或不匹配的技能 ID,并校验:

  • 技能包目录名必须等于 SKILL.md.name;
  • metadata.omega-skill-id、清单 skill_id 和契约文件 id 必须完全一致;
  • metadata.omega-contract 必须解析到技能包内,通常是 references/omega-skill.yaml;
  • 契约文件只能包含下文列出的 OMEGA 类型化字段。

所有投影都从同一份归一化目录在 omega_skill_specs 内派生。该包构建 PlannerSkillCard.description、WorkerSkillCapability 发现条目、运行约束,以及 A2A 投影 需要的 SkillSpecHeader 序列。部署配置代码提供 skill_allowlist 等公开 worker 事实; omega_worker_boundary.agent_card 在构建公开 Agent Card 时接收 worker 快照和匹配的头部记录。这些投影继续从目录派生, 而不是复制到文档、拓扑或 worker 本地代码。

运行时实现选择是单独的 worker-private 层。worker 代码只有在分配好的 TaskNode 到达后才消费私有绑定。 目录保持语义层职责,不携带私有 implementation data。

编写包形状

packages/skill_specs/skills/lift2/
  manipulation-pick-conveyor-bundle/
    SKILL.md
    references/
      omega-skill.yaml

SKILL.md 是 Agent Skills 技能包入口。它的文件头元数据拥有包身份、 公开发现文本,以及 OMEGA 契约文件指针:

name: manipulation-pick-conveyor-bundle
description: Pick two supported ingredients from the conveyor using both arms.
metadata:
  omega-skill-id: lift2.manipulation.pick_conveyor_bundle
  omega-contract: references/omega-skill.yaml

references/omega-skill.yaml 拥有 OMEGA 类型化技能契约。它只拥有这些字段: id、title、robot_type、category、slot_schema、instruction_template 和 fixed_timeout_s。

id: lift2.manipulation.pick_conveyor_bundle
title: Pick conveyor bundle
robot_type: lift2
category: manipulation
slot_schema:
  object_1:
    required: true
    allowed_values:
      - bread
  object_2:
    required: true
    allowed_values:
      - steak
      - lettuce
instruction_template: Take the {object_1} and {object_2} from the rotating tray
fixed_timeout_s: 8

公开字段拆分

字段 拥有来源 公开含义
SKILL.md.name Agent Skills 技能包 Kebab-case 包身份。它必须匹配技能包目录名,不是 OMEGA runtime skill ID。
SKILL.md.description Agent Skills 技能包 唯一的公开技能级描述来源。它进入 SkillSpecHeader.description、PlannerSkillCard.description、WorkerSkillCapability.description 和 AgentSkill.description。
metadata.omega-skill-id Agent Skills metadata 必须匹配 manifest skill_id 和 sidecar id。
metadata.omega-contract Agent Skills metadata 契约文件指针,通常是 references/omega-skill.yaml。
id OMEGA 契约文件 稳定公开 lift2.* 能力身份,用于 planning、task graph、dispatch、worker matching 和 private binding。
title OMEGA 契约文件 人类可读公开标题。它进入 A2A AgentSkill.name。
robot_type / category OMEGA 契约文件 类型化目录元数据。它进入 planner card 和 A2A AgentSkill.tags,不进入 worker-discovery skill entry。
slot_schema OMEGA 契约文件 公开 required slot 和 allowed value 契约。没有公开 slot 时使用 {}。
instruction_template OMEGA 契约文件 渲染后的执行短语。分派前填入 slot placeholder。
fixed_timeout_s OMEGA 契约文件 派生到运行约束的固定超时策略。

契约文件不拥有技能级 summary 或 description 字段。

当前 Kitchen 示例

当前 kitchen catalog 把 pick、assembly、plate placement 和 heating 保持为公开语义 skill; implementation binding 留在 worker 边界下方。

Skill 当前公开契约
lift2.manipulation.pick_conveyor_bundle 公开 bundle-pick skill。SKILL.md.description 表示从 conveyor pick supported ingredients;instruction_template 渲染 Take the {object_1} and {object_2} from the rotating tray;slot_schema 保持 object_1=bread、object_2=steak|lettuce。
lift2.manipulation.assemble_sandwich 一个 generalized public assembly skill,不使用 role-specific skill ID。SKILL.md.description 表示 pickup 和 assembly-zone facing 是显式前置条件;instruction_template 渲染 Grasping a {object_1} and {object_2}, coordinate with the second robot to construct a beef sandwich.
lift2.manipulation.place_plate_beside_oven 公开 no-slot plate-placement skill,用在两个 assembly task 之后、oven-facing 之前。公开 result evidence 可以包含 plate_placed_beside_oven;private replay routing 仍在 worker 边界下方。
lift2.manipulation.load_dish_for_heating 公开 no-slot heating loader,用在显式 oven-facing 完成之后。

投影契约

以 lift2.manipulation.pick_conveyor_bundle 为例,归一化目录会产生:

Projection 字段映射
PlannerSkillCard 从归一化目录派生 skill_id、title、robot_type、category、description、instruction_template 和槽位卡片。
WorkerSkillCapability Worker 发现只暴露 version、skill_id 和 description。
A2A AgentSkill id = SkillSpecHeader.id、name = SkillSpecHeader.title、description = SkillSpecHeader.description、tags = [robot_type, category]。
WorkerCapabilitySnapshot Worker 级机器人/能力事实加有序的窄化 WorkerSkillCapability 条目。

投影图

这个图强调人工编写的技能规格是事实来源。规划器、worker discovery、A2A 和运行时视图都是派生视图, 不是独立的技能定义。

flowchart LR
    Manifest["目录清单"]
    Package["Agent Skills package"]
    SkillMd["SKILL.md"]
    Sidecar["references/omega-skill.yaml"]
    Loader["omega_skill_specs 目录加载器"]
    Catalog["归一化目录记录"]

    WorkerProfile["worker 技能允许列表"]
    CapabilitySnapshot["公开 worker capability snapshot"]
    PlannerCards["规划器卡片"]
    WorkerSkills["WorkerSkillCapability entries"]
    SkillHeaders["SkillSpecHeader sequence"]
    RuntimeConstraints["运行约束"]
    AgentSkill["A2A AgentSkill entries"]
    AgentCard["Agent Card capability extension"]

    Manifest --> Loader
    Package --> SkillMd
    Package --> Sidecar
    SkillMd --> Loader
    Sidecar --> Loader
    Loader --> Catalog
    Catalog --> PlannerCards
    Catalog --> WorkerSkills
    Catalog --> SkillHeaders
    Catalog --> RuntimeConstraints
    Catalog --> CapabilitySnapshot
    WorkerProfile --> CapabilitySnapshot
    WorkerSkills --> CapabilitySnapshot
    SkillHeaders --> AgentSkill
    AgentSkill --> AgentCard
    CapabilitySnapshot --> AgentCard

职责

维护仓库内编写的技能目录,并用它派生有界的规划器卡片、worker discovery capability entries、 A2A skill projection 和运行约束。worker 发现可以声明某个 worker 支持哪些目录技能,但不会重新定义 slot 规则、指令模板、description、超时策略、私有 implementation compatibility 或运行时实现身份。

拥有

  • packages/skill_specs/skills/ 下人工编写的 Agent Skills package directory。
  • 通过 packages/skill_specs/catalog_manifest.json 管理的目录成员和顺序。
  • packages/skill_specs/src/omega_skill_specs/ 中的目录解析、Agent Skills frontmatter 归一化、OMEGA sidecar 校验、 planner card、worker skill capability、runtime constraint 和 public worker capability snapshot。
  • 包 README 中的目录策略,确保规划器卡片、worker discovery、Agent Card 和运行约束都从目录派生。
  • 扩展人工编写目录时使用的稳定检索指针,同时避免把目录细节复制到文档。
  • 当前 LIFT2 技能的语义权威,例如 lift2.base.face_assembly_zone、lift2.base.face_oven、 lift2.manipulation.pick_conveyor_bundle、lift2.manipulation.assemble_sandwich、 lift2.manipulation.place_plate_beside_oven、lift2.manipulation.load_dish_for_heating、 lift2.manipulation.acquire_package、 lift2.utility.select_destination_layer、lift2.manipulation.place_package_on_selected_layer 和 lift2.base.return_to_conveyor_ready。

不拥有

  • worker capability 发现声明。
  • 运行时执行、全局调度或任务图 compilation。
  • 拓扑/配置档 manifest 中的 worker-specific 技能允许列表。
  • worker-private implementation selection 或 configuration bodies。
  • 正式文档中重复复制的 slot 模式、指令模板、超时值或自动生成的投影 payload。

关键输入输出

流程 输入 输出
人工编写目录 Agent Skills package directory 加 packages/skill_specs/catalog_manifest.json 按清单顺序归一化的技能记录。
规划器投影 归一化后的目录记录 规划器卡片,包含指令和 slot 检索指针。
worker discovery projection worker 配置档技能允许列表加归一化目录 通过 worker discovery 暴露的 WorkerSkillCapability 条目。
A2A projection Worker capability snapshot 加匹配的 SkillSpecHeader records A2A-native AgentSkill.id、AgentSkill.name、AgentSkill.description 和 tags。
运行约束投影 归一化后的目录记录 从人工技能策略派生的运行时 constraint。
Worker support authority deploy/topology/profiles/workers.yaml skill_allowlist 加归一化目录 Dispatch 前校验的公开 worker support set。

当前状态

已交付。packages/skill_specs/ 和 omega_skill_specs package 拥有面向规划器的人工技能目录,以及目录解析、 Agent Skills frontmatter 归一化、OMEGA sidecar 校验、planner card、worker skill capability、runtime constraint 和 public worker capability snapshot。 Deploy-config code 消费公开 worker profile fact 与 source-owned projection 来完成 deploy-neutral resolution; 它不是 skill catalog 或 projection authority。当前受支持的 profiles 使用同一组完整公开 lift2.* skill ID,同时由 worker-private configuration 在 worker 边界下方选择 implementation 行为。

权威来源

关注点 源码权威
目录归属和投影策略 packages/skill_specs/README.md
清单顺序和目录成员 packages/skill_specs/catalog_manifest.json
Agent Skills package identity 和 public description packages/skill_specs/skills/**/SKILL.md
OMEGA typed skill fields packages/skill_specs/skills/**/references/omega-skill.yaml
目录加载和投影代码 packages/skill_specs/src/omega_skill_specs/catalog.py, packages/skill_specs/src/omega_skill_specs/projections.py
公开技能权威 deploy/topology/profiles/workers.yaml 和 Deploy Config
LIFT2 公开证据标签 packages/lift2_skill_specs/src/omega_lift2_skill_specs/vocabulary.py 与 packages/lift2_skill_specs/src/omega_lift2_skill_specs/schemas.py
Private implementation coverage A2A worker 边界下方选择的 worker-private configuration
场景添加流程 Scenario 添加指南
投影护栏归属 packages/skill_specs/src/omega_skill_specs/ 与 packages/deploy_config/src/omega_deploy_config/

关键源码路径

路径 用途
packages/skill_specs/README.md 人工技能目录的权威和投影规则。
packages/skill_specs/catalog_manifest.json 由清单拥有的目录版本、技能 ID 和源码路径。
packages/skill_specs/skills/ 已提交到仓库的 Agent Skills package catalog。
packages/skill_specs/skills/lift2/*/SKILL.md Agent Skills package identity、public description 和 OMEGA sidecar pointer。
packages/skill_specs/skills/lift2/*/references/omega-skill.yaml OMEGA typed skill fields。
packages/skill_specs/src/omega_skill_specs/catalog.py Manifest 加载、Agent Skills package 解析、sidecar 校验和归一化目录记录。
packages/skill_specs/src/omega_skill_specs/projections.py 派生 worker skill capability、planner card、runtime constraint 和 public worker capability snapshot。
packages/deploy_config/src/omega_deploy_config/resolver.py 根据目录校验 deploy-neutral worker 配置档技能允许列表。
deploy/topology/profiles/workers.yaml worker capability profiles 的公开 skill allowlist authority。

非当前范围

本页给出当前公开字段示例;catalog code 仍拥有技能定义权威。它不发布 worker 允许列表、 自动生成的 Agent Card payload、运行约束结构、private configuration bodies 或 implementation internals。这些细节仍由 catalog code、deploy-config 代码、拓扑/profile manifest 和 worker-private implementation source 拥有。

相关页面