A FastAPI-based backend for uploading resumes, extracting content, and tailoring them to specific job descriptions using NLP and embeddings.
app/
├── api/ # FastAPI routers and dependencies
├── core/ # Application settings and constants
├── db/ # Database session and Base declaration
├── models/ # SQLAlchemy ORM models
├── schemas/ # Pydantic request/response models
├── services/ # Business logic for auth, resumes, and job analysis
└── main.py # FastAPI application entrypoint
-
Create and activate a virtual environment
python -m venv .venv source .venv/bin/activate -
Install dependencies
pip install fastapi uvicorn[standard] sqlalchemy passlib[bcrypt] python-jose pip install python-multipart pdfplumber python-docx spacy sentence-transformers scikit-learn
-
Run database migrations (SQLite is used by default, tables are created on startup)
-
Start the API server
uvicorn app.main:app --reload
Environment variables can override defaults in app/core/config.py:
DATABASE_URL– database connection string (defaults to SQLite file)SECRET_KEY– JWT signing keyUPLOAD_DIR– path for uploaded resumesEMBEDDING_MODEL– SentenceTransformer model name
POST /auth/register– create a new userPOST /auth/login– obtain a JWT access tokenPOST /resumes/upload– upload and parse a resume file (PDF or DOCX)POST /jobs/analyze– analyze a job description against the latest or specified resume
Use the token from /auth/login as a Bearer token for protected endpoints.