Agent Loop Skillのロゴ

Agent Loop Skill

コミュニティ
dososo
agent-loop-skill

Build and run long-running AI agent workflows for Codex, Claude Code, Cursor, and other coding agents with contracts, disk-backed state, role separation, verification traces, restart criteria, subjective scoring, and harness cleanup. Use when a user asks an agent to complete multi-step coding, product, research, content, design, debugging, batch generation, or cross-session tasks that require planning, repeated execution, evidence, or recovery after failures.

概要

公開者dososo
リポジトリagent-loop-skill
スキル名agent-loop-skill
スター
32
フォーク
4
同梱ファイル
1
リンク
  • Markdown形式の指示

    モデルが必要に応じて読み込むSKILL.mdファイルです。関連するリクエストがあったときだけトークンを消費します。

  • どのLLMでも利用可能

    AIスキルはプロバイダー固有のコードではなく、通常のMarkdownなので、GPT、Claude、Gemini、Grok、ローカルモデルで利用できます。

  • 1個の同梱ファイル

    モデルが作業中に読み取れるスクリプト、テンプレート、参考資料です。ファイルは読み取り専用で、実行されることはありません。

  • オープンソース

    dososoがGitHubで公開しています。インストールする前にソースを確認してください。

インストール

AIスキルAgent Loop SkillをTypingMindにインストールすれば、どのLLMでも利用できます。SKILL.mdを読み取れる別のAIエージェントに追加することもできます。

1

TypingMindにインストール

TypingMindはGitHubフォルダから直接スキルをインストールします。SKILL.mdを読み取り、リソースファイルをまとめてローカルに保存します。

  1. アプリを開き、「プラグイン」→「スキル」に移動します。
  2. 「GitHubからインストール」を選択します。
  3. 以下のスキルフォルダのURLを貼り付けて確定します。
    https://github.com/dososo/agent-loop-skill/tree/main/skills/agent-loop-skill
  4. スキルを利用したいチャットごとに、そのスキルを有効にしてください。
「プラグイン」→「スキル」→「スキルを追加」→「GitHubのURLから」を選択し、フォルダのURLを貼り付けて「続行」を押します。
2

別のAIエージェントにインストール

Agent Skills形式を読み取れるAIエージェントなら、このスキルを利用できます。フォルダをそのAIエージェントのスキルディレクトリにコピーしてください。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/dososo/agent-loop-skill.git /tmp/agent-loop-skill
mkdir -p .claude/skills
cp -r /tmp/agent-loop-skill/skills/agent-loop-skill .claude/skills/agent-loop-skill
コピー後、新しいスキルを読み込むためにClaude Codeを再起動してください。

TypingMindで使用

TypingMindのチャットでAgent Loop Skillを有効にするだけで、あとはモデルが対応します。名前と説明がシステムプロンプトに含まれ、関連するリクエストがあると、モデルが指示の全文を自動で読み込みます。手動で呼び出す必要はなく、実際に使用されるまでトークンを消費しません。

関連するリクエストがあると、モデルが自動的にAgent Loop Skillを読み込みます。

どのAIモデルでも利用可能

AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、Agent Loop Skillは作成時に想定されたモデルに縛られません。TypingMindに一度インストールすれば、ご自身のAPIキーを使って、GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama、またはご自身で実行するローカルモデルで利用できます。

  • 必要なときだけ読み込み

    システムプロンプトには名前と説明だけが含まれます。関連するリクエストが初めてあったときに指示を取得するため、未使用のスキルにはコストがかかりません。

  • チャットの途中でモデルを切り替え

    スキルはコードではなく指示なので、モデルを切り替えてもそのまま使えます。次のモデルも同じSKILL.mdを読み込みます。

スキルの指示

モデルが読み込むSKILL.mdの内容です。スキルはモデルが従う指示なので、インストールする前に確認してください。

Agent Loop Skill

Use this skill to turn an open-ended agent task into a repeatable loop that can run, verify, recover, and finish without relying only on chat context.

