Skip to main content

A deterministic validator for AI-generated code.

Project description

Aegis

A deterministic validator for AI-generated code. Apache 2.0.

What it does

aegis check ./path runs a 24-layer pipeline against a directory of code and reports whether the validation passes. Layers cover AST parsing, import resolution, cross-file consistency, package install, type check, test execution, design-brief fidelity, and feature coverage. 22 layers are deterministic (no model call); 1 is LLM-judge; 1 is hybrid (LLM verdict with a deterministic override).

Install

Install from source (a published pip install aegis-validator package is coming soon):

git clone https://github.com/andraste-labs/aegis.git
cd aegis
pip install -e .

The Anthropic SDK is an optional extra for the LLM-using layers:

pip install -e ".[anthropic]"

Quick start

aegis check ./my-code                          # deterministic + LLM
aegis check ./my-code --no-llm                 # deterministic only
aegis check ./my-code --brief brief.json       # include design / feature layers
aegis check ./my-code --json report.json       # machine-readable report
aegis check ./my-code --exit-on-fail           # exit 1 on FAIL

The LLM-using layers (design_fidelity, feature_coverage) skip unless an ANTHROPIC_API_KEY is set and a brief.json is supplied.

Layers

See docs/LAYER_INDEX.md for the full list of layers, their kinds (deterministic / hybrid / llm_judge), and the file under aegis/checks/ that implements each one.

Benchmark

aegis-bench/ contains a cohort of reproducible cases. Each case has a brief.json, an input/ directory, an expected.json describing the validator output, and a short technical README.

python -m aegis_cli check aegis-bench/cohort/<case>/input \
    --brief aegis-bench/cohort/<case>/brief.json \
    --no-llm

See aegis-bench/METHODOLOGY.md for case structure and reproducibility rules.

Contributing

See CONTRIBUTING.md.

License

Apache License 2.0.

Maintainer

Aegis is maintained by Andraste Labs. Contact: github@andrastelabs.com.

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

aegis_validator-0.1.0.tar.gz (157.5 kB view details)

Uploaded Source

Built Distribution

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

aegis_validator-0.1.0-py3-none-any.whl (110.7 kB view details)

Uploaded Python 3

File details

Details for the file aegis_validator-0.1.0.tar.gz.

File metadata

  • Download URL: aegis_validator-0.1.0.tar.gz
  • Upload date:
  • Size: 157.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.0

File hashes

Hashes for aegis_validator-0.1.0.tar.gz
Algorithm Hash digest
SHA256 084be19ea65fa8493b64917cf7153b4a8fdbc4d021e0989b062d87b3721b3e9c
MD5 1c8cd4cd61b0ac8f1e6c841bcbfa55a5
BLAKE2b-256 7196949d808792a96b5a85c9ea578b5858a7b4af80754b3cc56c4a9471d2e492

See more details on using hashes here.

File details

Details for the file aegis_validator-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for aegis_validator-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ee0e2e3047c48c24823219302fb2ef073358dbcffe0edaf4ef6c314560d15d5e
MD5 0e9437a2093e44a02cfb436e51544656
BLAKE2b-256 774d2333c7cc9e6d693a8586b932fa83d45d9ed22c85ede0803ff18828d4e515

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