feat: optional [shap] extra + SHAP plot helper for donor scores

Abierto
#5 1 comentario 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
54/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
matplotlib, python, scikit-learn

Línea de trabajo

Start with philanthropy.inspection.donor_feature_importance and examples/method_reference_lalakiya2025.py to understand the existing permutation-importance interface and example. Then inspect the project’s optional-dependency configuration and estimator tests; done means SHAP is installable through the shap extra, an opt-in helper can produce a summary/beeswarm plot for fitted estimators, and core dependencies and default behavior remain unchanged.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

roadmap

philanthropy.inspection.donor_feature_importance gives permutation-based feature attribution for fitted estimators (dependency-free). The method in the ICCED 2025 paper (DOI 10.1109/ICCED68324.2025.11325064) leans on SHAP for the same "which signals move the score" story.

Proposal

  • Add an optional extra: pip install philanthropy[shap].
  • Ship a thin helper wrapping SHAP for fitted PhilanthroPy estimators, plus a summary/beeswarm plot.
  • Keep SHAP out of core deps (core is scikit-learn / pandas / numpy / joblib; matplotlib and seaborn are the optional viz extra).
  • Permutation importance stays the default; SHAP is opt-in.

Pairs naturally with examples/method_reference_lalakiya2025.py, which currently uses permutation importance as the SHAP analog.

Lenguaje dominante
Python
Estrellas
11
Forks
23
Merge medio
1 d 11 h
PR fusionados (30 d)
30

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de PhilanthroPy-Project/PhilanthroPy

Todos los issues de PhilanthroPy-Project/PhilanthroPy

Issues similares

Más issues de Python

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.