Skip to content

Add acceptance criteria verification skill and unify AI tool configs#9

Merged
alireza-sharifpour merged 1 commit intostagingfrom
tools/add-ac-check-skill-and-ai-configs
Mar 30, 2026
Merged

Add acceptance criteria verification skill and unify AI tool configs#9
alireza-sharifpour merged 1 commit intostagingfrom
tools/add-ac-check-skill-and-ai-configs

Conversation

@alireza-sharifpour
Copy link
Copy Markdown
Member

@alireza-sharifpour alireza-sharifpour commented Mar 24, 2026

Summary

  • AC-check skill (.claude/skills/ac-check/SKILL.md): A reusable skill that verifies whether current branch code changes satisfy all Acceptance Criteria from a linked GitHub issue. It resolves the issue (from user input, branch name, or by asking), diffs against staging, reads committed + staged + unstaged + untracked files, then reports per-AC status (Implemented / Partial / Not Addressed / Needs Manual Verification) with file:line evidence. Also flags genuinely relevant uncovered edge cases.
  • Unified repo guidelines: CLAUDE.md is now a symlink to AGENTS.md so all AI-assisted tools (Claude Code, Codex, Cursor) read one source of truth instead of maintaining separate files.
  • Cross-tool symlinks: .codex/skills/ac-check and .cursor/skills/ac-check symlink to the shared .claude/skills/ac-check directory, so the skill is available across all three tools without duplication.

Why

Developers currently have to manually cross-reference issue acceptance criteria against their code changes before opening PRs. This skill automates that verification step, catching missed or partially implemented requirements early. The symlink setup ensures all AI coding tools in the team share the same configs and skills.

What it does NOT do

  • No test coverage enforcement (separate tooling)
  • No code quality review (separate tooling)
  • No prescriptive git commands — the agent uses whatever tools are available

How to use

From any feature branch, run /ac-check (or /ac-check 123 with an issue number). The skill fetches the issue, parses AC items, reads all code changes, and produces a verification report table.

Test plan

  • Run /ac-check on a branch with a linked issue and verify the report is generated correctly
  • Run /ac-check 123 with an explicit issue number
  • Verify symlinks resolve correctly for Codex and Cursor
  • Verify CLAUDE.md symlink points to AGENTS.md

Summary by CodeRabbit

  • New Features
    • Added acceptance criteria verification agent (ac-check) to validate code changes against specified acceptance criteria
    • Agent provides structured verification with status tracking and evidence-based reporting
    • Added configuration support for development tool integration

- Add ac-check skill that verifies code changes against GitHub issue
  acceptance criteria, with status reporting per AC item
- Symlink CLAUDE.md → AGENTS.md so all AI tools read one source of truth
- Add Codex and Cursor symlinks to shared skill directory
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Mar 24, 2026

Walkthrough

New skill configuration files are added to enable an "ac-check" acceptance criteria verification agent. The primary skill definition is established in .claude/skills/ac-check/SKILL.md with symbolic references created in .codex/ and .cursor/ IDE configuration directories. An AGENTS.md documentation file is added at the repository root.

Changes

Cohort / File(s) Summary
AI Skill Definition
.claude/skills/ac-check/SKILL.md
Defines a multi-step acceptance criteria verification workflow including issue resolution, criteria extraction, code change collection, AC item verification with status taxonomy, and uncovered edge case identification. Specifies output report format with evidence mapping and readiness assessment.
IDE Configuration References
.codex/skills/ac-check, .cursor/skills/ac-check
Path reference files linking to the centralized skill definition, enabling the AC-check agent across multiple IDE environments.
Repository Documentation
AGENTS.md
Root-level agents documentation file (currently minimal content).

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~8 minutes

Possibly related PRs

Poem

🐰 A rabbit hops through branches with glee,
Checking acceptance criteria with care and delight—
Each AC item verified, each edge case seen,
From .claude to .cursor, the agent's now bright! ✨
No edge cases shall hide from our fluffy friend's might! 🌟

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and specifically summarizes the main changes: adding an AC-check skill and unifying AI tool configurations through symlinks.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch tools/add-ac-check-skill-and-ai-configs

Warning

Review ran into problems

🔥 Problems

Git: Failed to clone repository. Please run the @coderabbitai full review command to re-trigger a full review. If the issue persists, set path_filters to include or exclude specific files.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (2)
.claude/skills/ac-check/SKILL.md (2)

98-98: Base branch assumption may need flexibility in edge cases.

Line 98 hardcodes staging as the base branch in the output template. While this aligns with the typical workflow described in the PR objectives, there are edge cases where this assumption might not hold:

  • Developer runs /ac-check while already on staging branch
  • Feature branch was forked from a different base (e.g., main, develop)
  • Hotfix branches that target production branches directly

