Skip to main content

Hefesto AI - Intelligent Code Quality Analysis and Technical Debt Detection

Project description

๐Ÿ”ฅ Hefesto - AI-Powered Code Quality Guardian

PyPI version Python 3.10+ License: MIT

Multi-language AI code quality validation powered by Gemini that works seamlessly with AI coding assistants.

Hefesto is the AI-powered code quality guardian that validates your Python, TypeScript, and JavaScript code before it hits production. It caught 3 critical bugs in its own v4.0.1 release through self-validation (dogfooding). Now it's protecting codebases worldwide.


๐ŸŽฏ What is Hefesto?

Hefesto analyzes your code using AI and catches issues that traditional linters miss:

  • Multi-Language Support: Python, TypeScript, JavaScript (Java & Go coming soon)
  • AI-Powered Analysis: Uses Google Gemini for semantic code understanding
  • ML Enhancement: Detects code smells, duplications, and anti-patterns
  • Security Scanning: Finds hardcoded secrets, SQL injections, command injections
  • Pre-Push Hooks: Validates code automatically before every commit
  • REST API: Integrate into any workflow
  • BigQuery Analytics: Track code quality over time

๐ŸŒŸ OMEGA Guardian

OMEGA Guardian adds production monitoring on top of Hefesto PRO:

  • IRIS Agent: Real-time production monitoring
  • Auto-Correlation: Links code issues to production incidents
  • Real-Time Alerts: Get notified when code causes production failures
  • Unlimited Everything: Repos, LOC, users - no limits

๐Ÿ“– The Dogfooding Story

We used Hefesto to validate Hefesto itself.

Before publishing v4.0.1 to PyPI, we ran OMEGA Guardian's self-validation on its own codebase. Here's what it caught:

๐Ÿ› Critical Bugs Found:

  1. Hardcoded Password in test fixtures

    • Severity: CRITICAL
    • Location: tests/fixtures/auth.py
    • Could leak credentials to GitHub
  2. Dangerous exec() Call without validation

    • Severity: HIGH
    • Location: utils/dynamic_loader.py
    • Remote code execution vulnerability
  3. 155 Other Issues including:

    • 23 code smells
    • 12 security warnings
    • 47 complexity violations
    • 73 best practice violations

โœ… Result:

We fixed everything before shipping. v4.0.1 went to production clean.

This is meta-validation at its finest: AI validating AI code.


๐Ÿ’ฐ Pricing - Launch Special

๐Ÿš€ Lock in Launch Pricing Forever

First 100 customers get launch pricing locked permanently. Sign up now and your rate never increases.

Feature FREE PRO OMEGA Guardian
Price $0 $8/mo $19/mo
Future Price $0 $25/mo $35/mo
You Save - $204/year $192/year
Basic Analysis โœ… โœ… โœ…
Pre-push Hooks โœ… โœ… โœ…
CLI Commands โœ… โœ… โœ…
AI/ML Enhancement โŒ โœ… โœ…
REST API โŒ โœ… โœ…
BigQuery Integration โŒ โœ… โœ…
IRIS Monitoring โŒ โŒ โœ…
Production Correlation โŒ โŒ โœ…
Real-time Alerts โŒ โŒ โœ…
Repos/LOC/Users Limited Unlimited Unlimited

๐ŸŽ 14-Day Free Trial

Both PRO and OMEGA Guardian include 14 days free trial. No credit card required upfront.

Get Started Now

๐Ÿ’Ž Hefesto PRO - $8/month

AI-powered code quality with ML enhancement

โœ… SemanticAnalyzer (AI/ML) โœ… REST API (8 endpoints) โœ… BigQuery integration โœ… Unlimited analysis โœ… Priority support โœ… 14-day free trial

Start Free Trial โ†’


๐ŸŒŸ OMEGA Guardian - $19/month

Everything in PRO + Production Monitoring

โœ… Everything in Hefesto PRO โœ… IRIS Agent monitoring โœ… Auto-correlation engine โœ… Real-time alerts โœ… Production incident tracking โœ… Unlimited everything โœ… 14-day free trial

