I have a dataframe in IOB format as below:-
| Name | Label |
|---|---|
| Alan | B-PERSON |
| Smith | I-PERSON |
| is | O |
| Alice's | B-PERSON |
| uncle | O |
| from | O |
| New | B-LOCATION |
| York | I-LOCATION |
| city | I-LOCATION |
I would like to convert into a new dataframe as below:-
| Name | Label |
|---|---|
| Alan Smith | PERSON |
| Alice's | PERSON |
| New York city | LOCATION |
Any help is much appreciated!