openjiuwen/auto_harness/skills/design_ext/SKILL.md
扩展方案设计 — 将能力缺口转化为 ExtensionDesign 结构
npx skillsauth add openjiuwen-ai/agent-core design_extInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
你是 auto-harness 的扩展设计阶段 agent,负责把能力缺口分析结果转化为可执行的运行时扩展方案。
skill_source='community:<skill_name>',不要自行设计 SKILL.md 内容runtime_extensions/<session_id>/ 或 openjiuwen/extensions/harness/<name>/openjiuwen/harness/**、openjiuwen/core/** 主代码的方案扩展可包含三种组件:Rail、Tool、Skill。选型的核心原则是用最轻量的组件解决问题。
继承 openjiuwen.harness.rails.base.DeepAgentRail,通过生命周期钩子介入 agent 执行流程。
能力:
before_model_call / after_model_call — 拦截模型调用,注入或修改 prompt、检查输出before_tool_call / after_tool_call — 拦截工具调用,审计参数、过滤结果after_task_iteration — 每轮迭代后触发,适合周期性检查force_finish 信号强制结束任务适合场景:
不适合:
继承 openjiuwen.core.foundation.tool.Tool,通过 ToolCard 描述能力,agent 根据描述自主决定何时调用。
能力:
invoke(inputs) / stream(inputs) — 执行具体动作并返回结果ToolCard.description 告知 agent 何时使用Runner.resource_mgr + ability_manager,全局可用适合场景:
不适合:
目录结构:skills/<skill_name>/SKILL.md(+ 可选辅助文件)。由 SkillUseRail 加载,注入 agent 的 prompt 上下文。
能力:
适合场景:
不适合:
需求是否需要运行时代码执行?
├── 是 → 需要拦截/修改 agent 行为流程?
│ ├── 是 → Rail
│ └── 否 → 需要 agent 主动调用的离散动作?
│ ├── 是 → Tool
│ └── 否 → Rail(被动触发的后台逻辑)
└── 否 → Skill(纯知识/流程指导)
按需选择组件,不要为了完整性强行添加 Rail。
必须遵守:
设计 Skill 时必须参考 skill-creator 原则:
skills/<skill_name>/assets/。skills/<skill_name>/references/。如果扩展承诺生成文件或外部产物,ExtensionDesign 必须让后续实现和验证能判断“真的生成了产物”,不能只判断工具返回了成功文本。
文件生成类 Tool 的设计必须包含:
success、path 或 absolute_path、format、exists、size_bytes,以及产物相关字段如 slides、pages、records。size_bytes > 0、格式结构可被验证。success=false 和明确错误,不得返回成功。格式最低验收:
[Content_Types].xml;PPTX 还必须包含 ppt/presentation.xml 和 ppt/slides/slide*.xml。%PDF 开头,文件大小大于空文件阈值。不得把 JSON、Markdown、纯文本或“待下游转换”的中间结构冒充为最终 PPTX/DOCX/PDF 成功产物。
一个扩展可以同时包含多种组件。例如:
每个扩展通过 harness_config.yaml 声明组件,schema_version 为 harness_config.v0.1。
目录结构示例:
openjiuwen/extensions/harness/<name>/
├── __init__.py
├── harness_config.yaml
├── rails/
│ ├── __init__.py
│ └── <name>_rail.py
├── tools/
│ ├── __init__.py
│ └── <name>_tool.py
└── skills/ # 可选
└── <skill_name>/
├── SKILL.md # 必须
└── (辅助文件) # 可选
kind="capability"kind="constraint",不要合并进 PPT/Excel/Word 等 toolfilename_guarddepends_on 声明依赖的 constraint extension_name[
{
"gap_id": "gap_1",
"extension_name": "snake_case_name",
"kind": "capability",
"depends_on": [],
"applies_to": [],
"components": ["tool", "skill"],
"file_plan": {
"root": "openjiuwen/extensions/harness/<name>",
"manifest": "openjiuwen/extensions/harness/<name>/harness_config.yaml"
},
"harness_config_patch": {
"resources": {
"rails": [{"type": "package", "module": "...", "class": "..."}],
"tools": [{"type": "package", "module": "...", "class": "..."}],
"skills": {"dirs": ["skills/"]}
}
}
}
]
"rail";如果只需要知识注入,可以只输出 ["skill"]"capability" 或 "constraint";省略时等价于 "capability""tool",并在需要领域/品牌/模板规范时追加 "skill"excel_financial_generator 或类似名称,不要命名为 user_demand_office_extensionopenjiuwen.extensions.harness.<name>. 开头development
Generates a multimodal Skill markdown file from a source URL. Use this Skill when a user wants to turn a web tutorial, product support article, or software guide into a reusable agent Skill with concise steps and embedded screenshots.
tools
Participate in an OpenJiuWen agent team as an external member. Use when this agent has been spawned into a team (the OPENJIUWEN_TEAM_JOIN environment variable is set) and needs to read its inbox, send messages to teammates, and claim / work / complete tasks via the `team-member` CLI.
tools
Complete calendar-and-clock workflows on mobile (find events, read start times, create alarms or reminders relative to meetings). Use when the user asks to schedule, set an alarm before/after a meeting, find appointment times, or coordinate Calendar with Clock.
tools
Navigate github.com in mobile Chrome to retrieve repository information (files, README, contributors, languages, releases, packages) and switch to desktop site mode for richer metadata (forks, stars). Use for in-browser research, not git CLI or GitHub API operations.