How yashwanth-r19/compass works
Compass analyzes a submitted Git repository by cloning it, mining commit history and source structure, then computing persisted facts and deterministic insights. Users explore the results through repository overview, guide, exploration, findings, and evolution views; the product also supports security checks, comparisons, and optional narrative summaries. The README documents the analysis pipeline and major capabilities. Source excerpts establish application and UI routing, but most API and engine implementations were not sampled, so their internal call relationships are not asserted.
Main entry points: main.py FastAPI application · engines Insight engines · analysis.py Analysis endpoints · cloner.py Clone and guardrails
Components 22
Repository ingestion
- Job runner
backend/app/jobs/runner.py - Clone and guardrails
backend/app/ingestion/cloner.py - History mining
backend/app/ingestion/miner.py - Language analysis
backend/app/languages/scanner.py - Fact persistence
backend/app/ingestion/persist.py - History security scan
backend/app/security/scanner.py
Deterministic analysis
- Insight engines
backend/app/engines - Analysis capabilities
backend/app/analysis - Narrative generation
backend/app/narrative/generate.py
API and persistence
- FastAPI application
backend/app/main.py - Repository endpoints
backend/app/api/repos.py - Analysis endpoints
backend/app/api/analysis.py - Narrative endpoints
backend/app/api/narrative.py - Comparison endpoints
backend/app/api/compare.py - PostgreSQL
backend/app/db/models.py
User experience
- Compass web app
frontend/src/App.tsx - Repository surfaces
frontend/src/pages/repo - API data hooks
frontend/src/api/hooks.ts - API client
frontend/src/api/client.ts
Other components
- Engineer
- Git repository
- OSV.dev
Connections 25
- Engineer → Compass web app: explores results
frontend/src/App.tsx - Compass web app → Repository surfaces: routes to
frontend/src/App.tsx - Engineer → Repository endpoints: submits repository
README.md - Git repository → Clone and guardrails: cloned from
README.md - Repository endpoints → Job runner: starts analysis
README.md - Job runner → Clone and guardrails: runs pipeline
README.md - Clone and guardrails → History mining: mines history
README.md - History mining → Language analysis: parses structure
README.md - Language analysis → Fact persistence: persists facts
README.md - Fact persistence → History security scan: scans history
README.md - History security scan → Insight engines: then computes
README.md - Insight engines → PostgreSQL: reads and writes
README.md - Insight engines → OSV.dev: checks advisories
README.md - Insight engines → Analysis capabilities: supports analysis
backend/app/analysis/compare.py - Analysis endpoints → Insight engines: serves computed results
- Analysis endpoints → Analysis capabilities: serves analysis
- Repository surfaces → API data hooks: requests results
frontend/src/pages/repo/FindingsSurfacePage.tsx - API data hooks → API client: uses client
- API client → FastAPI application: calls API
- Narrative endpoints → Narrative generation: requests summaries
- Comparison endpoints → Analysis capabilities: provides comparisons
- FastAPI application → Repository endpoints: registers routes
backend/app/main.py - FastAPI application → Analysis endpoints: registers routes
backend/app/main.py - FastAPI application → Narrative endpoints: registers routes
backend/app/main.py - FastAPI application → Comparison endpoints: registers routes
backend/app/main.py