Agent skill

Agent Introspection Debugging

by affaan-m in affaan-m/ECC

キャプチャ、診断、封じ込め回復、内省レポートを使用した AI エージェント障害のための構造化された自己デバッグワークフロー。

MITAuto-check passedDevelopment

Install Agent Introspection Debugging

skills CLI
$ npx skills add affaan-m/ECC --skill agent-introspection-debugging -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install affaan-m/ECC agent-introspection-debugging --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/affaan-m/ECC.git skills-src && mkdir -p .claude/skills && cp -r skills-src/docs/ja-JP/skills/agent-introspection-debugging .claude/skills/agent-introspection-debugging && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
agent-introspection-debugging
GitHub stars
276k
Token cost
~763 tokens
SKILL.md length
143 words
Files
1
Skills in repo
673
Repo updated
First seen
Licence
MIT

At a glance

キャプチャ、診断、封じ込め回復、内省レポートを使用した AI エージェント障害のための構造化された自己デバッグワークフロー。

  • Works in 5 steps: 実際の目標を一文で再述べる。 → メモリを信頼するのではなく世界の状態を確認する。 → 失敗しているスコープを縮小する。 → …
  • Tasks that involve Debugging
  • SKILL.md covers 起動タイミング, スコープ境界, 四フェーズループ and 回復ヒューリスティクス, plus 2 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Agent Introspection Debugging is an agent skill from affaan-m/ECC. キャプチャ、診断、封じ込め回復、内省レポートを使用した AI エージェント障害のための構造化された自己デバッグワークフロー。

Its SKILL.md is about 760 tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Development, covering Debugging. The repository describes itself as: The agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Cursor and beyond. The licence is MIT.

When your agent uses it

  • Tasks that involve Debugging

Example prompts

  • “/agent-introspection-debugging”

Workflow steps

5 steps, taken from the first numbered list in SKILL.md.

  1. 実際の目標を一文で再述べる。
  2. メモリを信頼するのではなく世界の状態を確認する。
  3. 失敗しているスコープを縮小する。
  4. 1 つの識別チェックを実行する。
  5. その後にのみリトライする。

What it can do on your machine

Read from SKILL.md and the folder at commit ef648e0. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are markdown).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Agent Introspection Debugging loads about 763 tokens when it runs. Until then it costs about 23 tokens; SKILL.md has 143 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~23
When it runs · the whole SKILL.md, loaded when a task matches
~763

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from affaan-m/ECC at commit ef648e0, republished under its MIT licence (© affaan-m). 143 words, ~763 tokens.

