Files
cli/skills/models/SKILL.md
jiantw83 daa4bcf9e1 fix(frontmatter): 修正 models 技能 SKILL.md frontmatter 的 YAML 純量語法錯誤
What:
- 修正 skills/models/SKILL.md frontmatter 裡 description 欄位的 YAML 語法錯誤。
- 整串 description 加上單引號,內部撇號改寫成兩個單引號,內容文字一個字都沒變。
- 同步更新 plugin.json、.claude-plugin/plugin.json、.codex-plugin/plugin.json 三個 manifest 版本號,從 0.2.6 進到 0.2.7。

Why:
- description 內含「冒號加空白」,屬於未加引號的 YAML plain scalar,違反 YAML 語法規定。
- Antigravity 解析 frontmatter 時當場中斷,整支技能被靜默丟棄,沒有任何錯誤訊息;磁碟上 34 支技能,Antigravity 只認得 28 支。
- 準則要求 description 用英文撰寫,不能把「: 」改成全形冒號迴避語法問題,只能加引號修正。

How:
- 整串 description 值加上單引號,內部撇號寫成兩個單引號跳脫,其餘字元不動。
- 用 git show HEAD: 取出改前的原始值,把改後的單引號純量還原後做字串相等比對,確認逐字相同、字元數一致。
- 執行 ste100-lint.sh、check-behaviors.sh、lint-frontmatter.sh 三支檢查腳本,退出碼皆為 0;git diff --numstat 顯示只動了 frontmatter 那一行。

Who:
- 本次修到 cli 技能組的 models 技能,屬盤點各 CLI 可用模型與能力標籤的功能。
2026-08-31 19:02:43 +08:00

4.9 KiB

name, description
name description
models List every model usable by each installed AI CLI (claude, codex, copilot, antigravity, kiro) and attach capability tags from references/model-tags.md. Syncs the tag table to $JSC_HOME/model-tags.tsv via tools/model-tags.sh, so jsc-sdlc gates are enforced in code. States each SDLC stage's required tags: plan and analyze need reasoning-max, implement needs coding, maintain any. Resolves each stage's preferred model chain via tools/model-config.sh (project .jsc/models overrides $JSC_HOME/models.conf), for switch suggestions only. Use when checking model fitness, inventorying models, or reviewing stage gating; not for switching models or editing the config files.

models — list CLI models with capability tags

Steps

  1. Start three collectors at once. They read different files and share no state, so the stage preference chain is fetched here rather than waited for at the end.

    1. jsc-cli/tools/detect-clis.sh — the installed CLIs, as {name}<TAB>{path}<TAB>{version}. Exit 0 with at least one row → that is the CLI list. Exit 0 with no row → no AI agent CLI is installed on this machine: report that, name the five it probes, skip steps 2 to 4, and go straight to step 5, because the tag table and the stage requirements are still worth writing out. Any non-zero exit → stop and report the exit code and stderr.
    2. jsc-cli/tools/list-models.sh — each CLI's models and the model currently in use, as cli<TAB>model<TAB>in-use, read from each CLI's own config. It stays silent for a CLI whose config it cannot read and always exits 0; a non-zero exit means the script itself failed, so report the model inventory as 無法取得 with the exit code. This collector MUST run as a sub agent.
    3. jsc-cli/tools/model-config.sh list — one line per stage, stage<TAB>chain<TAB>source, with - for unconfigured stages. Exit 0 → use the rows in step 6. Exit 2 → usage error, report it as a defect in this skill and show step 6's 階段偏好模型 table as 未取得. Any other exit → same handling, with the exit code named.

    Done when all three collectors have returned, and each has either its rows or an explicit failure reason.

  2. Reconcile the two lists. For every detected CLI that collector 1.2 returned no rows for, list that CLI's known default models and mark each one with the literal label 「預設推定」 (assumed default). Done when every detected CLI has either a model list from its config or a set of assumed defaults.

  3. Attach capability tags to every model per references/model-tags.md. A model missing from that table is not tagged by guesswork: add it to the table from the vendor's documentation, or queue it as a jsc-ask:ask question. Done when every listed model carries at least one tag and every unlisted model is either added to the table or queued as a jsc-ask:ask question.

  4. Output a table with four columns: CLI, model, tags, currently in use. Done when the table holds one row per model from step 2.

  5. Run tools/model-tags.sh sync to write the tag table to $JSC_HOME/model-tags.tsv. This file is what jsc-hooks/hooks/sdlc-gate.sh reads, so the SDLC gate stays broken until it exists.

    Exit Action
    0 Report the path it printed
    1 references/model-tags.md could not be parsed, or $JSC_HOME could not be written, so nothing was written. Name the reference path and the stderr, and state that the SDLC gate stays broken until this is fixed
    2 Usage error — the subcommand or its arguments are wrong, and the script printed its usage line instead of running. Report it as a defect in this skill, and do not retry with a guessed argument. This is the same code the script uses for UNKNOWN-MODEL and UNKNOWN-STAGE, so it never means a model failed a requirement
    other Report the sync as failed with the exit code and stderr. Never report a path that was not printed

    Done when the written path is reported, or the failure is reported with its exit code.

  6. Append the two stage tables, in this order.

    1. The SDLC stage requirement table (plan and analyze need reasoning-max; implement needs coding; maintain accepts any), stating that gating is done in code by sdlc-gate.sh lock {stage} against the transcript's actual model id — the models listed here are never allowed to self-assess their own tags.
    2. A 「階段偏好模型」 table right after it, built from collector 1.3's rows, with three columns: stage, chain, source (project / global). State below the table that the chain does not grant passage: it only names the model to suggest switching to when the gate blocks, and expresses preference among models that already satisfy the required tags.

    Done when the requirement table shows all four stages with their required tags, and the 階段偏好模型 table shows the same four stages with - for unconfigured ones.