https://github.com/rohitm1518/policylens
PolicyLens is an AI-powered insurance management system that simplifies policy understanding using document summarization, regional language translation, and an interactive chatbot.
https://github.com/rohitm1518/policylens
express insurance javascript mern react tailwindcss
Last synced: about 2 months ago
JSON representation
PolicyLens is an AI-powered insurance management system that simplifies policy understanding using document summarization, regional language translation, and an interactive chatbot.
- Host: GitHub
- URL: https://github.com/rohitm1518/policylens
- Owner: RohitM1518
- Created: 2024-11-19T06:15:41.000Z (11 months ago)
- Default Branch: main
- Last Pushed: 2025-01-20T16:10:09.000Z (9 months ago)
- Last Synced: 2025-01-20T16:53:45.930Z (9 months ago)
- Topics: express, insurance, javascript, mern, react, tailwindcss
- Language: JavaScript
- Homepage: https://policylens.tech
- Size: 7.41 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# PolicyLens: AI-Powered Insurance Policy Management System
## Overview
PolicyLens is an AI-powered application designed to simplify the understanding and management of insurance policies. It provides a user-friendly interface for:
- **Policy Summarization:** Transforms lengthy insurance documents into clear, concise summaries.
- **Multilingual Support:** Breaks down language barriers by providing translations in multiple regional languages.
- **AI Chatbot:** Offers instant answers to policy-related questions through an intelligent chatbot.## Architecture
The system architecture follows a MERN (MongoDB, Express.js, React.js, Node.js) stack pattern with a strong emphasis on AI integration.

## Features
- **User Authentication and Authorization:**
- Secure user registration and login (`/client/src/pages/SignIn.jsx`, `/client/src/pages/SignUp.jsx`)
- JWT (JSON Web Token) based authentication (`/server/src/middlewares/authUserMiddleware.js`)- **Document Processing:**
- Upload and storage of insurance policy documents (PDF format) (`/server/src/middlewares/multerMiddleware.js`)
- AI-powered extraction of key terms and conditions (`/server/src/controllers/geminiController.js`)
- Generation of concise and easy-to-understand summaries (`/server/src/controllers/summaryController.js`)- **Multilingual Support:**
- On-demand translation of policy summaries into multiple regional languages (`/server/src/controllers/regionalLanguageController.js`)- **AI Chatbot Integration:**
- Interactive chatbot interface (`/client/src/pages/ChatBot.jsx`)
- Context-aware responses using Retrieval Augmented Generation (RAG) for personalized assistance (`/server/src/controllers/messageController.js`)- **User Profile Management:**
- Create, view, and update user profiles (`/client/src/pages/Profile.jsx`)
- Secure storage of user data (`/server/src/models/userModel.js`)- **Policy Management (Future Feature):**
- Planned features for users to manage their insurance policies within the application## Technologies Used
- **Frontend:**
- React.js
- Redux (for state management)
- HTML, CSS, JavaScript- **Backend:**
- Node.js
- Express.js- **Database:**
- MongoDB- **AI Integration:**
- Google Gemini API- **Cloud Storage:**
- Cloudinary## Screenshots
**Home Page**
**Sign Up page**
**Sign In page**
**Policy Summary Generator page for creating concise policy overviews**
**Policy Summary Page generated using the provided policy PDF**
**Translation of the summary into the user's preferred native language for better understanding**
**English text translated into regional languages to improve accessibility and user experience**
**Initiating a new chat with query recommendations tailored to the user's context**
**User interacting with the chatbot for assistance and query resolution**
**Updating user profile details to provide better context and personalization**
**Updating the user password by verifying the old password for security**
**Including an insurance policy on the personalized dashboard for easy access and management**
**Dashboard displaying a list of user-added insurance policies for convenient tracking and management**
## Getting Started
### Prerequisites:
- Node.js (version 12 or higher)
- npm (Node Package Manager)
- MongoDB (ensure you have a running MongoDB instance)### Installation & Setup:
1. **Clone the repository:**
```bash
git clone https://github.com/your-username/PolicyLens.git
cd PolicyLens
2. **Install server-side dependencies:**
```bash
cd server
npm install
3. **Install client-side dependencies:**
```bash
cd client
npm install
4. **Configuration:**
- Create a .env file in the server directory.
- Add the following environment variables to the .env file, replacing the placeholders with your actual credentials:
```bash
MONGODB_URI=your-mongodb-connection-string
GEMINI_API_KEY=your-gemini-api-key
CLOUDINARY_URL=your-cloudinary-url
ACCESS_TOKEN_SECRET_KEY=your-access-token-secret-key
REFRESH_TOKEN_SECRET_KEY=your-refresh-token-secret-key
CORS_ORIGIN=http://localhost:5173
5. **Run the application:**
```bash
# Start the development servers
cd server && npm run dev
cd client && npm run dev
6. Access the application:
Open your web browser and navigate to http://localhost:5173 (or your defined frontend port) to access PolicyLens.## Future Enhancements Advanced Policy Comparisons:
- Allow users to compare different insurance policies side-by-side.
- Automated Claim Assistance: Guide users through the claims process with AI-powered assistance.
- Integration with Insurance Providers: Enable seamless policy management and claims filing within the platform.