Validator commit

From Codagent-AI/agent-validator · View interactive version

Validator commit is an AI agent skill from the GitHub repository Codagent-AI/agent-validator. Activates only for explicit validator-aware commit requests such as "commit with validator", "run validator then commit", "run checks before commit", or "skip validator and commit". Excludes plain commit requests.

How to use this skill

Skill file

/validator-commit $ARGUMENTS

Commit with explicit validator validation intent. Runs agent-validate detect first, validates based on intent (full run, checks only, or skip), handles failures, then commits.

Invocation Policy

Use this skill only when the user explicitly asks to involve Agent Validator in the commit flow, including full validation, checks-only validation, or intentionally skipping validator state as part of the commit.

Do not choose this skill for a plain "commit", "make a commit", or "commit these changes" request that does not mention validator, gauntlet, checks, validation, or skip.

Step 1 - Detect Changes

Run agent-validate detect using Bash:

agent-validate detect 2>&1; echo "DETECT_EXIT:$?"

Check the exit code from the DETECT_EXIT: line:

Step 2 - Determine Validation Intent

Parse $ARGUMENTS for a validation intent. Do not prompt the user if a clear intent is found.

| ARGUMENTS pattern | Action |

|-------------------|--------|

| Contains "check" or "checks" | Invoke /validator-check (Step 3b) |

| Contains "run", "full", or "all gates" | Invoke /validator-run (Step 3a) |

| Contains "skip" | Run agent-validate skip 2>&1 (Step 3c), then go to Step 4 |

| Empty or no clear intent | Present the three choices below to the user, wait for selection |

Evaluate the "check" or "checks" pattern before the generic "run" pattern, so

phrases like "run checks before commit" select /validator-check.

When prompting the user, present these choices:

  1. Run all gates — full validation (checks + reviews)
  2. Run checks only — checks without AI reviews
  3. Skip validator — advance baseline without running any gates

Then proceed to the step matching the user's selection.

Step 3a - Full Validation (validator-run)

Invoke /validator-run.

Step 3b - Checks-Only Validation (validator-check)

Invoke /validator-check.

Step 3c - Skip Validation

Run:

agent-validate skip 2>&1

Report the command output to the user, then go to Step 4.

Step 4 - Commit

Check whether you have a skill for committing git changes available (excluding validator-commit itself to avoid self-invocation).

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.