Problem surfaces
An agent proposes a risky or unverified action inside your project.
Native rules + real-time hooks + static guards to catch what AI coding agents get wrong — before it reaches your codebase. Duplicate files, invented APIs, dangerous shell commands, unverified "I'm done" claims. Blocked, warned, or surfaced with a fix.
An agent proposes a risky or unverified action inside your project.
A native hook blocks, warns, or returns a concrete correction at the action boundary.
The local event stream records whether a later ordinary pass appears in the same session.
A later build pass is a time-ordered association to inspect, not a causal impact claim.
utils_v2.py next to utils.py — duplicate files pile up.user.fullName that never existed on the model.git push --force on main.--force-with-lease./vibeguard:learn turns each mistake into a new guard.A strictly later post-build-check pass in the same session can verify event order after a guardrail signal. It does not prove cause.
The local stream can show follow-up passes, unresolved sessions, repeated guardrail signals, suppressions, events that cannot be correlated, and hook overhead.
The event stream cannot establish causality, incidents prevented, token, time, or money savings, or compliance.
Hooks block bad actions at the source. Not prompt guidelines the model can forget.
Interceptions return OBSERVATION → FIX → WHY. The agent self-corrects in one turn.
Repeated errors become new guards via /vibeguard:learn. The system gets stricter over time.
| layer | what it does |
|---|---|
| Native rules | 127 constraints auto-loaded into CLAUDE.md / AGENTS.md. Bias the model away from bad decisions before it acts. |
| Runtime hooks | PreToolUse / PostToolUse intercept writes, bash, edits. Block, warn, or surface fix instructions in real time. |
| Static guards | Project scans for duplicate files, slop patterns, structural issues. Run via /vibeguard:check. |
| Slash commands | /vibeguard:preflight, :review, :check, :learn — workflows for each phase of the loop. |
| Learning loop | Repeated mistakes surface as candidate rules. Reviewed, then compiled into the native rule set. |
| Observability | Metrics, logs, and health checks for every interception. You see what was blocked and why. |
┌─ VibeGuard ─────────────────────────────────────────┐ ✗ blocked pre-bash-guard → command: git push --force origin main → rule: L7 · commit discipline · W-force-destructive → reason: destructive overwrite on protected ref ⚠ fix use git push --force-with-lease instead or resolve upstream locally before pushing └─────────────────────────────────────────────────────┘ agent: retrying with --force-with-lease
$ git clone https://github.com/majiayu000/vibeguard.git ~/vibeguard $ bash ~/vibeguard/setup.sh --yes
Works with Claude Code and Codex CLI · MIT licensed · no telemetry