# Choosing Openmed Models

Discover and pick the right OpenMed model for a clinical or biomedical task, domain, or...

- Repository: https://github.com/maziyarpanahi/openmed (5755 stars)
- Category: Engineering
- License: Apache-2.0
- Last updated: 2026-10-31
- Runs scripts: no, instructions only

## Install

Claude Code: `npx skills add maziyarpanahi/openmed --skill choosing-openmed-models -g -a claude-code -y`
Codex: `npx skills add maziyarpanahi/openmed --skill choosing-openmed-models -g -a codex -y`
Cursor: `npx skills add maziyarpanahi/openmed --skill choosing-openmed-models -g -a cursor -y`
Gemini CLI: `npx skills add maziyarpanahi/openmed --skill choosing-openmed-models -g -a gemini-cli -y`
Claude Code plugin marketplace: `/plugin marketplace add maziyarpanahi/openmed`

## Description

Discover and pick the right OpenMed model for a clinical or biomedical task, domain, or language. Use when the user asks which OpenMed model to use, wants to list model categories, find a Disease vs Oncology vs Privacy/PII model, get a PII model for a specific language, search models by size or task, or inspect a model's labels and metadata before loading. Covers list_model_categories, get_models_by_category, get_pii_models_by_language, get_default_pii_model, search_models(ModelQuery(...)), get_model_info, and the openmed models CLI. Pairs with loading-openmed-models.

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# Choosing OpenMed Models

OpenMed ships a registry of clinical and biomedical NER models grouped into 12
categories. **Never hardcode a model list**, query the registry at runtime so
your code stays correct as models are added. This skill helps you go from "I need
to find diseases in Spanish discharge notes" to a concrete model key.

## When to use

- The user knows the task (find diseases / tumors / PHI) but not the model.
- You need the right **PII model for a language** (es, fr, de, …).
- You want to filter models by size, task, or tier before loading.
- You want to inspect a model's labels, params, and license first.

Once you have a key, hand off to `loading-openmed-models` to load it.

## Install

```bash
pip install openmed         # registry queries work without the [hf] extra
```

## Quick start: browse categories, then pick

```python
import openmed

# 1) The 12 categories
openmed.list_model_categories()
# ['Medical', 'Privacy', 'Anatomy', 'Hematology', 'Chemical', 'Disease',
#  'Genomics', 'Oncology', 'Species', 'Pathology', 'Pharmaceutical', 'Protein']

# 2) Models in a category -> list[ModelInfo]
for m in openmed.get_models_by_category("Disease"):
    print(m.model_id, "|", m.size_category, "|", m.entity_types)

# 3) Inspect one model before loading
info = openmed.get_model_info("OpenMed/OpenMed-NER-DiseaseDetect-BigMed-278M")
print(info.display_name, info.task, info.param_count, info.license)
```

`get_models_by_category` and `get_all_models` return `ModelInfo` objects.
`get_all_models()` returns a `dict[str, ModelInfo]` keyed by registry key.

## What `ModelInfo` tells you

Every model exposes (real attributes):

The rest: https://github.com/maziyarpanahi/openmed/blob/HEAD/skills/choosing-openmed-models/SKILL.md
