Token Classification
PyTorch
ONNX
multilingual
glitext
rpeel commited on
Commit
175d602
·
verified ·
1 Parent(s): fd904d9

Update model card and security scan results

Browse files
Files changed (1) hide show
  1. README.md +105 -16
README.md CHANGED
@@ -1,28 +1,126 @@
1
  ---
2
- library_name: glitext
3
  license: apache-2.0
 
 
 
 
 
 
4
  tags:
5
  - glitext
6
  glitext:
7
  name: medium
8
  label: GliText Recognition (Balanced)
9
- description: An efficient zero-shot named entity recognition model tuned for generalized extraction with balanced speed and accuracy.
 
10
  recognition: true
11
  classification: false
12
  association: false
13
  span_mode: true
14
  size_gb: 0.78
15
- hf_repo: rpeel/glitext-medium
16
  source_url: gliner-community/gliner_medium-v2.5
17
  ---
18
 
19
- # rpeel/glitext-medium
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
20
 
21
- An efficient zero-shot named entity recognition model tuned for generalized extraction with balanced speed and accuracy.
22
 
23
- ## Requirements
24
 
25
- To download this model to the SAS GLiText server:
26
 
27
  ```
28
  POST /v1/models/download?name=medium
@@ -34,11 +132,6 @@ To download and load into memory in one step:
34
  PUT /v1/models?name=medium
35
  ```
36
 
