Skip to content

Schlaflied/job-autopilot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

58 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Job Autopilot πŸš€

GitHub stars GitHub forks License: AGPL v3

AI-powered job application automation system that streamlines your job search workflow using GPT-4o, automated scraping, resume optimization, LinkedIn outreach, and intelligent cold email campaigns.

Perfect for: Job seekers in EdTech, L&D, AI Product Management, and Automation fields


✨ Features

🎯 Intelligent Job Discovery

  • πŸ” Automated Indeed Scraping via Apify
  • πŸ€– AI-Powered Job Scoring (0-10 rating based on your profile)
  • πŸ“Š Smart Categorization (EdTech, AI PM, Automation, L&D)
  • πŸ’Ύ Database Caching (Neon PostgreSQL + Local SQLite fallback)
  • πŸ“¦ Load Cached Jobs (reuse previous searches, save API quota)

πŸ“„ Resume Export & Optimization

  • πŸ“€ Multi-Format Upload: Support PDF, DOCX, and Markdown master resumes
  • 🎨 Professional Templates: 4 ATS-friendly templates (single/two-column, classic/modern)
  • 🧠 GPT-4o Powered: Resume optimization uses GPT-4o for higher accuracy
  • πŸ“Š ATS Scoring: Real-time ATS compatibility score with keyword matching
  • 🎯 Job-Tailored Resumes: AI optimizes resume for each job description
  • πŸ”’ Anti-Hallucination: Iron-clad data protection - dates, locations locked

β˜• Coffee Chat Center ✨ NEW

  • πŸŽ“ School Configuration: Set your alumni schools (priority-ranked)
  • 🏷️ Target Fields: Define your professional interests (L&D, AI, etc.)
  • πŸ“‹ Job Integration: Link high-value jobs to LinkedIn search
  • πŸ”— One-Click LinkedIn Launch: Search alumni directly from UI

πŸ”— LinkedIn Automation ✨ NEW

  • 🌐 Chrome DevTools MCP: AI-friendly browser automation via accessibility tree
  • πŸŽ“ Alumni Search: Find 2nd-degree connections from your schools
  • πŸ€– AI Agents:
    • ContactRankerAgent: Priority scoring (0-100) based on job match, alumni status
    • ScamDetectionAgent: Filter suspicious profiles automatically
    • PersonalizationAgent: GPT-4 powered message generation
  • 🧠 Memory Layer: ChromaDB vector storage for learning from successful messages
  • πŸ“¨ Auto-Connect: Send connection requests with rate limiting (10-20s delays)
  • πŸ’Ύ Persistent Profile: Uses dedicated Chrome profile (no conflict with personal Chrome)

πŸ“§ Email Center

  • πŸ“ Draft Cold Emails: AI-generated personalized emails
  • πŸ“¬ Gmail Integration: Create drafts directly in Gmail
  • πŸ“Š Email Statistics: Track drafts, sent, replied counts
  • ⏰ Follow-up Queue: Auto-generate follow-up drafts

πŸ“Š Dashboard

  • πŸ“ˆ Kanban Board: Visual pipeline (To Apply β†’ Sent β†’ Replied β†’ Interview)
  • πŸ“š Applied History: Manage manually marked applications
  • 🎯 One-Click Apply: Move jobs through stages
  • πŸ“§ Status Tracking: Real-time application status

πŸ—οΈ Architecture

Project Overview

Project Architecture

Coffee Chat Data Flow

Data Flow

LinkedIn Automation Flow

LinkedIn Flow


πŸ› οΈ Tech Stack

Category Technology
AI/LLM OpenAI GPT-4o / GPT-4o-mini
Frontend Streamlit 1.30+
Backend Python 3.11+
Database Neon PostgreSQL (cloud)
Job Scraping Apify (Indeed Actor)
LinkedIn Automation Chrome DevTools MCP (Puppeteer-based)
Memory Layer ChromaDB (Vector Database)
Email Gmail API (OAuth 2.0)
Resume python-docx, ReportLab (PDF)
ORM SQLAlchemy 2.0

