Skip to content

Commit 5b74c29

Browse files
authored
fix: Gliner bug in training (#643)
1 parent 398f581 commit 5b74c29

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

label_studio_ml/examples/gliner/model.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -239,9 +239,9 @@ def fit(self, event, data, **kwargs):
239239
tokens, ner = self.process_training_data(task)
240240
training_data.append({"tokenized_text": tokens, "ner": ner})
241241

242+
from_name, to_name, value = self.label_interface.get_first_tag_occurence('Labels', 'Text')
242243
eval_data = {
243-
"entity_types": sorted(self.label_interface.get_tag(from_name).labels)
244-
,
244+
"entity_types": sorted(self.label_interface.get_tag(from_name).labels),
245245
"samples": training_data[:10]
246246
}
247247

0 commit comments

Comments
 (0)