jpskill.com
🛠️ 開発・MCP コミュニティ

agent-framework

Create AI agents and workflows using Microsoft Agent Framework SDK. Supports single-agent and multi-agent workflow patterns. USE FOR: create agent, build agent, scaffold agent, new agent, agent framework, workflow pattern, multi-agent, MCP tools, create workflow. DO NOT USE FOR: deploying agents (use deploy), evaluating agents (use agent/evaluate), Azure AI Foundry agents without Agent Framework SDK.

⚡ おすすめ: コマンド1行でインストール(60秒)

下記のコマンドをコピーしてターミナル(Mac/Linux)または PowerShell(Windows)に貼り付けてください。 ダウンロード → 解凍 → 配置まで全自動。

🍎 Mac / 🐧 Linux
mkdir -p ~/.claude/skills && cd ~/.claude/skills && curl -L -o agent-framework.zip https://jpskill.com/download/19652.zip && unzip -o agent-framework.zip && rm agent-framework.zip
🪟 Windows (PowerShell)
$d = "$env:USERPROFILE\.claude\skills"; ni -Force -ItemType Directory $d | Out-Null; iwr https://jpskill.com/download/19652.zip -OutFile "$d\agent-framework.zip"; Expand-Archive "$d\agent-framework.zip" -DestinationPath $d -Force; ri "$d\agent-framework.zip"

完了後、Claude Code を再起動 → 普通に「動画プロンプト作って」のように話しかけるだけで自動発動します。

💾 手動でダウンロードしたい(コマンドが難しい人向け)
  1. 1. 下の青いボタンを押して agent-framework.zip をダウンロード
  2. 2. ZIPファイルをダブルクリックで解凍 → agent-framework フォルダができる
  3. 3. そのフォルダを C:\Users\あなたの名前\.claude\skills\(Win)または ~/.claude/skills/(Mac)へ移動
  4. 4. Claude Code を再起動

⚠️ ダウンロード・利用は自己責任でお願いします。当サイトは内容・動作・安全性について責任を負いません。

🎯 このSkillでできること

下記の説明文を読むと、このSkillがあなたに何をしてくれるかが分かります。Claudeにこの分野の依頼をすると、自動で発動します。

📦 インストール方法 (3ステップ)

  1. 1. 上の「ダウンロード」ボタンを押して .skill ファイルを取得
  2. 2. ファイル名の拡張子を .skill から .zip に変えて展開(macは自動展開可)
  3. 3. 展開してできたフォルダを、ホームフォルダの .claude/skills/ に置く
    • · macOS / Linux: ~/.claude/skills/
    • · Windows: %USERPROFILE%\.claude\skills\

Claude Code を再起動すれば完了。「このSkillを使って…」と話しかけなくても、関連する依頼で自動的に呼び出されます。

詳しい使い方ガイドを見る →
最終更新
2026-05-18
取得日時
2026-05-18
同梱ファイル
7

📖 Skill本文(日本語訳)

※ 原文(英語/中国語)を Gemini で日本語化したものです。Claude 自身は原文を読みます。誤訳がある場合は原文をご確認ください。

[Skill 名] agent-framework

Microsoft Agent Framework を使用したエージェントの作成

Microsoft Agent Framework SDK を使用して、AI エージェント、エージェントアプリケーション、およびマルチエージェントワークフローを構築します。

クイックリファレンス

プロパティ
SDK Microsoft Agent Framework (Python)
パターン シングルエージェント、マルチエージェントワークフロー
サーバー Azure AI Agent Server SDK (HTTP)
デバッグ AI Toolkit Agent Inspector + VSCode
最適用途 型安全性、チェックポイント、オーケストレーションを備えたエンタープライズエージェント

このスキルを使用するタイミング

ユーザーが以下を望む場合に使用します。

  • 新しい AI エージェントまたはエージェントアプリケーションを作成する
  • ツール (MCP、関数呼び出し) を使用してエージェントをスキャフォールドする
  • オーケストレーションパターンを使用してマルチエージェントワークフローを構築する
  • 既存のエージェントに HTTP サーバーモードを追加する
  • VSCode の F5/デバッグサポートを構成する

