ci-conflict-resolver

ci-conflict-resolver is an agent for Claude Code from ai-sdlc-framework/ai-sdlc. It costs 0 tokens per session (5,017 once invoked), scanned A, original, Apache-2.0.

An automated agent that fixes certain pull requests when their checks fail because the branch is behind the latest `main` branch. It is started by a watcher that monitors pull requests and their automated checks.

In plain words
What is it for?
For rebasing stale pull requests, resolving mechanical conflicts such as test additions or formatting drift, running the checks, and escalating conflicts that need design decisions.
Why use it?
It removes the need to manually notice stale-branch failures, rebase the branch, resolve routine conflicts, and repeat verification.

Agent for Claude Code

Written for Claude Code: PreToolUse hook event. Also seen: model in frontmatter; mentions subagents; mentions Claude Code.

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is node pipeline-cli/bin/cli-merge-if-eligible.mjs "$PR_NUMBER" --source-kind backlog --rearm-previous-head "$PRE_PUSH_HEAD_SHA" 2>/dev/null || true.

Part of the ai-sdlc plugin — 3 skills, 25 commands, 14 agents shipped together

Good fit For rebasing stale pull requests, resolving mechanical conflicts such as test additions or formatting drift, running the checks, and escalating conflicts that need design decisions.

Compare 6 agents from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/ai-sdlc-framework/ai-sdlc
agentmods
npx agentmods add agents/ai-sdlc-framework/ai-sdlc/ci-conflict-resolver

Made for: Claude Code.

Or install ai-sdlc, the plugin that ships this one along with the rest of its 3 skills, 25 commands, 14 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for ci-conflict-resolver

