Skip to content

Latest commit

 

History

2,073 Commits

Folders and files

Repository files navigation

Aegis Stack

Inspired by the Neverwinter Nights toolset, Project Zero Dawn, and Dr. Wily.

CI Docs PyPI Python 3.11+ License: MIT
Monthly Downloads Total Downloads Commits per Month Total Commits Last Commit
Astral Copier FastAPI Flet HTMX LangChain PostgreSQL Pydantic

Full-stack Python apps that know what they are.

Aegis Stack gives you a complete FastAPI app, wired and running: API, workers, scheduler, database, auth and AI, with plugins for anything else. Alongside it is the Twin, a model of that app taken from its code and its live state. Overseer shows it live and lets you operate it, Illiana explains it, and CI catches changes that break its rules, whether you wrote them or your agents did.

Aegis Stack: a stack made, started, and asked about itself in Overseer

Build

An app. Build from a blueprint or pick your pieces. Add or remove them later; your changes are merged, not overwritten.

Ship

A server. One command, or one button in Overseer, provisions a server in your own Hetzner or DigitalOcean account, adds HTTPS, and deploys. The server, the bill, and the data stay yours.

See

A control plane. A live map of your system, from the whole stack down to a single function, with errors, deploys, jobs, resources, and cost on the same map. See Overseer. The same data is in your app's CLI and, for your agents, over MCP.

Ask

An operator, if you want one. Talk to Illiana or type. She reads that map, answers with diagrams instead of guesses, and reviews every pull request against the system's rules.

What you could build

Each is uvx aegis-stack init my-app with:

Build With
A SaaS MVP with billing -s auth,payment -c database,htmx,worker
A finance app with an MCP server -b finance -c database,scheduler,worker,mcp
A voice agent for your meetings -s "meetings,ai[sqlite,voice]"
A document vault, read by AI -s auth,documents,ai -c database,storage,worker
A local AI app on Ollama -s "ai[ollama]"
5 more
Build With
Email, SMS and calls from your app -s comms -c worker
A Markdown blog with an editor -s blog
A tracker for posts on your topic -s research -c database,scheduler
Adoption analytics -s "insights[github,pypi]"
Background jobs at scale -c worker,scheduler

Running on it

Live What it is
Aegis Pulse Package analytics with honest decomposition (total, filtered, human)
Sector 7G Millions of tasks on a single $5 VPS, zero restarts
NWVault Revival A searchable archive of the original Neverwinter Vault (2002-2014), built in 24 hours

Quick Start

uvx aegis-stack init my-app

init opens a full-screen guided setup that walks through every component and service with explanations. Prefer the classic one-line prompts? Pass --quick.

More examples
# Skip the guided setup, use the classic one-line prompts
uvx aegis-stack init my-app --quick

# Add user authentication out of the box
uvx aegis-stack init user-app --services auth

# Add background processing + scheduling
uvx aegis-stack init task-processor --components scheduler,worker

# Everything wired up at init
uvx aegis-stack init full-app --services auth,payment,comms --components worker,scheduler

CLI in 9 languages: English, German, Spanish, French, Japanese, Korean, Russian, Simplified Chinese, Traditional Chinese. Run e.g. uvx aegis-stack --lang zh init my-app, or set AEGIS_LANG=zh.

Installation alternatives: See the Installation Guide for uv tool install, pip install, and development setup.

Customizing Your Stack

Aegis Stack spinning up a new project

Components are infrastructure pieces (database, workers, scheduler, cache). Services are business capabilities (auth, AI, payments, comms).

Don't worry about what you pick today. Add anything later with a single command and remove what you outgrow. Where a change touches files you've edited, your edits are merged in, and anything that can't merge cleanly is marked for you to review.

# Monday: Ship MVP
aegis init my-app

# Week 3: Add scheduled reports
aegis add scheduler --project-path ./my-app

# Month 2: Need async workers
aegis add worker --project-path ./my-app

# Month 6: Scheduler not needed
aegis remove scheduler --project-path ./my-app

# Stay current with template improvements
aegis update

See Evolving Your Stack for the complete guide.

Components