デフォルト

  • 言語: Python
  • SDK: Microsoft Agent Framework (バージョン 1.0.0b260107 を固定)
  • サーバー: Azure AI Agent Server SDK を介した HTTP
  • 環境: 仮想環境 (既存のものを検出または作成)

リファレンス

トピック ファイル 説明
サーバーパターン references/agent-as-server.md HTTP サーバーラッピング (本番環境)
デバッグ設定 references/debug-setup.md Agent Inspector 用の VS Code 設定
エージェントサンプル references/agent-samples.md シングルエージェント、ツール、MCP、スレッド
ワークフローの基本 references/workflow-basics.md エグゼキュータタイプ、ハンドラシグネチャ、エッジ、WorkflowBuilder — あらゆるワークフローの開始点です
ワークフローエージェント references/workflow-agents.md エグゼキュータノードとしてのエージェント、線形パイプライン、run_stream イベント消費
ワークフローファウンドリ references/workflow-foundry.md 双方向エッジ、ループ制御、register_executor ファクトリを備えたファウンドリエージェント

💡 ヒント: 高度なパターン (Reflection、Switch-Case、Fan-out/Fan-in、Loop、Human-in-Loop) については、GitHub で microsoft/agent-framework を検索してください。

MCP ツール

このスキルは、モデルおよびプロジェクト操作のために microsoft-foundry MCP ツールに委譲します。

ツール 目的
foundry_models_list 選択のためにモデルカタログを閲覧する
foundry_models_deployments_list 選択のためにデプロイされたモデルをリストする
foundry_resource_get プロジェクトエンドポイントを取得する

作成ワークフロー

  1. コンテキストを収集する (agent-as-server.md + debug-setup.md + コードサンプルを読む)
  2. モデルを選択し、環境を構成する
  3. エージェント/ワークフローコード + HTTP サーバーモード + .vscode/ 設定を実装する
  4. 依存関係をインストールする (venv + requirements.txt)
  5. 起動を検証する (実行-修正ループ)
  6. ドキュメント

ステップ 1: コンテキストの収集

ユーザーのリクエストに基づいてリファレンスファイルを読みます。

常にこれらのリファレンスを読んでください:

  • サーバーパターン: agent-as-server.md (必須 — HTTP サーバーがデフォルトです)
  • デバッグ設定: debug-setup.md (必須 — 常に .vscode/ 設定を生成します)

関連するコードサンプルを読んでください:

  • コードサンプル: agent-samples.md、workflow-basics.md、workflow-agents.md、または workflow-foundry.md

モデル選択: microsoft-foundry スキルのモデルカタログを使用して、ユーザーがモデルを選択してデプロイするのを支援します。

推奨: 高度なパターンについては、GitHub で microsoft/agent-framework を検索してください。

ステップ 2: モデルの選択と環境の構成

コーディングの前にモデルを決定してください。

ユーザーがモデルを指定していない場合は、microsoft-foundry スキルを使用してデプロイされたモデルをリストするか、デプロイを支援します。

常に .env ファイルを作成/更新してください:

FOUNDRY_PROJECT_ENDPOINT=<project-endpoint>
FOUNDRY_MODEL_DEPLOYMENT_NAME=<model-deployment-name>
  • 標準フロー: ユーザーの Foundry プロジェクトからの実際の値で入力します
  • 遅延構成: プレースホルダーを使用し、実行前に更新するようユーザーに通知します

ステップ 3: コードの実装

デフォルトでは、これら3つすべてが必須です:

  1. エージェント/ワークフローコード: 収集したコンテキストを使用してエージェントまたはワークフローを構築します
  2. HTTP サーバーモード: agent-as-server.md の Agent-as-Server パターンでラップします — これがデフォルトのエントリポイントです
  3. デバッグ設定: debug-setup.md のテンプレートを使用して .vscode/launch.json.vscode/tasks.json を生成します

⚠️ 警告: ユーザーが明示的に「最小限」または「サーバーなし」のセットアップを要求した場合にのみ、サーバーモードまたはデバッグ設定をスキップしてください。