Do not use the full loop for trivial one-line answers, simple typo fixes, or single commands with obvious output.

Quick Start

When the task is non-trivial:

  1. Read the user request and local project context.
  2. Create .agent-loop/contract.md.
  3. Create .agent-loop/progress.md.
  4. Create .agent-loop/log.md.
  5. Split work into Planner, Generator, and Evaluator roles.
  6. Execute the smallest verifiable round.
  7. Save evidence in logs, traces, screenshots, command output, or diffs.
  8. Fix, restart, or finish based on the contract.
  9. Remove or justify temporary harness files before delivery.

1. Write The Loop, Not Just The Prompt

Convert the request into a loop before doing the work.

Define:

  • the final deliverable
  • in-scope work
  • out-of-scope work
  • acceptance criteria
  • validation commands or evidence
  • restart criteria
  • stop conditions

If chat messages are repeating without progress, stop and write the loop to disk.

2. Separate Roles

Use three roles by default:

  • Planner: clarify the goal, scope, risks, acceptance criteria, and execution order.
  • Generator: implement, edit, generate, or repair only inside the contract.
  • Evaluator: test, inspect, read traces, and decide whether acceptance criteria pass.

Add a Referee only when the roles disagree. The Referee arbitrates; it does not expand scope.

3. Negotiate The Contract First

Before writing final code or content, write .agent-loop/contract.md.

Use this structure:

text
Goal:
In scope:
Out of scope:
Definition of done:
Acceptance criteria:
Validation commands:
Subjective scoring criteria:
Risk assumptions:
Stop conditions:
Restart conditions:
Final deliverables:

Avoid vague criteria. Each item must be checkable through command output, screenshot, trace, log, diff, checklist, or scorecard.

4. Write To Disk, Not To Context

For long work, maintain these files:

text
.agent-loop/contract.md
.agent-loop/progress.md
.agent-loop/log.md

Use optional files only when useful:

text
.agent-loop/state.json
.agent-loop/scorecard.md
.agent-loop/defects.md
.agent-loop/traces/

If these files cannot describe the state clearly, split the task.

Append to .agent-loop/log.md; do not rewrite history.

5. Let The Loop Restart

Restart from the contract when:

  • the same acceptance item fails twice
  • implementation is turning into patches on patches
  • tests pass but the deliverable misses the user goal
  • the log shows the contract was forgotten
  • continuing is more expensive than a clean retry

Before restarting, append the failure reason and evidence to .agent-loop/log.md.

6. Score The Subjective

For design, writing, UX, product, architecture, or taste-heavy work, write the scoring criteria before judging the result.

Default dimensions:

DimensionQuestion
FunctionalityDoes it solve the real target problem?
SimplicityDoes it avoid unnecessary abstraction and scope?
CraftAre details, naming, flow, and edge cases handled well?
OriginalityDoes it show judgment instead of copying a template?

Score 0-10 and write one sentence of evidence per dimension.

When references exist, compare against at least one strong sample, one weak sample, and the current output.

7. Read The Traces

Judge from evidence, not intuition.

Useful traces include:

  • test output
  • build logs
  • console errors
  • browser screenshots
  • Playwright traces
  • API requests and responses
  • diffs
  • generated artifacts
  • user-visible output

If trace evidence conflicts with intuition, trust the trace and create a smaller reproduction.

8. Delete The Harness

Before delivery, inspect whether the harness still helps.

Review:

  • temporary scripts
  • debug logs
  • redundant state files
  • verification-only code
  • stale traces
  • overgrown automation

Delete, archive, or justify anything that should not remain in the final project.

9. The Bottleneck Always Moves

At the end of each round, update .agent-loop/progress.md:

text
Current bottleneck:
Why this is the bottleneck:
How the next round will verify it is solved:

When coding is solved, planning may become the bottleneck. When planning is solved, verification may become the bottleneck. Keep looking for the current constraint.

Default Completion Standard

