How sreevarshinidesa/notemind works
NoteMind is a full-stack notes and document-grounded Q&A app. Users authenticate, manage private notes, upload PDFs for text extraction and indexing, then ask questions about one PDF or search across all PDFs and receive grounded answers with sources. The graph follows the documented capabilities and backend upload/chat handlers; source excerpts do not include Chat.jsx or several model implementations, so those links are documented or marked unverified rather than inferred from unsampled code.
Main entry points: index.js HTTP routes · App.jsx App and notes · Documents.jsx Document library · Auth.jsx Login form
Components 19
Web client
- App and notes
frontend/src/App.jsx - Login form
frontend/src/Auth.jsx - Document library
frontend/src/Documents.jsx - PDF chat UI
frontend/src/Chat.jsx - Ask all UI
frontend/src/AskAll.jsx
API and identity
- HTTP routes
backend/index.js - JWT middleware
backend/middleware/auth.js - PDF upload validation
backend/middleware/upload.js
Document indexing and retrieval
- Text chunking
backend/utils/chunking.js - Embedding service
backend/utils/embeddings.js - Similarity ranking
backend/utils/similarity.js - PDF text extraction
backend/index.js
Persistent data
- User records
backend/models/User.js - Notes
backend/models/Note.js - Documents
backend/models/Document.js - Embedded chunks
backend/models/Chunk.js
Other components
- User
- Gemini API
- MongoDB
Connections 27
- User → App and notes: uses
README.md - App and notes → Login form: renders
frontend/src/App.jsx - App and notes → Document library: renders
frontend/src/App.jsx - App and notes → Ask all UI: renders
frontend/src/App.jsx - App and notes → HTTP routes: requests notes
frontend/src/App.jsx - Login form → HTTP routes: posts credentials
frontend/src/Auth.jsx - Document library → HTTP routes: requests documents
frontend/src/Documents.jsx - Document library → PDF chat UI: renders
frontend/src/Documents.jsx - PDF chat UI → HTTP routes: asks PDF
README.md - Ask all UI → HTTP routes: asks all
README.md - HTTP routes → JWT middleware: protects routes
backend/index.js - HTTP routes → PDF upload validation: accepts PDF
backend/index.js - HTTP routes → User records: reads and creates
backend/index.js - HTTP routes → Notes: manages notes
backend/index.js - HTTP routes → Documents: stores and reads
backend/index.js - HTTP routes → PDF text extraction: extracts text
backend/index.js - HTTP routes → Text chunking: splits text
backend/index.js - HTTP routes → Embedding service: embeds text
backend/index.js - HTTP routes → Embedded chunks: creates and queries
backend/index.js - HTTP routes → Similarity ranking: ranks chunks
backend/index.js - HTTP routes → Gemini API: generates answers
backend/index.js - Embedding service → Gemini API: requests vectors
backend/utils/embeddings.js - HTTP routes → MongoDB: connects
backend/index.js - User records → MongoDB: persists in
- Notes → MongoDB: persists in
- Documents → MongoDB: persists in
- Embedded chunks → MongoDB: persists in