--- license: mit title: Resume_Analyzer sdk: gradio emoji: 🚀 colorFrom: blue colorTo: green pinned: false --- <<<<<<< HEAD # Resume Analyzer - AI-Powered Resume Analysis Tool A professional web application built with Python and Gradio that analyzes resumes using AI and provides detailed insights, recommendations, and career guidance. ## 🎯 Features - **📄 Multi-Format Support**: Analyze resumes in PDF, DOCX, and TXT formats - **🤖 AI-Powered Analysis**: Uses OpenAI's GPT models for intelligent analysis - **📊 Comprehensive Evaluation**: - Skills assessment (technical & soft skills) - Experience review with highlights and concerns - Education background analysis - Career gap identification - Job market compatibility assessment - Overall resume scoring (0-100) - **💡 Smart Recommendations**: Actionable improvement suggestions - **📥 Export Results**: Download analysis as JSON or text report - **🎨 Modern UI**: Clean, intuitive Gradio interface with organized tabs - **⚡ Real-time Processing**: Fast resume parsing and analysis ## 🚀 Quick Start ### Prerequisites - Python 3.8 or higher - pip (Python package manager) - OpenAI API key (optional - mock data available for demo) ### Installation 1. **Clone or Navigate to Project Directory** ```bash cd c:\Users\Admin\Desktop\Workshop_dev ``` 2. **Create Virtual Environment** (Recommended) ```bash # Windows python -m venv venv venv\Scripts\activate # macOS/Linux python -m venv venv source venv/bin/activate ``` 3. **Install Dependencies** ```bash pip install -r requirements.txt ``` 4. **Configure API Key** (Optional) - Create a `.env` file in the project root - Add your OpenAI API key: ``` OPENAI_API_KEY=your_api_key_here ``` - If not configured, the app will use mock data for demo 5. **Run the Application** ```bash python app.py ``` The application will open in your default browser at `http://localhost:7860` ## 📋 How to Use 1. **Upload Resume**: Click the upload area and select your resume file (PDF, DOCX, or TXT) 2. **Load Resume**: Click "Load Resume" to extract and preview the text 3. **Analyze**: Click the "Analyze with AI" button 4. **Review Results**: - View overall score and executive summary - Explore technical and soft skills - Check experience highlights and concerns - Identify career gaps - Read improvement recommendations 5. **Export**: Use the Export tab to download analysis as JSON or text format ## 📁 Project Structure ``` resume-analyzer/ ├── app.py # Main Gradio application ├── requirements.txt # Python dependencies ├── README.md # This file ├── .env.example # Example environment variables ├── .gitignore # Git ignore patterns ├── config/ │ ├── __init__.py │ └── settings.py # Configuration and constants ├── utils/ │ ├── __init__.py │ ├── resume_parser.py # Resume file parsing utilities │ └── ai_analyzer.py # AI analysis logic └── sample_resumes/ # Directory for sample resume files ``` ## 🔧 Configuration Edit `config/settings.py` to customize: - **Model Configuration**: Change AI model, temperature, max tokens - **File Upload**: Adjust max file size and allowed extensions - **Analysis Sections**: Customize which analysis sections to include ### Environment Variables Create a `.env` file with: ```env # OpenAI API Configuration OPENAI_API_KEY=sk-your-key-here # Use local model (experimental) USE_LOCAL_MODEL=False ``` ## 📊 Analysis Output The analyzer provides detailed insights on: ### Overall Score (0-100) - Quick assessment of resume quality - Accompanied by detailed explanation ### Skills Analysis - Technical skills identified - Soft skills assessment - Missing skills for target roles ### Experience Review - Key achievements and highlights - Career concerns and gaps - Work history coherence ### Education Assessment - Background evaluation - Relevance to career goals - Certification details ### Career Gaps - Timeline inconsistencies - Unexplained employment gaps - Industry transition concerns ### Recommendations - Specific action items for improvement - Skills to develop - Resume optimization tips ### Job Market Compatibility - Industry-relevant strengths - Competitive weaknesses - Market positioning ## 🔌 API Integration ### OpenAI Integration The app uses OpenAI's GPT API for resume analysis. To use: 1. Get an API key from [OpenAI Platform](https://platform.openai.com) 2. Add to `.env` file as `OPENAI_API_KEY` 3. App automatically uses GPT-3.5-turbo model ### Demo Mode Without an API key configured, the app provides mock analysis data suitable for: - Testing the UI and functionality - Demonstrations - Development without API costs ## 🛠️ Development ### Adding New Analysis Features 1. Update `config/settings.py` to add new analysis sections 2. Modify the AI prompt in `utils/ai_analyzer.py` 3. Add formatting function in `app.py` for new sections ### Extending File Format Support 1. Add new format handler in `utils/resume_parser.py` 2. Update `ALLOWED_EXTENSIONS` in `config/settings.py` 3. Update file uploader type list in `app.py` ### Customizing Analysis Edit the prompt in `analyze_resume_with_openai()` function to: - Focus on specific industries - Emphasize particular skills - Add custom scoring criteria ## 🎨 UI Customization Gradio allows easy customization through: - **Themes**: Change the theme in `gr.Blocks(theme=gr.themes.Soft())` - **Layout**: Modify tab structure and component organization - **Styling**: Add custom CSS through Gradio's styling options ## 🐛 Troubleshooting ### "ModuleNotFoundError" when running ```bash # Ensure virtual environment is activated # Windows: venv\Scripts\activate # macOS/Linux: source venv/bin/activate # Reinstall dependencies pip install -r requirements.txt ``` ### PDF parsing errors - Ensure PDF is not encrypted - Try converting to DOCX first - Check file is not corrupted ### API Key not working - Verify key is correctly added to `.env` - Check API key has sufficient credits - Ensure key has correct permissions ### Gradio not found ```bash pip install gradio==4.20.0 ``` ### Port already in use By default, Gradio runs on port 7860. If it's already in use: ```python # Modify app.py to use a different port demo.launch(server_port=7861) ``` ## 📝 Sample Usage ```python # Example of programmatic usage from utils.resume_parser import parse_resume from utils.ai_analyzer import analyze_resume_with_openai # Parse resume resume_text = parse_resume(file_content, ".pdf") # Analyze analysis = analyze_resume_with_openai(resume_text) # Access results print(f"Score: {analysis['overall_score']['rating']}") print(f"Technical Skills: {analysis['skills']['technical']}") ``` ## ⚖️ Requirements - Python 3.8+ - Gradio 4.20.0 - PyPDF2 3.0.1 - python-docx 0.8.11 - openai 1.3.0 - python-dotenv 1.0.0 ## 📄 License This project is provided as-is for educational and professional use. ## 🤝 Contributing Feel free to: - Report issues - Suggest improvements - Add features - Optimize code ## 💬 Support For issues or questions: 1. Check the troubleshooting section 2. Review existing issues 3. Create a detailed bug report ## 🚀 Future Enhancements - [ ] Database integration for saving analyses - [ ] User accounts and analysis history - [ ] Multiple resume comparison - [ ] Industry-specific analysis templates - [ ] Resume improvement suggestions with examples - [ ] ATS (Applicant Tracking System) compatibility checker - [ ] Job description matching - [ ] Interview preparation tips based on resume - [ ] Support for additional file formats - [ ] Multi-language support - [ ] Dark mode theme option ## 📚 Resources - [Gradio Documentation](https://www.gradio.app/docs) - [OpenAI API Documentation](https://platform.openai.com/docs) - [PyPDF2 Documentation](https://github.com/py-pdf/PyPDF2) - [python-docx Documentation](https://python-docx.readthedocs.io) --- **Built with ❤️ using Python and Gradio** ======= # Resume_Analyzer Python based interactive resume analyzer. That gives score for your resume. >>>>>>> f6f8dc17a4e8894979dec8347d3b381389f1d10b