@staticmethod
def _label_id_index_mapping(training_data: TrainingData, attribute: Text) -> Dict[(Text, int)]:
    'Create label_id dictionary.'
    distinct_label_ids = ({example.get(attribute) for example in training_data.intent_examples} - {None})
    return {label_id: idx for (idx, label_id) in enumerate(sorted(distinct_label_ids))}
Create label_id dictionary.
@staticmethod
def _label_id_index_mapping(training_data: TrainingData, attribute: Text) -> Dict[(Text, int)]:
    
    distinct_label_ids = ({example.get(attribute) for example in training_data.intent_examples} - {None})
    return {label_id: idx for (idx, label_id) in enumerate(sorted(distinct_label_ids))}