37
- ## Source Model
38
-
39
- Exported from [gliner-community/gliner_medium-v2.5](https://huggingface.co/gliner-community/gliner_medium-v2.5).
40
- See the [original model card](https://huggingface.co/gliner-community/gliner_medium-v2.5) for full architecture and training details.
41
-
42
  ## Security Scan
43
 
44
  Scanned with [modelaudit](https://github.com/promptfoo/modelaudit) v0.2.40 on 2026-04-27. 24/24 checks passed. [Full results](modelaudit.json).
@@ -47,7 +140,3 @@ Scanned with [modelaudit](https://github.com/promptfoo/modelaudit) v0.2.40 on 20
47
  | File | Size | SHA-256 |
48
  |------|------|---------|
49
  | `model.onnx` | 835.6 MB | `dfbf82b4c9b7cb8e…` |
50
-
51
- ## License
52
-
53
- [Apache 2.0](https://www.apache.org/licenses/LICENSE-2.0). Derived from [gliner-community/gliner_medium-v2.5](https://huggingface.co/gliner-community/gliner_medium-v2.5) by [gliner-community](https://huggingface.co/gliner-community).
 
1
  ---
 
2
  license: apache-2.0
3
+ language:
4
+ - multilingual
5
+ library_name: glitext
6
+ datasets:
7
+ - urchade/pile-mistral-v0.1
8
+ pipeline_tag: token-classification
9
  tags:
10
  - glitext
11
  glitext:
12
  name: medium
13
  label: GliText Recognition (Balanced)
14
+ description: An efficient zero-shot named entity recognition model tuned for generalized
15
+ extraction with balanced speed and accuracy.
16
  recognition: true
17
  classification: false
18
  association: false
19
  span_mode: true
20
  size_gb: 0.78
21
+ hf_repo: sassoftware/glitext-medium
22
  source_url: gliner-community/gliner_medium-v2.5
23
  ---
24
 
25
+ # About
26
+
27
+ GLiNER is a Named Entity Recognition (NER) model capable of identifying any entity type using a bidirectional transformer encoder (BERT-like). It provides a practical alternative to traditional NER models, which are limited to predefined entities, and Large Language Models (LLMs) that, despite their flexibility, are costly and large for resource-constrained scenarios.
28
+
29
+
30
+ ## Links
31
+
32
+ * Paper: https://arxiv.org/abs/2311.08526
33
+ * Repository: https://github.com/urchade/GLiNER
34
+
35
+ ## Installation
36
+ To use this model, you must install the GLiNER Python library:
37
+ ```
38
+ !pip install gliner -U
39
+ ```
40
+
41
+ ## Usage
42
+ Once you've downloaded the GLiNER library, you can import the GLiNER class. You can then load this model using `GLiNER.from_pretrained` and predict entities with `predict_entities`.
43
+
44
+ ```python
45
+ from gliner import GLiNER
46
+
47
+ model = GLiNER.from_pretrained("gliner-community/gliner_medium-v2.5", load_tokenizer=True)
48
+
49
+ text = """
50
+ Cristiano Ronaldo dos Santos Aveiro (Portuguese pronunciation: [kɾiʃˈtjɐnu ʁɔˈnaldu]; born 5 February 1985) is a Portuguese professional footballer who plays as a forward for and captains both Saudi Pro League club Al Nassr and the Portugal national team. Widely regarded as one of the greatest players of all time, Ronaldo has won five Ballon d'Or awards,[note 3] a record three UEFA Men's Player of the Year Awards, and four European Golden Shoes, the most by a European player. He has won 33 trophies in his career, including seven league titles, five UEFA Champions Leagues, the UEFA European Championship and the UEFA Nations League. Ronaldo holds the records for most appearances (183), goals (140) and assists (42) in the Champions League, goals in the European Championship (14), international goals (128) and international appearances (205). He is one of the few players to have made over 1,200 professional career appearances, the most by an outfield player, and has scored over 850 official senior career goals for club and country, making him the top goalscorer of all time.
51
+ """
52
+
53
+ labels = ["person", "award", "date", "competitions", "teams"]
54
+
55
+ entities = model.predict_entities(text, labels)
56
+
57
+ for entity in entities:
58
+ print(entity["text"], "=>", entity["label"])
59
+ ```
60
+
61
+ ```
62
+ Cristiano Ronaldo dos Santos Aveiro => person
63
+ 5 February 1985 => date
64
+ Al Nassr => teams
65
+ Portugal national team => teams
66
+ Ballon d'Or => award
67
+ UEFA Men's Player of the Year Awards => award
68
+ European Golden Shoes => award
69
+ UEFA Champions Leagues => competitions
70
+ UEFA European Championship => competitions
71
+ UEFA Nations League => competitions
72
+ Champions League => competitions
73
+ European Championship => competitions
74
+ ```
75
+
76
+ ## Named Entity Recognition benchmark result
77
+ Below is a comparison of results between previous versions of the model and the current one:
78
+ ![Models performance](models_comparison.png)
79
+
80
+
81
+ ## Available models
82
+
83
+ | Release | Model Name | # of Parameters | Language | License |
84
+ | - | - | - | - | - |
85
+ | v0 | [urchade/gliner_base](https://huggingface.co/urchade/gliner_base)<br>[urchade/gliner_multi](https://huggingface.co/urchade/gliner_multi) | 209M<br>209M | English<br>Multilingual | cc-by-nc-4.0 |
86
+ | v1 | [urchade/gliner_small-v1](https://huggingface.co/urchade/gliner_small-v1)<br>[urchade/gliner_medium-v1](https://huggingface.co/urchade/gliner_medium-v1)<br>[urchade/gliner_large-v1](https://huggingface.co/urchade/gliner_large-v1) | 166M<br>209M<br>459M | English <br> English <br> English | cc-by-nc-4.0 |
87
+ | v2 | [urchade/gliner_small-v2](https://huggingface.co/urchade/gliner_small-v2)<br>[urchade/gliner_medium-v2](https://huggingface.co/urchade/gliner_medium-v2)<br>[urchade/gliner_large-v2](https://huggingface.co/urchade/gliner_large-v2) | 166M<br>209M<br>459M | English <br> English <br> English | apache-2.0 |
88
+ | v2.1 | [urchade/gliner_small-v2.1](https://huggingface.co/urchade/gliner_small-v2.1)<br>[urchade/gliner_medium-v2.1](https://huggingface.co/urchade/gliner_medium-v2.1)<br>[urchade/gliner_large-v2.1](https://huggingface.co/urchade/gliner_large-v2.1) <br>[urchade/gliner_multi-v2.1](https://huggingface.co/urchade/gliner_multi-v2.1) | 166M<br>209M<br>459M<br>209M | English <br> English <br> English <br> Multilingual | apache-2.0 |
89
+
90
+
91
+ ## Model Authors
92
+ The model authors are:
93
+ * [Urchade Zaratiana](https://huggingface.co/urchade)
94
+ * [Ihor Stepanov](https://huggingface.co/Ihor)
95
+ * Nadi Tomeh
96
+ * Pierre Holat
97
+ * Thierry Charnois
98
+
99
+ ## Citation
100
+ ```bibtex
101
+ @misc{zaratiana2023gliner,
102
+ title={GLiNER: Generalist Model for Named Entity Recognition using Bidirectional Transformer},
103
+ author={Urchade Zaratiana and Nadi Tomeh and Pierre Holat and Thierry Charnois},
104
+ year={2023},
105
+ eprint={2311.08526},
106
+ archivePrefix={arXiv},
107
+ primaryClass={cs.CL}
108
+ }
109
+ ```
110
+
111
+ ## Source Model Repo
112
+
113
+ This model is derived from [`gliner-community/gliner_medium-v2.5`](https://huggingface.co/gliner-community/gliner_medium-v2.5). See the upstream repository for the original safetensors weights, training data, and the full upstream model card.
114
+
115
+ ## ONNX Weights
116
+
117
+ ONNX weights added by SAS — converted from the upstream safetensors checkpoint.
118
 
119
+ File in this repo: `model.onnx`.
120
 
121
+ ## Using this Model with the SAS GLiText API
122
 
123
+ This repo is consumed by the SAS GLiText product. To download it onto a SAS GLiText server:
124
 
125
  ```
126
  POST /v1/models/download?name=medium
 
132
  PUT /v1/models?name=medium
133
  ```
134
 
 
 
 
 
 
135
  ## Security Scan
136
 
137
  Scanned with [modelaudit](https://github.com/promptfoo/modelaudit) v0.2.40 on 2026-04-27. 24/24 checks passed. [Full results](modelaudit.json).
 
140
  | File | Size | SHA-256 |
141
  |------|------|---------|
142
  | `model.onnx` | 835.6 MB | `dfbf82b4c9b7cb8e…` |