
scikit-survival Analysis
Build, evaluate and audit right-censored and competing-risk survival models in Python
- Repository
- K-Dense-AI/scientific-agent-skills
- Stars
- 55,780
- Licence
- MIT
- Files
- 13 files
What it does
Once installed, the agent follows a disciplined workflow for survival analysis, where the outcome is 'time until an event happens' and some subjects are only partly observed (censored). It sets up outcomes correctly, splits data before any learned preprocessing to avoid leakage, fits Cox, forest, boosting or SVM survival models with scikit-survival, and reports censoring-aware metrics. It also includes small local command-line tools for validating CSV files, estimating competing-risk cumulative incidence, evaluating metrics and writing Markdown model cards.
Great for
- Data scientists or biostatisticians building survival models in Python who want guardrails against common mistakes
- Students learning right-censored or competing-risk methods with synthetic examples
- Teams auditing an existing survival pipeline for leakage or wrong metric inputs
Skip it if
- Clinical decisions or medical advice: the skill itself says outputs are not clinical advice or proof of clinical utility
- Fine-Gray regression or other competing-risk regression: the library only provides nonparametric cumulative incidence, so the agent cannot deliver it from this skill
- Analysing sensitive patient data without review: the scripts read local files, but the user is responsible for data governance
Try asking
- “Build a Cox proportional hazards model predicting time to relapse from my patient CSV, with a leakage-safe pipeline”
- “Validate my survival CSV file for correct event and time columns before modelling”
- “Estimate cumulative incidence for three competing causes of death from this dataset”
- “Write a Markdown model card summarising my concordance and Brier score results”
Install in 3 steps
- 1
Download the skill
The ZIP contains the 13 original files, the MIT licence and an attribution note.
scikit-survival.zip - 2
Add it to your agent
Claude Code (all projects)
mkdir -p ~/.claude/skills && unzip scikit-survival.zip -d ~/.claude/skills/Claude Code / Agent SDK (this project only)
mkdir -p .claude/skills && unzip scikit-survival.zip -d .claude/skills/Claude apps (web/desktop): Settings → Capabilities → Skills → Upload skill, and choose the ZIP.
- 3
Ask for the task
No special command needed — the agent reads the skill's description and loads it when your request matches. Try one of the prompts above.
Get better results
- Give the agent the event coding and time units up front so it can choose the right estimator and outcome format
- Keep study data outside the skill folder and review the CLI outputs before sharing them, since the scripts run locally on your files
- Ask for nested cross-validation or a holdout set when you need honest tuned performance estimates
What's inside
- references/competing-risks.md
- references/cox-models.md
- references/data-handling.md
- references/ensemble-models.md
- references/evaluation-metrics.md
- references/svm-models.md
- scripts/_common.py
- scripts/competing_risk_cif.py
- scripts/evaluate_survival_metrics.py
- scripts/model_report.py
- scripts/train_survival_model.py
- scripts/validate_survival_csv.py
- SKILL.md
Redistributed unmodified from K-Dense-AI/scientific-agent-skills under the MIT licence. The assessment was drafted with AI from the skill's files on 2026-10-29. Skills can instruct your agent to run code — read SKILL.md and any scripts before installing.