ステップ 4: 依存関係のインストール

  1. requirements.txt を生成/更新します
    
    # 破壊的変更を避けるためバージョンを固定します

エージェントフレームワーク

agent-framework-azure-ai==1.0.0b260107 agent-framework-core==1.0.0b260107

エージェントサーバー (HTTP サーバーモード用)

azure-ai-agentserver-core==1.0.0b10 azure-ai-agentserver-agentframework==1.0.0b10

デバッグサポート

debugpy agent-dev-cli



2. グローバルな Python インストールを汚染しないように、仮想環境を使用します

> ⚠️ **警告:** bare `python` や `pip` は絶対に使用しないでください — 常に venv がアクティブ化されたバージョンまたはフルパス (例: Windows の `.venv/Scripts/python`、macOS/Linux の `.venv/bin/pip`) を使用してください。

### ステップ 5: 起動の検証 (実行-修正ループ)

起動エラーがなくなるまで実行-修正ループに入ります。

1. venv の Python を使用してメインエントリポイントを実行します (例: Windows の `.venv/Scripts/python main.py`、macOS/Linux の `.venv/bin/python main.py`)
2. **起動に失敗した場合**: エラーを修正 → 再実行
3. **起動に成功した場合**: サーバーを直ちに停止します

**ガードレール**:
- ✅ 起動エラーを捕捉するために実際の実行を行います
- ✅ 検証後にクリーンアップします (HTTP サーバーを停止します)
- ✅ 環境/認証/接続/タイムアウトエラーは無視します
- ❌ ユーザー入力を待ちません
- ❌ 個別のテストスクリプトを作成しません
- ❌ 設定をモックしません

### ステップ 6: ドキュメント

セットアップ手順と使用例を含む `README.md` を作成/更新します。

## エラー処理

| エラー | 原因 | 解決策 |
|-------|-------|------------|
| `ModuleNotFoundError` | SDK が見つからない | venv で `pip install agent-framework-azure-ai==1.0.0b260107` を実行します |
| `AgentRunResponseUpdate` が見つからない | SDK のバージョンが間違っている | `1.0.0b260107` に固定します (新しいバージョンで名前変更が発生しました) |
| Agent name vali

(原文がここで切り詰められています)
📜 原文 SKILL.md(Claudeが読む英語/中国語)を展開

Create Agent with Microsoft Agent Framework

Build AI agents, agentic apps, and multi-agent workflows using Microsoft Agent Framework SDK.

Quick Reference

Property Value
SDK Microsoft Agent Framework (Python)
Patterns Single Agent, Multi-Agent Workflow
Server Azure AI Agent Server SDK (HTTP)
Debug AI Toolkit Agent Inspector + VSCode
Best For Enterprise agents with type safety, checkpointing, orchestration

When to Use This Skill

Use when the user wants to:

  • Create a new AI agent or agentic application
  • Scaffold an agent with tools (MCP, function calling)
  • Build multi-agent workflows with orchestration patterns
  • Add HTTP server mode to an existing agent
  • Configure F5/debug support for VSCode

Defaults

  • Language: Python
  • SDK: Microsoft Agent Framework (pin version 1.0.0b260107)
  • Server: HTTP via Azure AI Agent Server SDK
  • Environment: Virtual environment (create or detect existing)

References

Topic File Description
Server Pattern references/agent-as-server.md HTTP server wrapping (production)
Debug Setup references/debug-setup.md VS Code configs for Agent Inspector
Agent Samples references/agent-samples.md Single agent, tools, MCP, threads
Workflow Basics references/workflow-basics.md Executor types, handler signatures, edges, WorkflowBuilder — start here for any workflow
Workflow Agents references/workflow-agents.md Agents as executor nodes, linear pipeline, run_stream event consumption
Workflow Foundry references/workflow-foundry.md Foundry agents with bidirectional edges, loop control, register_executor factories

💡 Tip: For advanced patterns (Reflection, Switch-Case, Fan-out/Fan-in, Loop, Human-in-Loop), search microsoft/agent-framework on GitHub.

MCP Tools

This skill delegates to microsoft-foundry MCP tools for model and project operations:

