LeoWalker commited on
Commit
89c233a
1 Parent(s): d8f42ac

increased max retires to handle mistral

Browse files
Files changed (3) hide show
  1. app.py +3 -3
  2. leoBaseProfile.json +96 -0
  3. profile_extenders.py +19 -0
app.py CHANGED
@@ -75,7 +75,7 @@ def extract_resume_fields(full_text, model):
75
  llm = llm_dict.get(model, ChatOpenAI(temperature=0, model=model))
76
 
77
  chain = prompt_template | llm | parser
78
- max_attempts = 2
79
  attempt = 1
80
 
81
  while attempt <= max_attempts:
@@ -159,7 +159,7 @@ if uploaded_file is not None:
159
  end_time = time.time()
160
  elapsed_time = end_time - start_time
161
  st.write(f"Extraction completed in {elapsed_time:.2f} seconds")
162
- display_extracted_fields(extracted_fields1, "Extracted Resume Fields (Model 1)")
163
 
164
  with col2:
165
  start_time = time.time()
@@ -167,4 +167,4 @@ if uploaded_file is not None:
167
  end_time = time.time()
168
  elapsed_time = end_time - start_time
169
  st.write(f"Extraction completed in {elapsed_time:.2f} seconds")
170
- display_extracted_fields(extracted_fields2, "Extracted Resume Fields (Model 2)")
 
75
  llm = llm_dict.get(model, ChatOpenAI(temperature=0, model=model))
76
 
77
  chain = prompt_template | llm | parser
78
+ max_attempts = 3
79
  attempt = 1
80
 
81
  while attempt <= max_attempts:
 
159
  end_time = time.time()
160
  elapsed_time = end_time - start_time
161
  st.write(f"Extraction completed in {elapsed_time:.2f} seconds")
162
+ display_extracted_fields(extracted_fields1, f"{selected_model1} Extracted Fields ")
163
 
164
  with col2:
165
  start_time = time.time()
 
167
  end_time = time.time()
168
  elapsed_time = end_time - start_time
169
  st.write(f"Extraction completed in {elapsed_time:.2f} seconds")
170
+ display_extracted_fields(extracted_fields2, f"{selected_model2} Extracted Fields ")
leoBaseProfile.json ADDED
@@ -0,0 +1,96 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "personal_details": {
3
+ "full_name": "Leo Walker",
4
+ "contact_info": {
5
+ "email": "[email protected]",
6
+ "phone": "(571) 294-9678",
7
+ "linkedin": "linkedin.com/in/leowalker"
8
+ },
9
+ "professional_summary": "Data Scientist with expertise in Python, SQL, Data Visualization, Machine Learning, NLP, LLMs, LangChain, and LlamaIndex."
10
+ },
11
+ "education": [
12
+ {
13
+ "institution": "University of Denver",
14
+ "degree": "MS",
15
+ "field_of_study": "Data Science",
16
+ "graduation_date": "November 2023"
17
+ },
18
+ {
19
+ "institution": "Ranger School - the Army\u2019s Premier Leadership School",
20
+ "degree": null,
21
+ "field_of_study": null,
22
+ "graduation_date": "April 2012"
23
+ },
24
+ {
25
+ "institution": "Virginia Military Institute",
26
+ "degree": "BS",
27
+ "field_of_study": "Electrical and Computer Engineering",
28
+ "graduation_date": "May 2011"
29
+ }
30
+ ],
31
+ "work_experience": [
32
+ {
33
+ "company": "IVP",
34
+ "title": "Data Scientist",
35
+ "duration": "August 2022 - September 2023",
36
+ "description": "",
37
+ "notable_contributions": [
38
+ "Orchestrated comprehensive performance analysis using SQL and Python to pinpoint promising investment opportunities guided by historical investment success metrics.",
39
+ "Improved investor engagement with 60% faster email crafting using optimized LLM pipelines.",
40
+ "Increased accuracy and transparency of peer comparisons by implementing a refined distribution algorithm in company performance assessments."
41
+ ]
42
+ },
43
+ {
44
+ "company": "BP",
45
+ "title": "Data Scientist",
46
+ "duration": "February 2018 - August 2022",
47
+ "description": "",
48
+ "notable_contributions": [
49
+ "Developed an automated GreenHouse Gas report that reduced lead time by two weeks and saved 300 man-hours annually while increasing KPI transparency across leadership levels.",
50
+ "Established strategic partnerships with stakeholders at all levels to enhance safety awareness through an NLP tool, leading to a 15% decrease in safety events.",
51
+ "Developed an IT-wide portfolio tracker that integrated directly into MS DevOps to provide a single point where leaders across the organization can track project progress."
52
+ ]
53
+ },
54
+ {
55
+ "company": "US Army, Special Operations Command",
56
+ "title": "Distribution Platoon Leader",
57
+ "duration": "May 2014 - April 2017",
58
+ "description": "Led a cross-functional team of 28 and controlled an annual budget of $111MM.",
59
+ "notable_contributions": [
60
+ "Managed development of 1st mobile performance appraisal app, decreasing delivery time by 80%."
61
+ ]
62
+ },
63
+ {
64
+ "company": null,
65
+ "title": "Data Analyst",
66
+ "duration": "April 2017 - February 2018",
67
+ "description": "Led development project leveraging localized drilling data to provide focused drilling directives, potentially saving $300K per well with projected productivity gains valued at $43.2MM in 2019.",
68
+ "notable_contributions": [
69
+ "Developed a KPI dashboard to increase safety incident awareness across the company, resulting in robust data collection and strategy sessions to distribute lessons learned and reduce incidents."
70
+ ]
71
+ }
72
+ ],
73
+ "projects": [],
74
+ "skills": [
75
+ "Python",
76
+ "SQL",
77
+ "Data Visualization",
78
+ "Machine Learning",
79
+ "NLP",
80
+ "LLMs",
81
+ "LangChain",
82
+ "PyTorch"
83
+ ],
84
+ "certifications": [
85
+ "Certified ScrumMaster",
86
+ "PMI Agile Certified Practitioner (PMP-ACP)",
87
+ "Project Management Professional (PMP)"
88
+ ],
89
+ "publications": [],
90
+ "awards": [],
91
+ "additional_sections": {
92
+ "volunteer_experience": [],
93
+ "languages": [],
94
+ "interests": []
95
+ }
96
+ }
profile_extenders.py ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from typing import List, Optional, Dict
2
+ from langchain_core.pydantic_v1 import BaseModel, Field
3
+
4
+ class BlogPost(BaseModel):
5
+ title: Optional[str] = None
6
+ url: Optional[str] = None
7
+ date: Optional[str] = None
8
+ summary: Optional[str] = None
9
+
10
+ class Hackathon(BaseModel):
11
+ name: Optional[str] = None
12
+ date: Optional[str] = None
13
+ description: Optional[str] = None
14
+ role: Optional[str] = None
15
+ achievements: Optional[List[str]] = None
16
+
17
+ class OtherInfo(BaseModel):
18
+ category: Optional[str] = None
19
+ description: Optional[str] = None