def METHOD_NAME(data_args):
    ner_task_mapping = {}
    for name, obj in inspect.getmembers(flair.datasets.sequence_labeling):
        if inspect.isclass(obj) and name.startswith(("NER", "CONLL", "WNUT")):
            ner_task_mapping[name] = obj
    dataset_args = {}
    dataset_name = data_args.dataset_name
    if data_args.dataset_arguments:
        dataset_args = json.loads(data_args.dataset_arguments)
    if dataset_name not in ner_task_mapping:
        raise ValueError(f"Dataset name {dataset_name} is not a valid Flair datasets name!")
    return ner_task_mapping[dataset_name](**dataset_args)