Skip to main content

Control and audit plane CLI for AI coding agents.

Project description

Aegisure

Control & audit plane for AI coding agents — one constitution, every agent, safer commits.

Aegisure is a local-first CLI for teams and developers using coding agents such as Codex, Claude Code, Cursor, Copilot, Cline, and Roo. It gives every repo a shared Constitution, scans AI-generated diffs before they land, exports rule files that agents can read, and creates constrained repair prompts when a change is risky.

The static core is LLM-free. It runs locally, works without API keys, and does not send your code to a model.

What It Does

  • Scans staged, working-tree, or PR diffs for secret values, destructive shell commands, permissive CORS, auth/session/permission changes, payment/billing changes, risky dependency scripts, deployment config changes, deleted tests, and large risky changes.
  • Generates a canonical Aegisure.md Constitution for a repository.
  • Exports the Constitution into agent-readable files: AGENTS.md, CLAUDE.md, .cursorrules, .clinerules, and .github/copilot-instructions.md.
  • Preserves existing user-authored agent files by writing only inside an Aegisure-managed block.
  • Produces constrained repair prompts that tell an agent exactly what to fix and what not to touch.
  • Captures declared provenance and attribution when you commit through aegisure commit.
  • Supports a lightweight GitHub Actions path with aegisure scan --changed --json.

Install

pip install aegisure

Requires Python 3.10 or newer.

Quickstart

Initialize Aegisure in a repo:

aegisure init
aegisure export

Stage a risky change:

echo 'OPENAI_API_KEY = "sk-proj-realfakekey1234567890abcdef"' >> app.py
git add app.py

Scan the staged diff:

aegisure scan --staged

Example output:

Aegisure verdict: block (100/100)
1 files changed, 1 additions, 0 deletions, 1 risk findings.
- CRITICAL secret_in_diff at app.py:1: This added line looks like a secret, token, password, private key, or credential.

Create a constrained repair prompt:

aegisure repair --staged --agent codex

CLI Commands

aegisure init      Generate the canonical Aegisure.md Constitution.
aegisure export    Export Aegisure.md into standard agent memory files.
aegisure scan      Analyze a local or CI diff using the LLM-free static core.
aegisure repair    Generate a constrained repair prompt for risky diffs.
aegisure commit    Commit changes and capture declared agent provenance.
aegisure login     Store local workspace metadata for CLI use.
aegisure doctor    Run a read-only repository readiness check.
aegisure run       Start or end a git snapshot-and-scan session.
aegisure rewind    Prepare a safe git-based rollback for an Aegisure-tagged commit.

The public CLI is intentionally static-core and LLM-free.

GitHub Actions

Copy .github/workflows/aegisure.yml.example into your repository as .github/workflows/aegisure.yml:

name: Aegisure

on:
  pull_request:
    branches: ["**"]

jobs:
  scan:
    runs-on: ubuntu-latest
    permissions:
      contents: read
      pull-requests: read
    steps:
      - uses: actions/checkout@v4
        with:
          fetch-depth: 0
      - uses: actions/setup-python@v5
        with:
          python-version: "3.12"
      - run: python -m pip install aegisure
      - run: aegisure scan --changed --base origin/${{ github.base_ref }} --json

aegisure scan --json exits non-zero when the verdict is block, so CI can fail safely on critical findings.

Hosted Dashboard Beta

A hosted dashboard beta exists for teams that want GitHub App PR comments, audit history, BYOK audit chat, and workspace views.

Learn more: https://aegisure.dev

License

MIT

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

aegisure-0.2.3.tar.gz (44.3 kB view details)

Uploaded Source

Built Distribution

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

aegisure-0.2.3-py3-none-any.whl (47.4 kB view details)

Uploaded Python 3

File details

Details for the file aegisure-0.2.3.tar.gz.

File metadata

  • Download URL: aegisure-0.2.3.tar.gz
  • Upload date:
  • Size: 44.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.4

File hashes

Hashes for aegisure-0.2.3.tar.gz
Algorithm Hash digest
SHA256 9695e771606454a6df45693e9a46498c9034f6c4c1bb47ea4c3e83d1c5afde8d
MD5 42e1e3c772dca8499be1fe81490995b9
BLAKE2b-256 34067b42d127952e5a3860c66858861d7f6e02f73ac7ffc9c296327bad4f94dd

See more details on using hashes here.

File details

Details for the file aegisure-0.2.3-py3-none-any.whl.

File metadata

  • Download URL: aegisure-0.2.3-py3-none-any.whl
  • Upload date:
  • Size: 47.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.4

File hashes

Hashes for aegisure-0.2.3-py3-none-any.whl
Algorithm Hash digest
SHA256 5372850f8cc4f43440dcdb2000eb2875969320aeda460c7baf6407664536d079
MD5 e6a1a7b77cb03d4a9f19710fcfb3a680
BLAKE2b-256 619ae7d224e35851867ed2975620529ed64be9ffb912bacef429c9215f7ff571

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