Component What you get
Backend FastAPI on uvicorn or granian, lifecycle hooks, in-memory request metrics, API load testing for every route Always
CLI Typer, first-class system interface Always
Frontend Flet, ships with the Overseer system dashboard Always
Browser Remote Chromium in its own container, driven over Playwright: JavaScript pages, sign-ins, a bot that joins a meeting Optional
Database Postgres (self-hosted or Neon serverless) or SQLite + SQLModel ORM Optional
Deploy Deployment target (Docker Compose), read by the Overseer Optional
Inference Local AI models via Ollama or llama.cpp, speech via Kokoro Optional
Ingress Traefik v3 reverse proxy with TLS Optional
MCP Serves the app's own tools to Claude Desktop, Claude Code or a local model over MCP: the tools you grant, never a write Optional
Observability Pydantic Logfire tracing + metrics + logging Optional
Redis Redis for caching, sessions, pub/sub Optional
Runner Work the app sends out to a coding agent: a queue of runs, and a runner on any machine with the repository that answers them Optional
Scheduler APScheduler with persistent jobs Optional
Secrets Encrypted credential store: keys set while the app runs, checked with the provider on paste, never shown again Optional
Storage S3 object storage for the files an app keeps, SeaweedFS in dev Optional
Web Frontend Server-rendered pages at /: Jinja2 + htmx + Alpine, Tailwind/DaisyUI styling Optional
Worker Pluggable Arq, Taskiq, or Dramatiq Optional

Components Docs →

Services

Service What you get
AI Conversational agents, RAG, model catalog, TTS and STT (PydanticAI / LangChain across 7 providers) Optional
Auth Persistent sessions with refresh-token rotation, GitHub/Google sign-in, RBAC, multi-tenant Organizations Optional
Blog Markdown publishing with drafts, tags, and an Overseer editor Optional
Comms Transactional email (Resend) + SMS / voice (Twilio) Optional
Documents Content-addressed document store, deduped, with page-addressed extraction Optional
Finance Personal finance aggregation (accounts, transactions, net worth, import) Optional Experimental
Insights Adoption metrics across GitHub, PyPI, Plausible, Reddit Optional
Meetings A bot that joins Google Meet as its own agent: transcript, notes, threads, people, what keeps coming up, joined from its calendar Optional Experimental
Payment Stripe checkout, subscriptions, refunds, disputes Optional
Research Outside posts and threads, collected by saved searches Optional

Services Docs →

Plugins

What the built-in services don't cover can come from a plugin: a Python package that adds routes, tables, a CLI and a dashboard card, and goes in and out the same way (aegis add <name>, aegis remove <name>). Browse them at aegis-stack.io/plugins or with aegis plugins search, and start your own with aegis plugins create.

Plugins Docs →

Deploy and back up

  • Provision a server in your own Hetzner or DigitalOcean account, price shown first, with aegis deploy-provision or from Overseer > Deployments. HTTPS comes with it.
  • Deploy to any VPS over SSH with aegis deploy: rsync and Docker, no PaaS lock-in.
  • Back up before every deploy, roll back on a failed health check, keep encrypted nightly copies off the server, and run a drill that proves they restore.
  • CI on every push: GitHub Actions for lint, types and tests, CodeQL scanning, and an optional continuous-deploy workflow.

Deployment Docs →

Integrations

Aegis Stack is the orchestration layer. Services and components wire into best-in-class tools you already trust, so you keep your vendor choices and your data.

Anthropic Astral ChromaDB Dramatiq FastAPI Flet
GitHub Google Kokoro LangChain Neon Ollama
Plausible Postgres Pydantic Reddit Redis Resend
SQLite Stripe Supabase Taskiq Traefik Twilio
Typer

For The Veterans

Ron Swanson

No reinventing the wheel. It's FastAPI, SQLModel, Pydantic and the rest of the tools you already know, wired together and ready to compose.

No custom abstractions or proprietary framework to learn. Once your stack is generated, it's your code: build it however you want. The Twin reads the code as it is; it doesn't ask you to write it a special way.

Aegis gets out of your way so you can get started.

Releases

Packages

Used by

Contributors

Languages