varshamishra commited on
Commit
71b7d4c
·
verified ·
1 Parent(s): d5852a2

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +5 -6
README.md CHANGED
@@ -57,15 +57,14 @@ cleaned_resume_skills = clean_text(" ".join(resume_skills) if isinstance(resume_
57
 
58
  def clean_text(text):
59
  if isinstance(text, list):
60
- text = " ".join(text) # Join list elements into a single string
61
  elif text is None:
62
- text = "" # Replace None with an empty string
63
-
64
- text = re.sub(r'[^\w\s]', '', str(text)) # Convert to string and remove special characters
65
- text = text.lower() # Convert to lowercase
66
  return text
67
 
68
- cleaned_resume_skills = clean_text(resume_skills) # Now works with lists!
69
 
70
  vectorizer = CountVectorizer(stop_words='english')
71
  job_desc_matrix = vectorizer.fit_transform(df['cleaned_job_info'])
 
57
 
58
  def clean_text(text):
59
  if isinstance(text, list):
60
+ text = " ".join(text)
61
  elif text is None:
62
+ text = ""
63
+ text = re.sub(r'[^\w\s]', '', str(text))
64
+ text = text.lower()
 
65
  return text
66
 
67
+ cleaned_resume_skills = clean_text(resume_skills)
68
 
69
  vectorizer = CountVectorizer(stop_words='english')
70
  job_desc_matrix = vectorizer.fit_transform(df['cleaned_job_info'])