AI-based volunteer matching system
Volunteer management platforms often face a mismatch problem: dozens of unfilled positions alongside unengaged volunteers. AI matching finds optimal matches based on skills, availability, location, and preferences, increasing the fill rate by 40-60%.
Smart Matching Volunteer - Position
import pandas as pd
import numpy as np
from anthropic import Anthropic
def match_volunteers_to_positions(volunteers: pd.DataFrame,
positions: pd.DataFrame,
top_k: int = 3) -> list[dict]:
"""
Двусторонний матчинг: находим лучших кандидатов для каждой позиции.
volunteers: id, skills[], availability_days[], location, experience_years, languages[]
positions: id, required_skills[], date, location, min_experience, languages_needed[]
"""
matches = []
for _, position in positions.iterrows():
scored = []
for _, volunteer in volunteers.iterrows():
# Навыки
vol_skills = set(volunteer.get('skills', []))
req_skills = set(position.get('required_skills', []))
skill_match = len(vol_skills & req_skills) / max(len(req_skills), 1)
if skill_match == 0:
continue # Нет обязательных навыков — пропускаем
# Доступность
pos_date = str(position.get('date', ''))
available = pos_date in volunteer.get('availability_days', []) or not pos_date
if not available:
continue
# Локация (расстояние или совпадение города)
location_match = int(volunteer.get('location') == position.get('location'))
# Язык
pos_lang = set(position.get('languages_needed', []))
vol_lang = set(volunteer.get('languages', ['ru']))
lang_match = int(bool(pos_lang.issubset(vol_lang)) or not pos_lang)
# Опыт
min_exp = position.get('min_experience_years', 0)
exp_match = min(1.0, volunteer.get('experience_years', 0) / max(min_exp, 1))
score = (
skill_match * 0.45 +
location_match * 0.25 +
lang_match * 0.15 +
exp_match * 0.15
)
scored.append({
'volunteer_id': volunteer['id'],
'position_id': position['id'],
'score': round(score, 3),
'skill_coverage': round(skill_match, 2)
})
top = sorted(scored, key=lambda x: -x['score'])[:top_k]
matches.extend(top)
return matches
AI-based volunteer matching reduces the time it takes to fill positions from 5-7 days to 1-2 days and increases volunteer retention: when a person is matched to a suitable role, the likelihood of repeat participation increases by 35-45%.







