AGENT SKILL
class-imbalance
What to do when one class is rare.
- License 许可
- MIT
- 最近更新
- 2026-10-25
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- class-imbalance
- metadata
- { "beyondml": { "kind": "knowledge" } }
- description
- What to do when one class is rare.
03 SKILL.md 正文
- Below about 20% minority share, accuracy misleads; use F1 or recall.
- Prefer class_weight="balanced" (the search applies it when the profile flags imbalance) over resampling.
- Stratify every split so the rare class appears in train and test.
- Do not oversample before splitting; that leaks copies of test rows into training.
04 同仓库更多 Skills
tabular-demo
Demo step skill for tabular data.
★ 0
leakage-demo
Demo knowledge skill about target leakage.
★ 0
bad-name
Name does not match its folder.
★ 0
train-test-split
How to split data so the score is honest.
★ 0
tabular-features
Writes src/features.py with derived features (ratios, logs, interactions) and no target use. Usually right after tabular-eda. Check: run src/features.py, expects data/processed/features.csv.
★ 0
tabular-export
Writes the shipped code (src/pipeline.py, src/train.py, src/predict.py) from the winning run and trains it. Usually right after evolve-search or tabular-ensemble. Check: run src/train.py, expects models/model.joblib, metric accuracy (classification) or r2 (regression) with a minimum.
★ 0