πŸš€ Quick Start

Prerequisites

  • Python 3.11+
  • Node.js 18+ (for Chrome DevTools MCP)
  • Git

Installation

# 1. Clone the repository
git clone https://github.com/Schlaflied/job-autopilot.git
cd job-autopilot

# 2. Create virtual environment
python -m venv venv
venv\Scripts\activate  # Windows
source venv/bin/activate  # macOS/Linux

# 3. Install dependencies
pip install -r requirements.txt

# 4. Configure environment variables
cp .env.example .env
# Edit .env with your API keys

# 5. Initialize database
python scripts/init_database.py
python scripts/init_coffee_chat_db.py

# 6. Run the application
streamlit run streamlit_app.py --server.port=8502

Access the app: http://localhost:8502

🐳 Docker Deployment

You can run the entire application in a Docker container (recommended for stability).

# 1. Build the image
docker build -t job-autopilot .

# 2. Run the container
# We map port 8502 and allow access to the host's Chrome (CDP)
docker run -p 8502:8502 -p 5000:5000 \
  --add-host=host.docker.internal:host-gateway \
  --env-file .env \
  -v "%cd%/data":/app/data \
  job-autopilot

Note: The --add-host flag is crucial for the Docker container to connect to your local Chrome instance for LinkedIn automation.


πŸ“ Project Structure

job-autopilot/
β”œβ”€β”€ modules/
β”‚   β”œβ”€β”€ ai_agent.py              # GPT-4o integration (scoring, resume, emails)
β”‚   β”œβ”€β”€ coffee_chat_agents.py    # ✨ AI Agents (Ranker, Scam, Personalization)
β”‚   β”œβ”€β”€ coffee_chat_memory.py    # ✨ ChromaDB Memory Layer
β”‚   β”œβ”€β”€ coffee_chat_models.py    # SQLAlchemy models for Coffee Chat
β”‚   β”œβ”€β”€ linkedin_automation.py   # ✨ LinkedIn search and automation
β”‚   β”œβ”€β”€ job_scraper.py           # Apify job scraper with caching
β”‚   β”œβ”€β”€ job_contact_integrator.py # Job + Contact integration
β”‚   β”œβ”€β”€ gmail_service.py         # Gmail API integration
β”‚   β”œβ”€β”€ database.py              # SQLAlchemy models (Neon PostgreSQL)
β”‚   β”œβ”€β”€ resume_generator.py      # Resume PDF/DOCX generation
β”‚   └── logger_config.py         # Centralized logging
β”œβ”€β”€ pages/
β”‚   β”œβ”€β”€ coffee_chat_center.py    # ✨ Coffee Chat Dashboard
β”‚   └── user_profile.py          # ✨ School & Fields Configuration
β”œβ”€β”€ scripts/
β”‚   β”œβ”€β”€ linkedin_auto_connect.py # ✨ End-to-end LinkedIn automation
β”‚   β”œβ”€β”€ init_database.py         # Database initialization
β”‚   └── init_coffee_chat_db.py   # Coffee Chat tables
β”œβ”€β”€ docs/
β”‚   └── COFFEE_CHAT_PLAN/        # LinkedIn & Coffee Chat documentation
β”œβ”€β”€ streamlit_app.py             # Main Streamlit UI
β”œβ”€β”€ requirements.txt             # Python dependencies
└── README.md                    # This file

βš™οΈ Configuration

Required API Keys

1. OpenAI API (AI features)

OPENAI_API_KEY=sk-proj-your_openai_api_key_here
OPENAI_MODEL=gpt-4o-mini

2. Apify API (Job scraping)

APIFY_API_TOKEN=apify_api_your_token_here

3. Neon PostgreSQL (Database)

DATABASE_URL=postgresql://user:password@host.neon.tech/dbname?sslmode=require

