Skill Comply

by affaan-mef648e01899bNo license275K starsListed Oct 8, 2026Updated Oct 8, 2026Repository updated 3 days ago

スキル、ルール、エージェント定義が実際に遵守されているかを可視化する——3種類のプロンプト厳格度レベルのシナリオを自動生成し、エージェントを実行し、動作シーケンスを分類し、完全なツール呼び出しタイムラインの遵守率をレポートする

Instructions onlyAI & Agents
AI-generated overview

Measures whether coding agents actually follow skills, rules, or agent definitions and reports compliance rates.

What it does
Generates an expected behavior specification from any .md file and creates scenarios at three prompt-strictness levels (supportive, neutral, competitive). It runs the agent, captures tool-call traces, classifies calls against spec steps using an LLM, and checks ordering deterministically. It produces a self-contained report with the spec, prompts, per-scenario compliance scores, and a tool-call timeline.
When to use it
Use it to check whether a skill, rule, or agent definition is actually being followed, especially after adding a new rule or skill or during periodic quality maintenance. It is also meant for questions about whether a given rule is truly respected.
Requirements
Requires the uv Python runner and the claude CLI with stream-json output, plus model access for generation and classification. The SKILL.md documents commands such as uv run python -m scripts.run, but no scripts ship with the skill.

skill-comply:自動化された遵守測定

コーディングエージェントがスキル、ルール、またはエージェント定義を実際に遵守しているかを以下の方法で測定する:

  1. 任意の .md ファイルから期待される動作シーケンス(仕様)を自動生成する
  2. プロンプトの厳格度が段階的に低下するシナリオを自動生成する(支持的 → 中立的 → 競合的)
  3. claude -p を実行し、stream-json 経由でツール呼び出しトレースを取得する
  4. 正規表現ではなくLLMを使用してツール呼び出しを仕様ステップに分類する
  5. 決定論的に時系列順を確認する
  6. 仕様、プロンプト、タイムラインを含む自己完結型レポートを生成する

サポートされるターゲット

  • スキル(skills/*/SKILL.md):検索優先、TDDガイドなどのワークフロースキル
  • ルール(rules/common/*.md):testing.md、security.md、git-workflow.md などの強制的なルール
  • エージェント定義(agents/*.md):エージェントが期待される場面で呼び出されるか(内部ワークフロー検証は未サポート)

起動条件

  • ユーザーが /skill-comply <path> を実行する
  • ユーザーが「このルールは本当に遵守されているか?」と尋ねる
  • 新しいルール/スキルを追加した後、エージェントの遵守を確認する
  • 品質メンテナンスの一環として定期的に実行する

使い方

bash
# Full runuv run python -m scripts.run ~/.claude/rules/common/testing.md
# Dry run (no cost, spec + scenarios only)uv run python -m scripts.run --dry-run ~/.claude/skills/search-first/SKILL.md
# Custom modelsuv run python -m scripts.run --gen-model haiku --model sonnet <path>

重要なコンセプト:プロンプト独立性

プロンプトが明示的にサポートしていない場合でも、スキル/ルールが遵守されるかどうかを測定する。

レポートの内容

レポートは自己完結型で、以下を含む:

  1. 期待される動作シーケンス(自動生成された仕様)
  2. シナリオプロンプト(各厳格度レベルで尋ねる内容)
  3. 各シナリオの遵守スコア
  4. LLM分類ラベル付きのツール呼び出しタイムライン

高度な内容(オプション)

フックに精通したユーザー向けに、レポートには遵守率が低いステップに対するフック強化の推奨事項も含まれる。これは参考情報——主要な価値は遵守性自体の可視化にある。

Source and attribution

Source:affaan-m/eccindocs/ja-JP/skills/skill-complyat commitef648e0

License: No license

Content belongs to its original authors. SourceWeft indexes it from a public repository.

Report or request removal