Start Free Trial โ†’


๐Ÿš€ Quick Start

Installation

# FREE tier
pip install hefesto-ai

# PRO tier ($8/month)
pip install hefesto-ai[pro]

# OMEGA Guardian ($19/month)
pip install hefesto-ai[omega]

Basic Usage

# Analyze a single file
hefesto analyze main.py

# Analyze entire directory
hefesto analyze .

# With severity filter
hefesto analyze . --severity HIGH

# JSON output
hefesto analyze . --format json

Activate PRO/OMEGA Features

# Set license key (from Stripe after purchase)
export HEFESTO_LICENSE_KEY="your-license-key-here"

# Verify activation
hefesto status

# Should show:
# License: PRO โœ…  (or OMEGA โœ…)
# ML Enhancement: โœ… Enabled

Pre-Push Hook (Automatic Validation)

# Install git hook
hefesto install-hook

# Now every git push validates your code automatically
git add .
git commit -m "Add new feature"
git push  # โ† Hefesto validates before pushing

๐ŸŽฏ Features

FREE Tier

  • โœ… Static Analysis: Complexity, code smells, best practices
  • โœ… Security Scanning: Hardcoded secrets, injections (basic)
  • โœ… CLI Commands: Analyze, status, install hooks
  • โœ… Pre-Push Hooks: Automatic validation on git push
  • โœ… Multi-language: Python, JavaScript, TypeScript, Go, Rust

PRO Tier ($8/month)

Everything in FREE, plus:

  • โœ… SemanticAnalyzer: AI-powered ML code understanding
  • โœ… Deep Security Scanning: Advanced vulnerability detection
  • โœ… REST API: 8 endpoints for CI/CD integration
  • โœ… BigQuery Integration: Historical code quality analytics
  • โœ… Duplicate Detection: Find copy-pasted code
  • โœ… Anti-Pattern Detection: Identify design flaws
  • โœ… Priority Support: Email support with 24h response

OMEGA Guardian ($19/month)

Everything in PRO, plus:

  • โœ… IRIS Agent: Production monitoring and alerting
  • โœ… HefestoEnricher: Auto-correlate code issues โ†’ production failures
  • โœ… Real-Time Alerts: Pub/Sub notifications when code causes incidents
  • โœ… BigQuery Analytics: Track correlations over time
  • โœ… Production Dashboard: Visualize code quality โ†’ production health
  • โœ… Unlimited Everything: Repos, LOC, users, analysis
  • โœ… Priority Slack Support: Direct Slack channel access

๐Ÿ“Š REST API

Hefesto PRO includes a REST API for CI/CD integration:

# Start server
hefesto serve --port 8000

# Analyze code via API
curl -X POST http://localhost:8000/analyze \
  -H "Content-Type: application/json" \
  -d '{"code": "def test(): pass", "severity": "MEDIUM"}'

API Endpoints

  • POST /analyze - Analyze code
  • GET /health - Health check
  • POST /batch - Batch analysis
  • GET /metrics - Quality metrics
  • GET /history - Analysis history
  • POST /webhook - GitHub webhook integration
  • GET /stats - Statistics
  • POST /validate - Validate without storing

๐Ÿ”ง Configuration

License Key

Set via environment variable:

export HEFESTO_LICENSE_KEY="your-key-here"

Or create .hefesto.env:

HEFESTO_LICENSE_KEY=your-key-here
HEFESTO_SEVERITY=MEDIUM
HEFESTO_OUTPUT=json

Custom Rules

Create .hefesto.yaml:

severity: HIGH
exclude:
  - tests/
  - node_modules/
  - .venv/

rules:
  complexity:
    max_cyclomatic: 10
    max_cognitive: 15

  security:
    check_secrets: true
    check_injections: true

  ml:
    enabled: true
    threshold: 0.7

๐Ÿ—๏ธ OMEGA Guardian Setup

