/ Модель

Характеристики

Лицензия
Своя лицензия
Архитектура
medextractor · dense
Базовая модель
LFM2.5-Encoder-350M
Библиотека
transformers
Опубликована
22 окт 2026

medextractor-liquid

Разметка токеновТекст → label4 профессии

Дообученный энкодер для извлечения пользовательских полей, сущностей и ответов из клинических и биомедицинских текстов.

75скачиваний за 30 дней1лайквеса обновлены24 ноя 2026

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

MedExtractor Liquid — дообученный энкодер LiquidAI на базе LFM2.5-Encoder-350M с головой извлечения информации, содержащий 359 млн параметров. Модель извлекает из клинических и биомедицинских текстов заданные пользователем поля: для каждого поля возвращает соответствующий фрагмент текста или null, а для полей-списков — все подходящие фрагменты. Один интерфейс подходит для распознавания сущностей, извлечения ответов и заполнения слотов; описания полей могут быть на разных языках.

Модель рассчитана на английские клинические и биомедицинские тексты и поддерживает до 2048 токенов и 24 полей за один проход; более длинный ввод обрезается. В тестах на 15 биомедицинских корпусах, отсутствовавших в обучении, средний показатель F1 составил 63,8. Модель также предназначена для быстрого пакетного извлечения полей, однако качество на типах полей, далёких от обучающих данных, уступает крупной языковой модели.

Весами следует пользоваться с осторожностью: клинические испытания проводились только на синтетических заметках, и модель не прошла проверку на реальных записях пациентов. Это не медицинское устройство; каждое извлечённое значение нужно проверять до применения в медицинской помощи. Лицензия указана как other.

Сценарии применения

  • извлечение медицинских сущностей из биомедицинских публикаций
  • заполнение заданных полей по клинической заметке
  • извлечение значений анамнеза и симптомов из текста
  • поиск ответа на вопрос в медицинском тексте
  • извлечение нескольких упоминаний сущности в виде списка

Ограничения

Клиническая оценка проводилась только на синтетических заметках, реальной клинической валидации нет. На типах полей, далёких от обучающих данных, качество ниже, чем у крупной языковой модели; длинные тексты свыше 2048 токенов обрезаются.

Для каких профессий подходит4

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

MedExtractor Liquid

A 359M-parameter encoder that extracts user-defined fields from clinical and biomedical text. You pass a text and a list of fields (name, type, description). One forward pass returns, for every field, a span from the text or null; list fields return all matching spans.

  • Zero-shot biomedical NER: on 15 corpora absent from training it averages 63.8 F1, level with a prompted Gemma 4 31B (64.0) at 1/87 of its size and more than 10 points above every GLiNER model.
  • Your own fields: handles field names and descriptions it was not trained on.
  • Fast: about 545 clinical notes per second on one GPU: 8–14× the GLiNER models and about 60× Gemma 4 31B served with vLLM on the same card. On a CPU it takes about 0.3 s per note.
  • One model for NER, extractive QA and slot filling, with the same interface.

Actual model output on a synthetic note: 12 user-defined fields filled with spans from the text, and one field the note does not mention returned as null.

Not a medical device. Trained and evaluated only on public datasets and synthetic notes, never on real patient records. Verify every output before using it in care.

Usage

from transformers import AutoModel

model = AutoModel.from_pretrained("lion-ai/medextractor-liquid", trust_remote_code=True)  # add .to("cuda") for speed

note = ("A 67-year-old woman was admitted on 03/12/2025 with shortness of breath. Her mother had breast cancer. "
        "Medications: metformin 850 mg twice daily, ramipril 5 mg in the morning. Atorvastatin was stopped because of muscle pain.")
fields = [
    ("age", "number", "patient age in years"),
    ("admission_date", "date", "date of admission"),
    ("current_drugs", "list[text]", "drugs the patient takes now"),
    ("stopped_drugs", "list[text]", "discontinued drugs"),
    ("ramipril_dose", "text", "dose of ramipril"),
    ("cancer", "text", "cancer of the patient (not relatives)"),
]
print(model.extract(note, fields))
# {"age": "67", "admission_date": "03/12/2025", "current_drugs": ["metformin", "ramipril"], "stopped_drugs": ["Atorvastatin"], "ramipril_dose": "5 mg", "cancer": null}
  • Descriptions can be in any language and may state a span convention, for example "protein, as the outermost (longest) mention".
  • Thresholds: null_threshold (default 0.3) and list_threshold (default 0.6). For NER with bare entity labels, list_threshold=0.3 works better.
  • Spans: with_spans=True adds character offsets, a score and p_null.

Model details

