Nr
int64
1
28
Model ID
stringclasses
28 values
Base Model ID
stringclasses
13 values
1
tomaarsen/span-marker-roberta-large-fewnerd-fine-super
roberta-large
2
tomaarsen/span-marker-bert-base-fewnerd-fine-super
bert-base-cased
3
tomaarsen/span-marker-bert-tiny-conll03
prajjwal1/bert-tiny
4
tomaarsen/span-marker-bert-tiny-fewnerd-coarse-super
prajjwal1/bert-tiny
5
tomaarsen/span-marker-xlm-roberta-large-conll03
xlm-roberta-large
6
tomaarsen/span-marker-xlm-roberta-large-conll03-doc-context
xlm-roberta-large
7
tomaarsen/span-marker-xlm-roberta-large-conllpp-doc-context
xlm-roberta-large
8
tomaarsen/span-marker-roberta-large-ontonotes5
roberta-large
9
tomaarsen/span-marker-xlm-roberta-base-fewnerd-fine-super
xlm-roberta-base
10
krinal/span-marker-robert-base
roberta-base
11
tomaarsen/span-marker-xlm-roberta-large-verbs
xlm-roberta-large
12
tomaarsen/span-marker-xlm-roberta-base-multinerd
xlm-roberta-base
13
tomaarsen/span-marker-mbert-base-multinerd
bert-base-multilingual-cased
14
lxyuan/span-marker-bert-base-multilingual-cased-multinerd
bert-base-multilingual-cased
15
tomaarsen/span-marker-bert-base-ncbi-disease
bert-base-cased
16
tomaarsen/span-marker-bert-base-acronyms
bert-base-cased
17
tomaarsen/span-marker-bert-base-uncased-acronyms
bert-base-uncased
18
lxyuan/span-marker-bert-base-multilingual-uncased-multinerd
bert-base-multilingual-uncased
19
tomaarsen/span-marker-bert-base-cross-ner
bert-base-cased
20
tomaarsen/span-marker-bert-base-uncased-cross-ner
bert-base-uncased
21
stefan-it/span-marker-gelectra-large-germeval14
deepset/gelectra-large
22
gwlms/span-marker-bert-germeval14
gwlms/bert-base-dewiki-v1
23
gwlms/span-marker-token-dropping-bert-germeval14
gwlms/bert-base-token-dropping-dewiki-v1
24
gwlms/span-marker-teams-germeval14
gwlms/teams-base-dewiki-v1-discriminator
25
ashishpatel26/span-marker-bert-base-fewnerd-coarse-super
bert-base-cased
26
ashishpatel26/span-marker-roberta-base-conll03
roberta-base
27
tomaarsen/span-marker-bert-base-uncased-keyphrase-inspec
bert-base-uncased
28
tomaarsen/span-marker-bert-base-uncased-bionlp
bert-base-uncased

SpanMarker Base Model Detection

It is relative simply to determine base model of a fine-tuned SpanMarker model:

import os

from huggingface_hub import login, HfApi

hf_token = os.environ.get("HF_TOKEN")
login(token=hf_token, add_to_git_credential=True)
api = HfApi()

Please make sure that HF_TOKEN is set as environment variable.

After that, list of all SpanMarker models can be retrieved and configuration file is parsed. Please make sure that span-marker library is installed:

from span_marker import SpanMarkerConfig

f_out = open("span_marker_base_model_detection.csv", "wt")

f_out.write("Nr,Model ID,Base Model ID\n")

counter = 1
for span_marker_model in api.list_models(filter="span-marker"):
    try:
        config = SpanMarkerConfig.from_pretrained(span_marker_model.modelId)

        base_model = config.encoder["_name_or_path"]
        
        f_out.write(f"{counter},{span_marker_model.modelId},{base_model}\n")
        
        counter +=1
    except Exception as e:
        print(e)
f_out.close()
Downloads last month
47