{"id":28460533,"url":"https://github.com/obomhese-raphael/docscribe","last_synced_at":"2026-04-29T23:31:59.702Z","repository":{"id":291104873,"uuid":"976591448","full_name":"Obomhese-Raphael/DocScribe","owner":"Obomhese-Raphael","description":"DocScribe - A fullstack application designed to efficiently summarize various text and document formats, including plain text, PDFs, and web pages. Leveraging pdf parse and the Huggingface api, DocScribe provides users with concise and informative summaries, streamlining information consumption. Built with the MERN stack with Typescript.","archived":false,"fork":false,"pushed_at":"2026-02-05T11:35:17.000Z","size":16648,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-02-05T21:53:31.888Z","etag":null,"topics":["clerk","huggingface","mernstack","mongodb","typescript","vite"],"latest_commit_sha":null,"homepage":"https://doc-scribe-frontend.vercel.app/","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/Obomhese-Raphael.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-05-02T11:39:32.000Z","updated_at":"2026-02-05T11:35:21.000Z","dependencies_parsed_at":"2025-06-06T14:30:01.366Z","dependency_job_id":null,"html_url":"https://github.com/Obomhese-Raphael/DocScribe","commit_stats":null,"previous_names":["obomhese-raphael/docscribe"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Obomhese-Raphael/DocScribe","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Obomhese-Raphael%2FDocScribe","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Obomhese-Raphael%2FDocScribe/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Obomhese-Raphael%2FDocScribe/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Obomhese-Raphael%2FDocScribe/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Obomhese-Raphael","download_url":"https://codeload.github.com/Obomhese-Raphael/DocScribe/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Obomhese-Raphael%2FDocScribe/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32448399,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-29T22:27:22.272Z","status":"ssl_error","status_checked_at":"2026-04-29T22:10:49.234Z","response_time":110,"last_error":"SSL_read: 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":["clerk","huggingface","mernstack","mongodb","typescript","vite"],"created_at":"2025-06-07T02:38:32.130Z","updated_at":"2026-04-29T23:31:59.674Z","avatar_url":"https://github.com/Obomhese-Raphael.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# DocScribe\n\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n[![TypeScript](https://img.shields.io/badge/TypeScript-007ACC?logo=typescript\u0026logoColor=white)](https://www.typescriptlang.org/)\n[![React](https://img.shields.io/badge/React-20232A?logo=react\u0026logoColor=61DAFB)](https://reactjs.org/)\n[![Node.js](https://img.shields.io/badge/Node.js-339933?logo=node.js\u0026logoColor=white)](https://nodejs.org/)\n[![MongoDB](https://img.shields.io/badge/MongoDB-47A248?logo=mongodb\u0026logoColor=white)](https://www.mongodb.com/)\n\n\u003cimg width=\"1839\" height=\"826\" alt=\"image\" src=\"https://github.com/user-attachments/assets/511eaadb-e81e-43da-9f03-3de9969ca49e\" /\u003e\n\n\n\u003e AI-powered document summarization platform that transforms lengthy documents into concise, actionable insights using advanced language models.\n\n[Live Demo](https://doc-scribe-frontend.vercel.app) · [Report Bug](https://github.com/Obomhese-Raphael/DocScribe/issues) · [Request Feature](https://github.com/Obomhese-Raphael/DocScribe/issues)\n\n---\n\n## 📋 Table of Contents\n\n- [Overview](#overview)\n- [Key Features](#key-features)\n- [Tech Stack](#tech-stack)\n- [Architecture](#architecture)\n- [Getting Started](#getting-started)\n  - [Prerequisites](#prerequisites)\n  - [Installation](#installation)\n  - [Environment Variables](#environment-variables)\n  - [Running Locally](#running-locally)\n- [Deployment](#deployment)\n- [API Documentation](#api-documentation)\n- [Project Structure](#project-structure)\n- [Contributing](#contributing)\n- [License](#license)\n- [Contact](#contact)\n\n---\n\n## 🎯 Overview\n\nDocScribe is a full-stack web application that leverages cutting-edge AI technology to provide intelligent document summarization. Built with the MERN stack and powered by Groq's ultra-fast inference engine, it enables users to quickly extract key insights from documents, saving time and improving productivity.\n\n### Why DocScribe?\n\n- **⚡ Lightning Fast**: Powered by Groq's inference engine for near-instantaneous summaries\n- **🔒 Secure**: Enterprise-grade authentication with Clerk\n- **📱 Responsive**: Seamless experience across all devices\n- **💾 Persistent**: Complete history tracking and document management\n- **🎨 Modern**: Built with the latest web technologies and best practices\n\n---\n\n## ✨ Key Features\n\n### Core Functionality\n- **Multi-Format Support**: Upload and summarize PDF, TXT, and DOCX files\n- **AI-Powered Summarization**: Leverages Groq's LLaMA models for intelligent text analysis\n- **Real-time Processing**: Get summaries in seconds, not minutes\n- **Document Management**: Complete CRUD operations for your documents\n- **Search \u0026 Filter**: Quickly find specific documents in your history\n\n### User Experience\n- **Drag \u0026 Drop Upload**: Intuitive file upload interface\n- **Inline Editing**: Rename documents directly in the interface\n- **Share Summaries**: Generate shareable links for collaboration\n- **Download Options**: Export summaries as text files\n- **Responsive Design**: Optimized for desktop, tablet, and mobile\n\n### Security \u0026 Authentication\n- **Secure Authentication**: Clerk integration for user management\n- **Protected Routes**: Role-based access control\n- **Data Encryption**: Secure storage of sensitive information\n- **Session Management**: Automatic token refresh and validation\n\n---\n\n## 🛠 Tech Stack\n\n### Frontend\n| Technology | Purpose |\n|------------|---------|\n| **React 18** | UI framework with hooks and modern patterns |\n| **TypeScript** | Type-safe development and better DX |\n| **Vite** | Lightning-fast build tool and dev server |\n| **Tailwind CSS** | Utility-first CSS framework |\n| **React Router** | Client-side routing and navigation |\n| **Axios** | HTTP client for API communication |\n| **React Toastify** | User-friendly notifications |\n| **Lucide React** | Modern, customizable icon library |\n| **React Dropzone** | File upload with drag-and-drop |\n\n### Backend\n| Technology | Purpose |\n|------------|---------|\n| **Node.js** | JavaScript runtime environment |\n| **Express.js** | Fast, minimalist web framework |\n| **MongoDB** | NoSQL database for flexible data storage |\n| **Mongoose** | Elegant MongoDB object modeling |\n| **Groq SDK** | AI-powered text summarization |\n| **Clerk SDK** | User authentication and management |\n| **Multer** | Multipart file upload handling |\n| **Mammoth** | DOCX to text conversion |\n| **pdf-parse** | PDF text extraction |\n\n### DevOps \u0026 Infrastructure\n- **Vercel**: Frontend and backend hosting\n- **MongoDB Atlas**: Cloud database service\n- **Git \u0026 GitHub**: Version control and collaboration\n- **ESLint \u0026 Prettier**: Code quality and formatting\n\n---\n\n## 🏗 Architecture\n\n```\n┌─────────────────────────────────────────────────────────────┐\n│                         Client Layer                         │\n│  ┌──────────────┐  ┌──────────────┐  ┌──────────────┐      │\n│  │   React UI   │  │  TypeScript  │  │   Tailwind   │      │\n│  └──────────────┘  └──────────────┘  └──────────────┘      │\n└──────────────────────────────┬──────────────────────────────┘\n                               │\n                          Axios HTTP\n                               │\n┌──────────────────────────────▼──────────────────────────────┐\n│                      Application Layer                       │\n│  ┌──────────────┐  ┌──────────────┐  ┌──────────────┐      │\n│  │   Express    │  │  Middleware  │  │    Routes    │      │\n│  └──────────────┘  └──────────────┘  └──────────────┘      │\n└──────────────────────────────┬──────────────────────────────┘\n                               │\n                    ┌──────────┴──────────┐\n                    │                     │\n┌───────────────────▼─────┐   ┌──────────▼──────────────────┐\n│      Data Layer          │   │    External Services        │\n│  ┌──────────────┐        │   │  ┌──────────────┐          │\n│  │   MongoDB    │        │   │  │  Groq API    │          │\n│  │   (Mongoose) │        │   │  │  Clerk Auth  │          │\n│  └──────────────┘        │   │  └──────────────┘          │\n└──────────────────────────┘   └─────────────────────────────┘\n```\n\n---\n\n## 🚀 Getting Started\n\n### Prerequisites\n\nEnsure you have the following installed:\n\n- **Node.js** \u003e= 18.0.0 ([Download](https://nodejs.org/))\n- **npm** \u003e= 9.0.0 or **yarn** \u003e= 1.22.0\n- **MongoDB** account ([MongoDB Atlas](https://www.mongodb.com/cloud/atlas))\n- **Git** ([Download](https://git-scm.com/))\n\n### Installation\n\n1. **Clone the repository**\n   ```bash\n   git clone https://github.com/Obomhese-Raphael/DocScribe.git\n   cd DocScribe\n   ```\n\n2. **Install backend dependencies**\n   ```bash\n   cd backend\n   npm install\n   ```\n\n3. **Install frontend dependencies**\n   ```bash\n   cd ../frontend\n   npm install\n   ```\n\n### Environment Variables\n\n#### Backend Configuration\n\nCreate a `.env` file in the `backend` directory:\n\n```env\n# Server Configuration\nNODE_ENV=development\nPORT=5000\n\n# Database\nMONGODB_URI=mongodb+srv://username:password@cluster.mongodb.net/docscribe?retryWrites=true\u0026w=majority\n\n# Authentication (Clerk)\nCLERK_SECRET_KEY=sk_test_xxxxxxxxxxxxxxxxxxxxx\nCLERK_WEBHOOK_SECRET=whsec_xxxxxxxxxxxxxxxxxxxxx\n\n# AI Service (Groq)\nGROQ_API_KEY=gsk_xxxxxxxxxxxxxxxxxxxxx\n\n# Frontend URL\nFRONTEND_BASE_URL=http://localhost:5173\n\n# File Upload\nMAX_FILE_SIZE=10485760\nALLOWED_FILE_TYPES=application/pdf,text/plain,application/vnd.openxmlformats-officedocument.wordprocessingml.document\n```\n\n#### Frontend Configuration\n\nCreate a `.env` file in the `frontend` directory:\n\n```env\n# API Configuration\nVITE_API_BASE_URL=http://localhost:5000\n\n# Authentication (Clerk)\nVITE_CLERK_PUBLISHABLE_KEY=pk_test_xxxxxxxxxxxxxxxxxxxxx\n\n# Environment\nVITE_NODE_ENV=development\n```\n\n### Running Locally\n\n#### Start the Backend Server\n\n```bash\ncd backend\nnpm run dev\n```\n\nThe backend server will start on `http://localhost:5000`\n\n#### Start the Frontend Development Server\n\n```bash\ncd frontend\nnpm run dev\n```\n\nThe frontend will be available at `http://localhost:5173`\n\n#### Access the Application\n\nOpen your browser and navigate to `http://localhost:5173`\n\n---\n\n## 🌐 Deployment\n\n### Frontend Deployment (Vercel)\n\n1. **Create `vercel.json` in the frontend root:**\n   ```json\n   {\n     \"rewrites\": [\n       {\n         \"source\": \"/(.*)\",\n         \"destination\": \"/index.html\"\n       }\n     ]\n   }\n   ```\n\n2. **Deploy to Vercel:**\n   ```bash\n   cd frontend\n   vercel --prod\n   ```\n\n3. **Set environment variables in Vercel dashboard:**\n   - `VITE_API_BASE_URL`\n   - `VITE_CLERK_PUBLISHABLE_KEY`\n\n### Backend Deployment (Vercel)\n\n1. **Ensure `vercel.json` exists in the backend root:**\n   ```json\n   {\n     \"version\": 2,\n     \"builds\": [\n       {\n         \"src\": \"server.js\",\n         \"use\": \"@vercel/node\"\n       }\n     ],\n     \"routes\": [\n       {\n         \"src\": \"/(.*)\",\n         \"dest\": \"/server.js\"\n       }\n     ]\n   }\n   ```\n\n2. **Deploy to Vercel:**\n   ```bash\n   cd backend\n   vercel --prod\n   ```\n\n3. **Set environment variables in Vercel dashboard:**\n   - All variables from backend `.env` file\n\n### Post-Deployment\n\n- Update `FRONTEND_BASE_URL` in backend environment variables\n- Update `VITE_API_BASE_URL` in frontend environment variables\n- Test all functionality in production environment\n- Monitor logs for any errors\n\n---\n\n## 📚 API Documentation\n\n### Base URL\n```\nProduction: https://your-backend.vercel.app\nDevelopment: http://localhost:5000\n```\n\n### Authentication\nAll protected routes require a valid Clerk session token in the `Authorization` header:\n```\nAuthorization: Bearer \u003cclerk_session_token\u003e\n```\n\n### Endpoints\n\n#### Document Upload \u0026 Summarization\n```http\nPOST /api/upload\nContent-Type: multipart/form-data\n\nBody:\n  file: \u003cbinary\u003e\n\nResponse: 200 OK\n{\n  \"success\": true,\n  \"data\": {\n    \"_id\": \"document_id\",\n    \"originalName\": \"example.pdf\",\n    \"summary\": \"AI-generated summary...\",\n    \"fileType\": \"application/pdf\",\n    \"uploadDate\": \"2026-02-05T10:30:00.000Z\"\n  }\n}\n```\n\n#### Get Summary History\n```http\nGET /api/summaries/history\n\nResponse: 200 OK\n{\n  \"success\": true,\n  \"data\": [\n    {\n      \"_id\": \"summary_id\",\n      \"documentId\": \"document_id\",\n      \"summaryText\": \"Summary content...\",\n      \"summaryDate\": \"2026-02-05T10:30:00.000Z\",\n      \"document\": {\n        \"_id\": \"document_id\",\n        \"originalName\": \"example.pdf\",\n        \"fileType\": \"application/pdf\"\n      }\n    }\n  ]\n}\n```\n\n#### Generate Share Link\n```http\nPOST /api/summaries/:id/share\n\nResponse: 200 OK\n{\n  \"success\": true,\n  \"shareableLink\": \"https://your-app.vercel.app/shared/document_id\"\n}\n```\n\n#### Get Shared Summary\n```http\nGET /api/summaries/shared/:id\n\nResponse: 200 OK\n{\n  \"success\": true,\n  \"data\": {\n    \"_id\": \"document_id\",\n    \"summaryText\": \"Summary content...\",\n    \"document\": {\n      \"originalName\": \"example.pdf\",\n      \"fileType\": \"application/pdf\"\n    }\n  }\n}\n```\n\n#### Download Summary\n```http\nGET /api/summaries/:id/download\n\nResponse: 200 OK\nContent-Type: text/plain\nContent-Disposition: attachment; filename=\"summary.txt\"\n```\n\n#### Delete Summary\n```http\nDELETE /api/summaries/:id\n\nResponse: 200 OK\n{\n  \"success\": true,\n  \"message\": \"Summary deleted successfully\"\n}\n```\n\n#### Rename Document\n```http\nPATCH /api/upload/documents/:id/rename\nContent-Type: application/json\n\nBody:\n{\n  \"newName\": \"Updated Document Name.pdf\"\n}\n\nResponse: 200 OK\n{\n  \"success\": true,\n  \"data\": {\n    \"_id\": \"document_id\",\n    \"originalName\": \"Updated Document Name.pdf\"\n  }\n}\n```\n\n---\n\n## 📁 Project Structure\n\n```\nDocScribe/\n├── frontend/\n│   ├── public/\n│   │   └── assets/\n│   ├── src/\n│   │   ├── components/\n│   │   │   ├── Header.tsx\n│   │   │   ├── Footer.tsx\n│   │   │   └── ProtectedRoute.tsx\n│   │   ├── pages/\n│   │   │   ├── Home.tsx\n│   │   │   ├── History.tsx\n│   │   │   ├── SharedSummary.tsx\n│   │   │   └── About.tsx\n│   │   ├── hooks/\n│   │   │   └── useAuth.ts\n│   │   ├── utils/\n│   │   │   └── api.ts\n│   │   ├── types/\n│   │   │   └── index.ts\n│   │   ├── App.tsx\n│   │   ├── main.tsx\n│   │   └── index.css\n│   ├── .env\n│   ├── vercel.json\n│   ├── package.json\n│   ├── tsconfig.json\n│   ├── vite.config.ts\n│   └── tailwind.config.js\n│\n├── backend/\n│   ├── controllers/\n│   │   ├── uploadController.js\n│   │   └── summaryController.js\n│   ├── models/\n│   │   ├── Document.js\n│   │   └── User.js\n│   ├── routes/\n│   │   ├── uploadRoutes.js\n│   │   └── summaryRoutes.js\n│   ├── middleware/\n│   │   ├── auth.js\n│   │   ├── errorHandler.js\n│   │   └── validateFile.js\n│   ├── utils/\n│   │   ├── groqService.js\n│   │   └── fileParser.js\n│   ├── config/\n│   │   └── database.js\n│   ├── uploads/\n│   ├── .env\n│   ├── vercel.json\n│   ├── server.js\n│   └── package.json\n│\n├── .gitignore\n├── LICENSE\n└── README.md\n```\n\n---\n\n## 🤝 Contributing\n\nWe welcome contributions from the community! Here's how you can help:\n\n### Development Process\n\n1. **Fork the repository**\n   ```bash\n   # Click the 'Fork' button on GitHub\n   ```\n\n2. **Create a feature branch**\n   ```bash\n   git checkout -b feature/amazing-feature\n   ```\n\n3. **Make your changes**\n   - Write clean, readable code\n   - Follow existing code style\n   - Add comments for complex logic\n   - Update documentation if needed\n\n4. **Test your changes**\n   ```bash\n   npm run test\n   npm run lint\n   ```\n\n5. **Commit your changes**\n   ```bash\n   git commit -m \"feat: add amazing feature\"\n   ```\n\n6. **Push to your fork**\n   ```bash\n   git push origin feature/amazing-feature\n   ```\n\n7. **Open a Pull Request**\n   - Provide a clear description\n   - Reference any related issues\n   - Wait for review\n\n### Commit Convention\n\nWe follow [Conventional Commits](https://www.conventionalcommits.org/):\n\n- `feat:` New feature\n- `fix:` Bug fix\n- `docs:` Documentation changes\n- `style:` Code style changes (formatting, etc.)\n- `refactor:` Code refactoring\n- `test:` Adding or updating tests\n- `chore:` Maintenance tasks\n\n### Code Style\n\n- Use TypeScript for type safety\n- Follow ESLint and Prettier configurations\n- Write meaningful variable and function names\n- Keep functions small and focused\n- Add JSDoc comments for complex functions\n\n---\n\n## 📄 License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n---\n\n## 👤 Contact\n\n**Obomhese Raphael**\n\n- 🐦 Twitter: [@ObomheseR](https://twitter.com/ObomheseR)\n- 📧 Email: obomheser@gmail.com\n- 💼 LinkedIn: [Obomhese Raphael](https://linkedin.com/in/obomhese-raphael)\n- 🐙 GitHub: [@Obomhese-Raphael](https://github.com/Obomhese-Raphael)\n\n---\n\n## 🙏 Acknowledgments\n\n- [Groq](https://groq.com/) for providing ultra-fast AI inference\n- [Clerk](https://clerk.com/) for seamless authentication\n- [MongoDB](https://www.mongodb.com/) for flexible data storage\n- [Vercel](https://vercel.com/) for hosting and deployment\n- The open-source community for amazing tools and libraries\n\n---\n\n\u003cdiv align=\"center\"\u003e\n\n**[⬆ Back to Top](#docscribe)**\n\nMade with ❤️ by [Obomhese Raphael](https://github.com/Obomhese-Raphael)\n\n\u003c/div\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fobomhese-raphael%2Fdocscribe","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fobomhese-raphael%2Fdocscribe","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fobomhese-raphael%2Fdocscribe/lists"}