Only finish when:

  • every contract item passes
  • every acceptance criterion has evidence
  • .agent-loop/progress.md has no unresolved blocker
  • .agent-loop/log.md explains key decisions and failed attempts
  • subjective work has a scorecard or user approval
  • temporary harness files are removed or justified
  • final deliverables are usable directly

Suggested Trigger

text
Use agent-loop-skill for this task. Write the contract first, keep state in .agent-loop, separate Planner/Generator/Evaluator, verify each round with traces, and restart if the same acceptance item fails twice.

同梱ファイル

スキルが読み込まれている間、モデルは必要に応じてこれらを読み取ります。読み取り可能なファイルとして提供され、実行されることはありません。

よくある質問

AIスキル「Agent Loop Skill」では何ができますか?

Build and run long-running AI agent workflows for Codex, Claude Code, Cursor, and other coding agents with contracts, disk-backed state, role separation, verification traces, restart criteria, subjective scoring, and harness cleanup. Use when a user asks an agent to complete multi-step coding, product, research, content, design, debugging, batch generation, or cross-session tasks that require planning, repeated execution, evidence, or recovery after failures.

TypingMindでAgent Loop Skillを使うメリットは何ですか?

一度インストールすれば、どのモデルでも使えるからです。Agent Loop Skillはプロバイダー固有のコードではなく、通常のMarkdownで記述されているため、同じスキルをGPT-5、Claude、Gemini、Grok、ローカルモデルで利用できます。チャットの途中でモデルを切り替えても、そのまま使い続けられます。TypingMindは自分のAPIキーで動作するため、シート単位のサブスクリプションではなく、プロバイダーに直接料金を支払います。スキルとチャットは自分のストレージに保持されます。

TypingMindにAgent Loop Skillをインストールするにはどうすればよいですか?

TypingMindで「プラグイン」→「スキル」→「GitHubからインストール」を開き、https://github.com/dososo/agent-loop-skill/tree/main/skills/agent-loop-skillを貼り付けてください。TypingMindがSKILL.mdを読み込み、関連ファイルをまとめて、チャットごとに有効にできるスキルとしてインストールします。

Agent Loop Skillを使えるAIモデルはどれですか?

TypingMindに接続したどのモデルでも利用できます。AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、GPT、Claude、Gemini、Grok、ローカルモデルのいずれも、リクエストが合致したときにこのスキルを読み込めます。

Agent Loop Skillは何個のAIモデルで使えますか?

数に制限はありません。スキルに対応したモデルであれば、GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llamaなど、どのモデルでもAgent Loop Skillを利用できます。すべてTypingMind上で、自分のAPIキーを使って利用できます。

AIスキル「Agent Loop Skill」は無料ですか?

dososoがGitHubで公開しています。ライセンス条件はリポジトリでご確認ください。支払いが必要なのは、利用したトークンに対する、ご自身が契約するAIプロバイダーへの料金だけです。

AIスキルとは何ですか?

AIスキルは、特定のタスクの実行方法をAIモデルに教える、再利用可能な指示のセットです。オープンなAgent Skills形式に従い、名前と説明を含むSKILL.mdファイルに加え、モデルが必要とするスクリプト、テンプレート、参照ファイルで構成されます。モデルはリクエストがスキルに合致したときだけ指示を読み込むため、インストール済みのスキルも、使うまでは費用がかかりません。

AIスキルは、プラグインやMCPサーバーとどう違いますか?

プラグインやMCPサーバーは、モデルが呼び出せる新しいツールを提供します。ツールとは、どこかで実行され、結果を返すコードです。一方、AIスキルは、タスクへの取り組み方、従うべき手順、望ましい出力の例といった知識や進め方をモデルに伝えます。スキルは通常のMarkdownで記述されているため、サーバー、APIキー、実行環境は不要で、どのモデルでも利用できます。

すべて見る

今すぐ自分専用のAIワークスペースを作成

ニュースレターに登録すると、新機能や今後のプレゼント企画のお知らせが届きます👇