Skip to main content

AI-powered governance for development teams — policy-as-code with specialized personas

Project description

Gatekeep

License: MIT Python 3.11+ PyPI

AI-powered governance that explains the "why" behind best practices.

Gatekeep catches security issues, cost problems, and design anti-patterns before they reach production. Instead of cryptic linter errors, you get conversational explanations from specialized AI personas who help you learn as you build.

pipx install gatekeep

Alternative installation methods:

  • pip install gatekeep (standard Python package)
  • Other package managers (Homebrew, Nix, Snap) — let us know if you'd like us to add support!

Quick Start

# Install (recommended: use pipx for isolated environment)
pipx install gatekeep

# Set your OpenRouter API key
export OPENROUTER_API_KEY=sk-or-...

# Ask a persona
gatekeep ask sentinel "Is storing passwords in plaintext safe?"
gatekeep ask auditor "What will 3 Lambda functions at 256MB cost monthly?"
gatekeep ask architect "Should I use DynamoDB or RDS for this use case?"

# Run a full team review
gatekeep review "New payment API with Stripe integration"

# Check deployment readiness
gatekeep deploy "API v2.0 release" --env production

The Personas

Persona Role What They Do
🧭 Guide Triage Routes your question to the right specialist
👁️ Reviewer Peer Review Multi-LLM consensus code review
💰 Auditor Cost Control Budget enforcement and optimization
🔒 Sentinel Security Vulnerability detection and hardening
🎨 Architect Design Architecture patterns and best practices
🧪 Tester Test Gate Test environment deployment approval
🛡️ Guardian Prod Gate Production deployment approval
📊 Observer Metrics Routing, observability, optimization

Each persona has a distinct personality, enforces specific governance rules, and uses the optimal LLM model for their domain.

How It Works

Gatekeep uses a two-layer governance model:

Your Question
     ↓
┌─────────────────────────────────┐
│  PERSONAS (AI Specialists)      │
│  Sentinel, Auditor, Architect…  │
└─────────────────────────────────┘
     ↓                ↓
┌──────────┐  ┌──────────────────┐
│ Your     │  │ Regulatory       │
│ Policies │  │ Standards        │
│          │  │                  │
│ security │  │ OWASP Top 10    │
│ cost     │  │ CIS AWS 2.0     │
│ arch     │  │ GDPR / SOC 2    │
└──────────┘  └──────────────────┘

Layer 1 — Governance (your rules): Customizable YAML policies for security, cost control, and architecture that reflect your organization's standards.

Layer 2 — Standards (external regulations): Built-in support for OWASP Top 10, CIS AWS 2.0, GDPR, and SOC 2. Personas automatically enforce applicable standards.

CLI Commands

gatekeep ask <persona> <question>    # Consult a specific persona
gatekeep review <content>            # Parallel team review (Auditor + Sentinel + Architect)
gatekeep deploy <plan> --env <env>   # Deployment gate check
gatekeep route <question>            # Let Guide pick the right persona
gatekeep personas                    # List all personas
gatekeep standards status            # Show installed standards
gatekeep init                        # Initialize Gatekeep in your project

Project Setup

Initialize Gatekeep in any project to customize governance rules:

cd my-project
gatekeep init

This creates:

  • governance/ — Your security, cost, and architecture policies (editable YAML)
  • personas/ — Persona definitions (add your own or tweak existing ones)
  • standards/ — Regulatory standards (OWASP, CIS, GDPR, SOC 2)
  • gatekeep.yaml — Project configuration

Customizing Governance

Edit the YAML files in governance/ to match your organization:

# governance/security.yaml
secrets:
  storage:
    aws:
      primary: "AWS Secrets Manager"
  rotation: "90 days minimum"

encryption:
  in_transit: "TLS 1.2+ required"
  at_rest: "Enable for all storage"
# governance/cost-control.yaml
budgets:
  global:
    monthly_limit: 100
    currency: "USD"

Personas automatically pick up your governance rules and enforce them in their responses.

Requirements

Cost Transparency

Gatekeep uses your OpenRouter API key — no data leaves your machine, no subscriptions, no vendor lock-in.

Typical costs:

  • Individual developer: $1-5/month
  • Small team (5 people): $10-25/month
  • You control the spend (set OpenRouter limits)

Compare to:

  • GitHub Copilot: $10/user/month ($50/month for 5 people)
  • Other AI code review tools: $50-200/month

Gatekeep is cheaper because you only pay for what you use, and we're not trying to extract maximum revenue — we're trying to make governance accessible.

Contributing

See CONTRIBUTING.md for guidelines.

Security

See SECURITY.md for reporting vulnerabilities.

Philosophy

Gatekeep exists because quality code shouldn't be a privilege. Whether you're learning to code, building a side project, or running a startup, you deserve access to the same governance standards that enterprise teams use.

We believe:

  • Good practices should be taught, not enforced through fear
  • Security and compliance shouldn't require a six-figure budget
  • Open source tools should stay open (no bait-and-switch)
  • Developers learn best when they understand why, not just what

Commercial Use

Gatekeep is MIT licensed — free for everyone, including commercial use.

If you're building a business on Gatekeep or using it at work, we'd love to hear from you! Consider:

  • ⭐ Starring the repo (helps others discover it)
  • 💬 Sharing your story (how Gatekeep helped you)
  • 💰 Sponsoring development (keeps the project sustainable)
  • 🤝 Contributing improvements back (makes it better for everyone)

We're not here to gatekeep governance — we're here to make it accessible.

Support the Project

Gatekeep is built and maintained by developers who care about making quality code accessible. If it's helped you or your team:

Every contribution helps us spend more time on Gatekeep and less time on client work.

License

MIT — see LICENSE.


Ship safely, not slowly. 🚀

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gatekeep_ai-1.0.0.tar.gz (35.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gatekeep_ai-1.0.0-py3-none-any.whl (35.7 kB view details)

Uploaded Python 3

File details

Details for the file gatekeep_ai-1.0.0.tar.gz.

File metadata

  • Download URL: gatekeep_ai-1.0.0.tar.gz
  • Upload date:
  • Size: 35.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for gatekeep_ai-1.0.0.tar.gz
Algorithm Hash digest
SHA256 c8f7771f495ad41fca8c5f954efeab7b4f66a2f9d5dec95b6c3d372352ed2615
MD5 47b17ab67e1f7f7f6abec2af65e8e5e9
BLAKE2b-256 0ce25b792decd7f2e9c43f25c65bbd7c632d7f45f6abd14c3713b750cf4ee519

See more details on using hashes here.

File details

Details for the file gatekeep_ai-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: gatekeep_ai-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 35.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for gatekeep_ai-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 718f5f2eeab512cf2188ba27aa6318b940e4ea99b65eaffc9bbc8ee4c571aa62
MD5 f244c07cf4610a44b5659885703059aa
BLAKE2b-256 a73a1e263c56c0e826034236c50f8c39122d56efd0e4826975b6e03c085a0676

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page