The simple aggregation strategy for an NER pipeline
nlp = pipeline("ner", model=model_directory, aggregation_strategy="simple")
aggregates correctly if we use BIO tags, but not if using BILOU style, is there a way to amend this easily?
I can change
nlp.model.config.id2label = {k: v.replace('L-', 'I-').replace('U-', 'B-') for k, v in nlp.model.config.id2label.items()}
but is there an in-built way to handle such cases where we have non BIO format labels?