How shakeer7/campusai works
CampusAI is a college-management assistant serving students, faculty, and administrators through a Next.js interface and FastAPI backend. Users access academic records and attendance tools, chat with a multilingual assistant, search academic documents, and submit or review attendance corrections. The backend combines role-based access, academic services, LLM tools, a PDF-to-vector retrieval flow, and persistent academic/workflow data. The README documents voice interaction, administrator monitoring, and the correction workflow; some implementation paths are unsampled, so those relationships are shown only where supported or marked unverified.
Main entry points: main.py FastAPI application · dependencies.py Identity and access control · bedrock_client.py LLM and tool orchestration · chat.py Chat API
Components 24
User experience
- College portal
frontend/src/app - Chat and voice UI
frontend/src/components
API and workflows
- FastAPI application
backend/app/main.py - Authentication API
backend/app/api/auth.py - Student API
backend/app/api/students.py - Faculty API
backend/app/api/faculty.py - Admin API
backend/app/api/admin.py - Chat API
backend/app/api/chat.py - Voice API
backend/app/api/voice.py - Correction workflow API
backend/app/api/workflows.py - Document API
backend/app/api/rag.py - Academic services and tools
backend/app/services/academic_service.py - Correction state machine
backend/app/agents/attendance_correction.py
AI and retrieval
- LLM and tool orchestration
backend/app/ai/bedrock_client.py - Multilingual processing
backend/app/ai/multilingual.py - PDF indexing pipeline
backend/app/rag - Semantic retrieval
backend/app/rag/retriever.py
Identity and data
- Identity and access control
backend/app/auth/dependencies.py - Academic and workflow records
backend/app/models - Relational and vector store
backend/app/core/database.py
External services
- Academic MCP tools
mcp-server/server.py - AWS Bedrock / Ollama
- Speech services
Other components
- Students, faculty, admins
Connections 35
- Students, faculty, admins → College portal: use
README.md - College portal → Chat and voice UI: offers chat
README.md - College portal → FastAPI application: calls API
- Chat and voice UI → Chat API: sends queries
- Chat and voice UI → Voice API: voice requests
- FastAPI application → Authentication API: routes to
backend/app/main.py - FastAPI application → Student API: routes to
backend/app/main.py - FastAPI application → Faculty API: routes to
backend/app/main.py - FastAPI application → Admin API: routes to
backend/app/main.py - FastAPI application → Chat API: routes to
backend/app/main.py - FastAPI application → Voice API: routes to
backend/app/main.py - FastAPI application → Correction workflow API: routes to
backend/app/main.py - FastAPI application → Document API: routes to
backend/app/main.py - Authentication API → Identity and access control: authenticates
backend/app/api/auth.py - Student API → Identity and access control: checks roles
- Faculty API → Identity and access control: checks roles
- Admin API → Identity and access control: checks roles
backend/app/api/admin.py - Chat API → Identity and access control: identifies user
backend/app/api/chat.py - Chat API → LLM and tool orchestration: requests response
backend/app/api/chat.py - LLM and tool orchestration → Academic services and tools: executes tools
backend/app/ai/bedrock_client.py - LLM and tool orchestration → AWS Bedrock / Ollama: invokes model
- LLM and tool orchestration → Multilingual processing: uses language detection
backend/app/ai/bedrock_client.py - Voice API → Speech services: speech processing
- Academic services and tools → Academic and workflow records: queries records
backend/app/services/academic_service.py - Academic services and tools → Semantic retrieval: searches documents
backend/app/tools/registry.py - Correction workflow API → Correction state machine: runs workflow
- Correction state machine → Academic and workflow records: updates attendance
- Document API → PDF indexing pipeline: parses and chunks
backend/app/api/rag.py - Document API → Semantic retrieval: searches chunks
backend/app/api/rag.py - PDF indexing pipeline → Relational and vector store: stores embeddings
- Semantic retrieval → Relational and vector store: reads chunks
backend/app/rag/retriever.py - Semantic retrieval → Academic and workflow records: filters by profile
backend/app/rag/retriever.py - FastAPI application → Relational and vector store: initializes schema
backend/app/main.py - Relational and vector store → Academic and workflow records: persists
backend/app/models/user.py - Academic MCP tools → Academic services and tools: exposes tools