code: def test_mixed_labels():
      # example sentence
      sentence = Sentence("I love New York")
  
      # has sentiment value
      sentence.add_label("sentiment", "positive")
  
      # has 4 part of speech tags
      sentence[1].add_label("pos", "verb")
      sentence[2].add_label("pos", "proper noun")
      sentence[3].add_label("pos", "proper noun")
      sentence[0].add_label("pos", "pronoun")
  
      # has 1 NER tag
      sentence[2:4].add_label("ner", "City")
  
      # should be in total 6 labels
      assert len(sentence.labels) == 6
      assert len(sentence.get_labels("pos")) == 4
      assert len(sentence.get_labels("sentiment")) == 1
      assert len(sentence.get_labels("ner")) == 1
  
file_path: flair/tests/test_labels.py
imports: from typing import List
  from flair.data import Label, Relation, Sentence, Span
label_desc: Use image node_id 6 for calling a global function with example usage: test_mixed_labels() without return types