A Django application that allows users to upload work agreements and automatically generates AI agents to contact employees and handle terminations.
- Upload work agreements (PDF, DOC, DOCX, TXT)
- AI-powered extraction of agreement information
- Automatic generation of termination agents
- AI-generated professional termination communications
- Contact logging and tracking
- Multi-step termination workflow
-
Create a virtual environment:
python3 -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate
-
Install dependencies:
pip install -r requirements.txt
-
Set up environment variables:
cp .env.example .env # Edit .env and add your OpenAI API key -
Run migrations:
python manage.py makemigrations python manage.py migrate
-
Create a superuser (optional, for admin access):
python manage.py createsuperuser
-
Run the development server:
python manage.py runserver
-
Access the application:
- Main application: http://127.0.0.1:8000/
- Admin panel: http://127.0.0.1:8000/admin/
-
Upload a Work Agreement:
- Navigate to "Upload Agreement"
- Fill in employee name, email, and upload the agreement file
- The system will automatically process the agreement
-
Create a Termination Agent:
- Once the agreement is processed, view its details
- Click "Create Termination Agent" to generate an AI agent
-
Contact the Employee:
- Use the "Contact Employee" button to have the AI agent send a professional termination notice
-
Execute Termination:
- After contacting, use "Execute Termination" to finalize the process
- The AI will generate a comprehensive termination message
- This application requires an OpenAI API key to function
- Email sending is currently simulated (prints to console). In production, integrate with an email service
- Document parsing for PDF/DOC files is simplified. For production, use proper libraries like PyPDF2 or python-docx
- This is a development application. For production, ensure proper security measures, authentication, and error handling
- Django 5.2.8
- OpenAI API (GPT-4o-mini)
- Bootstrap 5 (for UI)
- SQLite (default database)
This project is for demonstration purposes.