back to home

feldroy / air

The first web framework designed for AI to write. Built on Python, FastAPI, Pydantic, and HTMX. By the authors of Two Scoops of Django.

View on GitHub
849 stars
98 forks
51 issues

AI Architecture Analysis

This repository is indexed by RepoMind. By analyzing feldroy/air in our AI interface, you can instantly generate complete architecture diagrams, visualize control flows, and perform automated security audits across the entire codebase.

Our Agentic Context Augmented Generation (Agentic CAG) engine loads full source files into context on-demand, avoiding the fragmentation of traditional RAG systems. Ask questions about the architecture, dependencies, or specific features to see it in action.

Source files are only loaded when you start an analysis to optimize performance.

Embed this Badge

Showcase RepoMind's analysis directly in your repository's README.

[![Analyzed by RepoMind](https://img.shields.io/badge/Analyzed%20by-RepoMind-4F46E5?style=for-the-badge)](https://repomind.in/repo/feldroy/air)
Preview:Analyzed by RepoMind

Repository Overview (README excerpt)

Crawler view

The first web framework designed for AI to write. Built on FastAPI, Pydantic, and HTMX. --- Why use Air? • **Designed for AI to write** - No magic, no implicit behavior. Comprehensive types and docstrings mean AI agents and editors understand the API without external docs • **Powered by FastAPI** - Your FastAPI knowledge and routes carry over. Serve your API and web pages from one project • **Fast to code** - Tons of intuitive shortcuts and optimizations designed to expedite coding HTML with FastAPI • **Air Tags** - Easy to write and performant HTML content generation using Python classes to render HTML • **Jinja Friendly** - No need to write and for every HTML view • **Mix Jinja and Air Tags** - Jinja and Air Tags both are first class citizens. Use either or both in the same view! • **HTMX friendly** - We love HTMX and provide utilities to use it with Air • **HTML form validation powered by pydantic** - We love using pydantic to validate incoming data. Air Forms provide two ways to use pydantic with HTML forms (dependency injection or from within views) • **Easy to learn yet well documented** - Hopefully Air is so intuitive and well-typed you'll barely need to use the documentation. In case you do need to look something up we're taking our experience writing technical books and using it to make documentation worth boasting about --- **Website**: **Documentation**: **Source Code**: > [!CAUTION] > Air is in alpha. APIs may change between releases. Installation Install Air with : Install optional features (with ) You can install each optional feature (extras) like this: • **Standard** — FastAPI’s recommended extras Built for AI-Assisted Development Air's API is fully typed and comprehensively documented in-source. AI coding assistants can understand the framework by reading the installed package, without fetching external documentation. For AI context, use llms-full.txt (complete docs) or llms.txt (index with links to individual sections). Third-party context providers: Code Wiki by Google, DeepWiki by Devin. Two Ways to Build Air gives you two paths to HTML. Start with whichever fits your workflow. Start with HTML Have your AI generate an HTML mockup, or write one yourself. Drop it in a template, wire it up with minimal Python: : : Start with Python Write HTML as typed Python classes. Your editor autocompletes attributes, your type checker validates nesting: : Run either one Open to see the result. Both paths produce the same thing: a working web page. Use FastAPI Alongside Air Air is powered by FastAPI. You get Air's HTML tools for your pages and FastAPI's full capabilities for your API, all in one app. Mount a FastAPI sub-app Two separate apps, clean split. Air serves pages, FastAPI serves your API at . Wrap a single FastAPI instance One app. Air adds its features on top. You get OpenAPI docs, , and WebSockets alongside your pages. Sponsors Maintenance of this project is made possible by all the contributors and sponsors. If you would like to support this project and have your avatar or company logo appear below, please sponsor us. 💖💨 Consider this low-barrier form of contribution yourself. Your support is much appreciated. Contributing > [!IMPORTANT] > Have a feature idea? Open an issue first. Air's core is intentionally minimal: new features are built as separate packages in the Air ecosystem, not added to this base package. For guidance on setting up a development environment and how to make a contribution to Air, see Contributing to Air. Contributors Thanks to all the contributors to the Air 💨 web framework! PyPI Stats • pypistats • libraries.io • deps.dev • PePy Star History