detectors-and-explainers
Use AIF360 MDSS and FACTS subgroup detectors plus metric text and JSON explainers.
- License 许可
- Apache-2.0
- 最近更新
- 2026-09-03
- Stars
- ★ 351
- Forks
- 27
01 前言 Front Matter
- name
- detectors-and-explainers
- license
- Apache 2.0
- metadata
- { "disco-role": "operating" }
- description
- Use AIF360 MDSS and FACTS subgroup detectors plus metric text and JSON explainers.
- disable-model-invocation
- true
02 资源文件 6
- 参考文档references/explainer-reference.md2.9 KB
- 参考文档references/facts-workflow.md2.3 KB
- 参考文档references/mdss-workflow.md3.0 KB
- 参考文档references/troubleshooting.md3.4 KB
- 脚本scripts/explainer_smoke.py2.7 KB
- 脚本scripts/mdss_smoke.py2.1 KB
03 SKILL.md 正文
AIF360 Detectors and Explainers
Use this sub-skill when a task asks for subgroup bias scanning, MDSS/FACTS detectors, or text/JSON explanations of AIF360 metric objects.
Start here
- Read mdss-workflow.md for legacy and sklearn
bias_scansignatures, inputs, modes, scoring choices, and output handling. - Read facts-workflow.md for optional FACTS counterfactual subgroup-recourse workflows and dependency requirements.
- Read explainer-reference.md for
MetricTextExplainerandMetricJSONExplainerusage with metric objects. - Read troubleshooting.md when labels, probabilities, indexes, optional extras, or metric objects do not match.
- Use mdss_smoke.py or explainer_smoke.py for no-download base smoke checks.
Route by user intent
| User asks for... | Use this route |
|---|---|
| "Find a subgroup with unusually high error or bias" | Use MDSS bias_scan; read mdss-workflow.md. |
| "Score a known subgroup with MDSS inside classification metrics" | Use MDSSClassificationMetric via datasets-and-metrics, then return here for scan interpretation if needed. |
| "Find subgroups that have worse recourse/counterfactual action costs" | Use optional FACTS; read facts-workflow.md. |
| "Explain what this metric means in text or JSON" | Use explainer-reference.md. |
| "Compute fairness metrics before scanning" | Route to ../datasets-and-metrics/SKILL.md for legacy metrics or ../sklearn-interface/SKILL.md for pandas metrics. |
| "Mitigate bias after detecting a problem" | Route to ../mitigation-algorithms/SKILL.md. |
Detector/explainer distinction
- MDSS detectors search for subgroups whose observed outcomes differ from expectations under a scoring function.
- FACTS searches for subgroups with unequal counterfactual recourse cost or effectiveness; it is optional-extra gated.
- Metric explainers wrap an existing AIF360 metric object and render method outputs in human-readable text or structured JSON; they do not compute new metrics independently.
Safe smoke checks
python sub-skills/detectors-and-explainers/scripts/mdss_smoke.py --json
python sub-skills/detectors-and-explainers/scripts/explainer_smoke.py --json
Both scripts use synthetic in-memory data and require only the base package surface that was verified for this skill construction run.
04 同仓库更多 Skills
passnet-triton-opt
Make a single PassNet Triton kernel fast AND numerically faithful: performance model (when a replacement can win at all), block/grid/warp tuning, autotune policy, launch overhead, and per-op numeric recipes to pass the dtype baseline tolerances. Use when a pass matches and is correct but speedup below expected, or when correctness fails by small numeric margins.
passnet-solve
END-TO-END playbook for solving one PassNet sample: analyze the computation graphs, decide the optimization strategy (what to fuse, what to replace, what to leave alone), drive the iteration loop, and maximize the sample score. This is the ENTRY skill — invoke it first for any PassNet optimization task; it tells you when to use passnet-pattern-fusion, passnet-triton-opt and passnet-feedback.
passnet-skill
PassNet GPU kernel optimization via compiler passes. Design and implement Triton-based optimization passes, create pass files under ./pass_dir/, self-evaluate with pass_evaluator, and iterate to maximize GPU speedup.
passnet-pattern-fusion
Author PassNet pass files: write patterns that actually MATCH the FX graph, pick fusion regions (which ops to absorb into one Triton kernel), and structure multi-pass submissions with the mandatory shared-dispatch architecture. Use when creating or fixing pattern()/replacement_args()/replacement_func() files, when a pass "failed to match", or when deciding how to fuse multiple kernels/ops.
passnet-orchestrate
Round/batch planning and decision support for PassNet graph optimization. Use for multi-sample triage, worker allocation, eval-budget policy, and post-eval keep/revert decisions. For solving one concrete sample end to end, use passnet-solve as the entry skill; consult this skill only when you need broader planning or a specific decision gate.
passnet-feedback
Fast, deterministic feedback for PassNet work: pre-flight pattern/match verification WITHOUT burning a GPU evaluation, per-node bottleneck analysis of a sample's graphs, and eval-log parsing into per-variant status + estimated score + failure classification. Use BEFORE every GPU evaluation (check_pattern), at the START of a sample (analyze_graph), and AFTER every evaluation (parse_eval_log).