File size: 2,263 Bytes
a5a5a1c
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
---
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`.