{"id":31952341,"url":"https://github.com/ag-tej/shiksha-setu","last_synced_at":"2026-04-29T20:34:39.459Z","repository":{"id":318685604,"uuid":"1072328634","full_name":"ag-tej/shiksha-setu","owner":"ag-tej","description":"A multi-source educational chatbot that uses AI and RAG to answer queries from PDFs and URLs with contextually grounded responses.","archived":false,"fork":false,"pushed_at":"2025-10-08T15:20:56.000Z","size":197,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-10-08T17:40:18.422Z","etag":null,"topics":["ai","chatbot","education","langchain","llama","rag"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ag-tej.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-10-08T15:10:56.000Z","updated_at":"2025-10-08T15:22:04.000Z","dependencies_parsed_at":"2025-10-13T22:01:36.106Z","dependency_job_id":null,"html_url":"https://github.com/ag-tej/shiksha-setu","commit_stats":null,"previous_names":["ag-tej/shiksha-setu"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/ag-tej/shiksha-setu","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ag-tej%2Fshiksha-setu","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ag-tej%2Fshiksha-setu/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ag-tej%2Fshiksha-setu/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ag-tej%2Fshiksha-setu/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ag-tej","download_url":"https://codeload.github.com/ag-tej/shiksha-setu/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ag-tej%2Fshiksha-setu/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32443563,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-29T20:22:27.477Z","status":"ssl_error","status_checked_at":"2026-04-29T20:22:26.507Z","response_time":110,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai","chatbot","education","langchain","llama","rag"],"created_at":"2025-10-14T13:13:18.403Z","updated_at":"2026-04-29T20:34:39.440Z","avatar_url":"https://github.com/ag-tej.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Shiksha Setu\n\n**An AI-powered multi-source educational chatbot using Retrieval-Augmented Generation (RAG)**\n\nShiksha Setu is an intelligent educational chatbot designed to make learning interactive and context-aware.\nIt enables students and educators to upload PDFs or add website URLs, retrieve relevant content using semantic search, and generate grounded answers through a local Large Language Model (LLM).\n\n---\n\n## Features\n\n* **Multi-source content ingestion** — Upload PDFs, text files, or submit website URLs.\n* **Retrieval-Augmented Generation (RAG)** — Combines semantic retrieval with local generative AI for accurate answers.\n* **Conversational interface** — Real-time chat with context history and document grounding.\n* **FastAPI backend** — High-performance async API for document and chat handling.\n* **ChromaDB vector store** — Efficient embedding storage and retrieval.\n* **React frontend** — Clean, responsive UI built with React + Tailwind CSS.\n* **JWT authentication** — Secure user login and session control.\n* **Local LLM via Ollama** — Privacy-preserving response generation without external API calls.\n\n---\n\n## Tech Stack\n\n| Layer               | Technologies                             |\n| ------------------- | ---------------------------------------- |\n| **Frontend**        | React.js, Tailwind CSS                   |\n| **Backend**         | FastAPI, LangChain                       |\n| **Vector DB**       | ChromaDB                                 |\n| **Database**        | MongoDB                                  |\n| **Embeddings**      | all-MiniLM-L6-v2 (Sentence Transformers) |\n| **Language Model**  | Mistral / Llama 3 via Ollama             |\n| **Scraping**        | BeautifulSoup                            |\n| **Version Control** | Git \u0026 GitHub                             |\n\n---\n\n## System Architecture\n\n```\nUser → React Frontend → FastAPI Backend\n     → ChromaDB (semantic retrieval)\n     → Ollama (Mistral/Llama 3 generation)\n     → MongoDB (users, chats, documents)\n```\n\nThe layered architecture:\n\n* **Frontend:** React + Tailwind for uploads and chat UI\n* **Backend:** FastAPI handles routing, embedding, and RAG orchestration\n* **RAG Pipeline:** Query embedding, similarity search, prompt construction, and generation\n* **Data Layer:** MongoDB + ChromaDB manage persistence and semantic search\n\n---\n\n## Setup Instructions\n\n### Prerequisites\n\nMake sure you have installed:\n\n* **Python 3.10 +**\n* **Node.js 16 + and npm**\n* **Ollama** (for running local LLM)\n* **MongoDB** (local or remote instance)\n* **Git**\n\n---\n\n### Backend Setup\n\n1. **Clone the repository**\n\n   ```bash\n   git clone https://github.com/ag-tej/shiksha-setu.git\n   cd shiksha-setu/backend\n   ```\n\n2. **Create a virtual environment and activate**\n\n   ```bash\n   python -m venv venv\n   source venv/bin/activate      # (Linux/Mac)\n   venv\\Scripts\\activate         # (Windows)\n   ```\n\n3. **Install dependencies**\n\n   ```bash\n   pip install -r requirements.txt\n   ```\n\n4. **Set environment variables**\n   Create a `.env` file in `/backend`:\n\n   ```\n   MONGO_URI=mongodb://localhost:27017/shiksha_setu\n   JWT_SECRET=your_secret_key\n   ```\n\n5. **Run the backend server**\n\n   ```bash\n   uvicorn app.main:app --reload\n   ```\n\n   The backend will start at **[http://localhost:8000](http://localhost:8000)**\n\n---\n\n### Ollama Setup\n\n1. **Install Ollama** from [https://ollama.ai/download](https://ollama.ai/download)\n2. **Pull the model** (Mistral or Llama 3)\n\n   ```bash\n   ollama pull mistral\n   # or\n   ollama pull llama3\n   ```\n3. **Start Ollama** in a separate terminal\n\n   ```bash\n   ollama serve\n   ```\n\n   Ollama will run on port 11434 by default.\n\n---\n\n### 💻 Frontend Setup\n\n1. **Open a new terminal and navigate to frontend**\n\n   ```bash\n   cd ../frontend\n   ```\n\n2. **Install dependencies**\n\n   ```bash\n   npm install\n   ```\n\n3. **Configure environment variables**\n   Create a `.env` file in `/frontend`:\n\n   ```\n   VITE_API_URL=http://localhost:8000\n   ```\n\n4. **Run the frontend**\n\n   ```bash\n   npm run dev\n   ```\n\n   The frontend will be available at **[http://localhost:5173](http://localhost:5173)**\n\n---\n\n### Access the App\n\n1. Ensure **Ollama**, **backend**, and **frontend** are all running.\n2. Open your browser at **[http://localhost:5173](http://localhost:5173)**.\n3. Sign up / Log in, upload a PDF or URL, and start chatting!\n\n---\n\n## Project Structure\n\n```\nshiksha-setu/\n├── backend/\n│   ├── app/\n│   │   ├── auth.py\n│   │   ├── chat.py\n│   │   ├── rag.py\n│   │   ├── database.py\n│   │   └── main.py\n│   └── requirements.txt\n├── frontend/\n│   ├── src/\n│   │   ├── components/\n│   │   ├── pages/\n│   │   └── services/\n│   └── package.json\n├── README.md\n└── .gitignore\n```\n\n---\n\n## Testing\n\n* ✅ File and URL uploads\n* ✅ RAG response generation accuracy\n* ✅ JWT authentication\n* ✅ Load testing (20 parallel requests \u003c 55 s avg latency)\n\n---\n\n## Results\n\n* Delivered accurate, context-aware answers from uploaded documents and URLs\n* Stable performance with robust authentication and persistence\n* Modular design ready for GPU acceleration and scaling\n\n---\n\n## Future Enhancements\n\n* GPU-accelerated inference\n* Multi-language support\n* Long-context memory\n* Integration with LMS platforms\n* Adaptive learning analytics\n\n---\n\n## License \u0026 Credits\n\nDeveloped as a **B.Sc. CSIT Final Year Project** at **Deerwalk Institute of Technology (Tribhuvan University)**\n**Project Title:** *Implementation of a Retrieval-Augmented Generation Pipeline for a Multi-Source Educational Chatbot*\n**Author:** Tej Agrawal (2025)\n**Supervisor:** Mr. Saurav Gautam\n\n---\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fag-tej%2Fshiksha-setu","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fag-tej%2Fshiksha-setu","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fag-tej%2Fshiksha-setu/lists"}