Skip to content

Commit

Permalink
fix: Gliner bug in training (#643)
Browse files Browse the repository at this point in the history
  • Loading branch information
makseq authored Oct 7, 2024
1 parent 398f581 commit 5b74c29
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions label_studio_ml/examples/gliner/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -239,9 +239,9 @@ def fit(self, event, data, **kwargs):
tokens, ner = self.process_training_data(task)
training_data.append({"tokenized_text": tokens, "ner": ner})

from_name, to_name, value = self.label_interface.get_first_tag_occurence('Labels', 'Text')
eval_data = {
"entity_types": sorted(self.label_interface.get_tag(from_name).labels)
,
"entity_types": sorted(self.label_interface.get_tag(from_name).labels),
"samples": training_data[:10]
}

Expand Down

0 comments on commit 5b74c29

Please sign in to comment.