Base modelLFM2.5-Encoder-350M with an extraction head
Parameters359M
Inputup to 2048 tokens and 24 fields per pass (longer texts are truncated)
Field typestext, number, date, duration, list[...]
LanguageEnglish

Evaluation

All numbers are on locked test splits, scored once after every choice had been fixed on dev data. We ran every competitor ourselves on the same records. Full per-dataset tables and the protocol are in EVALUATION.md.

Zero-shot biomedical NER. The 15 corpora are absent from the training data. Each system gets the corpus entity types as labels, and the metric is strict span micro-F1. On four corpora the same frozen convention rules are applied to every system: the official BC2GM scorer, plus rules for JNLPBA, Linnaeus and AnatEM (see EVALUATION.md). Without these rules MedExtractor Liquid averages 60.7, against 52.5 for the best GLiNER model.

DatasetMedExtractor LiquidGemma 4 31BGLiNER-BioMed bi-largeGLiNER-BioMed largegliner-bi-large v2.0gliner-bi-base v2.0gliner-bi-small v2.0GLiNER2 large
Parameters359M31.3B569M478M530M194M108M486M
AnatEM50.250.545.236.747.448.250.532.5
BC2GM85.579.875.769.877.378.177.667.1
BioInfer44.530.531.928.620.512.317.831.5
BioNLP BB46.756.240.844.040.041.840.440.3
BioNLP CG67.165.252.955.955.853.350.242.7
BioNLP ID65.076.650.354.955.150.354.749.9
BioNLP PC74.172.462.664.566.462.159.345.7
CellFinder61.059.243.144.249.445.642.539.4
CPI66.268.056.960.656.357.655.756.9
JNLPBA62.457.563.552.261.757.158.550.2
Linnaeus71.578.059.056.458.957.255.265.6
miRNA70.277.061.969.561.847.547.157.0
OSIRIS42.843.531.731.928.520.117.730.1
PDR66.662.756.159.157.355.956.153.5
ProGene83.983.062.867.767.066.163.961.5
Average63.864.053.053.153.650.249.848.3

Clinical notes with user-defined fields (English notes; share of fields with a correct or overlapping value):

FieldsMedExtractor LiquidGLiNER2 largeGemma 4 31B
Seen field kinds75.863.269.6
Held-out field families62.645.078.8

Seen kinds also occur in our training data. Held-out families (smoking, physician and department, referral and follow-up) were never generated for training. The GLiNER-BioMed and gliner-bi models are not in this table: they are NER models that return every mention of an entity type, with no notion of one value per field or of an empty field.

Speed (500 synthetic clinical notes of about 310 tokens, 12 fields, one NVIDIA RTX PRO 6000; model loading excluded):

ModelParametersNotes per second
MedExtractor Liquid359M545
gliner-bi-large v2.0530M67
GLiNER-BioMed bi-large569M48
GLiNER2 large486M40
Gemma 4 31B (vLLM, FP8)31.3B9

Every encoder runs its library's batched inference with batch size 32; the GLiNER models get the 12 field descriptions as entity labels. Gemma runs with vLLM continuous batching. On a CPU (16 threads, AMD Threadripper PRO 7975WX), MedExtractor Liquid processes 3.5 notes per second.

Limitations

  • On field families far from training, a prompted 31B LLM is clearly better (78.8 against 62.6).
  • Without the convention rules, BC2GM, JNLPBA and AnatEM trail the best GLiNER model by 5–10 points. JNLPBA stays 1.1 below it even with them.
  • The clinical evaluation uses synthetic notes only. The model has no real-world clinical validation.

Training

  • Data: 1.25M records from 93 sources:
    • public QA, NER, slot-filling, biomedical and clinical datasets;
    • programmatic clinical notes;
    • notes and annotations generated with Gemma 4 31B.
  • Decontamination: texts that share a sentence with any evaluation split were removed. The evaluated corpora and held-out field families are not in training. Other human-annotated biomedical corpora with similar entity types are.
  • Procedure: two-stage fine-tuning of encoder and head. The released weights are a uniform average of six fine-tunes from one shared first stage (three variants of the training mixture, two seeds each). Training ran on one NVIDIA RTX PRO 6000.

License

The weights are a derivative of LFM2.5-Encoder-350M under the LFM Open License v1.0 (LICENSE). Commercial use is licensed only for organisations below USD 10M annual revenue. The training data also includes non-commercial datasets (MultiNERD, the DDI corpus, parts of MRQA) and Gemma-generated data (Gemma terms of use), so treat this release as non-commercial / research use.

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · transformers · token-classification

Нельзя запустить

Модели нужен код из репозитория; автор пока не в списке доверенных организаций.

Класс архитектуры
MedExtractorModel
Ревизия весов
07bb580

0 моделей