OMEGA Guardian requires Docker for the IRIS Agent:

1. Install OMEGA Guardian

pip install hefesto-ai[omega]
export HEFESTO_LICENSE_KEY="your-omega-key"

2. Configure IRIS Agent

Create iris_config.yaml:

project_id: your-gcp-project
dataset: omega_production
pubsub_topic: hefesto-alerts

alert_rules:
  - name: error_rate_spike
    query: |
      SELECT COUNT(*) as error_count
      FROM `production.logs`
      WHERE severity = 'ERROR'
      AND timestamp > TIMESTAMP_SUB(CURRENT_TIMESTAMP(), INTERVAL 5 MINUTE)
    threshold: 10

  - name: latency_increase
    query: |
      SELECT AVG(latency_ms) as avg_latency
      FROM `production.metrics`
      WHERE timestamp > TIMESTAMP_SUB(CURRENT_TIMESTAMP(), INTERVAL 5 MINUTE)
    threshold: 1000

3. Run IRIS Agent

# Via Docker (coming soon)
docker run -v ./iris_config.yaml:/config.yaml \
  narapa/iris-agent:latest

# Or via Python
python -m hefesto.omega.iris_agent --config iris_config.yaml

4. Verify Correlation

# Check that IRIS is correlating issues
hefesto omega status

# Should show:
# IRIS Agent: โœ… Running
# Correlations: 3 active
# Last Alert: 2 minutes ago

๐Ÿงช Testing & CI/CD

GitHub Actions

name: Hefesto Validation

on: [push, pull_request]

jobs:
  validate:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3

      - name: Install Hefesto
        run: pip install hefesto-ai[pro]

      - name: Run Analysis
        env:
          HEFESTO_LICENSE_KEY: ${{ secrets.HEFESTO_LICENSE_KEY }}
        run: hefesto analyze . --severity HIGH --format json

GitLab CI

hefesto:
  stage: test
  script:
    - pip install hefesto-ai[pro]
    - export HEFESTO_LICENSE_KEY=$HEFESTO_LICENSE_KEY
    - hefesto analyze . --severity HIGH

Pre-Commit Hook

# .pre-commit-config.yaml
repos:
  - repo: local
    hooks:
      - id: hefesto
        name: Hefesto Analysis
        entry: hefesto analyze
        language: system
        pass_filenames: false

๐Ÿ“ˆ Use Cases

1. AI Coding Assistant Validation

Use Hefesto to validate code generated by Claude, Cursor, or GitHub Copilot:

# After AI generates code
hefesto analyze generated_code.py --severity MEDIUM

# Before committing AI-generated code
git add .
git commit -m "AI-generated feature"
git push  # โ† Hefesto validates automatically

2. Production Monitoring (OMEGA)

Correlate code quality issues with production failures:

# IRIS detects production error spike
# HefestoEnricher correlates to recent code changes
# Alert sent: "High complexity function causing 500 errors"

3. Team Code Reviews

Run Hefesto before code review to catch obvious issues:

# Before opening PR
hefesto analyze feature_branch/ --format json > review.json

# Share review.json with team

4. Technical Debt Tracking

Track code quality over time with BigQuery:

-- Query code quality trends
SELECT
  DATE(analyzed_at) as date,
  AVG(complexity_score) as avg_complexity,
  COUNT(*) as issues_found
FROM hefesto_analytics.analyses
WHERE project = 'my-app'
GROUP BY date
ORDER BY date DESC

๐Ÿ›ก๏ธ Security

Hefesto helps find security vulnerabilities:

What Hefesto Catches

  • โœ… Hardcoded Secrets: API keys, passwords, tokens
  • โœ… SQL Injection: Unsafe query construction
  • โœ… Command Injection: Unsafe shell command execution
  • โœ… Path Traversal: Unsafe file access
  • โœ… Unsafe Deserialization: pickle, yaml.unsafe_load
  • โœ… XSS Vulnerabilities: Unsafe HTML rendering
  • โœ… SSRF Attempts: Unsafe URL requests