Tool Purpose
foundry_models_list Browse model catalog for selection
foundry_models_deployments_list List deployed models for selection
foundry_resource_get Get project endpoint

Creation Workflow

  1. Gather context (read agent-as-server.md + debug-setup.md + code samples)
  2. Select model & configure environment
  3. Implement agent/workflow code + HTTP server mode + .vscode/ configs
  4. Install dependencies (venv + requirements.txt)
  5. Verify startup (Run-Fix loop)
  6. Documentation

Step 1: Gather Context

Read reference files based on user's request:

Always read these references:

  • Server pattern: agent-as-server.md (required — HTTP server is the default)
  • Debug setup: debug-setup.md (required — always generate .vscode/ configs)

Read the relevant code sample:

  • Code samples: agent-samples.md, workflow-basics.md, workflow-agents.md, or workflow-foundry.md

Model Selection: Use microsoft-foundry skill's model catalog to help user select and deploy a model.

Recommended: Search microsoft/agent-framework on GitHub for advanced patterns.

Step 2: Select Model & Configure Environment

Decide on the model BEFORE coding.

If user hasn't specified a model, use microsoft-foundry skill to list deployed models or help deploy one.

ALWAYS create/update .env file:

FOUNDRY_PROJECT_ENDPOINT=<project-endpoint>
FOUNDRY_MODEL_DEPLOYMENT_NAME=<model-deployment-name>
  • Standard flow: Populate with real values from user's Foundry project
  • Deferred Config: Use placeholders, remind user to update before running

Step 3: Implement Code

All three are required by default:

  1. Agent/Workflow code: Use gathered context to structure the agent or workflow
  2. HTTP Server mode: Wrap with Agent-as-Server pattern from agent-as-server.md — this is the default entry point
  3. Debug configs: Generate .vscode/launch.json and .vscode/tasks.json using templates from debug-setup.md

⚠️ Warning: Only skip server mode or debug configs if the user explicitly requests a "minimal" or "no server" setup.

Step 4: Install Dependencies

  1. Generate/update requirements.txt
    
    # pin version to avoid breaking changes

agent framework

agent-framework-azure-ai==1.0.0b260107 agent-framework-core==1.0.0b260107

agent server (for HTTP server mode)

azure-ai-agentserver-core==1.0.0b10 azure-ai-agentserver-agentframework==1.0.0b10

debugging support

debugpy agent-dev-cli



2. Use a virtual environment to avoid polluting the global Python installation

> ⚠️ **Warning:** Never use bare `python` or `pip` — always use the venv-activated versions or full paths (e.g., `.venv/bin/pip`).

### Step 5: Verify Startup (Run-Fix Loop)

Enter a run-fix loop until no startup errors:

1. Run the main entrypoint using the venv's Python (e.g., `.venv/Scripts/python main.py` on Windows, `.venv/bin/python main.py` on macOS/Linux)
2. **If startup fails**: Fix error → Rerun
3. **If startup succeeds**: Stop server immediately

**Guardrails**:
- ✅ Perform real run to catch startup errors
- ✅ Cleanup after verification (stop HTTP server)
- ✅ Ignore environment/auth/connection/timeout errors
- ❌ Don't wait for user input
- ❌ Don't create separate test scripts
- ❌ Don't mock configuration

### Step 6: Documentation

Create/update `README.md` with setup instructions and usage examples.

## Error Handling

| Error | Cause | Resolution |
|-------|-------|------------|
| `ModuleNotFoundError` | Missing SDK | Run `pip install agent-framework-azure-ai==1.0.0b260107` in venv |
| `AgentRunResponseUpdate` not found | Wrong SDK version | Pin to `1.0.0b260107` (breaking rename in newer versions) |
| Agent name validation error | Invalid characters | Use alphanumeric + hyphens, start/end with alphanumeric, max 63 chars |
| Async credential error | Wrong import | Use `azure.identity.aio.DefaultAzureCredential` (not `azure.identity`) |

同梱ファイル

※ ZIPに含まれるファイル一覧。`SKILL.md` 本体に加え、参考資料・サンプル・スクリプトが入っている場合があります。