Spaces:
Running
Running
import streamlit as st | |
import requests | |
from database import save_resume_data | |
from crewai import ResumeAgents | |
st.title("AI-Powered Resume Screening") | |
uploaded_files = st.file_uploader("Upload Resumes", accept_multiple_files=True, type=["pdf", "txt"]) | |
job_description = st.text_area("Enter Job Description") | |
if st.button("Process Resumes"): | |
results = [] | |
for uploaded_file in uploaded_files: | |
resume_text = uploaded_file.read().decode("utf-8") | |
parsed_details = ResumeAgents.parse_resume(resume_text) | |
ranking_score = ResumeAgents.rank_resume(parsed_details, job_description) | |
save_resume_data(resume_text, parsed_details, ranking_score) | |
results.append(f"Resume: {uploaded_file.name}\nRank: {ranking_score}\nDetails: {parsed_details}") | |
st.write("\n\n".join(results)) |