본문으로 건너뛰기
Skillpedia
일반 코딩260k · #438

agent-merge-conflict-arbiter

하는 일

중립적인 에이전트가 양쪽의 변경과 각자 밝힌 목표를 검토해 병합된 결과를 만듭니다. 한 저장소에서 여러 AI 에이전트를 병렬로 돌리는 팀을 위한 스킬입니다.

사용하는 경우

  • ✓병렬 작업 중에 두 에이전트 브랜치가 충돌할 때.
  • ✓두 에이전트가 같은 코드를 바꿔서 git 병합이 멈췄을 때.
  • ✓어느 한 에이전트가 충돌 결과를 혼자 정하면 안 될 때.

스킬 링크

https://github.com/NousResearch/hermes-agent/blob/main/optional-skills/autonomous-ai-agents/agent-merge-conflict-arbiter/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/NousResearch/hermes-agent/blob/main/optional-skills/autonomous-ai-agents/agent-merge-conflict-arbiter/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“두 에이전트가 같은 파일을 고쳐서 병합이 멈췄습니다. 중립적으로 충돌을 해결하고 작업을 병합해 주세요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

에이전트는 두 diff와 각 쪽이 밝힌 의도를 검토한 뒤 병합된 버전을 만듭니다. 프로젝트에 빌드나 테스트가 있으면 그것도 실행합니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Agent Merge-Conflict Arbiter

Resolve a git merge conflict between two AGENTS' branches as an impartial third party. Agents resolving conflicts against a peer's work reliably either overwrite the peer or abandon their own change — they lack the peer's context and are biased toward their own side. This skill is the fix: a neutral reconciler that receives both diffs plus both sides' stated intents and produces a merged result, like a merge-queue arbiter.

When to Use

  • Two agent branches/worktrees collide during a parallel campaign (kanban engineering pipeline, parallel-PR wave, multi-worktree refactor).
  • git merge or git rebase halts on conflicts between two agents' work and neither original agent should self-adjudicate.
  • Do NOT use for conflicts within a single agent's own work, or for trivial lockfile/generated-file conflicts (regenerate those instead).

Prerequisites

  • A repo checkout containing the halted merge, or the two branch names plus permission to run the merge yourself.
  • Both sides' intent sources: kanban completion summaries (terminal running hermes kanban show <task-id>), PR bodies, or at minimum each branch's commit messages.
  • The project's build/test command, if one exists.

How to Run

Standalone — a human (or agent) invokes this skill inside the conflicted repo: load the skill, then follow the Procedure top to bottom.

Spawned neutral agent — the preferred shape in multi-agent campaigns:

  • delegate_task: spawn a subagent whose task message contains the repo path, both branch names, and both sides' intent summaries verbatim, plus an instruction to follow this skill.
  • Kanban-native: create a reconciliation card assigned to a third profile (not either worker's profile) with BOTH conflicted cards linked as parents — kanban_create(title="reconcile branch-a x branch-b", assignee="reconciler", parents=["t_a", "t_b"]). The parent links carry both sides' completion summaries into the reconciler's context automatically; the card body should name the repo path and the two branches.

Quick Reference

Hunk class Definition Resolution
disjoint-intent The two changes serve different goals and can coexist Combine both
same-question-different-answer Both sides answered one design question differently Pick ONE per stated intents; surface the decision
superseded One side's premise no longer holds after the other's change Keep the surviving side; note why

Impartiality contract: never favor the side that spawned you; touch ONLY conflicted regions (no drive-by edits); every design-question pick must appear explicitly in the hand-back summary.

Procedure

1. Gather both sides

  • Run via terminal: git status (confirm the conflicted state and list conflicted files), git merge-base <A> <B>, then for each side git log --oneline <base>..<side> and git diff <base>..<side> -- <file> for every conflicted file. In a halted merge, HEAD is one side and MERGE_HEAD is the other.
  • Collect each side's intent: hermes kanban show <task-id> for completion summaries/metadata, or the PR body, or the commit messages from the log above. Write down one sentence of intent per side before touching any file.
  • Done when: you can state both intents in your own words and have both diffs for every conflicted file.

2. Classify every conflicted hunk

  • Open each conflicted file with read_file and locate each <<<<<<</=======/>>>>>>> block.
  • Assign each hunk exactly one class from the Quick Reference table, judging by the stated intents — not by which change looks nicer.
  • If a single hunk contains multiple independent decisions (e.g., new logic that combines cleanly PLUS a styling/rounding choice both sides answered differently), decompose it into sub-decisions and classify each one.
  • A single file often mixes classes: one hunk may be a design collision while a neighboring hunk is disjoint. Classify per hunk, not per file.
  • Done when: every hunk has a written class and a one-line rationale.

3. Resolve under the impartiality contract

  • Edit each hunk with patch (or write_file for whole-file rewrites):
    • disjoint-intent → merge both changes so each intent is fully served.
    • same-question-different-answer → pick the answer that best serves the STATED intents (e.g., an intent of "strict validation" beats "quick default" if the task required correctness). Ne
자주 묻는 질문

언제 쓰면 안 되나요?

한 에이전트 자신의 작업 내 충돌이나, 잠금 파일처럼 사소한 생성 파일에는 쓰지 않습니다. 그런 파일은 다시 생성하는 것이 맞습니다.

시작하려면 무엇이 필요한가요?

멈춘 병합이 있는 저장소나 두 브랜치 이름이 필요하고, 각 쪽의 의도는 커밋 메시지나 풀 리퀘스트 메모에서 가져옵니다.

왜 중립적인 에이전트를 쓰나요?

상대 작업을 두고 충돌을 해결하는 에이전트는 상대의 작업을 덮어쓰거나 자기 변경을 빠뜨리기 쉽다고 스킬은 설명합니다.

상세 정보

작성자의 원본 설명

Neutral arbiter for merge conflicts between two agents.

repo: NousResearch/hermes-agent

인기도

GitHub 스타
260k
순위
#438
라이선스
MIT
업데이트
2026. 11. 2.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