AGENT SKILL

sync-skills-openai-yaml

Sync every skill's agents/openai.yaml with its SKILL.md — display name, short description, and implicit-invocation policy.

License 许可
MIT
所属仓库
fschwiet/honist-v
最近更新
2026-11-08
Stars
★ 0
Forks
0

01 前言 Front Matter

name
sync-skills-openai-yaml
description
Sync every skill's agents/openai.yaml with its SKILL.md — display name, short description, and implicit-invocation policy.
disable-model-invocation
true

02 资源文件 1

03 SKILL.md 正文

Sync Skills OpenAI YAML

Claude Code reads a skill's invocation policy from SKILL.md frontmatter (disable-model-invocation). Codex reads the same policy from a sibling agents/openai.yaml. The two drift independently — a skill can gain or flip disable-model-invocation in SKILL.md without anyone touching the Codex file, or a new skill can ship with no agents/ folder at all. This skill closes that gap for every SKILL.md in the project, using ask-matt/agents/openai.yaml as the reference shape.

Process

  1. Inventory. Find every SKILL.md under the project that isn't gitignored, not a hardcoded exclude list — this is what actually keeps caches, node_modules, and similar out without needing to know their paths in advance. git ls-files alone only covers tracked files and misses a skill that moved to or was created at a new, not-yet-added path; run both git ls-files (tracked) and git ls-files --others --exclude-standard (untracked but not gitignored) and take the union. Outside a git repo, fall back to excluding node_modules and .git. For each, read the frontmatter: name, description, disable-model-invocation.

    Completion criterion: every SKILL.md path in the project is listed with those three values.

  2. Compute target state. The paired file is agents/openai.yaml in a folder sibling to SKILL.md. For each skill:

    • interface.display_name: Title Case of name (hyphens → spaces). Known acronyms (TDD, ADR, YAML, PR, ...) keep their conventional capitalization rather than generic title-casing.
    • interface.short_description: a short (~40 character), human-facing paraphrase of description — reworded, not copied verbatim or truncated mid-word.
    • policy.allow_implicit_invocation: false when disable-model-invocation: true is set in SKILL.md. When disable-model-invocation is absent, omit the policy block entirely — the schema default is true, so an explicit true is a no-op and shouldn't be written.

    Compare against whatever the file currently holds (nothing, if it doesn't exist). A missing file, a missing or wrong interface block, or a policy block that doesn't match the rule above are all findings. Leave any other existing field alone (e.g. interface.default_prompt) — this skill only owns interface.display_name, interface.short_description, and policy.allow_implicit_invocation.

    Completion criterion: every skill from Step 1 is marked create, fix (naming what's wrong), or already-correct.

  3. Apply. For every skill marked create or fix, write or edit agents/openai.yaml, creating the agents/ folder when needed. Single-quote YAML string values, matching the reference file.

    Completion criterion: every SKILL.md in the inventory has a sibling agents/openai.yaml whose interface and policy match Step 2's target state.

  4. Report. Show the user a table: skill → created / fixed (what changed) / already correct.

04 同仓库更多 Skills