ml-pipeline
Machine learning pipeline for scientific research including data preprocessing, feature engineering, model selection, training, evaluation, and interpretation.
Skill by beita6969
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/beita6969-ml-pipeline
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: data, ml, research
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/ml-pipeline
What's inside
- Skill name
ml-pipeline- Description
- Machine learning pipeline for scientific research including data preprocessing, feature engineering, model selection, training, evaluation, and interpretation. Covers supervised/unsupervised learning, deep learning, cross-validation, hyperparameter tuning, and model explainability. Use when user asks to build a predictive model, classify data, cluster samples, do feature selection, or apply ML to research data. Triggers on "machine learning", "classification", "clustering", "random forest", "neural network", "deep learning", "predict", "feature selection", "cross-validation", "train model".
- License
- MIT
- Instructions
- 123 lines in SKILL.md · view on GitHub
Agent Skills spec issues
- body: contains an absolute path from the author's machine
Files (1)
- SKILL.md
SKILL.md (first lines)
# ML Pipeline
Machine learning for scientific research. Venv: `source /Users/zhangmingda/clawd/.venv/bin/activate`
## Pipeline Overview
```
Data → Clean → Features → Split → Train → Evaluate → Interpret → Report
```
## Model Selection Guide
| Task | Data Size | Interpretability Need | Recommended |
|------|-----------|----------------------|-------------|
| Classification (small) | < 10K | High | Logistic Regression, Decision Tree |
| Classification (medium) | 10K-100K | Medium | Random Forest, XGBoost |
| Classification (large) | > 100K | Low OK | Neural Network, XGBoost |
| Regression (linear) | Any | High | Linear/Ridge/Lasso |
| Regression (nonlinear) | Medium+ | Medium | Random Forest, Gradient Boosting |
| Clustering | Any | Medium | K-Means, DBSCAN, Hierarchical |
| Dimensionality reduction | Any | Medium | PCA, t-SNE, UMAP |
| Anomaly detection | Any | Medium | Isolation Forest, LOF |
| Time series | Any | Varies | ARIMA, Prophet, LSTM |
## Standard Pipeline
```python
import numpy as np
import pandas as pd
from sklearn.model_selection import train_test_split, cross_val_score, GridSearchCV
from sklearn.preprocessing import StandardScaler, LabelEncoder
from sklearn.metrics import classification_report, confusion_matrix, roc_auc_score
from sklearn.ensemble import RandomForestClassifier, GradientBoostingClassifier
from sklearn.linear_model import LogisticRegression
from sklearn.pipeline import Pipeline
# 1. Preprocessing
X = df.drop('target', axis=1)
y = df['target']
X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.2, random_state=42, stratify=y)
# 2. Pipeline with scaling
pipe = Pipeline([
('scaler', StandardScaler()),
('model', RandomForestClassifier(random_state=42))
])
# 3. Cross-validation
scores = cross_val_score(pipe, X_train, y_train, cv=5, scoring='roc_auc')
print(f"CV AUC: {scores.mean():.3f} ± {scores.std():.3f}")
# 4. Hyperparameter tuning
param_grid = {
'model__n_estimators': [100, 300, 500],
'model__max_depth': [5, 10, None],
'model__min_samples_leaf': [1, 5, 10]
}
grid = GridSearchCV(pipe, param_grid, cv=5, scoring='roc_auc', n_jobs=-1)
grid.fit(X_train, y_train)
# 5. Evaluation
y_pred = grid.predict(X_test)
print(classification_report(y_test, y_pred))
print(f"Test AUC: {roc_auc_score(y_test, grid.predict_proba(X_test)[:,1]):.3f}")
```
## Feature Importance & Explainability
```python
# Built-in importance (tree models)
importances = grid.best_estimator_.named_steps['model'].feature_importances_
feat_imp = pd.Series(importances, index=X.columns).sort_values(ascending=False)
# SHAP values (model-agnostic)
# pip install shap
import shap
explainer = shap.TreeExplainer(model)
shap_values = explainer.shap_values(X_test)
shap.summary_plot(shap_values, X_test)
```
## Unsupervised Learning
```python
from sklearn.cluster import KMeans, DBSCAN
from sklearn.decomposition import PCA
from sklearn.manifold import TSNE
# PCA
pca = PCA(n_components=0.95) # retain 95% variance
X_pca = pca.fit_transform(X_scaled)
print(f"Components: {pca.n_components_}, Explained variance: {pca.explained_variance_ratio_.cumsum()[-1]:.3f}")
# K-Means with elbow method
inertias = [KMeans(n_clusters=k, random_state=42).fit(X_scaled).inertia_ for k in range(2, 11)]
# t-SNE visualization
X_tsne = TSNE(n_components=2, random_state=42, perplexity=30).fit_transform(X_scaled)
```
## Reporting ML Results in Papers
Always include:
1. Dataset description (size, features, class balance)
2. Preprocessing steps
3. Model selection rationale
4. Cross-validation strategy (k-fold, stratified, leave-one-out)
5. Hyperparameter search space and method
6. Multiple metrics (accuracy, precision, recall, F1, AUC)
7. Comparison with baselines
8. Feature importance / model interpretation
9. Confidence intervals or statistical tests on performance
10. Code/data availability statement
## Tips
- Always use stratified splits for imbalanced data
- Report multiple metrics, not just accuracy
- Compare against simple baselines (majority class, mean prediction)
- Use nested CV for unbiased performance estimationFrom beita6969/ScienceClaw, MIT.
More from beita6969/ScienceClaw
- 0.608score
scienceclaw-benchmark-for51
beita6969
Use when a task asks to predict a phonon property of inorganic crystals from their structure, for example the frequency of the last peak of the phonon density…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark-for44
beita6969
Use when a task gives a covariate table plus, for each of many simulated observational datasets, a binary treatment vector and an outcome vector, and asks for…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark-for43
beita6969
Use when a task gives noisy OCR text of historical newspapers, periodicals or books (several languages, with metadata and a set of labelled OCR/ground-truth…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark-for34
beita6969
Use when predicting a binary molecular property such as HIV replication inhibition (OGB ogbg-molhiv, MoleculeNet-style activity) from SMILES strings and…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark-for42
beita6969
Use when a task gives hourly ICU records (vitals, labs, demographics, one stay per patient) with sepsis labels and asks for causal hour-by-hour sepsis alarms…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark-for33
beita6969
Use when forecasting day-ahead hourly electricity load of individual buildings (residential and commercial smart-meter data, BuildingsBench-style) from the…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark-for32
beita6969
Use when segmenting the hippocampus into anterior and posterior parts in small 3-D T1-weighted brain MRI crops (Medical Segmentation Decathlon Task04) from a…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark-for35
beita6969
Use when forecasting monthly tourism, visitor or other seasonal business and service series (Monash Tourism Monthly, 24-month horizon, period 12) from each…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark
beita6969
Index of the 23 discipline skills (FoR30-FoR52) that mirror the disciplines of the companion ScienceClaw-Eval benchmark: find which discipline skill fits a…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark-for30
beita6969
Use when segmenting top-down field or UAV RGB images of crops (sugar beet, PhenoBench-style) into soil / crop / weed semantics plus crop-plant and crop-leaf…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark-for31
beita6969
Use when ranking or predicting the fitness effect of single amino-acid substitutions in a protein (deep mutational scanning, ProteinGym-style assays) from…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark-for46
beita6969
Use when a task gives Python programming problems (a function stub with docstring or a task description, an entry-point name, a few public assert tests) and…
SkillAFreshness: A★ 1KClaude Code +9
Signals
- Stars
- 1,019
- Forks
- 109
- Open issues
- 1
- Last commit (this folder)
- Mar 12, 2026 (7 months ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- MIT
- Repository
- github.com/beita6969/ScienceClaw
- Website
- scienceclaw.science
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from beita6969
- 0.608score
scienceclaw-benchmark-for33
beita6969
Use when forecasting day-ahead hourly electricity load of individual buildings (residential and commercial smart-meter data, BuildingsBench-style) from the…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark-for34
beita6969
Use when predicting a binary molecular property such as HIV replication inhibition (OGB ogbg-molhiv, MoleculeNet-style activity) from SMILES strings and…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark-for30
beita6969
Use when segmenting top-down field or UAV RGB images of crops (sugar beet, PhenoBench-style) into soil / crop / weed semantics plus crop-plant and crop-leaf…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark-for32
beita6969
Use when segmenting the hippocampus into anterior and posterior parts in small 3-D T1-weighted brain MRI crops (Medical Segmentation Decathlon Task04) from a…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark
beita6969
Index of the 23 discipline skills (FoR30-FoR52) that mirror the disciplines of the companion ScienceClaw-Eval benchmark: find which discipline skill fits a…
SkillAFreshness: A★ 1KClaude Code +9 - 0.608score
scienceclaw-benchmark-for35
beita6969
Use when forecasting monthly tourism, visitor or other seasonal business and service series (Monash Tourism Monthly, 24-month horizon, period 12) from each…
SkillAFreshness: A★ 1KClaude Code +9
Cite this page
ml-pipeline skill. Agent Mart. https://agentmart.dev/skills/beita6969-ml-pipeline (last updated 2026-10-24)