If you're building clinical ML pipelines and tired of reinventing EHR preprocessing, this wraps PyHealth's opinionated five-stage workflow: dataset, task definition, model instantiation, training, metrics. It handles MIMIC-III/IV, eICU, OMOP, sleep signals, and chest X-rays out of the box, plus a stable of architectures like Transformer, RETAIN, and SafeDrug. The real value is in the task library (mortality, readmission, drug recommendation, ICD coding) and the medical code utilities for mapping between ICD-9/10, ATC, NDC, and RxNorm vocabularies. It's prescriptive by design, so if your workflow fits the mold you save weeks of plumbing. If it doesn't, you'll fight it. The skill emphasizes the critical gotchas: models need SampleDatasets not BaseDatasets, always split by patient to avoid leakage, and match your monitor metric to the task type.

skills.sh installs
2K
GitHub stars
56.6K
last updated
Aug 21, 2026

Install

$ npx -y skills add k-dense-ai/scientific-agent-skills --skill pyhealth --agent claude-code

Installs into .claude/skills of the current project.

Files

PyHealth

Targets PyHealth 2.0.2, verified against its released wheel, current official documentation, and CPU execution on Python 3.12/Torch 2.7.1. PyHealth's pipeline is Dataset -> Task -> Model -> Trainer -> Metrics; its 1.x and 2.x interfaces differ. Do not combine legacy Visit examples with the 2.x event/processor API.

When to use

Use for clinical prediction with PyHealth, including EHR sequences, physiological signals, imaging tasks, or medical-code lookup. Establish the cohort, prediction time, observation window, outcome horizon, and unit of evaluation before modeling. For general tabular learning without a PyHealth dataset/task, this skill is optional.

Install and smoke-test

uv run --no-project --isolated --python 3.12 --with pyhealth==2.0.2 python assets/starter_pipeline.py --demo --epochs 1

Run that command from the skill directory, or use the absolute path to the asset. It trains on invented in-memory records and exercises patient splitting, metrics, and best-checkpoint restoration. It provides no evidence of clinical performance. See installation for project setup and device options.

Workflow

Sponsors

Details

Repository
github.com/k-dense-ai/scientific-agent-skills
Categories
DevOps & CI/CD, AI & Agent Building, Data Science & ML, Automation & Workflows, Sales & Marketing
First seen
Jun 3, 2026

More from k-dense-ai/scientific-agent-skills

All 137
1k-dense-ai avatardnanexus-integrationk-dense-ai/scientific-agent-skillsBuild and operate reproducible genomics workloads on DNAnexus with the dx CLI, dxpy, apps/applets, native workflows, dxCompiler, and Nextflow. Use for DNAnexus 2Kskills.sh installs
2k-dense-ai avatarlatchbio-integrationk-dense-ai/scientific-agent-skillsBuild, register, debug, and operate bioinformatics workflows on Latch using the Python SDK, CLI, Latch Data and Registry, Nextflow, Snakemake, programmatic exec2Kskills.sh installs
3datadog-labs avatardd-monitorsdatadog-labs/agent-skillsMonitor management - list, search, file-based create, and alerting best practices.2Kskills.sh installs
4replicate avatarpublish-modelsreplicate/skillsPush and publish custom AI models to Replicate, and set up CI/CD for releasing new model versions safely. Use when running cog push, deploying a model to Replic1.9Kskills.sh installs
5apollographql avatarapollo-routerapollographql/skillsVersion-aware guide for configuring and running Apollo Router for federated GraphQL supergraphs. Generates correct YAML for both Router v1.x and v2.x. Use this 1.9Kskills.sh installs
6nvidia avatarlaunch-nemo-rlnvidia/skillsPlaybook for launching, monitoring, stopping, and debugging NeMo-RL recipes on a Kubernetes cluster via the nrl-k8s CLI. Covers ephemeral vs long-lived RayClust1.9Kskills.sh installs