This project integrates a React frontend with a RAG model backend for analyzing financial audit documents. Users can upload documents (PDF, DOCX, TXT) and receive AI-powered analysis and insights.
Audit-GPT/
├── backend/ # Flask backend API
│ ├── app.py # Main Flask application
│ ├── audit_assistant.py # AI assistant with Groq LLM
│ ├── document_processor.py # Document processing & ChromaDB
│ ├── requirements.txt # Python dependencies
│ ├── .env.example # Environment variables template
│ └── chroma_db/ # Vector database storage
├── src/ # React frontend
│ ├── components/ # Reusable UI components
│ ├── pages/ # Page components
│ │ └── UploadPage.tsx # Document upload & query interface
│ ├── App.tsx # Main app component
│ └── main.tsx # Entry point
├── RAG_model/ # Original RAG implementation
├── package.json # Node.js dependencies
├── vite.config.ts # Vite configuration
└── README.md # This file
- Create and activate a Python virtual environment:
# Navigate to the backend directory
cd backend
# Create virtual environment
python -m venv venv
# Activate virtual environment
# On Windows:
venv\Scripts\activate
# On macOS/Linux:
source venv/bin/activate- Install dependencies:
pip install -r requirements.txt- Create a
.envfile in thebackend/directory:
# On Windows
copy .env.example .env
# On macOS/Linux
cp .env.example .env- Edit the
.envfile and add your GROQ API key:
GROQ_API_KEY=your_groq_api_key_here
CHROMA_DB_DIR=./chroma_db
MAX_CHUNK_SIZE=1000
CHUNK_OVERLAP=200Get your free API key from: https://console.groq.com/keys
- Start the backend server:
python app.pyThe backend will run on http://localhost:5000
- Install Node.js dependencies:
# Navigate to the project root directory
npm install- Start the development server:
npm run devThe frontend will run on http://localhost:5173
- Start both servers (backend and frontend)
- Open your browser and navigate to http://localhost:5173
- Click on "Upload" in the navigation menu
- Upload a PDF document: Drag and drop a financial audit document (PDF only) or click "Choose File"
- Wait for processing: The document will be processed and stored in ChromaDB
- Ask questions: Once uploaded, type questions about the document in the chat interface
- Get AI-powered answers: The assistant will analyze the document and provide relevant answers
- "What is the total revenue for the fiscal year?"
- "Summarize the key audit findings"
- "What are the internal control weaknesses mentioned?"
- "List all compliance issues identified"
- React 18 - UI framework
- TypeScript - Type safety
- Vite - Build tool & dev server
- TailwindCSS - Styling
- Flask - Web server
- LangChain - RAG framework
- ChromaDB - Vector database
- Groq LLM - Language model provider
✅ PDF Document Upload - Upload financial audit PDFs for analysis
✅ AI-Powered Q&A - Ask questions about uploaded documents
✅ RAG Technology - Retrieval-Augmented Generation for accurate answers
✅ Context-Aware Responses - Answers based on actual document content
✅ Chat Interface - Interactive conversation with your documents
✅ Vector Search - Fast semantic search using ChromaDB
✅ Clean Response Formatting - Professional, formatted answers without symbols
Contributions are welcome! Please open issues or submit pull requests for improvements or new features.
This project is licensed under the MIT License. See the LICENSE file for details.