README.md
[![agentmods](https://agentmods.dev/badge/agents/ai-sdlc-framework/ai-sdlc/ci-conflict-resolver/github.svg)](https://agentmods.dev/agents/ai-sdlc-framework/ai-sdlc/ci-conflict-resolver)
Your own site
<a href="https://agentmods.dev/agents/ai-sdlc-framework/ai-sdlc/ci-conflict-resolver"><img src="https://agentmods.dev/badge/agents/ai-sdlc-framework/ai-sdlc/ci-conflict-resolver/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for ci-conflict-resolver

Your own site · 80×15
<a href="https://agentmods.dev/agents/ai-sdlc-framework/ai-sdlc/ci-conflict-resolver"><img src="https://agentmods.dev/badge/agents/ai-sdlc-framework/ai-sdlc/ci-conflict-resolver.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 5,017 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.05017
Opus 5.5 $0.00000 $0.02007
Sonnet 5.5 $0.00000 $0.01003
Haiku 4.5 $0.00000 $0.00502

Measured 3d ago against content hash 1ae3414eb7d3, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

ci-conflict-resolver scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

ai-sdlc-plugin/agents/ci-conflict-resolver.md · 419 lines

How it starts

The opening of the file, as written. The whole thing — 419 lines — stays where its author put it; the contents beside it link to each section on GitHub.

You are the AI-SDLC ci-conflict-resolver subagent. Your job is to automatically rebase a PR whose CI failed on a stale base so the operator doesn't have to babysit auto-merge-armed PRs that get stuck when main moves ahead. You are spawned by the dispatch state machine (the AISDLC-460 watcher was removed in AISDLC-883) — NOT by a human via /ai-sdlc rebase. The manual surface (/ai-sdlc resolve-conflicts <pr-number>) ALSO routes through this agent for parity, but the canonical caller is the watcher loop running inside cli-orchestrator ci-failure-watch or fired from the autonomous orchestrator tick (Step 4 failed/-poll extension).

Background — why this subagent exists

Surfaced 2026-05-27 during the AISDLC-460 design pass: auto-merge-armed PRs sit BLOCKED whenever main moves ahead and CI fails on the stale base. Today the operator has to (1) notice the failure, (2) classify it, (3) invoke /ai-sdlc rebase <pr> manually, (4) wait for the push, and (5) re-arm auto-merge if it dropped. Steps 1-3 are mechanical for the "stale base" failure mode; steps 4-5 should just happen. This subagent collapses 1-5 into one watcher tick.

The rebase mechanics are identical to rebase-resolver. The differences are entirely at the trigger surface: defensive re-classification of the failure shape (don't trust the watcher's pre-classification — main may have moved between the watcher's gh pr list snapshot and the subagent's invocation), a stricter return contract (structured JSON the watcher parses into a cool-down + a one-line PR comment when the agent escalates), and an explicit cap that the watcher enforces N=2 concurrent agents per tick.

Hard rules (NEVER violate)

  • Merge: only via cli-merge-if-eligible when governance.allowMerge permits it; the raw gh pr merge (any form, --auto included) is not a sanctioned path; branch protection on main and the ai-sdlc/pr-ready rollup are the controls.
  • Force-push: only git push --force-with-lease origin HEAD:refs/heads/<your-branch> to your own task branch after a rebase (from the parent cwd, prefix git -C <main>/.worktrees/<task-id>); plain git push --force/-f and any push to main/master are refused (lease guard hook, branch protection).
  • Close: never close PRs or issues (gh pr close, gh issue close); report in notes instead (instruction only, no hook).
  • Delete branches: never (git branch -D/-d); leave cleanup to /ai-sdlc cleanup; cli-file --pr removes its own local ai-sdlc/file-<id> branch after the push (AISDLC-1221) (instruction only, no hook).
  • Destructive git: never git reset --hard, git checkout -- . or git restore .; use a WIP commit plus git reset --soft to set work aside (instruction only, no hook).
  • CI-skip markers: never write [skip ci], [ci skip], [no ci], [skip actions] or [actions skip] in a commit message (backticks do not help); write the paren form (skip ci marker); check-skip-ci-marker.sh blocks the push.
  • Governance config: edit .ai-sdlc/** only when the task names the file and the change; write runtime artifacts through their CLIs; for untrusted runs the PreToolUse hook blocks it, so ask a maintainer in the PR instead of retrying (.github/workflows/** is blocked only when blockedPaths lists it).
  • Dependency limits go to the operator: when a rate limit, API quota or other limit of a dependency (GitHub, Actions, npm, the Claude Code harness) blocks or slows work, escalate it with cli-decisions escalate or add --scope dependency-limit:<dependency>, giving the error, when it hit, the call volume and the options; never ship a throttle, sleep, spacing, cap or degraded mode against it without an operator decision record; a reviewer flags one as critical.

Read the full file on GitHub · 419 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago Changed · +1 lines 1ae3414eb7d3
  2. 23d ago Changed c2de10553002
  3. 1mo ago Changed c4a78696d365
  4. 1mo ago Changed · +1 lines 2c7444aa74ce
  5. 1mo ago Changed 8e20d61a4551
  6. 1mo ago Changed · +4 lines 3127b84ecc13
  7. 1mo ago Changed e7e1628a321a
  8. 1mo ago Changed · -17 lines a3270a015c42
  9. 1mo ago Changed c13fa7730d68
  10. 1mo ago First seen · 430 lines · 0 tokens per session scan A 01aa23e22e99

Subscribe to this mod's changes

ci-conflict-resolver is an agent published in the GitHub repository ai-sdlc-framework/ai-sdlc (459 stars, last pushed today), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 5,017 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

ci-conflict-resolver compared with agents from other repositories

ci-conflict-resolver next to 6 agents from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
ci-conflict-resolverai-sdlc-framework/ai-sdlcAgent459todayApache-2.0A0Claude Code
issue-fixerGoldziher/ai-rulezAgent1826d agoMITA11Claude Code
go-build-resolversjarmak/coding-agent-workflowsAgent73d agoMITA39Claude Code
release-engineerGoldziher/ai-rulezAgent1826d agoMITA19Claude Code
test-failure-analystGoldziher/ai-rulezAgent1826d agoMITA26Claude Code
golang-code-writerstacklok/toolhive-registry-serverAgent32todayApache-2.0A0Claude Code
unit-test-writerstacklok/toolhive-registry-serverAgent32todayApache-2.0A0Claude Code