Skip to content

Commit

Permalink
fix formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
India Kerle committed May 8, 2024
1 parent 321f09a commit 7f47cb3
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 7 deletions.
1 change: 1 addition & 0 deletions ojd_daps_skills/extract_skills/extract_skills_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Utility functions and a configuration manager for
extracting skills from job descriptions.
"""

import os
from typing import List, Optional

Expand Down
1 change: 1 addition & 0 deletions ojd_daps_skills/extract_skills/multiskill_rules.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Phrase splitting rules for multi-skill phrases.
"""

import re
from typing import List

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -155,10 +155,10 @@ def remove_bad_hierarchy_levels(hierarchy_levels):
lightcast_formatted = pd.concat(
[all_skills, category_skills, subcategory_skills]
).reset_index(drop=True)
lightcast_formatted[
"hierarchy_levels"
] = lightcast_formatted.hierarchy_levels.apply(map_subcategory_ids).apply(
remove_bad_hierarchy_levels
lightcast_formatted["hierarchy_levels"] = (
lightcast_formatted.hierarchy_levels.apply(map_subcategory_ids).apply(
remove_bad_hierarchy_levels
)
)
lightcast_formatted = lightcast_formatted.query("description.notna()").query(
'description != "NULL"'
Expand Down
6 changes: 3 additions & 3 deletions ojd_daps_skills/map_skills/skill_mapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,9 +219,9 @@ def map_skills(self, job_ads: List[Doc]) -> List[Dict[str, Any]]:
high_hier_codes += [hier_level] * round(sim_score * 10)
high_tax_skills_results = {}
for hier_level in range(self.config.taxonomy_config["num_hier_levels"]):
high_tax_skills_results[
"most_common_level_" + str(hier_level)
] = get_most_common_code(high_hier_codes, hier_level)
high_tax_skills_results["most_common_level_" + str(hier_level)] = (
get_most_common_code(high_hier_codes, hier_level)
)

if high_tax_skills_results:
match_results["high_tax_skills"] = high_tax_skills_results
Expand Down
1 change: 1 addition & 0 deletions ojd_daps_skills/utils/text_cleaning.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Text cleaning utilities for the skills extraction pipeline.
"""

import re
from hashlib import md5

Expand Down

0 comments on commit 7f47cb3

Please sign in to comment.