# カスタム エージェントについて

Custom agents お客様のニーズに合わせた支援で Copilot を強化します。

## custom agents の概要

Custom agents は、独自のワークフロー、コーディング規則、ユース ケースに合わせて調整できる、 Copilot エージェントの特殊なバージョンです。 彼らは、あなたの標準に従い、適切なツールを使用し、チーム固有のプラクティスを実装する調整されたチームメイトのように動作します。 これらのエージェントは、同じ命令とコンテキストを繰り返し提供するのではなく、1 回定義します。

custom agentsと呼ばれる Markdown ファイルを使用して、agent profilesを定義します。 これらのファイルは、プロンプト、ツール、および MCP サーバーを指定します。 これにより、規則、フレームワーク、および必要な結果を Copilotに直接エンコードできます。

agent profileは、custom agentの動作を定義します。 タスクまたは問題にエージェントを割り当てると、 custom agentがインスタンス化されます。

## Agent profile 形式

Agent profiles は、YAML frontmatter を含む Markdown ファイルです。 最も単純な形式では、次のものが含まれます。

* **名前** (省略可能): custom agentの表示名。 省略すると、エージェントのファイル名が識別子と既定の表示名として使用されます。
* **説明**: エージェントの目的と機能について説明します。
* **プロンプト**: エージェントの動作と専門知識を定義するカスタム命令。
* **ツール** (省略可能): エージェントがアクセスできる特定のツール。 既定では、エージェントは、組み込みのツールや MCP サーバー ツールなど、使用可能なすべてのツールにアクセスできます。

Agent profiles では、 `mcp-servers` プロパティを使用して MCP サーバー構成を含めることもできます。

### agent profile の例

この例は、名前、説明、プロンプトが構成された基本的な agent profile です。

```text
---
name: readme-creator
description: Agent specializing in creating and improving README files
---

You are a documentation specialist focused on README files. Your scope is limited to README files or other related documentation files only - do not modify or analyze code files.

Focus on the following instructions:
- Create and update README.md files with clear project descriptions
- Structure README sections logically: overview, installation, usage, contributing
- Write scannable content with proper headings and formatting
- Add appropriate badges, links, and navigation elements
- Use relative links (e.g., `docs/CONTRIBUTING.md`) instead of absolute URLs for files within the repository
- Make links descriptive and add alt text to images
```

## 設定を行う場所 custom agents

agent profilesは、さまざまなレベルで定義できます。

* **リポジトリ レベル**: プロジェクト固有のエージェントの `.github/agents/CUSTOM-AGENT-NAME.md` をリポジトリに作成します。
* **組織レベル**: 組織の`/agents/CUSTOM-AGENT-NAME.md`または`.github`リポジトリに`.github-private`を作成して、組織内のより広範な可用性を実現します。
* **エンタープライズ レベル**: エンタープライズ所有者がエンタープライズ設定で指定した組織の`/agents/CUSTOM-AGENT-NAME.md` リポジトリに`.github-private`を作成し、エンタープライズ内のすべてのリポジトリで可用性を確保します。

詳細については、「[組織でカスタム エージェントを使用する準備](/ja/copilot/how-tos/administer-copilot/manage-for-organization/prepare-for-custom-agents)」および「[企業でカスタム エージェントを使用する準備](/ja/copilot/how-tos/administer-copilot/manage-for-enterprise/manage-agents/prepare-for-custom-agents)」を参照してください。

## どこで使用できるか custom agents

> \[!NOTE]
> Custom agents は、JetBrains IDE、Eclipse、Xcode 用 パブリック プレビュー にあり、変更される可能性があります。

custom agentsを作成すると、それらが利用可能になります。

* **Copilot cloud agentのGitHub.com**: \[エージェント] タブとパネル、課題の割り当て、およびプルリクエスト
* **IDEのCopilot cloud agent**：Visual Studio Code、JetBrains IDE、Eclipse、Xcode
* **GitHub Copilot CLI**

agent profilesは、Visual Studio Code、JetBrains IDE、Eclipse、Xcode で直接使用できます。 一部のプロパティは、動作が異なる場合や、環境間で無視される場合があります。

custom agentsでのVisual Studio Codeの使用の詳細については、Custom agents[のVS Codeを](https://code.visualstudio.com/docs/copilot/customization/custom-agents)参照してください。

## 次のステップ

独自の custom agentsを作成するには、次を参照してください。

* [Copilot cloud agent用のカスタム エージェントの作成](/ja/copilot/how-tos/copilot-on-github/customize-copilot/customize-cloud-agent/create-custom-agents)
* [GitHub Copilot CLI のカスタムエージェントの作成と使用](/ja/copilot/how-tos/copilot-cli/customize-copilot/create-custom-agents-for-cli)
* [Copilot カスタマイズのチートシート](/ja/copilot/reference/customization-cheat-sheet)