Universal configurations that teach AI coding assistants to follow engineering best practices for security, quality, and documentation.
Without guardrails, AI coding assistants can create security vulnerabilities, inconsistent code, and technical debt.
AI might commit API keys, passwords, or sensitive credentials directly to your repository.
Different AI tools generate different code styles, making maintenance difficult.
AI-generated code often lacks proper type hints, docstrings, and comments.
AI Guardrails provides tool-specific configuration files that teach AI coding assistants to follow your engineering standards from day one.
# Security (HIGHEST PRIORITY)
priority: 100
scope: "**/*"
## NEVER Commit Secrets
โ API keys, tokens, passwords
โ Private keys (SSH, TLS)
โ Cloud credentials (AWS, GCP, Azure)
โ
Use .env files (gitignored)
โ
Provide .env.example (safe to commit)
## Example: Proper Secret Handling
import os
# โ
CORRECT
api_key = os.environ.get("OPENAI_API_KEY")
# โ WRONG
api_key = "sk-1234567890abcdef"
Comprehensive configurations, automated checks, and professional standards.
Tool-specific configurations optimized for Cursor, Claude, Copilot, Aider, Continue.dev, and Windsurf.
Automated quality checks that run before every commit, catching issues before they reach your repository.
Comprehensive CI workflows for testing, security scanning, and quality validation on every push.
Easy-to-use scripts to enable/disable hooks and CI jobs, manage configuration, and customize enforcement.
Multiple layers of security: AI instructions, pre-commit hooks, commit message validation, and CI scanning.
CONTEXT.md serves as the canonical standards document. All tool-specific configs derive from it.
WORKLOG.md prevents context loss and circular debugging by tracking features, decisions, and failed approaches across AI agent sessions.
Native support for all major AI coding assistants with optimized configurations.
Scoped .mdc files with priority system
Comprehensive conversational instructions
Optimized single-line configuration
Concise, example-heavy format
YAML configuration with auto-read files
Agent config with rules and prompts
Context exclusions and VS Code settings
Python, YAML, JSON, Markdown formatters
Comprehensive coding standards for all major languages and formats.
import os
# โ
Load from environment
api_key = os.environ.get("OPENAI_API_KEY")
if not api_key:
raise ValueError("OPENAI_API_KEY required")
#!/usr/bin/env bash shebangset -euo pipefail#!/usr/bin/env bash
set -euo pipefail
# Validate input
if [[ -z "${1:-}" ]]; then
echo "Error: Missing argument" >&2
exit 2
fi
# Quote variables
FILENAME="$1"
echo "Processing: ${FILENAME}"
from typing import List
def calculate_average(numbers: List[float]) -> float:
"""Calculate the average of numbers.
Args:
numbers: List of numbers to average
Returns:
Average value
Raises:
ValueError: If list is empty
"""
if not numbers:
raise ValueError("Empty list")
return sum(numbers) / len(numbers)
# Use .yaml extension
log_level: "info"
retry_count: 3
features:
- "auth"
- "logging"
Copy configurations, run one script, and you're protected.
# Clone as a reference directory in your project
cd your-project
git clone https://github.com/christopherpaquin/Guardrails-AI .ai-guardrails
# Copy context files to your project root
cp .ai-guardrails/AGENTS.md .
cp .ai-guardrails/WORKLOG.md .
cp .ai-guardrails/WORKLOG_USAGE.md .
cp .ai-guardrails/CONTEXT.md .
cp .ai-guardrails/CONTRIBUTING.md .
# Copy tool-specific configs
cp .ai-guardrails/.cursor/ . -r
cp .ai-guardrails/CLAUDE.md .
cp .ai-guardrails/.continue/ . -r
# Bootstrap copies:
# - Pre-commit config (.pre-commit-config.yaml)
# - CI/CD workflows (.github/workflows/)
# - Management scripts (scripts/)
./.ai-guardrails/template/bootstrap-guardrails.sh .
# Install and activate pre-commit hooks
./scripts/setup-precommit.sh
# CI/CD activates automatically on next push!
AI assistants will follow your standards, pre-commit hooks will catch issues locally, and CI/CD will scan on every push.
Join developers using AI Guardrails for secure, high-quality code.