Views
No views yet
OpenMed/OpenMed-ZeroShot-NER-Organism-Medium-209M for Apple Silicon inference with OpenMed.zero-shot-nergliner-uni-encoder-spansafetensorsGLiNERMLXPipelineOpenMed/OpenMed-ZeroShot-NER-Organism-Medium-209Mconfig.json, id2label.json, openmed-mlx.json, MLX weights, and tokenizer assetshf download OpenMed/OpenMed-ZeroShot-NER-Organism-Medium-209M-mlx --local-dir ./OpenMed-ZeroShot-NER-Organism-Medium-209M-mlx1pip install openmed
2pip install "openmed[mlx]"1from huggingface_hub import snapshot_download
2from openmed.mlx.inference import GLiNERMLXPipeline
3
4model_path = snapshot_download("OpenMed/OpenMed-ZeroShot-NER-Organism-Medium-209M-mlx")
5pipe = GLiNERMLXPipeline(model_path)
6
7entities = pipe.predict_entities(
8 "Patient John Doe was seen at Stanford Hospital.",
9 labels=["person", "organization", "location"],
10 threshold=0.5,
11)
12
13for entity in entities:
14 print(entity)1{
2 "kind": "gliner-words",
3 "entity_token": "<<ENT>>",
4 "separator_token": "<<SEP>>",
5 "class_token_index": 128002,
6 "embed_marker_token": true,
7 "split_mode": "words"
8}https://github.com/maziyarpanahi/openmedid2label.json to your app target.weights.safetensors, OpenMed falls back to weights.npz so the model remains usable.OpenMed/OpenMed-ZeroShot-NER-Organism-Medium-209M