From agentloop
Analyze code changes to find related areas that may also need modification. Supports uncommitted changes, specific commits, commit ranges, and branches. Use before committing or opening a PR to catch missed updates.
How this skill is triggered — by the user, by Claude, or both
Slash command
/agentloop:impact-checkThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
> **Repo profile — read `.claude/repo-profile.md` first.** This skill is repo-agnostic;
Repo profile — read
.claude/repo-profile.mdfirst. This skill is repo-agnostic; arc is the reference implementation. The monorepo layout, package naming, and paths below (packages/,providers/,runtimes/,blocklets/) are arc's — map them to the consuming repo's structure via the profile.
Analyze code changes and find related areas in the codebase that may also need modification.
Parse $ARGUMENTS to determine the diff mode:
| Input | Mode | Diff Command |
|---|---|---|
| (empty) | working-tree | git diff HEAD |
--branch | current branch vs main | git diff $(git merge-base <main> HEAD)..HEAD |
--branch <name> | named branch vs main | git diff $(git merge-base <main> <name>)..<name> |
--branch <name> --base <base> | branch vs custom base | git diff $(git merge-base <base> <name>)..<name> |
contains .. | commit range | git diff <from>..<to> |
| other | single commit | git diff <ref>^..<ref> |
When detecting the main branch, check which of main or master exists.
git diff command (with --stat for summary, and full diff for content)For each changed file, read the diff and identify:
For each significant change identified in Step 2:
agent-core, deriveAgentTools) to get the full candidate set — then filter comments in Step 4 by reading. Do not rely on a single-line import … from / require(…) regex: it misses multi-line imports (where the from "…" line has no import keyword) and re-exports, silently dropping real breaks.readSource("…/foo.ts"), readFileSync / join / resolve with the file path, dynamic import(…), and worker/route path literals. Cross-package breakage most often hides here (e.g. a runtimes/node/test/** that readSource()s a deleted providers/** file).src/foo.ts, check if test/foo.test.ts exists and whether it was also modified.claude/repo-profile.md) declare a provider conformance suite, and a provider changed, verify its conformance fixture was updated.claude/repo-profile.md) for which targets exist.switch, renderer map, handler registry — often in a different package) and confirm it gained the matching case/handler. This is the inverse hazard of reverse-reference: deleting breaks compilation loudly, but adding-without-wiring compiles clean. A default/fallback branch (renders "Unknown", silent no-op, drops the message) swallows the missing case, so check-types and build stay green and the gap only shows at runtime as a degraded/absent result. Also check the reverse — a new dispatch case for a variant the declaration side never added.Use the Agent tool with subagent_type=Explore to parallelize searches when there are many changed files (>5).
For each related file found in Step 3, Read the relevant sections and assess:
runAgent moved to a new provider) is not a break. Only a dangling reference — one that still resolves to the deleted/changed definition — breaks. Confirm by reading which module the reference actually resolves to before flagging 🔴; a name match alone is noise.## Impact Analysis — <scope description>
<N> files changed | +X -Y lines | <mode: working-tree / branch X vs Y / commit abc1234 / ...>
### Changes Summary
- brief bullet points of what changed and why it matters
### 🔴 MUST — Requires Modification
> Files that will break or produce incorrect behavior if not updated.
- **`path/to/file.ts:42`** — <specific reason>
Changed: `oldThing` → `newThing`, but this file still references `oldThing`
### 🟡 SHOULD — Recommended to Check
> Files that likely need updates but won't immediately break.
- **`path/to/file.test.ts`** — test does not cover the new <behavior>
- **`README.md`** — example code references old API signature
- **`path/to/new-export.ts:12`** — new export `fooBar` has zero call sites repo-wide and isn't a public re-export (speculative — confirm a consumer exists or lands in a follow-up)
- **`runtimes/cloudflare/…`** — node side changed `<behavior>` but the CF mirror was not updated (cross-runtime parity)
- **`providers/…/dispatch.ts`** — new variant `fooKind` added to the enum/registry in `types.ts` but the consumer switch has no matching `case`; falls through to the `default` (renders "Unknown"/no-op) — compiles clean, degrades at runtime (declaration ↔ dispatch parity)
### 🟢 OK — No Action Needed
> Confirmed these related files are unaffected.
- `path/to/other.ts` — imports the module but doesn't use the changed API
<package_manager> monorepo. Cross-package impacts within the repo's monorepo layout are the highest-value findings — see the repo's Custom Impact Checks section (.claude/repo-profile.md) for which package boundaries matterOn top of the universal steps above, run the repo's Custom Impact Checks — the domain-specific
reverse-reference checks documented in .claude/repo-profile.md. Arc's are the AFS/AUP-specific ones
(e.g. @aigne/afs importers, runProviderTests / test/conformance.test.ts, AUP widget dispatch
parity, the cross-runtime mirror, joinURL from ufo) — read that section rather than assuming
this list, since a different repo's profile will name entirely different checks.
npx claudepluginhub arcblock/agent-skills --plugin agentloopCreates, edits, and verifies skills using a test-driven development approach with pressure scenarios and subagents.