How andrewsselvaraj/neet_chat works
NEET Paper Coach accepts a student's question, retrieves relevant passages from locally indexed past-paper PDFs, asks an OpenAI-compatible chat model to explain them, and returns an answer with paper and page citations. The graph distinguishes PDF loading/search, answer generation, and the web interface. The README documents startup indexing and local retrieval; the excerpts show the principal calls. The template and PDF corpus are represented from the tree and README, not inspected source excerpts.
Main entry points: ChatService.java Answer orchestration · ChatController.java Chat controller · QuestionPaperIndex.java PDF index and search · ChatAnswer.java Answer and citations
Components 11
Web interaction
- Chat controller
src/main/java/com/neetchat/web/ChatController.java - Chat page
src/main/resources/templates/index.html
Paper retrieval
- Past-paper PDFs
Questions - PDF index and search
src/main/java/com/neetchat/search/QuestionPaperIndex.java - Paper passages
src/main/java/com/neetchat/search/PaperPassage.java
Answer generation
- Answer orchestration
src/main/java/com/neetchat/chat/ChatService.java - Answer and citations
src/main/java/com/neetchat/chat/ChatAnswer.java - Paper citation
src/main/java/com/neetchat/chat/PaperCitation.java
Model integration
- Model configuration
src/main/java/com/neetchat/config/LanguageModelConfiguration.java - Chat model API
Other components
- Student
Connections 11
- Student → Chat controller: submits question
src/main/java/com/neetchat/web/ChatController.java - Chat controller → Answer orchestration: requests answer
src/main/java/com/neetchat/web/ChatController.java - Chat controller → Chat page: renders page
src/main/java/com/neetchat/web/ChatController.java - Past-paper PDFs → PDF index and search: indexes PDFs
README.md - PDF index and search → Paper passages: creates passages
src/main/java/com/neetchat/search/QuestionPaperIndex.java - Answer orchestration → PDF index and search: searches passages
src/main/java/com/neetchat/chat/ChatService.java - Answer orchestration → Paper citation: creates citations
src/main/java/com/neetchat/chat/ChatService.java - Answer orchestration → Chat model API: sends prompt
src/main/java/com/neetchat/chat/ChatService.java - Model configuration → Chat model API: configures client
src/main/java/com/neetchat/config/LanguageModelConfiguration.java - Answer orchestration → Answer and citations: returns result
src/main/java/com/neetchat/chat/ChatService.java - Chat controller → Answer and citations: displays result
src/main/java/com/neetchat/web/ChatController.java