How heysagnik/aethos works
Aethos is a GitHub pull-request review service: users install its GitHub App, mention @aethos-agent, and receive a code-computed merge-readiness verdict with inline findings. The main path triages a PR, assembles an inspectable context pack using the code index, requests structured model findings, computes the verdict, and posts a GitHub review. The dashboard exposes repositories, review history, settings, and pack details. Edges reflect excerpted calls or README workflow statements; indexing and frontend-to-API wiring are documented or apparent from API paths, but their implementation details were not sampled.
Main entry points: pipeline.py Review orchestration · api.py Dashboard API · handlers.py GitHub event handlers · services.py Repository lifecycle
Components 27
Identity & Repositories
- OAuth & membership
backend/apps/accounts/services.py - Repository lifecycle
backend/apps/repos/services.py - Repository records
backend/apps/repos/models.py
Code Index
- Index construction
backend/apps/indexing/indexer.py - Code parsing & graph
backend/apps/indexing/code/parse.py - Index lookup & jobs
backend/apps/indexing/services.py - Symbols & embeddings
backend/apps/indexing/models.py
Review Pipeline
- GitHub event handlers
backend/apps/github/handlers.py - PR triage
backend/core/triage.py - Context pack
backend/core/pack.py - Context selection
backend/apps/reviews/context.py - Review orchestration
backend/apps/reviews/pipeline.py - Review step queue
backend/apps/reviews/queue.py - Structured review call
backend/apps/reviews/llm.py - Verdict & reasons
backend/core/verdict.py - Reviews & findings
backend/apps/reviews/models.py
External Services
- GitHub
- QStash
- NVIDIA NIM
- GitHub gateway
backend/apps/github/client.py
Dashboard
- Dashboard API
backend/apps/dashboard/api.py - Dashboard selectors
backend/apps/dashboard/selectors.py - Dashboard pages
frontend/src/pages/ReviewDetailPage.tsx - Frontend API client
frontend/src/lib/api.ts - API routing
backend/aethos/urls.py - Django API entry
api/index.py
Other components
- GitHub user
Connections 28
- GitHub user → OAuth & membership: signs in
backend/apps/accounts/services.py - OAuth & membership → Repository lifecycle: links installations
backend/apps/accounts/services.py - Repository lifecycle → GitHub gateway: syncs repositories
backend/apps/repos/services.py - GitHub event handlers → Repository lifecycle: updates lifecycle
backend/apps/github/handlers.py - GitHub event handlers → Review step queue: enqueues review
backend/apps/github/handlers.py - GitHub event handlers → GitHub: receives events
README.md - Review step queue → Review orchestration: dispatches steps
backend/apps/reviews/queue.py - Review orchestration → GitHub gateway: fetches PR data
backend/apps/reviews/pipeline.py - Review orchestration → PR triage: triages diff
backend/apps/reviews/pipeline.py - Review orchestration → Context selection: builds context
backend/apps/reviews/pipeline.py - Context selection → Index lookup & jobs: looks up index
- Index construction → Code parsing & graph: parses source
- Index construction → Symbols & embeddings: stores chunks
- Review orchestration → Context pack: packs context
backend/apps/reviews/pipeline.py - Context pack → Review orchestration: returns pack
backend/apps/reviews/pipeline.py - Review orchestration → Structured review call: requests findings
backend/apps/reviews/pipeline.py - Structured review call → NVIDIA NIM: calls model
- Review orchestration → Verdict & reasons: computes verdict
backend/apps/reviews/pipeline.py - Review orchestration → Reviews & findings: saves review
backend/apps/reviews/pipeline.py - Review orchestration → GitHub gateway: posts review
README.md - GitHub user → Dashboard pages: inspects reviews
README.md - Dashboard pages → Frontend API client: requests review
frontend/src/pages/ReviewDetailPage.tsx - Frontend API client → API routing: calls endpoints
frontend/src/lib/api.ts - Django API entry → API routing: serves routes
api/index.py - API routing → Dashboard API: routes dashboard
backend/aethos/urls.py - Dashboard API → Dashboard selectors: reads dashboard data
- Dashboard API → Reviews & findings: serves reviews
- Dashboard API → Repository records: serves repositories