Download SKILL.mdSave it as .claude/skills/agent-introspection-debugging/SKILL.md (or your agent's skills folder).
name
agent-introspection-debugging
description
キャプチャ、診断、封じ込め回復、内省レポートを使用した AI エージェント障害のための構造化された自己デバッグワークフロー。
origin
ECC

エージェント内省デバッグ

エージェント実行が繰り返し失敗している、進展なくトークンを消費している、同じツールをループしている、または意図したタスクから逸脱している場合にこのスキルを使用します。

これはワークフロースキルであり、隠れたランタイムではありません。エージェントが人間にエスカレーションする前に体系的に自己デバッグするよう教えます。

起動タイミング

  • ツール呼び出しの最大数 / ループ制限の失敗
  • 前進なしの繰り返しリトライ
  • 出力品質の低下を招くコンテキストの増大またはプロンプトのドリフト
  • 期待と現実の間でのファイルシステムや環境状態の不一致
  • 診断とより小さな修正アクションで回復可能なツールの失敗

スコープ境界

このスキルを起動するのは以下の場合:

  • 盲目的にリトライする前に障害状態をキャプチャする
  • エージェント固有の一般的な障害パターンを診断する
  • 封じ込め回復アクションを適用する
  • 構造化された人間が読めるデバッグレポートを生成する

このスキルを主なソースとして使用しない場合:

  • コード変更後の機能検証; verification-loop を使用
  • より狭い ECC スキルが既に存在するフレームワーク固有のデバッグ
  • 現在のハーネスが自動的に強制できないランタイムの約束

四フェーズループ

フェーズ 1: 障害キャプチャ

回復を試みる前に、障害を正確に記録します。

キャプチャ内容:

  • エラーの種類、メッセージ、スタックトレース(利用可能な場合)
  • 最後の意味のあるツール呼び出しシーケンス
  • エージェントが何をしようとしていたか
  • 現在のコンテキスト圧力:繰り返されるプロンプト、過大なペーストされたログ、重複した計画、暴走するノート
  • 現在の環境の前提:cwd、ブランチ、関連するサービス状態、期待されるファイル

最小キャプチャテンプレート:

markdown
## 障害キャプチャ
- セッション / タスク:
- 進行中の目標:
- エラー:
- 最後に成功したステップ:
- 最後に失敗したツール / コマンド:
- 観察された繰り返しパターン:
- 検証すべき環境の前提:
フェーズ 2: 根本原因診断

何も変更する前に、障害を既知のパターンに照合します。

パターン考えられる原因チェック
ツール呼び出しの最大数 / 同じコマンドの繰り返しループまたは出口なしのオブザーバーパス最後の N 回のツール呼び出しを繰り返しについて検査する
コンテキストオーバーフロー / 推論の低下無制限のノート、繰り返される計画、過大なログ最近のコンテキストを重複と低シグナルのバルクについて検査する
ECONNREFUSED / タイムアウトサービスが利用不可または間違ったポートサービスの健全性、URL、ポートの前提を確認する
429 / クォータ枯渇リトライストームまたはバックオフなし繰り返し呼び出しを数え、リトライ間隔を検査する
書き込み後にファイルが見つからない / 古い差分レース、間違った cwd、またはブランチドリフトパス、cwd、git ステータス、実際のファイル存在を再確認する
「修正」後もテストが失敗し続ける間違った仮説失敗している正確なテストを分離し、バグを再導出する

診断の質問:

  • これはロジックの失敗か、状態の失敗か、環境の失敗か、ポリシーの失敗か?
  • エージェントは実際の目標を見失い、間違ったサブタスクを最適化し始めたか?
  • 障害は決定論的か一時的か?
  • 診断を検証する最小の可逆的アクションは何か?
フェーズ 3: 封じ込め回復

診断の表面を変える最小のアクションで回復します。

安全な回復アクション:

  • 繰り返しのリトライを停止し、仮説を再述べる
  • 低シグナルのコンテキストを削除し、アクティブな目標、ブロッカー、エビデンスのみを保持する
  • 実際のファイルシステム / ブランチ / プロセス状態を再確認する
  • タスクを 1 つの失敗しているコマンド、1 つのファイル、または 1 つのテストに絞り込む
  • 推測的な推論から直接観察に切り替える
  • 障害が高リスクまたは外部的にブロックされている場合は人間にエスカレーションする

現在の環境の実際のツールを通じて実際にそれらを行っていない限り、「エージェント状態をリセット」または「ハーネス設定を更新」のような自動回復アクションを主張しないこと。

封じ込め回復チェックリスト:

markdown
## 回復アクション
- 選択した診断:
- 取った最小アクション:
- なぜこれが安全か:
- 修正が機能したことを証明するエビデンスは何か:
フェーズ 4: 内省レポート

次のエージェントや人間が回復を理解できるレポートで終了します。

markdown
## エージェント自己デバッグレポート
- セッション / タスク:
- 障害:
- 根本原因:
- 回復アクション:
- 結果: 成功 | 部分的 | ブロック中
- トークン / 時間の消費リスク:
- 必要なフォローアップ:
- 後でエンコードすべき予防的変更:

回復ヒューリスティクス

この順序で介入を優先する:

  1. 実際の目標を一文で再述べる。
  2. メモリを信頼するのではなく世界の状態を確認する。
  3. 失敗しているスコープを縮小する。
  4. 1 つの識別チェックを実行する。
  5. その後にのみリトライする。

悪いパターン:

  • わずかに異なる言葉で同じアクションを 3 回リトライする

良いパターン:

  • 障害をキャプチャする
  • パターンを分類する
  • 1 つの直接チェックを実行する
  • チェックがサポートする場合にのみ計画を変更する

ECC との統合

  • コードが変更された場合、回復後に verification-loop を使用する。
  • 障害パターンが本能や将来のスキルに変える価値がある場合は continuous-learning-v2 を使用する。
  • 問題が技術的な失敗ではなく決定の曖昧さである場合は council を使用する。
  • 障害が競合するローカル状態やリポジトリのドリフトから来た場合は workspace-surface-audit を使用する。

出力標準

このスキルがアクティブな場合、「修正しました」だけで終わらないこと。

常に提供する:

  • 障害パターン
  • 根本原因の仮説
  • 回復アクション
  • 状況が改善されたまたはまだブロックされているエビデンス

© affaan-m, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in docs/ja-JP/skills/agent-introspection-debugging of affaan-m/ECC.

Open the folder on GitHubat commit ef648e0

Compare with similar skills

Agent Introspection Debugging next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Agent Introspection Debugging compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Agent Introspection Debugging this skillaffaan-m/ECC276k—~763Automated safety check: PassMIT
Trellis Session Insightmindfold-ai/Trellis15k4 repos~1.7kAutomated safety check: PassAGPL-3.0
Native Data FetchingCherryHQ/cherry-studio-app4k6 repos~2.9kAutomated safety check: NotesMIT
Debugging Executionsn8n-io/n8n207k—~2.6kAutomated safety check: PassCustom licence
Aoti Debugpytorch/pytorch104k1 repos~1.7kAutomated safety check: PassCustom licence
Herdr Throwaway Reproductionherdrdev/herdr43k—~2.4kAutomated safety check: PassApache-2.0

Similar skills

  • Trellis Session Insight

    mindfold-ai/Trellis

    Reach into past AI conversation history through the trellis mem CLI.

    15k GitHub starsUsed in 4 repos~1.7k tokens
    DevelopmentAuto-check passed
  • Native Data Fetching

    CherryHQ/cherry-studio-app

    A skill your agent uses when implementing or debugging ANY network request, API call, or data fetching.

    4k GitHub starsUsed in 6 repos~2.9k tokens
    DevelopmentAuto-check: notes
  • Official

    Debug failed or wrong-output workflow executions using executions tools.

    207k GitHub stars~2.6k tokensUpdated today
    DevelopmentAuto-check passed
  • Aoti Debug

    pytorch/pytorch

    Debug AOTInductor (AOTI) errors and crashes. An agent skill from pytorch/pytorch.

    104k GitHub starsUsed in 1 repo~1.7k tokens
    DevelopmentAuto-check passed
  • Runs a disposable, uniquely named Herdr session inside an existing one so runtime, pane, terminal or API bugs can be reproduced without touching the main session.

    43k GitHub stars~2.4k tokensUpdated today
    DevelopmentAuto-check passed
  • Systematic Debugging

    ultralisp/ultralisp

    A skill your agent uses when encountering any bug, test failure, or unexpected behavior, before proposing fixes

    258 GitHub starsUsed in 51 repos~2.4k tokens
    DevelopmentAuto-check passed

More from affaan-m/ECC

All 673 skills in this repo
  • Skill Stocktake

    affaan-m/ECC

    Audits your installed Claude skills and commands for quality, with a quick mode for recently changed skills and a full mode that evaluates all of them through subagents.

    276k GitHub starsUsed in 5 repos~1.9k tokens
    Auto-check passed
  • Ingests, indexes, searches, edits and monitors video, audio and live streams through the VideoDB Python SDK, returning stream links, clips and timestamps.

    276k GitHub starsUsed in 3 repos~3.5k tokens
    Auto-check: notes
  • Rules Distillation

    affaan-m/ECC

    Scans installed skills for principles that recur across them and proposes rule-file changes: append, revise, add a section, create a file or leave as covered.

    276k GitHub starsUsed in 2 repos~2.3k tokens
    Auto-check passed
  • Builds DRAFT counterparty agreements from one markdown template and a small JSON spec per party, with clauses picked by the party's role.

    276k GitHub stars~2.9k tokensUpdated 4 days ago
    Auto-check passed
  • Measures whether agents actually follow a skill, rule or agent definition by generating scenarios at three strictness levels and scoring tool-call traces.

    276k GitHub starsUsed in 1 repo~623 tokens
    Auto-check passed
  • Instinct-based learning system that observes sessions via hooks, creates atomic instincts with confidence scoring, and evolves them into skills/commands/agents.

    276k GitHub stars~3.5k tokensUpdated 4 days ago
    Auto-check passed

Categories

Questions about Agent Introspection Debugging

What does Agent Introspection Debugging do?

キャプチャ、診断、封じ込め回復、内省レポートを使用した AI エージェント障害のための構造化された自己デバッグワークフロー。. Agent Introspection Debugging is an agent skill from affaan-m/ECC.

When should I use Agent Introspection Debugging?

Agent Introspection Debugging fits situations like: tasks that involve Debugging.

How do I install Agent Introspection Debugging in Claude Code?

Run `npx skills add affaan-m/ECC --skill agent-introspection-debugging -a claude-code`. Or copy the skill folder (docs/ja-JP/skills/agent-introspection-debugging in affaan-m/ECC) into .claude/skills/agent-introspection-debugging in your project. Claude Code loads it when a task matches its description.

How do I install Agent Introspection Debugging in Codex?

Run `npx skills add affaan-m/ECC --skill agent-introspection-debugging -a codex`. Or copy the skill folder (docs/ja-JP/skills/agent-introspection-debugging in affaan-m/ECC) into .agents/skills/agent-introspection-debugging in your project. Codex loads it when a task matches its description.

Can I use Agent Introspection Debugging in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add affaan-m/ECC --skill agent-introspection-debugging -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/agent-introspection-debugging, .gemini/skills/agent-introspection-debugging, .github/skills/agent-introspection-debugging and .opencode/skills/agent-introspection-debugging in your project.

What does Agent Introspection Debugging need to run?

SKILL.md names no scripts, command-line tools or credentials: Agent Introspection Debugging is instructions for the agent only.

Does Agent Introspection Debugging access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Agent Introspection Debugging safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Agent Introspection Debugging use?

Agent Introspection Debugging is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Agent Introspection Debugging use?

About 763 tokens (SKILL.md is roughly 3.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Agent Introspection Debugging?

Skills that share tags, products or a category with Agent Introspection Debugging: Trellis Session Insight (mindfold-ai/Trellis, 15k stars), Native Data Fetching (CherryHQ/cherry-studio-app, 4k stars), Debugging Executions (n8n-io/n8n, 207k stars) and Aoti Debug (pytorch/pytorch, 104k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Agent Introspection Debugging?

affaan-m (a GitHub user) maintains it in affaan-m/ECC, which has 275,546 GitHub stars. The repository holds 673 skills in this directory. The repository was last updated on October 5, 2026.

Source: affaan-m/ECC on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.