Combine NER and Relations annotation tasks with custom recipe

Good day,

Is it possible to combine NER and Relations annotation tasks with a custom recipe? Any example code to be able to do this?


hi @joebuckle!

Yes! We have a section in our documentation on combining NER and relations tasks with a custom recipe.

It's worth noting a section near the end of the docs:

While it’s tempting to have everything annotated in one step, it can make the data collection process more consistent to split the annotation for different aspects into their own separate steps. If you’re annotating relations between spans, the span boundaries can matter a lot and inconsistencies can lead to lower data quality for both tasks. It can therefore help to annotate and review entities first and only add relations once you know that the data is correct and consistent.

The key point is that it's important to have a solid annotation scheme for your entities first. If you do, then it can make sense to annotate together. However, if you're just starting and don't have a clear picture of your entities, you save yourself a lot of time down the road by starting first with entities, iterating on your entity scheme, and moving to relations once you have an acceptable entity definition.

Let alone, you may find annotators perform better with only one task at a time:

If spans and relations don’t have to be annotated at the same time, it can also make it easier for the annotators to focus on one objective at a time. This reduces the steps per completed annotation and the cognitive load, which can also help prevent careless mistakes.

Thank you!