技能创建器
skill-creator
创建、改进和评估自定义技能,把专业流程转化为可重复使用的 AI 能力。
river【数据与研究】Use River for online machine learning with streaming estimators, pipelines, datasets, progressive evaluation, drift, anomaly, clustering, forecasting, bandits, and recommender workflows.
独立 GitHub 快照 · 自动分类 · 以原作者文档为准
Use this skill when a task involves River, online machine learning, one-sample-at-a-time estimators, dictionary feature streams, progressive validation, concept drift, or River package maintenance.
pip install river.pip install "river[pandas]".import river
from river import compose, linear_model, metrics, preprocessing
model = preprocessing.StandardScaler() | linear_model.LogisticRegression()
metric = metrics.Accuracy()
Run scripts/check_river_environment.py when installation, Rust-extension import, or quickstart behavior is uncertain.
| Task | Read |
|---|---|
Estimator lifecycle, learn_one, predict_one, transform_one, base classes, tags, cloning, mutation, generic checks, new-estimator compatibility. | sub-skills/online-core-api/SKILL.md |
| Pipelines, ` | , +, *, selectors, feature unions, preprocessing, feature extraction, online statistics, target aggregation, learn_during_predict`, pipeline debugging. |
| Built-in datasets, stream adapters, CSV/array/dataframe ingestion, progressive validation, delayed labels, sample weights, metrics, metric/model compatibility. | sub-skills/streaming-evaluation/SKILL.md |
| Supervised classification/regression model families, linear models, optimizers/losses, trees, forests, ensembles, naive Bayes, neighbors, multiclass/multioutput/model-selection/compat wrappers. | sub-skills/supervised-models/SKILL.md |
| Concept drift, anomaly detection, clustering, forecasting/time series, bandits, recommenders, factorization machines in sparse interaction workflows, imbalanced learning, probability utilities. | sub-skills/specialized-workflows/SKILL.md |
references/api-map.md for public module-family routing and task-to-sub-skill mapping.references/troubleshooting.md for installation, import, Rust extension, optional dependency, and cross-cutting runtime failures.references/development-and-verification.md when editing a River checkout or choosing focused tests.references/repo-provenance.md before deciding whether this generated skill is stale for a checkout.from river import compose, linear_model, metrics, preprocessing
model = preprocessing.StandardScaler() | linear_model.LogisticRegression()
metric = metrics.Accuracy()
for x, y in stream:
y_pred = model.predict_one(x)
if y_pred is not None:
metric.update(y, y_pred)
model.learn_one(x, y)
Use evaluate.progressive_val_score instead of a manual loop when the task is standard online evaluation or delayed progressive validation.
*_one API is dictionary-based and does not require pandas.*_many APIs and some dataframe workflows.From this skill directory, run only the scripts that match the task:
python scripts/check_river_environment.py
python sub-skills/online-core-api/scripts/estimator_contract_smoke.py
python sub-skills/pipelines-and-features/scripts/pipeline_feature_smoke.py
python sub-skills/streaming-evaluation/scripts/stream_evaluation_smoke.py
python sub-skills/supervised-models/scripts/supervised_model_smoke.py
python sub-skills/specialized-workflows/scripts/specialized_workflows_smoke.py