Instructions to use BiomedicalEvidencePlatform/pico-extractor with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use BiomedicalEvidencePlatform/pico-extractor with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("token-classification", model="BiomedicalEvidencePlatform/pico-extractor")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForTokenClassification tokenizer = AutoTokenizer.from_pretrained("BiomedicalEvidencePlatform/pico-extractor") model = AutoModelForTokenClassification.from_pretrained("BiomedicalEvidencePlatform/pico-extractor", device_map="auto") - MLX
How to use BiomedicalEvidencePlatform/pico-extractor with MLX:
# Download the model from the Hub pip install huggingface_hub[hf_xet] hf download BiomedicalEvidencePlatform/pico-extractor --local-dir pico-extractor
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- Atomic Chat
|
Download README.md from BiomedicalEvidencePlatform/pico-extractor: direct link, hf CLI and curl.
- Browser
- Download file 2.26 kB
-
https://huggingface.co/BiomedicalEvidencePlatform/pico-extractor/resolve/main/README.md
- Command line
-
hf download hf://BiomedicalEvidencePlatform/pico-extractor/README.md
-
curl -L -o README.md https://huggingface.co/BiomedicalEvidencePlatform/pico-extractor/resolve/main/README.md
2.26 kB
| license: apache-2.0 | |
| base_model: zuzab/pico-extractor | |
| library_name: transformers | |
| pipeline_tag: token-classification | |
| language: | |
| - en | |
| tags: | |
| - mlx | |
| - safetensors | |
| - fp16 | |
| - biomedical | |
| - pico | |
| - ner | |
| - bert | |
| # pico-extractor | |
| BIO token classifier tagging PICO elements (Population, Intervention, Comparator, Outcome) in clinical-trial abstracts; used by Mineris for PICO span extraction. | |
| This is a **format conversion** of [`zuzab/pico-extractor`](https://huggingface.co/zuzab/pico-extractor) | |
| for Mineris' MLX inference stack (`mineris_inference`) — not a fine-tune. Weights are | |
| the full upstream `BertForTokenClassification` (encoder + classification head) cast to fp16 and stored as `model.safetensors`; a | |
| `tokenizer.json` is included so the model loads without `transformers` or `torch`. | |
| ## Labels | |
| | id | label | | |
| |---|---| | |
| | 0 | `O` | | |
| | 1 | `B-P` | | |
| | 2 | `B-I` | | |
| | 3 | `B-C` | | |
| | 4 | `B-O` | | |
| | 5 | `I-P` | | |
| | 6 | `I-I` | | |
| | 7 | `I-C` | | |
| | 8 | `I-O` | | |
| ## Provenance | |
| | | | | |
| |---|---| | |
| | Upstream repo | [`zuzab/pico-extractor`](https://huggingface.co/zuzab/pico-extractor) | | |
| | Upstream commit | `ed4df86e482d9c53d953791a71c15caa5a687d96` | | |
| | License | `apache-2.0` (declared by Mineris, the upstream owner) | | |
| | Conversion notebook | `notebook/notebooks/converter/convert_pico_extractor.ipynb` (mineris repo) | | |
| | Mineris commit | `9817fe7bbeb2a4b23fd683144a28a5843af94af9` | | |
| | Version | `v1.0.0` | | |
| | dtype | fp16 | | |
| | Tensors / size | 199 / 215.3 MB | | |
| ## Conversion parity (fp16 mirror vs fp32 upstream, PyTorch) | |
| | Metric | Value | | |
| |---|---| | |
| | Texts | 18 | | |
| | Tokenizer id mismatches (`tokenizer.json` via `tokenizers` vs upstream tokenizer) | 0 | | |
| | Token argmax label agreement, per text — min / mean | 1.000000 / 1.000000 | | |
| | Logits, non-padding tokens — max abs diff / median relative diff | 9.82e-03 / 5.09e-04 | | |
| | Threshold (min token argmax label agreement) | 0.995 | | |
| MLX-runtime parity is tracked separately in the mineris `notebook/notebooks/benchmark/` notebooks. | |
| ## Versioning | |
| Releases are semver git tags on this repo (`vMAJOR.MINOR.PATCH`); consumers pin a tag. MAJOR = | |
| output-incompatible change, MINOR = compatible re-conversion, PATCH = card/metadata only. | |
| ## CHANGELOG | |
| - `v1.0.0` — initial conversion from `zuzab/pico-extractor@ed4df86`. | |