Banh Mi Guard: dual-gate impact analysis & regression guard for AI coding agents (scope, invariants, build, Alibaba Open Code Review rules and LLM review)
pip install banh-mi-guard==0.17.5 Copy PIP instructions
Dual-Gate Impact Analysis & Regression Guard for AI-Assisted Development Enforcing the Sandwich Pattern with scope control, deterministic diff auditing, project invariants, and LLM gatekeeping.
guard wraps coding workflows in an automated safety harness that verifies changes before and after execution. It runs two gates around each task: a pre-task scope check and a post-task verification gate combining deterministic diff checks, static rules, project invariants, and an LLM review.
Live Documentation: https://okrath.github.io/banh-mi-guard/
Install the guard CLI globally on any platform:
# Recommended: Isolated global installation with pipx pipx install banh-mi-guard # Or with standard pip across all platforms: pip install banh-mi-guard For environment $PATH configuration, installation from GitHub main, and optional Alibaba OCR CLI setup, see CLI Reference: Installation & Environment Setup.
Integrate guard into your workflow in four simple steps:
# 1. PRE-TASK: Declare scope and capture baseline before editing code guard pre "Implement mobile responsive navigation drawer" --scope src/components/nav # 2. EDIT: Modify code using your AI agent (Claude Code, Cursor, Codex, etc.) or editor # 3. POST-TASK: Verify diffs, static security rules, build health, and LLM approval guard post # 4. COMMIT: Commit approved changes (approvals are HMAC-signed; unapproved commits or unsigned older sessions are blocked) git commit -m "feat: add responsive navigation drawer" To run deep repository inspection with Alibaba OCR, use guard post --full. For a large or security-sensitive change, the post report asks you (through your agent) whether you want a deeper review by a panel of three reviewers, a full OCR review, or both.
Every modification is verified before and after execution across three layers:
For architectural diagrams, taxonomy, and security specifications, see Architecture Specification.
Run the integration and unit test suite locally:
pytest Key dates PyPI data Data sourced directly from PyPI's database. Released: Oct 9, 2026 Newer release available (0.17.7) 1 maintainer PyPI data Data sourced directly from PyPI's database. trungngoprogramming Credits Author: Orca Team
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 9, 2026.




