Seraph
Code quality gate for AI-generated code. Mutation testing, static analysis, flaky test detection, and risk scoring in one pipeline.
Seraph takes a git diff and stress-tests it across 5 dimensions before it ships.
Install
pip install seraph-ai
With optional tools:
pip install "seraph-ai[mutation]" # mutmut for mutation testing
pip install "seraph-ai[sentinel]" # git-sentinel for risk signals
pip install "seraph-ai[all]" # everything
Quick Start
# Assess current changes (skipping heavy steps for speed)
seraph assess --skip-baseline --skip-mutations
# Full assessment with mutation testing
seraph assess
# View past assessments
seraph history
# JSON output for CI integration
seraph assess --json
# Debug mode
seraph assess --verbose
What It Does
Seraph runs your code changes through 5 tests and produces an overall grade (A-F):
| Dimension | Weight | What It Checks |
|---|---|---|
| Mutation Score | 30% | Deliberately breaks your code — do your tests catch it? |
| Static Cleanliness | 20% | Ruff + mypy findings weighted by severity |
| Test Baseline | 15% | Runs tests 3x to detect flaky tests |
| Sentinel Risk | 20% | Hot files, pitfall patterns, and risk signals from git history |
| Co-change Coverage | 15% | Did you forget files that historically change together? |
Grades: A >= 90, B >= 75, C >= 60, D >= 40, F < 40
MCP Server
Seraph works as an MCP server for AI assistants (Claude, etc.):
seraph-mcp
Tools: seraph_assess, seraph_mutate, seraph_history, seraph_feedback
Claude Desktop Config
{
"mcpServers": {
"seraph": {
"command": "seraph-mcp",
"env": {
"SERAPH_REPO_PATH": "/path/to/your/repo"
}
}
}
}
Configuration
Create .seraph/config.toml in your repo to customize:
[timeouts]
mutation_per_file = 300
static_analysis = 60
[scoring]
mutation_weight = 0.40
static_weight = 0.15
[pipeline]
baseline_runs = 5
[retention]
retention_days = 30
[logging]
level = "DEBUG"
Environment variables override TOML (e.g. SERAPH_TIMEOUT_MUTATION_PER_FILE=300).
Commands
seraph assess [repo_path] # Run full assessment
seraph history [repo_path] # View past assessments
seraph feedback <id> <outcome> # Submit feedback (accepted/rejected/modified)
seraph prune [repo_path] # Delete old data (--days N --yes)
Works With
- Sentinel — Git history intelligence (hot files, co-change patterns, pitfall detection)
- mutmut — Mutation testing
- ruff — Fast Python linter
- mypy — Type checker
Part of the EvoIntel MCP Suite
Seraph solves AI Blindness #4: Code Quality — mutation survival, flaky tests, and risk signals that "all tests pass" will never reveal.
Part of the EvoIntel MCP Suite by Evolving Intelligence AI: five tools for five blindnesses no model improvement will ever fix.
| Tool | Blindness | Install |
|---|---|---|
| Sentinel | Project History | pip install git-sentinel |
| Niobe | Runtime Behavior | pip install niobe |
| Merovingian | Cross-Service Dependencies | pip install merovingian |
| Seraph | Code Quality | pip install seraph-ai |
| Anno | Web Content | npm install -g @evointel/anno |
License
MIT
Metadata
Release files for seraph-ai 0.2.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| seraph_ai-0.2.1.tar.gz | 73.5 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| seraph_ai-0.2.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 135.1 kB
Release files / seraph_ai-0.2.1.tar.gz
| Download URL | seraph_ai-0.2.1.tar.gz |
|---|---|
| Size | 73.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c5f7c2e4ab73b100ad33632901881ef0d08b7692db73719165bb58af4a8b74ec
|
|
BLAKE2b-256 checksum How to use checksums |
5814acf2776d4fe2e78779c11e3f147b30f33a003b893b7ec3460de7eaa03c31
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.3
|
Release files / seraph_ai-0.2.1-py3-none-any.whl
| Download URL | seraph_ai-0.2.1-py3-none-any.whl |
|---|---|
| Size | 61.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d3d7f0aaae45aad041ffe1afb999a2c3e47b0e20121e1f4bd7a7984e8d8066b6
|
|
BLAKE2b-256 checksum How to use checksums |
b655d92f89363f4fa4c91c055089911ed64a0155b7eff5e2cbd99c142d96776c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.3
|
Security for seraph-ai 0.2.1
Provenance
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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.