Example

# Hefesto catches this:
password = "admin123"  # โŒ Hardcoded secret
os.system(f"rm {user_input}")  # โŒ Command injection
query = f"SELECT * FROM users WHERE id={user_id}"  # โŒ SQL injection

# Hefesto suggests:
password = os.getenv("PASSWORD")  # โœ…
subprocess.run(["rm", user_input], check=True)  # โœ…
cursor.execute("SELECT * FROM users WHERE id=?", (user_id,))  # โœ…

๐Ÿ“š Documentation


๐Ÿค Contributing

We welcome contributions! See CONTRIBUTING.md for guidelines.

Development Setup

# Clone repo
git clone https://github.com/artvepa80/Agents-Hefesto.git
cd Agents-Hefesto

# Install in development mode
pip install -e ".[dev]"

# Run tests
pytest tests/

# Run Hefesto on itself (dogfooding)
hefesto analyze . --severity MEDIUM

๐Ÿ“œ Changelog

See CHANGELOG.md for version history.

Recent Releases

  • v4.2.1 (2025-10-31): Critical tier hierarchy bugfix
  • v4.2.0 (2025-10-31): OMEGA Guardian release
  • v4.1.0 (2025-10-31): Unified package architecture
  • v4.0.1 (2025-10-30): Production stability fixes

โ“ FAQ

Do I need a license for the FREE tier?

No, FREE tier works without any license key.

How do I upgrade from FREE to PRO?

  1. Purchase PRO: Get PRO
  2. Set license key: export HEFESTO_LICENSE_KEY="your-key"
  3. Features unlock automatically

Can I try PRO/OMEGA before buying?

Yes! Both include 14-day free trials. No credit card required upfront.

What happens after 100 launch customers?

Pricing increases to $25/mo (PRO) and $35/mo (OMEGA) for new customers. Early customers keep their launch pricing forever.

Is my code sent to external servers?

  • FREE/PRO: Analysis runs locally, no code sent externally
  • OMEGA: Only metadata sent to BigQuery for correlation
  • Your actual code never leaves your infrastructure

What if I have issues?


๐Ÿ“ง Contact


๐Ÿ“„ License

MIT License for core functionality. See LICENSE for details.

PRO and OMEGA Guardian features are licensed separately under commercial terms.


๐Ÿ™ Acknowledgments

Built with:


โญ Star us on GitHub if Hefesto helped you catch bugs!


Hefesto: AI-powered code quality that caught 3 critical bugs in its own release. Now protecting your code.

ยฉ 2025 Narapa LLC. All rights reserved.

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

hefesto_ai-4.3.0.tar.gz (150.1 kB view details)

Uploaded Source

Built Distribution

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

hefesto_ai-4.3.0-py3-none-any.whl (158.4 kB view details)

Uploaded Python 3

File details

Details for the file hefesto_ai-4.3.0.tar.gz.

File metadata

  • Download URL: hefesto_ai-4.3.0.tar.gz
  • Upload date:
  • Size: 150.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for hefesto_ai-4.3.0.tar.gz
Algorithm Hash digest
SHA256 2bd361b9443aa6ca85a41c4f497940d05189319b9e6584df25908e927e740692
MD5 2ee74ce5afe8c55af0e88c7ff404577b
BLAKE2b-256 8feab798485b29db1e36e298f41ce953f285381feb618cf399b3d0cceecc165c

See more details on using hashes here.

File details

Details for the file hefesto_ai-4.3.0-py3-none-any.whl.

File metadata

  • Download URL: hefesto_ai-4.3.0-py3-none-any.whl
  • Upload date:
  • Size: 158.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for hefesto_ai-4.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a8ea5f42851914ff767ca6e578e11524ca7072646addb822d5726cb2d729db86
MD5 983c4caa5f3d17789ae03b899eb191e1
BLAKE2b-256 3378251a400f94f23c96ed299e8027af0d60021c605ae1ef09ea1d78d1facc13

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