INNER CODE UNIT · Python
days
LiuMengxuan04/shushu-internship-tool · skills/shushu-internship-tool/scripts/shushu_internship_tool/candidate_score.py:115
days = max((today - commit_date).days, 0)
if days <= 180:
return 10, "active within 180 days"
if days <= 365:
return 7, "active within 1 year"
if days <= 730:
return 4, "active within 2 years"
return 1, "inactive for more than 2 years"
def stars_score(raw: Any) -> tuple[int, str]:
stars = safe_int(raw)
if stars >= 1000:
return 10, "strong community signal"
if stars >= 200:
return 8, "good community signal"
if stars >= 50:
return 6, "some community signal"