4. Gmail API (Email automation)

GMAIL_CREDENTIALS_PATH=./data/credentials/gmail_credentials.json
GMAIL_TOKEN_PATH=./data/credentials/gmail_token.json

πŸ€– Browser Automation (MCP-Style)

This project uses a direct connection to Chrome's DevTools Protocol (CDP) to "read" web pages and perform actions like a human agent.

1. Launch Debug Chrome

To allow the app to control your browser, you must launch Chrome with a specific debugging port (9222).

Windows Users:

  1. Locate launch_chrome_debug.bat in the project root.
  2. Double-click to run it.
  3. A new Chrome window will open. Log in to LinkedIn in this window.

2. Use Coffee Chat Center

  1. Go to the Coffee Chat Center page in the app.
  2. Click "πŸ”— Test Connection" to verify the app can "see" your Chrome window.
  3. Use features like "Dive & Draft":
    • The app will navigate Chrome to a contact's profile.
    • It reads the screen (using MCP/CDP).
    • AI analyzes the profile hooks and drafts a message.
    • Click "Paste to LinkedIn" to insert the draft.

πŸ” Security & Privacy

Your Data Stays With You.

  • Local Database: Job data is stored in your local PostgreSQL/SQLite instance.
  • Local Browser: Automation happens on your machine, in your browser.
  • Git Ignoring: The .gitignore is pre-configured to exclude:
    • docs/ (Your personal strategies/logs)
    • data/ (Resumes, credentials)
    • chroma_data/ (AI memory)
    • *.csv (LinkedIn exports)

To Import LinkedIn Connections:

  1. Export your data from LinkedIn Settings (Connections.csv).
  2. Place it in the project folder.
  3. Run the import script (or use the UI uploader).
    python scripts/import_enhanced_connections.py

Command Line Usage

# Direct script execution
python scripts/linkedin_auto_connect.py --company "google.com" --school "University of Western Ontario" --limit 5

πŸ’° Cost Estimate

Service Cost Notes
OpenAI GPT-4o-mini ~$5-10/mo Job scoring + resume + emails
OpenAI Embeddings ~$0.30/1000 contacts Memory Layer vectors
Apify (Indeed scraper) $0 (free tier) $5 free credit
Neon PostgreSQL $0 (free tier) 0.5GB storage
Gmail API $0 Free for personal use
Total $5-10/mo Scalable to 100+ applications

πŸ› Troubleshooting

"Chrome already running"

taskkill /F /IM chrome.exe

"LinkedIn not loading"

  • The script uses a dedicated profile at C:/temp/linkedin-automation-profile
  • First run requires manual LinkedIn login
  • Login persists for future runs

"No 2nd degree connections found"

  • Try different company/school combinations
  • Some companies have few alumni in your network

πŸ“œ License

This project is licensed under GNU Affero General Public License v3.0 (AGPL-3.0).

  • βœ… Free to use, modify, distribute
  • ⚠️ Must open-source modifications under same license
  • ⚠️ Network users entitled to source code

πŸ™ Acknowledgments

  • OpenAI for GPT-4o API
  • Google Chrome DevTools Team for Chrome DevTools MCP
  • Apify for job scraping infrastructure
  • Neon for free PostgreSQL tier
  • ChromaDB for vector database
  • Resume-Matcher for inspiring our PDF/DOCX parsing approach using pdfminer.six and docx2txt
  • Job seekers worldwide πŸ’ͺ

🎯 Roadmap

  • LinkedIn auto-connect with AI agents
  • Memory layer for learning from successful messages
  • Coffee chat message automation (post-connection)
  • Multi-language support
  • Interview prep AI coach

⭐ Star this repo if it helped you land a job! ⭐

Report Bug Β· Request Feature

About

AI-powered job application automation with GPT-4o, LinkedIn auto-connect, resume optimization, and cold email campaigns. Features AI agents for contact ranking, scam detection, and memory layer for learning from successful outreach.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages