|
| 1 | +# AGENTS.md — Context for AI Assistants |
| 2 | + |
| 3 | +**Aperture** is open-source AI visibility infrastructure: it tracks how brands appear (or don’t) across ChatGPT, Perplexity, and other LLM-powered search engines. Self-hosted, bring your own API keys. |
| 4 | + |
| 5 | +## Stack |
| 6 | + |
| 7 | +| Layer | Tech | |
| 8 | +|--------|------| |
| 9 | +| Backend | Python 3, FastAPI, SQLAlchemy, Pydantic | |
| 10 | +| Frontend | TypeScript, React, Vite, Tailwind CSS | |
| 11 | +| Run | Docker Compose (optional); can run backend/frontend locally | |
| 12 | + |
| 13 | +## Where to Look |
| 14 | + |
| 15 | +- **API & app entry:** `backend/app/main.py` |
| 16 | +- **DB models & schemas:** `backend/app/models.py`, `backend/app/schemas.py` |
| 17 | +- **API routes:** `backend/app/routers/` (brands, queries, audits, results, settings) |
| 18 | +- **Business logic:** `backend/app/services/` — `audit_service.py`, `analysis.py`, `services/llm/*.py` for each provider |
| 19 | +- **Tests:** `backend/tests/` (pytest) |
| 20 | +- **Frontend:** `frontend/src/` — `App.tsx`, `pages/`, `components/`, `api/`, `types/` |
| 21 | + |
| 22 | +## Run & Test |
| 23 | + |
| 24 | +- **Full stack:** `docker compose up -d` → UI http://localhost:3000, API http://localhost:8000 |
| 25 | +- **Backend dev:** `cd backend && pip install -r requirements.txt && uvicorn app.main:app --reload` |
| 26 | +- **Frontend dev:** `cd frontend && npm install && npm run dev` |
| 27 | +- **Backend tests:** `cd backend && pytest tests/ -v` |
| 28 | +- **Frontend build:** `cd frontend && npm run build` |
| 29 | + |
| 30 | +## Conventions |
| 31 | + |
| 32 | +See [CONTRIBUTING.md](CONTRIBUTING.md) for code style (PEP 8, type hints, docstrings; TS strict, functional components, Tailwind). See [DOCS.md](DOCS.md) for architecture and configuration. |
0 commit comments