Spaces:
Running
Running
File size: 1,307 Bytes
56325dc edfcf73 19ea0c5 edfcf73 19ea0c5 56325dc edfcf73 56325dc edfcf73 56325dc |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 |
import streamlit as st
from utils import evaluate_resumes, generate_pdf_report, store_in_supabase, score_candidate, extract_email, parse_resume
from config import supabase
from config import HF_API_TOKEN, HF_HEADERS, HF_MODELS
import fitz # PyMuPDF
from io import BytesIO
from dotenv import load_dotenv
import os
import requests
def main():
st.set_page_config(page_title="TalentLens.AI", layout="centered")
st.markdown(
"<h1 style='text-align: center;'>TalentLens.AI</h1>",
unsafe_allow_html=True
)
st.divider()
st.markdown(
"<h3 style='text-align: center;'>AI-Powered Intelligent Resume Screening</h3>",
unsafe_allow_html=True
)
uploaded_files = st.file_uploader("Upload Resumes (PDF Only)", accept_multiple_files=True, type=["pdf"])
job_description = st.text_area("Enter Job Description")
if st.button("Evaluate Resumes"):
shortlisted = evaluate_resumes(uploaded_files, job_description)
for candidate in shortlisted:
st.write(f"**{candidate['name']}** - Score: {candidate['score']}")
# Generate PDF Report
pdf_report = generate_pdf_report(shortlisted)
st.download_button("Download Shortlist Report", pdf_report, "shortlist.pdf")
if __name__ == "__main__":
main() |