{"meta":{"title":"사용자 지정 에이전트 만들기 및 사용 GitHub Copilot CLI","intro":"특정 개발 작업에 대한 맞춤형 전문 지식을 갖춘 전문 에이전트를 만듭니다.","product":"GitHub Copilot","breadcrumbs":[{"href":"/ko/copilot","title":"GitHub Copilot"},{"href":"/ko/copilot/how-tos","title":"방법"},{"href":"/ko/copilot/how-tos/copilot-cli","title":"Copilot CLI"},{"href":"/ko/copilot/how-tos/copilot-cli/customize-copilot","title":"Copilot CLI 사용자 지정"},{"href":"/ko/copilot/how-tos/copilot-cli/customize-copilot/create-custom-agents-for-cli","title":"사용자 지정 에이전트 만들기"}],"documentType":"article"},"body":"# 사용자 지정 에이전트 만들기 및 사용 GitHub Copilot CLI\n\n특정 개발 작업에 대한 맞춤형 전문 지식을 갖춘 전문 에이전트를 만듭니다.\n\n## 소개\n\nCustom agents 를 사용하면 Copilot의 전문성을 특정 작업에 맞게 조정할 수 있습니다.\n\nCopilot에게 작업을 수행하라고 요청하면, custom agents이/가 에이전트의 전문 지식이 그 작업에 적합하다고 판단할 경우, Copilot 중 하나를 선택하여 사용할 수 있습니다.\n\na custom agent가 수행하는 작업은 작업을 완료하기 위해 생성되는 임시 에이전트인 서브에이전트를 사용하여 수행됩니다. Subagent에는 주 에이전트와 관련이 없는 정보로 채울 수 있는 자체 컨텍스트 창이 있습니다. 이러한 방식으로, 특히 더 큰 작업의 경우 주 에이전트의 컨텍스트 창을 어지럽히지 않고 작업의 일부를 오프로드할 custom agents수 있습니다. 그런 다음 주 에이전트는 더 높은 수준의 계획 및 조정에 집중할 수 있습니다.\n\n자세한 내용은 [사용자 지정 에이전트 정보](/ko/copilot/concepts/agents/copilot-cli/about-custom-agents)을(를) 참조하세요.\n\n## custom agent을 만들기\n\n각 custom agent 파일은 `.agent.md` 확장자를 가진 Markdown 파일로 정의됩니다. 다음 단계에 설명된 대로 이러한 파일을 직접 만들거나 CLI 내에서 추가할 수 있습니다.\n\n1. 대화형 모드에서 .를 입력합니다 `/agent`.\n\n2. 옵션 목록에서 **새 에이전트 만들기** 를 선택합니다.\n\n3. 리포지토리 또는 홈 디렉터리에 만드는 custom agent 옵션 중에서 선택합니다.\n\n   * **Project**(`.github/agents/`)\n\n   * **사용자** (`~/.copilot/agents/`)\n\n   > \\[!NOTE]\n   > 두 위치에 동일한 이름의 custom agents가 있는 경우, 리포지토리에 있는 것보다 홈 디렉터리에 있는 것이 사용됩니다.\n\n4. Copilot를 가져와 custom agent 파일을 만들지, 아니면 직접 만들지를 결정합니다.\n\n**옵션 1: 사용 Copilot**\n\n만들려는 에이전트의 세부 정보를 입력합니다. 에이전트의 전문 지식과 에이전트를 사용해야 하는 시기를 설명합니다.\nCopilot 은 입력한 설명을 가져와 에이전트 프로필을 작성하는 데 사용합니다.\n\n예를 들어 다음과 같이 입력할 수 있습니다.\n\n```text\nI am a security expert. I check code files thoroughly for potential security issues. Use me whenever a security review/check/audit is requested for one or more code files, or when the word \"seccheck\" is used in a prompt in reference to code files.\n\nI will identify potential problems, such as code that:\n\n- Exposes secrets or credentials\n- Allows cross-site scripting\n- Allows SQL injection\n- Contains vulnerable dependencies\n- Allows authentication to be bypassed\n\nIf any problems are identified, create a single GitHub issue in this repository on GitHub.com with details of problems, giving full details of each issue, including, but not limited to, risk level and recommended fix.\n```\n\nCopilot 초기 에이전트 프로필 생성이 완료되면 다음 옵션이 표시됩니다.\n\n* 계속\n* 콘텐츠 검토\n* 다시 시도\n* Quit\n\n콘텐츠를 검토하도록 선택하면 에이전트 파일이 기본 편집기에서 열립니다. 필요한 경우 CLI에서 에이전트 만들기 프로세스를 계속하기 전에 검토하고 변경할 수 있습니다.\n\n만들기 프로세스를 완료하려면 **\\[계속**]을 선택합니다.\n\n**옵션 2: 수동으로 에이전트 프로필 만들기**\n\n에이전트 파일을 직접 만들도록 선택하면 에이전트 프로필을 만드는 데 필요한 정보를 입력하는 일련의 프롬프트를 안내합니다.\n\n1. 에이전트의 이름을 입력합니다. 입력한 이름은 사용 가능한 에이전트를 나열할 때 표시되는 이름입니다. 이 버전은 에이전트 파일의 이름으로 사용됩니다. 예를 들어 \"보안 전문가\"를 입력하면 에이전트 파일의 이름이 지정 `security-expert.agent.md`됩니다.\n\n   > \\[!TIP]\n   > 프로그래밍 방식으로 사용할 custom agent 때 사용 편의성을 위해 소문자와 하이픈으로만 구성된 이름을 선택하는 것이 좋습니다.\n\n2. 이 에이전트의 전문 지식과 사용 시기를 나타내는 설명을 입력합니다.\n\n3. 특정 지침, 수행해야 하는 작업 또는 따라야 하는 제약 조건을 포함하여 에이전트의 동작 방식에 대한 지침을 입력합니다.\n\n4. 귀하의 custom agent이(가) 액세스해야 할 도구를 선택하세요.\n\n   기본적으로 custom agents 모든 도구에 액세스할 수 있습니다. 에이전트의 액세스를 `tools` 제한하는 경우 에이전트 파일에 사양이 추가됩니다.\n\n5. CLI를 다시 시작하여 새 custom agent를 로드합니다.\n\n## custom agent을(를) 사용하여\n\nCustom agents 은 다음과 같은 방법으로 사용할 수 있습니다.\n\n* **슬래시 커맨드**\n\n  대화형 모드에서 `/agent`를 입력하고 사용 가능한 custom agents 목록에서 선택합니다. 그런 다음 선택한 에이전트에 전달될 프롬프트를 입력합니다.\n\n  > \\[!NOTE]\n  > CLI의 기본 에이전트는 이 목록에 포함되지 않습니다. 기본 에이전트에 대한 자세한 내용은 [사용자 지정 에이전트 정보](/ko/copilot/concepts/agents/copilot-cli/about-custom-agents#built-in-agents)을 참조하세요.\n\n* **명시적 명령**\n\n  특정 에이전트를 사용하도록 지시 Copilot 합니다. 다음은 그 예입니다.\n\n  ```copilot\n  Use the security-auditor agent on all files in the /src/app directory\n  ```\n\n* **유추별**\n\n  에이전트 파일의 설명에 따라 특정 에이전트의 사용을 트리거하는 프롬프트를 사용합니다. 다음은 그 예입니다.\n\n  ```copilot\n  Check all TypeScript files in or under the src directory for potential security problems\n  ```\n\n  또는 (여기서 \"seccheck\"는 에이전트 프로필에서 트리거 단어로 정의됩니다.)\n\n  ```copilot\n  seccheck /src/app/validator.go\n  ```\n\nCopilot 은 사용하려는 에이전트를 자동으로 유추합니다.\n\n* **프로그래밍적으로**\n\ncustom agent 명령줄 옵션과 함께 사용할 항목을 지정합니다. 다음은 그 예입니다.\n\n```shell\ncopilot --agent security-auditor --prompt \"Check /src/app/validator.go\"\n```\n\n여기서 `security-auditor`는 custom agent 확장이 없는 `.agent.md` 프로필의 파일 이름입니다. 일반적으로 반드시 그렇지는 않지만 에이전트 프로필의 `name` 값과 동일합니다.\n\n## 추가 읽기\n\n* [GitHub Copilot CLI 사용자 지정 기능 비교](/ko/copilot/concepts/agents/copilot-cli/comparing-cli-features)\n* [사용자 지정 에이전트 구성](/ko/copilot/reference/custom-agents-configuration)\n* [GitHub Copilot CLI 명령 참조](/ko/copilot/reference/copilot-cli-reference/cli-command-reference#custom-agents-reference)\n* [사용자 지정 에이전트](/ko/copilot/tutorials/customization-library/custom-agents) - 큐레이팅된 예제 컬렉션"}