The Document Management and RAG-based Q&A Application is designed to manage users, documents, and an ingestion process that generates embeddings for document retrieval in a Q&A setting. It features an NextJS frontend for user interaction with backend services.
- User Authentication: Sign Up, Login, and Logout interfaces.
- User Management: Admin-only access for managing users and assigning roles.
- Document Management: Interface to upload and manage documents.
- Ingestion Management: Interface to trigger and monitor ingestion status.
- Q&A Interface: User-friendly interface for asking questions and receiving answers with relevant document excerpts.
https://www.loom.com/share/a15908a1a94b4c3f8666db1c7cbf9a2f?sid=449254c0-b7f2-4238-9f29-d681120ebfc9
Ensure the following are installed:
- Node.js
- Docker
- Clone the repository:
git clone https://github.com/keshavsaini2607/user-management-app.git- Setup Frontend:
cd user-management-app/client
npm install
npm run devAccess the frontend at: http://localhost:3000/
- Setup Backend:
Open a new terminal and navigate to the backend directory:
cd user-management-app/server
- Pull and run the Docker image:
docker pull keshavsaini0905/docify-server
docker run -d -p 8000:8000 keshavsaini0905/docify-server
Backend API: http://localhost:8000/
- Access the Application:: Visit http://localhost:3000/ to use the application.
This diagram illustrates the architectural design of the project, showcasing the interplay between various components and technologies.
Key Components:
- Client: The frontend of the application, built using NextJS, handles user interactions and displays data.
- NextJS: A powerful JavaScript library for building robust and scalable web applications. It facilitates the creation of dynamic and interactive user interfaces.
- Google Analytics 4: This is a web analytics service provided by Google that allows you to track user behavior and website performance. It's likely integrated to collect data on user interactions with your application.
- NestJS: A progressive Node.js framework for building efficient and scalable server-side applications. It provides a structured approach to organizing code and handling API requests.
- Prisma: An object-relational mapper (ORM) that simplifies database interactions by providing a type-safe and intuitive way to work with data models. It connects the NestJS backend to the MongoDB database.
- MongoDB: A flexible NoSQL database that excels in handling large volumes of unstructured data. It serves as the data storage layer for the application.
- AWS S3: A cloud-based service provided by AWS designed to optimize, store, and deliver assets efficiently. It integrates with a NestJS backend to handle raw document uploads.
Data Flow and Interactions
- Client to NextJS: The user interacts with the NextJS frontend, triggering actions like making requests or submitting forms.
- NextJS to NestJS: NextJS sends requests to the NestJS backend, which handles the business logic and data processing.
- NestJS to Prisma: NestJS interacts with the database using Prisma to fetch or store data as needed.
- NestJS to S3: NestJS interacts with S3 to manage documents, uploading, or fetching them.
