|
|
|
|
|
|
|
|
|
|
|
|
|
sudo apt install -y python-yaml docker.io vagrant virtualbox p7zip-full |
|
|
|
|
|
|
|
|
|
|
|
import os |
|
import jinja2 |
|
|
|
import pdfkit |
|
|
|
|
|
|
|
import numpy as np |
|
import gradio as gr |
|
|
|
from langchain.llms import OpenAI |
|
from langchain.chat_models import ChatOpenAI |
|
from langchain.output_parsers import ResponseSchema,PydanticOutputParser,StructuredOutputParser |
|
from langchain import PromptTemplate |
|
from langchain.prompts import PromptTemplate, ChatPromptTemplate, HumanMessagePromptTemplate |
|
from langchain.output_parsers import CommaSeparatedListOutputParser |
|
from pydantic import BaseModel, Field, validator |
|
from typing import List |
|
from langchain.text_splitter import CharacterTextSplitter,RecursiveCharacterTextSplitter |
|
|
|
|
|
|
|
output_parser = CommaSeparatedListOutputParser() |
|
|
|
|
|
|
|
|
|
from datetime import datetime |
|
|
|
|
|
|
|
|
|
|
|
|
|
c_splitter = CharacterTextSplitter(chunk_size = 450,chunk_overlap = 0,separator = ' ') |
|
r_splitter = RecursiveCharacterTextSplitter(chunk_size = 80,chunk_overlap = 0,separators = ["\n\n"]) |
|
|
|
|
|
|
|
|
|
|
|
output_parser = CommaSeparatedListOutputParser() |
|
format_instructions = output_parser.get_format_instructions() |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def company_cr(target_company,language,key): |
|
tar_com_prompt = """ List 6 competitors' name of {company} in {lang}.\n{format_instructions} |
|
""" |
|
chat_0_3 = ChatOpenAI(temperature = 0.0,openai_api_key = key) |
|
pTem_tar_c = ChatPromptTemplate.from_template(tar_com_prompt) |
|
prompt_c = pTem_tar_c.format_messages(company = target_company,lang = language,format_instructions = format_instructions) |
|
|
|
mock_exp_company = chat_0_3(prompt_c) |
|
|
|
mock_exp_company_fin = mock_exp_company.content.split(',') |
|
return mock_exp_company_fin |
|
|
|
|
|
def job_cr(target_job,language,key): |
|
tar_job_prompt = """ List 2 similar names of this {job} in {lang}.\n{format_instructions} |
|
""" |
|
chat_0_3 = ChatOpenAI(temperature = 0.0,openai_api_key = key) |
|
pTem_tar_j = ChatPromptTemplate.from_template(tar_job_prompt) |
|
prompt_j = pTem_tar_j.format_messages(job = target_job,lang = language,format_instructions = format_instructions) |
|
mock_exp_job = chat_0_3(prompt_j) |
|
|
|
mock_exp_job_fin = mock_exp_job.content.split(',') |
|
|
|
return mock_exp_job_fin |
|
|
|
|
|
def skill_pri_cr(job_req,key): |
|
tar_skill_pri_prompt = """ Assume you are the recruiter, read the {job_requirement}, then list 20 tech terms you want to see on candidates resume.\n{format_instructions} |
|
""" |
|
chat_0_4 = ChatOpenAI(temperature = 0.0,model_name = 'gpt-4',openai_api_key = key) |
|
pTem_tar_skill = ChatPromptTemplate.from_template(tar_skill_pri_prompt) |
|
prompt_skill = pTem_tar_skill.format_messages(job_requirement = job_req,format_instructions = format_instructions) |
|
mock_skill_pri = chat_0_4(prompt_skill) |
|
|
|
mock_skill_pri_fin = mock_skill_pri.content.split(',') |
|
|
|
return mock_skill_pri_fin |
|
|
|
|
|
|
|
def skill_sec_cr(skill_pri,language,key): |
|
tar_skill_sec_prompt = """ Assume you are the recruiter, read the skill sets in {skill_pri}, list 5 related tech terms for each skill set you want to see on candidates resume in {lang}.\n{format_instructions} |
|
""" |
|
chat_0_4 = ChatOpenAI(temperature = 0.0,model_name = 'gpt-4',openai_api_key = key) |
|
|
|
pTem_tar_skill_sec = ChatPromptTemplate.from_template(tar_skill_sec_prompt) |
|
prompt_skill_sec = pTem_tar_skill_sec.format_messages(skill_pri = skill_pri,lang = language,format_instructions = format_instructions) |
|
|
|
|
|
mock_skill_sec = chat_0_4(prompt_skill_sec) |
|
|
|
mock_skill_sec_fin = mock_skill_sec.content.split(',') |
|
|
|
return mock_skill_sec_fin |
|
|
|
|
|
def soc_cr(target_job,language,key): |
|
tar_soc_prompt = """ If a student want to become a {job_name} after graduation, list 5 possible school clubs or competitions the student wants to join in {lang}.\n{format_instructions} |
|
""" |
|
chat_0_4 = ChatOpenAI(temperature = 0.0,model_name = 'gpt-4',openai_api_key = key) |
|
pTem_tar_soc = ChatPromptTemplate.from_template(tar_soc_prompt) |
|
prompt_soc = pTem_tar_soc.format_messages(job_name = target_job,lang = language,format_instructions = format_instructions) |
|
|
|
mock_exp_soc = chat_0_4(prompt_soc) |
|
|
|
mock_exp_soc_fin = mock_exp_soc.content.split(',') |
|
|
|
|
|
return mock_exp_soc_fin |
|
|
|
|
|
|
|
def work_exp(mock_company,mock_title,mock_skill,language,key): |
|
working_exp_prompt = """ Write the working experience in {lang}. Considering my working experience in {company} as a {title}, and I am good at {skill_sec}, write a part of resume for me. A good resume reorganizes the skill set in 3 to 4 examples. Each example must include 60 to 80 words. A good resume must not use pronouns. Each example must have detail numbers to describe result. List each example in a new line without serial numbers. """ |
|
chat_0_4 = ChatOpenAI(temperature = 0.0,model_name = 'gpt-4',openai_api_key = key) |
|
|
|
pTem_tar_working_exp = ChatPromptTemplate.from_template(working_exp_prompt) |
|
prompt_working_exp = pTem_tar_working_exp.format_messages(company = mock_company,lang = language,title = mock_title,skill_sec = mock_skill) |
|
|
|
|
|
mock_working_exp = chat_0_4(prompt_working_exp) |
|
|
|
mock_working_exp_fin = r_splitter.split_text(mock_working_exp.content) |
|
|
|
result = [mock_working_exp_fin[0],mock_working_exp_fin[1],mock_working_exp_fin[2]] |
|
|
|
|
|
|
|
|
|
return (mock_working_exp_fin[0],mock_working_exp_fin[1],mock_working_exp_fin[2]) |
|
|
|
|
|
def club_exp(mock_soc,mock_skill_soc,language,key): |
|
club_exp_prompt = """ Write the school experience in {lang}. Considering my school experience in {club}, and I am good at {skill_sec_club}, write a part of resume for me. A good resume reorganizes the skill set in 3 examples. Each example must include 60 to 80 words. A good resume must not use pronouns. Each example must have detail numbers to describe result. List each example in a new line without serial numbers. """ |
|
chat_0_4 = ChatOpenAI(temperature = 0.0,model_name = 'gpt-4',openai_api_key = key) |
|
|
|
|
|
|
|
|
|
mock_skill_soc_fin = np.array(mock_skill_soc)[rand_value] |
|
|
|
pTem_tar_club_exp = ChatPromptTemplate.from_template(club_exp_prompt) |
|
prompt_club_exp = pTem_tar_club_exp.format_messages(club = mock_soc,lang = language,skill_sec_club = mock_skill_soc_fin) |
|
|
|
|
|
|
|
|
|
|
|
mock_club_exp = chat_0_4(prompt_club_exp) |
|
|
|
|
|
mock_club_exp_fin = r_splitter.split_text(mock_club_exp.content) |
|
|
|
|
|
|
|
|
|
return mock_club_exp_fin |
|
|
|
|
|
|
|
def skill_info(job_req,language,key): |
|
|
|
|
|
|
|
|
|
mock_skill_pri = skill_pri_cr(job_req,key) |
|
|
|
|
|
mock_skill_sec = skill_sec_cr(mock_skill_pri,language,key) |
|
|
|
|
|
return mock_skill_sec |
|
|
|
def resume_header(name,mobile,email,Gra_beg,Gra_end,Gra_sch,Gra_maj,underGra_beg,underGra_end,underGra_sch,underGra_maj): |
|
header = f""" |
|
<main role="main"> |
|
<div class="page"><!-- 1. Header --> |
|
<h1 style="text-align: center;">{name}</h1> |
|
<p style="text-align: center;">Mobile:{mobile} Email:{email}</p> |
|
<hr /><!-- 2a. Resume Content --> |
|
<section class="resume_content"> |
|
<article> |
|
<h3>Education Background</h3> |
|
<div style="float: left;">{Gra_beg}-{Gra_end} <strong>{Gra_sch}</strong></div> |
|
<div style="float: right;">{Gra_maj} <strong>Master</strong></div> |
|
<br /> |
|
<div style="float: left;">{underGra_beg}-{underGra_end} <strong>{underGra_sch}</strong></div> |
|
<div style="float: right;">{underGra_maj} <strong>Bachelor</strong></div> |
|
<br /><hr /> |
|
<h3>Working Experience</h3> |
|
</article> |
|
</section> |
|
</div> |
|
</main> |
|
|
|
""" |
|
return header |
|
|
|
def resume_working_exp(exp_beg,exp_end,exp_com,exp_title,exp_1,exp_2,exp_3): |
|
working_exp = f""" |
|
<main role="main"> |
|
<div class="page"> |
|
<section> |
|
<div style="float: left;">{exp_beg}-{exp_end} <strong>{exp_com}</strong></div> |
|
<div style="float: right;"><strong>{exp_title}</strong></div> |
|
<br /> |
|
<ul> |
|
<p><li>{exp_1}</li></p> |
|
<p><li>{exp_2}</li></p> |
|
<p><li>{exp_3}</li></p> |
|
</ul> |
|
</section> |
|
</div> |
|
</main> |
|
|
|
""" |
|
return working_exp |
|
|
|
|
|
|
|
|
|
def resume(name,mobile,email,Gra_beg,Gra_end,Gra_sch,Gra_maj,underGra_beg,underGra_end,underGra_sch,underGra_maj,exp_one_beg,exp_one_end,exp_one_com,exp_one_title,exp_one_1,exp_one_2,exp_one_3,exp_two_beg,exp_two_end,exp_two_com,exp_two_title,exp_two_1,exp_two_2,exp_two_3,exp_three_beg,exp_three_end,exp_three_com,exp_three_title,exp_three_1,exp_three_2,exp_three_3,exp_four_beg,exp_four_end,exp_four_com,exp_four_title,exp_four_1,exp_four_2,exp_four_3): |
|
|
|
|
|
|
|
pdfkit_options = {'encoding': 'UTF-8'} |
|
body = f""" |
|
|
|
<main role="main"> |
|
<div class="page"><!-- 1. Header --> |
|
<h1 style="text-align: center;">{name}</h1> |
|
<p style="text-align: center;">Mobile:{mobile} Email:{email}</p> |
|
<hr /><!-- 2a. Resume Content --> |
|
<section class="resume_content"> |
|
<article> |
|
<h3>Education Background</h3> |
|
<div style="float: left;">{Gra_beg}-{Gra_end} <strong>{Gra_sch}</strong></div> |
|
<div style="float: right;">{Gra_maj} <strong>Master</strong></div> |
|
<br /> |
|
<div style="float: left;">{underGra_beg}-{underGra_end} <strong>{underGra_sch}</strong></div> |
|
<div style="float: right;">{underGra_maj} <strong>Bachelor</strong></div> |
|
<br /><hr /> |
|
<h3>Working Experience</h3> |
|
<section> |
|
<div style="float: left;">{exp_one_beg}-{exp_one_end} <strong>{exp_one_com}</strong></div> |
|
<div style="float: right;"><strong>{exp_one_title}</strong></div> |
|
<br /> |
|
<ul> |
|
<p><li>{exp_one_1}</li></p> |
|
<p><li>{exp_one_2}</li></p> |
|
<p><li>{exp_one_3}</li></p> |
|
</ul> |
|
<div style="float: left;">{exp_two_beg}-{exp_two_end} <strong>{exp_two_com}</strong></div> |
|
<div style="float: right;"><strong>{exp_two_title}</strong></div> |
|
<br /> |
|
<ul> |
|
<p><li>{exp_two_1}</li></p> |
|
<p><li>{exp_two_2}</li></p> |
|
<p><li>{exp_two_3}</li></p> |
|
</ul> |
|
<div style="float: left;">{exp_three_beg}-{exp_three_end} <strong>{exp_three_com}</strong></div> |
|
<div style="float: right;"><strong>{exp_three_title}</strong></div> |
|
<br /> |
|
<ul> |
|
<p><li>{exp_three_1}</li></p> |
|
<p><li>{exp_three_2}</li></p> |
|
<p><li>{exp_three_3}</li></p> |
|
</ul> |
|
<div style="float: left;">{exp_four_beg}-{exp_four_end} <strong>{exp_four_com}</strong></div> |
|
<div style="float: right;"><strong>{exp_four_title}</strong></div> |
|
<br /> |
|
<ul> |
|
<p><li>{exp_four_1}</li></p> |
|
<p><li>{exp_four_2}</li></p> |
|
<p><li>{exp_four_3}</li></p> |
|
</ul> |
|
</article> |
|
</section> |
|
</div> |
|
</main> |
|
|
|
|
|
""" |
|
|
|
|
|
pdfkit.from_string(body, "Resume.pdf",options=pdfkit_options) |
|
|
|
|
|
|
|
return "Resume.pdf" |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def Dropdown_list(list_in): |
|
new_options = list_in |
|
return gr.Dropdown.update(choices=new_options) |
|
|
|
def Add_list(list_in,list_add): |
|
list_out = list_in + list_add.split(",") |
|
return list_out |
|
|
|
def Textbox_value(list_in,num): |
|
num = int(num) |
|
new_value = list_in[num] |
|
return gr.Textbox.update(value = new_value) |
|
|
|
def Dropdown_value_rand(list_in,num): |
|
num = int(num) |
|
n_range = range(0,80) |
|
rand_value = np.random.randint(0,80,size = num) |
|
list_out = np.array(list_in)[rand_value] |
|
list_out = list_out.tolist() |
|
return list_out |
|
|
|
def Button_visible(): |
|
return gr.Button.update(visible = True) |
|
|
|
def Textbox_value_os(str_in): |
|
return gr.Textbox.update(value = str_in) |
|
|
|
def Textbox_visible(): |
|
return gr.Textbox.update(visible = True) |
|
|
|
def Button_inact(): |
|
return gr.Button.update(interactive = False) |
|
|
|
def Button_act(): |
|
return gr.Button.update(interactive = True) |
|
|
|
|
|
|
|
options = ['Select a company'] |
|
|
|
with gr.Blocks() as demo: |
|
with gr.Row(): |
|
with gr.Column(): |
|
|
|
|
|
|
|
txt_key = gr.Textbox(type="password", placeholder="sk..",label = "Openai API key") |
|
|
|
txt_tarcom_in = gr.Textbox(label = "Target Company",info = "e.g. Amazon") |
|
txt_tarjob_in = gr.Textbox(label = "Target Job",info = "e.g. Data Analyst") |
|
txt_jd_in = gr.Textbox(label = "Job Responsibility",info = "e.g. - Write high quality distributed system software- Build production quality and large scale deployment of applications related to NLP and ML- Use software engineering best practices to ensure a high standard of quality for all team deliverables- Design, implement, test, deploy and maintain innovative software solutions to transform service performance, stability, cost and security- Help drive business decisions with your technical input- Work in an agile, startup-like development environment, where you're always working on the most important stuff") |
|
txt_lang_in = gr.Dropdown(["English"],label="Language", info="Choose the language of your resume") |
|
btn_resume_info = gr.Button(value="Analyze Target Job") |
|
|
|
|
|
|
|
js_com_out = gr.JSON(label = "Company output",visible = False) |
|
js_title_out = gr.JSON(label = "Proper Title",visible = False) |
|
js_sec_skill_out = gr.JSON(label = "Output",visible = False) |
|
js_club_out = gr.JSON(label = "Output",visible = False) |
|
|
|
|
|
|
|
notice = gr.Label("Please wait until resume is shown on the right side (around 90s with 4 paragraphs). Try to fill in bio below in this time.",visible = False) |
|
with gr.Row(): |
|
name = gr.Textbox(label = "Name",visible = False) |
|
mobile = gr.Textbox(label = "Mobile",visible = False) |
|
email = gr.Textbox(label = "Email",visible = False) |
|
with gr.Row(): |
|
Gra_beg = gr.Textbox(label = "Graduate School Beginning Year",visible = False) |
|
Gra_end = gr.Textbox(label = "Graduate School End Year",visible = False) |
|
Gra_sch = gr.Textbox(label = "Graduate School Name",visible = False) |
|
Gra_maj = gr.Textbox(label = "Graduate School Major",visible = False) |
|
with gr.Row(): |
|
underGra_beg = gr.Textbox(label = "Undergraduate School Beginning Year",visible = False) |
|
underGra_end = gr.Textbox(label = "Undergraduate School End Year",visible = False) |
|
underGra_sch = gr.Textbox(label = "Undergraduate School Name",visible = False) |
|
underGra_maj = gr.Textbox(label = "Undergraduate School Major",visible = False) |
|
|
|
btn_exp_gen = gr.Button(value = "Add Your Headers",visible = False) |
|
|
|
|
|
with gr.Row(): |
|
exp_com_one = gr.Textbox(value = options,label="Company Name",visible = False) |
|
exp_title_one = gr.Textbox(value = options,label="Title Name",visible = False) |
|
time_beg_one = gr.Textbox(value = '2016',label = "Beginning years",visible = False) |
|
time_end_one = gr.Textbox(value = '2017',label = "Ending years",visible = False) |
|
exp_skill_one = gr.Dropdown(value = options, label = "Skill",multiselect = True,visible = False) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
exp_txt_one_1 = gr.Textbox(value = options,interactive = True,visible = False) |
|
exp_txt_one_1_out = gr.Textbox(value = options,interactive = True,visible = False,label = "Working Experience") |
|
exp_txt_one_2 = gr.Textbox(value = options,interactive = True,visible = False) |
|
exp_txt_one_2_out = gr.Textbox(value = options,interactive = True,visible = False,label = "Working Experience") |
|
exp_txt_one_3 = gr.Textbox(value = options,interactive = True,visible = False) |
|
exp_txt_one_3_out = gr.Textbox(value = options,interactive = True,visible = False,label = "Working Experience") |
|
btn_work_exp_one = gr.Button(value = "Update Working Experience One",visible = False) |
|
|
|
|
|
|
|
|
|
|
|
|
|
with gr.Row(): |
|
exp_com_two = gr.Textbox(value = options,label="Company Name",visible = False) |
|
exp_title_two = gr.Textbox(value = options,label="Title Name",visible = False) |
|
time_beg_two = gr.Textbox(value = '2016',label = "Beginning years",visible = False) |
|
time_end_two = gr.Textbox(value = '2017',label = "Ending years",visible = False) |
|
exp_skill_two = gr.Dropdown(value = options, label = "Skill",multiselect = True,visible = False) |
|
|
|
|
|
|
|
exp_txt_two_1 = gr.Textbox(value = options,interactive = True,visible = False) |
|
exp_txt_two_1_out = gr.Textbox(value = options,interactive = True,visible = False,label = "Working Experience") |
|
exp_txt_two_2 = gr.Textbox(value = options,interactive = True,visible = False) |
|
exp_txt_two_2_out = gr.Textbox(value = options,interactive = True,visible = False,label = "Working Experience") |
|
exp_txt_two_3 = gr.Textbox(value = options,interactive = True,visible = False) |
|
exp_txt_two_3_out = gr.Textbox(value = options,interactive = True,visible = False,label = "Working Experience") |
|
btn_work_exp_two = gr.Button(value = "Update Working Experience Two",visible = False) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
with gr.Row(): |
|
exp_com_three = gr.Textbox(value = options,label="Company Name",visible = False) |
|
exp_title_three = gr.Textbox(value = options,label="Title Name",visible = False) |
|
time_beg_three = gr.Textbox(value = '2016',label = "Beginning years",visible = False) |
|
time_end_three = gr.Textbox(value = '2017',label = "Ending years",visible = False) |
|
exp_skill_three = gr.Dropdown(value = options, label = "Skill",multiselect = True,visible = False) |
|
|
|
|
|
|
|
|
|
exp_txt_three_1 = gr.Textbox(value = options,interactive = True,visible = False) |
|
exp_txt_three_1_out = gr.Textbox(value = options,interactive = True,visible = False,label = "Working Experience") |
|
exp_txt_three_2 = gr.Textbox(value = options,interactive = True,visible = False) |
|
exp_txt_three_2_out = gr.Textbox(value = options,interactive = True,visible = False,label = "Working Experience") |
|
exp_txt_three_3 = gr.Textbox(value = options,interactive = True,visible = False) |
|
exp_txt_three_3_out = gr.Textbox(value = options,interactive = True,visible = False,label = "Working Experience") |
|
btn_work_exp_three = gr.Button(value = "Update Working Experience Three",visible = False) |
|
|
|
|
|
|
|
with gr.Row(): |
|
exp_com_four = gr.Textbox(value = options,label="Company Name",visible = False) |
|
exp_title_four = gr.Textbox(value = options,label="Title Name",visible = False) |
|
time_beg_four = gr.Textbox(value = '2016',label = "Beginning years",visible = False) |
|
time_end_four = gr.Textbox(value = '2017',label = "Ending years",visible = False) |
|
exp_skill_four = gr.Dropdown(value = options, label = "Skill",multiselect = True,visible = False) |
|
|
|
|
|
|
|
|
|
exp_txt_four_1 = gr.Textbox(value = options,interactive = True,visible = False) |
|
exp_txt_four_1_out = gr.Textbox(value = options,interactive = True,visible = False,label = "Working Experience") |
|
exp_txt_four_2 = gr.Textbox(value = options,interactive = True,visible = False) |
|
exp_txt_four_2_out = gr.Textbox(value = options,interactive = True,visible = False,label = "Working Experience") |
|
exp_txt_four_3 = gr.Textbox(value = options,interactive = True,visible = False) |
|
exp_txt_four_3_out = gr.Textbox(value = options,interactive = True,visible = False,label = "Working Experience") |
|
btn_work_exp_four = gr.Button(value = "Update Working Experience four",visible = False) |
|
|
|
|
|
|
|
|
|
with gr.Column(): |
|
webpage_1 = gr.HTML() |
|
webpage_2 = gr.HTML() |
|
webpage_3 = gr.HTML() |
|
webpage_4 = gr.HTML() |
|
webpage_5 = gr.HTML() |
|
donate = gr.Markdown("Enjoy and generate your first AI resume. Wish you get all best offers.\n Please give your feedbacks so I can keep updating this project.\n Really appreciated for donating to the project if you like it.\n https://donate.stripe.com/7sI29DemibwjgkU4gg") |
|
btn_resume_download = gr.Button(value = "Download Resume and Donate the Project",visible = False) |
|
resume_file = gr.File(file_types = ["pdf"]) |
|
|
|
|
|
|
|
|
|
|
|
num_one = gr.Textbox("0",visible = False) |
|
num_two = gr.Textbox("1",visible = False) |
|
num_three = gr.Textbox("2",visible = False) |
|
num_four = gr.Textbox("3",visible = False) |
|
num_rand = gr.Textbox("10",visible = False) |
|
|
|
txt_key.change(Textbox_value_os,inputs = txt_key) |
|
btn_resume_info.click(Button_inact,outputs = btn_resume_info) |
|
btn_resume_info.click(company_cr, inputs = [txt_tarcom_in, txt_lang_in, txt_key], outputs = js_com_out) |
|
btn_resume_info.click(job_cr, inputs = [txt_tarjob_in, txt_lang_in,txt_key], outputs = js_title_out) |
|
btn_resume_info.click(skill_info, inputs = [txt_jd_in, txt_lang_in,txt_key], outputs = js_sec_skill_out) |
|
|
|
|
|
btn_resume_info.click(Textbox_visible,outputs = notice) |
|
btn_resume_info.click(Textbox_visible,outputs = name) |
|
btn_resume_info.click(Textbox_visible,outputs = mobile) |
|
btn_resume_info.click(Textbox_visible,outputs = email) |
|
btn_resume_info.click(Textbox_visible,outputs = Gra_beg) |
|
btn_resume_info.click(Textbox_visible,outputs = Gra_end) |
|
btn_resume_info.click(Textbox_visible,outputs = Gra_sch) |
|
btn_resume_info.click(Textbox_visible,outputs = Gra_maj) |
|
btn_resume_info.click(Textbox_visible,outputs = underGra_beg) |
|
btn_resume_info.click(Textbox_visible,outputs = underGra_end) |
|
btn_resume_info.click(Textbox_visible,outputs = underGra_sch) |
|
btn_resume_info.click(Textbox_visible,outputs = underGra_maj) |
|
|
|
|
|
btn_resume_info.click(Button_visible,outputs = btn_exp_gen) |
|
|
|
|
|
|
|
|
|
|
|
btn_exp_gen.click(resume_header,inputs=[name,mobile,email,Gra_beg,Gra_end,Gra_sch,Gra_maj,underGra_beg,underGra_end,underGra_sch,underGra_maj],outputs = webpage_1) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
js_com_out.change(Textbox_value,inputs = [js_com_out,num_one],outputs = exp_com_one) |
|
js_title_out.change(Textbox_value,inputs = [js_title_out,num_one],outputs = exp_title_one) |
|
js_sec_skill_out.change(Dropdown_value_rand,inputs = [js_sec_skill_out,num_rand],outputs = exp_skill_one) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
exp_skill_one.change(work_exp, inputs=[exp_com_one,exp_title_one,exp_skill_one,txt_lang_in,txt_key],outputs = [exp_txt_one_1,exp_txt_one_2,exp_txt_one_3]) |
|
|
|
exp_txt_one_1.change(resume_working_exp,inputs=[time_beg_one,time_end_one,exp_com_one,exp_title_one,exp_txt_one_1,exp_txt_one_2,exp_txt_one_3],outputs = webpage_2) |
|
|
|
exp_txt_one_1.change(Textbox_value_os,exp_txt_one_1,outputs = exp_txt_one_1_out) |
|
exp_txt_one_2.change(Textbox_value_os,exp_txt_one_2,outputs = exp_txt_one_2_out) |
|
exp_txt_one_3.change(Textbox_value_os,exp_txt_one_3,outputs = exp_txt_one_3_out) |
|
|
|
|
|
|
|
|
|
|
|
|
|
exp_txt_one_1.change(Textbox_visible,outputs = exp_txt_one_1_out) |
|
exp_txt_one_2.change(Textbox_visible,outputs = exp_txt_one_2_out) |
|
exp_txt_one_3.change(Textbox_visible,outputs = exp_txt_one_3_out) |
|
exp_txt_one_1.change(Textbox_visible,outputs = exp_com_one) |
|
exp_txt_one_1.change(Textbox_visible,outputs = exp_title_one) |
|
exp_txt_one_1.change(Textbox_visible,outputs = time_beg_one) |
|
exp_txt_one_1.change(Textbox_visible,outputs = time_end_one) |
|
|
|
|
|
|
|
|
|
exp_txt_one_1_out.submit(resume_working_exp,inputs=[time_beg_one,time_end_one,exp_com_one,exp_title_one,exp_txt_one_1_out,exp_txt_one_2_out,exp_txt_one_3_out],outputs = webpage_2) |
|
exp_txt_one_2_out.submit(resume_working_exp,inputs=[time_beg_one,time_end_one,exp_com_one,exp_title_one,exp_txt_one_1_out,exp_txt_one_2_out,exp_txt_one_3_out],outputs = webpage_2) |
|
exp_txt_one_3_out.submit(resume_working_exp,inputs=[time_beg_one,time_end_one,exp_com_one,exp_title_one,exp_txt_one_1_out,exp_txt_one_2_out,exp_txt_one_3_out],outputs = webpage_2) |
|
|
|
|
|
time_beg_one.submit(resume_working_exp,inputs=[time_beg_one,time_end_one,exp_com_one,exp_title_one,exp_txt_one_1_out,exp_txt_one_2_out,exp_txt_one_3_out],outputs = webpage_2) |
|
time_end_one.submit(resume_working_exp,inputs=[time_beg_one,time_end_one,exp_com_one,exp_title_one,exp_txt_one_1_out,exp_txt_one_2_out,exp_txt_one_3_out],outputs = webpage_2) |
|
exp_com_one.submit(resume_working_exp,inputs=[time_beg_one,time_end_one,exp_com_one,exp_title_one,exp_txt_one_1_out,exp_txt_one_2_out,exp_txt_one_3_out],outputs = webpage_2) |
|
exp_title_one.submit(resume_working_exp,inputs=[time_beg_one,time_end_one,exp_com_one,exp_title_one,exp_txt_one_1_out,exp_txt_one_2_out,exp_txt_one_3_out],outputs = webpage_2) |
|
|
|
|
|
|
|
js_com_out.change(Textbox_value,inputs = [js_com_out,num_two],outputs = exp_com_two) |
|
js_title_out.change(Textbox_value,inputs = [js_title_out,num_two],outputs = exp_title_two) |
|
js_sec_skill_out.change(Dropdown_value_rand,inputs = [js_sec_skill_out,num_rand],outputs = exp_skill_two) |
|
|
|
|
|
|
|
exp_txt_one_1.change(work_exp, inputs=[exp_com_two,exp_title_two,exp_skill_two,txt_lang_in,txt_key],outputs = [exp_txt_two_1,exp_txt_two_2,exp_txt_two_3]) |
|
|
|
exp_txt_two_1.change(resume_working_exp,inputs=[time_beg_two,time_end_two,exp_com_two,exp_title_two,exp_txt_two_1,exp_txt_two_2,exp_txt_two_3],outputs = webpage_3) |
|
|
|
exp_txt_two_1.change(Textbox_value_os,exp_txt_two_1,outputs = exp_txt_two_1_out) |
|
exp_txt_two_2.change(Textbox_value_os,exp_txt_two_2,outputs = exp_txt_two_2_out) |
|
exp_txt_two_3.change(Textbox_value_os,exp_txt_two_3,outputs = exp_txt_two_3_out) |
|
|
|
exp_txt_two_1.change(Textbox_visible,outputs = exp_txt_two_1_out) |
|
exp_txt_two_2.change(Textbox_visible,outputs = exp_txt_two_2_out) |
|
exp_txt_two_3.change(Textbox_visible,outputs = exp_txt_two_3_out) |
|
exp_txt_two_1.change(Textbox_visible,outputs = exp_com_two) |
|
exp_txt_two_1.change(Textbox_visible,outputs = exp_title_two) |
|
exp_txt_two_1.change(Textbox_visible,outputs = time_beg_two) |
|
exp_txt_two_1.change(Textbox_visible,outputs = time_end_two) |
|
|
|
|
|
|
|
exp_txt_two_1_out.submit(resume_working_exp,inputs=[time_beg_two,time_end_two,exp_com_two,exp_title_two,exp_txt_two_1_out,exp_txt_two_2_out,exp_txt_two_3_out],outputs = webpage_3) |
|
exp_txt_two_2_out.submit(resume_working_exp,inputs=[time_beg_two,time_end_two,exp_com_two,exp_title_two,exp_txt_two_1_out,exp_txt_two_2_out,exp_txt_two_3_out],outputs = webpage_3) |
|
exp_txt_two_3_out.submit(resume_working_exp,inputs=[time_beg_two,time_end_two,exp_com_two,exp_title_two,exp_txt_two_1_out,exp_txt_two_2_out,exp_txt_two_3_out],outputs = webpage_3) |
|
|
|
time_beg_two.submit(resume_working_exp,inputs=[time_beg_two,time_end_two,exp_com_two,exp_title_two,exp_txt_two_1_out,exp_txt_two_2_out,exp_txt_two_3_out],outputs = webpage_3) |
|
time_end_two.submit(resume_working_exp,inputs=[time_beg_two,time_end_two,exp_com_two,exp_title_two,exp_txt_two_1_out,exp_txt_two_2_out,exp_txt_two_3_out],outputs = webpage_3) |
|
exp_com_two.submit(resume_working_exp,inputs=[time_beg_two,time_end_two,exp_com_two,exp_title_two,exp_txt_two_1_out,exp_txt_two_2_out,exp_txt_two_3_out],outputs = webpage_3) |
|
exp_title_two.submit(resume_working_exp,inputs=[time_beg_two,time_end_two,exp_com_two,exp_title_two,exp_txt_two_1_out,exp_txt_two_2_out,exp_txt_two_3_out],outputs = webpage_3) |
|
|
|
|
|
|
|
|
|
js_com_out.change(Textbox_value,inputs = [js_com_out,num_three],outputs = exp_com_three) |
|
js_title_out.change(Textbox_value,inputs = [js_title_out,num_one],outputs = exp_title_three) |
|
js_sec_skill_out.change(Dropdown_value_rand,inputs = [js_sec_skill_out,num_rand],outputs = exp_skill_three) |
|
|
|
|
|
|
|
exp_txt_two_1.change(work_exp, inputs=[exp_com_three,exp_title_three,exp_skill_three,txt_lang_in,txt_key],outputs = [exp_txt_three_1,exp_txt_three_2,exp_txt_three_3]) |
|
exp_txt_three_1.change(resume_working_exp,inputs=[time_beg_three,time_end_three,exp_com_three,exp_title_three,exp_txt_three_1,exp_txt_three_2,exp_txt_three_3],outputs = webpage_4) |
|
|
|
exp_txt_three_1.change(Textbox_value_os,exp_txt_three_1,outputs = exp_txt_three_1_out) |
|
exp_txt_three_2.change(Textbox_value_os,exp_txt_three_2,outputs = exp_txt_three_2_out) |
|
exp_txt_three_3.change(Textbox_value_os,exp_txt_three_3,outputs = exp_txt_three_3_out) |
|
|
|
exp_txt_three_1.change(Textbox_visible,outputs = exp_txt_three_1_out) |
|
exp_txt_three_2.change(Textbox_visible,outputs = exp_txt_three_2_out) |
|
exp_txt_three_3.change(Textbox_visible,outputs = exp_txt_three_3_out) |
|
exp_txt_three_1.change(Textbox_visible,outputs = exp_com_three) |
|
exp_txt_three_1.change(Textbox_visible,outputs = exp_title_three) |
|
exp_txt_three_1.change(Textbox_visible,outputs = time_beg_three) |
|
exp_txt_three_1.change(Textbox_visible,outputs = time_end_three) |
|
|
|
exp_txt_three_1_out.submit(resume_working_exp,inputs=[time_beg_three,time_end_three,exp_com_three,exp_title_three,exp_txt_three_1_out,exp_txt_three_2_out,exp_txt_three_3_out],outputs = webpage_4) |
|
exp_txt_three_2_out.submit(resume_working_exp,inputs=[time_beg_three,time_end_three,exp_com_three,exp_title_three,exp_txt_three_1_out,exp_txt_three_2_out,exp_txt_three_3_out],outputs = webpage_4) |
|
exp_txt_three_3_out.submit(resume_working_exp,inputs=[time_beg_three,time_end_three,exp_com_three,exp_title_three,exp_txt_three_1_out,exp_txt_three_2_out,exp_txt_three_3_out],outputs = webpage_4) |
|
|
|
time_beg_three.submit(resume_working_exp,inputs=[time_beg_three,time_end_three,exp_com_three,exp_title_three,exp_txt_three_1_out,exp_txt_three_2_out,exp_txt_three_3_out],outputs = webpage_4) |
|
time_end_three.submit(resume_working_exp,inputs=[time_beg_three,time_end_three,exp_com_three,exp_title_three,exp_txt_three_1_out,exp_txt_three_2_out,exp_txt_three_3_out],outputs = webpage_4) |
|
exp_com_three.submit(resume_working_exp,inputs=[time_beg_three,time_end_three,exp_com_three,exp_title_three,exp_txt_three_1_out,exp_txt_three_2_out,exp_txt_three_3_out],outputs = webpage_4) |
|
exp_title_three.submit(resume_working_exp,inputs=[time_beg_three,time_end_three,exp_com_three,exp_title_three,exp_txt_three_1_out,exp_txt_three_2_out,exp_txt_three_3_out],outputs = webpage_4) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
js_com_out.change(Textbox_value,inputs = [js_com_out,num_four],outputs = exp_com_four) |
|
js_title_out.change(Textbox_value,inputs = [js_title_out,num_one],outputs = exp_title_four) |
|
js_sec_skill_out.change(Dropdown_value_rand,inputs = [js_sec_skill_out,num_rand],outputs = exp_skill_four) |
|
|
|
|
|
|
|
exp_txt_three_1.change(work_exp, inputs=[exp_com_four,exp_title_four,exp_skill_four,txt_lang_in,txt_key],outputs = [exp_txt_four_1,exp_txt_four_2,exp_txt_four_3]) |
|
exp_txt_four_1.change(resume_working_exp,inputs=[time_beg_four,time_end_four,exp_com_four,exp_title_four,exp_txt_four_1,exp_txt_four_2,exp_txt_four_3],outputs = webpage_5) |
|
|
|
exp_txt_four_1.change(Textbox_value_os,exp_txt_four_1,outputs = exp_txt_four_1_out) |
|
exp_txt_four_2.change(Textbox_value_os,exp_txt_four_2,outputs = exp_txt_four_2_out) |
|
exp_txt_four_3.change(Textbox_value_os,exp_txt_four_3,outputs = exp_txt_four_3_out) |
|
|
|
exp_txt_four_1.change(Textbox_visible,outputs = exp_txt_four_1_out) |
|
exp_txt_four_2.change(Textbox_visible,outputs = exp_txt_four_2_out) |
|
exp_txt_four_3.change(Textbox_visible,outputs = exp_txt_four_3_out) |
|
exp_txt_four_1.change(Textbox_visible,outputs = exp_com_four) |
|
exp_txt_four_1.change(Textbox_visible,outputs = exp_title_four) |
|
exp_txt_four_1.change(Textbox_visible,outputs = time_beg_four) |
|
exp_txt_four_1.change(Textbox_visible,outputs = time_end_four) |
|
|
|
exp_txt_four_1_out.submit(resume_working_exp,inputs=[time_beg_four,time_end_four,exp_com_four,exp_title_four,exp_txt_four_1_out,exp_txt_four_2_out,exp_txt_four_3_out],outputs = webpage_5) |
|
exp_txt_four_2_out.submit(resume_working_exp,inputs=[time_beg_four,time_end_four,exp_com_four,exp_title_four,exp_txt_four_1_out,exp_txt_four_2_out,exp_txt_four_3_out],outputs = webpage_5) |
|
exp_txt_four_3_out.submit(resume_working_exp,inputs=[time_beg_four,time_end_four,exp_com_four,exp_title_four,exp_txt_four_1_out,exp_txt_four_2_out,exp_txt_four_3_out],outputs = webpage_5) |
|
|
|
time_beg_four.submit(resume_working_exp,inputs=[time_beg_four,time_end_four,exp_com_four,exp_title_four,exp_txt_four_1_out,exp_txt_four_2_out,exp_txt_four_3_out],outputs = webpage_5) |
|
time_end_four.submit(resume_working_exp,inputs=[time_beg_four,time_end_four,exp_com_four,exp_title_four,exp_txt_four_1_out,exp_txt_four_2_out,exp_txt_four_3_out],outputs = webpage_5) |
|
exp_com_four.submit(resume_working_exp,inputs=[time_beg_four,time_end_four,exp_com_four,exp_title_four,exp_txt_four_1_out,exp_txt_four_2_out,exp_txt_four_3_out],outputs = webpage_5) |
|
exp_title_four.submit(resume_working_exp,inputs=[time_beg_four,time_end_four,exp_com_four,exp_title_four,exp_txt_four_1_out,exp_txt_four_2_out,exp_txt_four_3_out],outputs = webpage_5) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
exp_txt_three_1.change(Button_act,outputs = btn_resume_info) |
|
btn_exp_gen.click(Button_visible,outputs = btn_resume_download) |
|
|
|
|
|
|
|
btn_resume_download.click(resume,inputs = [name,mobile,email,Gra_beg,Gra_end,Gra_sch,Gra_maj,underGra_beg,underGra_end,underGra_sch,underGra_maj,time_beg_one,time_end_one,exp_com_one,exp_title_one,exp_txt_one_1,exp_txt_one_2,exp_txt_one_3,time_beg_two,time_end_two,exp_com_two,exp_title_two,exp_txt_two_1,exp_txt_two_2,exp_txt_two_3,time_beg_three,time_end_three,exp_com_three,exp_title_three,exp_txt_three_1,exp_txt_three_2,exp_txt_three_3,time_beg_four,time_end_four,exp_com_four,exp_title_four,exp_txt_four_1,exp_txt_four_2,exp_txt_four_3],outputs = resume_file) |
|
|
|
|
|
if __name__ == "__main__": |
|
demo.launch(enable_queue = True) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|