Since the skill doesn't provide guidance for these scenarios, the AI agent might produce misleading output if the base isn't actually staging.

💡 Suggested enhancement

Consider adding a brief note in Step 3 or Step 1 that instructs the agent to:

  1. Detect the actual base branch (e.g., via git merge-base or branch tracking info)
  2. Default to staging if detection fails or the branch is unambiguous
  3. Use the detected base in the report rather than hardcoding staging

Alternatively, document the assumption explicitly: "This skill assumes feature branches are based on staging. If your branch has a different base, specify it when running the command."

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.claude/skills/ac-check/SKILL.md at line 98, Update the SKILL.md to avoid
hardcoding the base branch: modify the text around Step 1/Step 3 (where
`staging` is currently used) to either (A) instruct the agent to detect the
actual base branch (e.g., via git merge-base or branch tracking info) and use
that detected base in the report, defaulting to `staging` only when detection
fails or is ambiguous, or (B) explicitly document the assumption by adding a
short note that the skill assumes feature branches are based on `staging` and
instruct users to specify a different base when applicable; reference the Step
1/Step 3 wording that currently outputs `staging` and replace it with the chosen
detection/defaulting or explicit-assumption text.

56-62: Consider adding brief technical guidance for gathering all change types.

Step 3 correctly emphasizes that the verification must include "committed changes, staged changes, unstaged modifications, and brand-new untracked files" (line 58), which is important for thorough AC coverage. However, gathering these different change types involves distinct git operations that may not be obvious from a simple branch comparison:

  • Committed changes: git diff staging...HEAD or git log staging..HEAD
  • Staged changes: git diff --cached
  • Unstaged modifications: git diff
  • Untracked files: git status --porcelain (filtering untracked entries)

Since Claude will need to orchestrate these separately, a brief note or example command sequence in this step could reduce ambiguity and ensure consistent behavior across invocations.

📋 Optional addition to Step 3
 ## Step 3 — Understand the Code Changes
 
-Gather **all** changes on this branch compared to `staging` — this must include committed changes, staged changes, unstaged modifications, **and** brand-new untracked files. Make sure nothing is missed; new features often live in files that haven't been `git add`-ed yet.
+Gather **all** changes on this branch compared to `staging` — this must include committed changes, staged changes, unstaged modifications, **and** brand-new untracked files. Make sure nothing is missed; new features often live in files that haven't been `git add`-ed yet.
+
+To capture everything, you'll need to combine multiple git operations:
+- Committed changes: `git diff staging...HEAD` or `git log -p staging..HEAD`
+- Staged changes: `git diff --cached`
+- Unstaged modifications: `git diff`
+- Untracked files: `git status --porcelain` (look for `??` entries)
 
 Read the changes carefully. For each changed file, understand what was added, modified, or removed.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.claude/skills/ac-check/SKILL.md around lines 56 - 62, Update Step 3 in
SKILL.md to include concise, actionable git guidance showing how to gather each
change type referenced (committed changes, staged changes, unstaged
modifications, and untracked files): state which git operations to run for
comparing the branch to staging, for inspecting the index (staged), for unstaged
workspace diffs, and for listing untracked files (porcelain-friendly output).
Mention these four categories by name in the paragraph and add one short example
command for each category so callers know exactly which git commands to run when
following Step 3.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In @.claude/skills/ac-check/SKILL.md:
- Line 98: Update the SKILL.md to avoid hardcoding the base branch: modify the
text around Step 1/Step 3 (where `staging` is currently used) to either (A)
instruct the agent to detect the actual base branch (e.g., via git merge-base or
branch tracking info) and use that detected base in the report, defaulting to
`staging` only when detection fails or is ambiguous, or (B) explicitly document
the assumption by adding a short note that the skill assumes feature branches
are based on `staging` and instruct users to specify a different base when
applicable; reference the Step 1/Step 3 wording that currently outputs `staging`
and replace it with the chosen detection/defaulting or explicit-assumption text.
- Around line 56-62: Update Step 3 in SKILL.md to include concise, actionable
git guidance showing how to gather each change type referenced (committed
changes, staged changes, unstaged modifications, and untracked files): state
which git operations to run for comparing the branch to staging, for inspecting
the index (staged), for unstaged workspace diffs, and for listing untracked
files (porcelain-friendly output). Mention these four categories by name in the
paragraph and add one short example command for each category so callers know
exactly which git commands to run when following Step 3.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 38d09832-1fe3-4702-a49c-24887f46a0e1

📥 Commits

Reviewing files that changed from the base of the PR and between 20a671b and be546f8.

📒 Files selected for processing (4)
  • .claude/skills/ac-check/SKILL.md
  • .codex/skills/ac-check
  • .cursor/skills/ac-check
  • CLAUDE.md

@alireza-sharifpour alireza-sharifpour merged commit 986a794 into staging Mar 30, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant