How kedar-1118/repoanalyzer works
Purpose and topology
OpenPulse is a dual-sided developer/recruiter platform for GitHub-based developer profiling, open-source recommendations, candidate search, and AI codebase evaluation. It is split into a React SPA, an Express API, and a Python FastAPI RAG service:
• frontend/src/main.jsx
• backend/src/server.js
• rag-service/main.py
Frontend application
The Vite/React client provides separate developer and recruiter workflows, with routing and top-level composition rooted in:
• frontend/src/App.jsx
• frontend/src/components/AppLayout.jsx
• frontend/src/services/apiClient.js
Developer-facing pages cover login, profile, recommendations, issues, saved items, history, and deep analysis. Recruiter pages cover search, dashboards, shortlists, candidate details, and reports. Client authentication and notifications are centralized in Zustand stores:
• frontend/src/store/authStore.js
• frontend/src/store/toastStore.js
Express API boundary
The Node/Express service is the primary application API and broker between the SPA, Supabase, GitHub, and the RAG service:
• backend/src/app.js
• backend/src/server.js
• backend/src/middleware/auth.js
Routes divide major domains into authentication, profiles, candidates/recruiters, repository analysis, recommendations, saved items, issues, search, and bulk analysis. JWT authentication and role-aware recruiter flows form the security boundary; controllers implement HTTP orchestration while services contain integration/business logic:
• backend/src/routes/authRoutes.js
• backend/src/controllers/analyzeController.js
• backend/src/services/recruiterService.js
GitHub ingestion and matching
GitHub OAuth and repository/activity retrieval feed profile construction, issue discovery, and candidate analysis. The backend translates external GitHub data into platform records and matching inputs:
• backend/src/config/github.js
• backend/src/services/githubService.js
• backend/src/services/matchService.js
Recommendation and issue functionality are separate application domains, allowing repository compatibility scoring and good-first-issue discovery to evolve independently:
• backend/src/controllers/recommendationController.js
• backend/src/controllers/issueController.js
Persistence and operational data
Supabase provides authentication and PostgreSQL-backed application persistence, including users, repositories, tech-stack data, candidate/bulk-analysis records, and recommended issues. Schema evolution is represented by SQL migrations:
• backend/src/config/database.js
• backend/supabase/migrations/20251202173826_create_users_and_repos_tables.sql
• backend/supabase/migrations/003_create_recommended_issues.sql
The backend also contains a migration runner, indicating database changes may be applied from the service environment:
• backend/run-migrations.js
• backend/src/migrations/001_bulk_candidates.sql
Deep-analysis RAG pipeline
The FastAPI service isolates expensive code analysis from request-routing concerns. Its analysis endpoint fetches GitHub code, chunks it, embeds chunks, retrieves relevant context, prompts an LLM, scores results, and caches/reuses completed analyses:
• rag-service/main.py
• rag-service/modules/github_fetcher.py
• rag-service/modules/llm_analyzer.py
ChromaDB is the vector-search layer, while SQLite/local caching and repository SHA-based deduplication reduce repeat embedding and LLM work:
• rag-service/modules/vector_store.py
• rag-service/modules/analysis_cache.py
• rag-service/modules/rag_retriever.py
Primary control flow
1. The SPA authenticates through the Express API using GitHub OAuth; the backend issues/uses JWT-backed identity.
2. Backend services fetch GitHub profile, contribution, repository, and issue data; Supabase stores durable platform state.
3. Developer recommendation and recruiter search endpoints query stored candidate/repository signals and apply matching logic.
4. A deep-analysis request reaches the backend analysis domain, which calls the FastAPI RAG service over HTTP.
5. The RAG service returns structured AI assessment/scoring; the backend persists or exposes it to recruiter reports and frontend analysis views.
Material external dependencies are GitHub OAuth/API, Supabase/PostgreSQL, Gemini or OpenAI for LLM inference, ChromaDB for embeddings, and local SQLite caching.
Main entry points: app.js Application routes · database.js Supabase PostgreSQL · App.jsx App routes and layout · githubService.js GitHub ingestion
Components 21
React SPA
- Vite entry
frontend/src/main.jsx - App routes and layout · Hosts developer and recruiter workflows.
frontend/src/App.jsx - Auth and toast state
frontend/src/store/authStore.js - API client
frontend/src/services/apiClient.js
Express API
- Express server
backend/src/server.js - Application routes · Routes authentication, profiles, candidates, analysis, recommendations, issues, and search.
backend/src/app.js - JWT and role guard · Protects authenticated and recruiter-only flows.
backend/src/middleware/auth.js - GitHub ingestion · Retrieves OAuth, profile, repository, activity, and issue data.
backend/src/services/githubService.js - Candidate matching · Applies repository and candidate matching logic.
backend/src/services/matchService.js - Deep analysis API · Delegates codebase analysis requests to the RAG service.
backend/src/controllers/analyzeController.js - Recommendations and issues · Separately serves compatibility recommendations and good-first-issue discovery.
backend/src/controllers/recommendationController.js - Schema migrations
backend/supabase/migrations/20251202173826_create_users_and_repos_tables.sql
RAG Analysis Service
- FastAPI analysis endpoint · Coordinates cached retrieval and AI assessment.
rag-service/main.py - Repository code fetcher
rag-service/modules/github_fetcher.py - Chunk embedding and retrieval · Indexes code chunks and retrieves relevant context.
rag-service/modules/rag_retriever.py - LLM assessment · Prompts an LLM and produces structured scoring.
rag-service/modules/llm_analyzer.py - SHA analysis cache · Deduplicates completed analyses and repeat inference.
rag-service/modules/analysis_cache.py
Other components
- Supabase PostgreSQL · Durable users, repositories, tech stack, candidates, analyses, and issues.
backend/src/config/database.js - GitHub OAuth and API
- ChromaDB
rag-service/modules/vector_store.py - Gemini or OpenAI
Connections 26
- Vite entry → App routes and layout: mounts
- App routes and layout → Auth and toast state: uses
- App routes and layout → API client: calls through
- API client → Express server: HTTPS API requests
- Express server → Application routes: hosts
- Application routes → JWT and role guard: protects routes with
- Application routes → GitHub ingestion: profile and issue flows
- Application routes → Candidate matching: search and recommendation flows
- Application routes → Recommendations and issues: dispatches
- Application routes → Deep analysis API: dispatches
- JWT and role guard → Supabase PostgreSQL: validates identity
- GitHub ingestion → GitHub OAuth and API: OAuth and data API
- GitHub ingestion → Supabase PostgreSQL: persists platform records
- Candidate matching → Supabase PostgreSQL: queries candidate signals
- Recommendations and issues → Supabase PostgreSQL: reads and stores results
- Deep analysis API → FastAPI analysis endpoint: HTTP deep-analysis request
- Deep analysis API → Supabase PostgreSQL: stores assessments
- Schema migrations → Supabase PostgreSQL: evolves schema
- FastAPI analysis endpoint → SHA analysis cache: checks SHA cache
- FastAPI analysis endpoint → Repository code fetcher: on cache miss
- Repository code fetcher → GitHub OAuth and API: fetches repository code
- Repository code fetcher → Chunk embedding and retrieval: supplies chunks
- Chunk embedding and retrieval → ChromaDB: indexes and searches
- Chunk embedding and retrieval → LLM assessment: retrieved context
- LLM assessment → Gemini or OpenAI: inference
- LLM assessment → SHA analysis cache: caches result