--- library_name: transformers base_model: michiyasunaga/BioLinkBERT-base tags: - transformers - pytorch - biomedical - text-classification - psynamic license: apache-2.0 language: - en pipeline_tag: text-classification --- # biolinkbert-data-type-20261107 Fine-tuned model from the PsyNamic project ([code](https://github.com/Ineichen-Group/PsyNamic), [webapp](https://psynamic.dcr.unibe.ch)): Data Type. This is the model deployed in the PsyNamic webapp after the revision (Nov 2026). It supersedes [STRIDE-lab/biobert-data-type-20250221](https://huggingface.co/STRIDE-lab/biobert-data-type-20250221) (tag `submission-v1`, initial submission). All current models: [PsyNamic collection](https://huggingface.co/collections/STRIDE-lab/psynamic). ## Base Model `michiyasunaga/BioLinkBERT-base` ## Task **Data Type** Specifies whether data were collected longitudinally or cross-sectionally. ## Labels (id2label) | ID | Label | Definition | |---|---|---| | 0 | Cross-sectional | Outcomes are measured during one single time point (or more than one time point within ≤ 24 hours). | | 1 | Longitudinal long | Outcomes are measures during at least two different time points > 24 hours apart and the total follow-up time is ≥ 3 months. | | 2 | Longitudinal short | Outcomes are measures during at least two different time points > 24 hours apart but the total follow-up time is < 3 months. | | 3 | Not applicable | e.g., for systematic reviews or for studies pooling a variety of other studies together without providing information about data type. | | 4 | Unknown | Data type is unknown. | ## Prediction rule Single-label: softmax over the labels, the label with the highest probability (argmax) is predicted. ## Model selection Five base models (BiomedBERT-abstract, BioBERT, BioLinkBERT, ClinicalBERT, SciBERT) were fine-tuned with identical hyperparameters. The checkpoint is the one with the lowest validation loss (early stopping), and the base model was selected on the validation set (weighted F1). The test set was used once, after selection. ## Test Performance Held-out test set (96 abstracts), argmax as in the webapp, 95% bootstrap CIs (1,000 BCa resamples). | Metric (test) | Value [95% CI] | |---|---| | **Weighted F1** | **0.712 [0.608–0.804]** | | Weighted precision | 0.725 [0.600–0.806] | | Weighted recall | 0.729 [0.635–0.812] | ## Usage ```python import torch from transformers import AutoTokenizer, AutoModelForSequenceClassification repo = "STRIDE-lab/biolinkbert-data-type-20261107" tokenizer = AutoTokenizer.from_pretrained(repo) model = AutoModelForSequenceClassification.from_pretrained(repo) inputs = tokenizer("