The challenges of real world entity extraction

One of the topics I have been focusing recently is about the challenges of entity extraction. It is a product agnostic topic as it mainly focusses in identifying common patterns. This awareness will then help when trying to design the entire entity extraction strategy.

Humans have a natural ability to understand a conversation and extract all relevant information from it.

For humans it is natural to be able to extract all the relevant information when reading or hearing a sentence, but how can a conversational AI Platform match such innate capabilities? What if there are any implicit rules or ambiguity? This is all part of the challenge, and we should be aware of some of the most common ones!

Ambiguity

I’d like to arrange dinner for 8

How can the AI know if it should extract the number 8 or a time? Is this reservation for 8 people or for 8 PM?

This is a classic example of ambiguity in conversation. Context plays a role, but sometimes there is no clear way of knowing with certainty. That’s where disambiguation plays a role.

Disambiguation

Disambiguation is when we ask for clarification. Whenever we face a doubt, and we have no means to make a decision , we should disambiguate and ask the question back to the user. Disambiguation is a natural step in NLP…as it is in a natural conversation.

Dates

Expressing date and time has so many different possibilities that sometimes it can be a challenge.

I want to book a flight for Monday

I want to create an expense for a meal I had Monday

How can the AI know if the expressed date (monday) is future or past? For humans it is quite easy, as we infer from the sentence context. Booking a flight is something we do for the future, but creating an expense report, on the other hand, refers to an event in the past.

My birthday is on 11/7

Is this birthday on 11th July, or on 7th November? The answer to that depends on where you are based. It’s locale based, the same way that Numbers and Currency are.

Multiple Entity Extraction

Having multiple entities in an utterance can bring additional challenges in their extraction.

I want to order a large cheese pizza with an extra topping of jalapenos, delivered at 7 later today, at my home office.

Typically each entity extracts one piece of information. Extracting multiple entities can pose a challenge, as we may need to define each entity characteristics and extraction rules. A good conversational AI platform ( as ODA is ) should be able to manage this by using a special entity type that manages them all. Composite bags – remember this name.

Conditional Entity Extraction

Sometimes we may skip entity extraction.

Create an expense report for my 10$ taxi ride

If we have a business rule that says that receipts are not required for expenses smaller than 20$, that means that for the above transaction, we would skip the receipt prompt. It’s a good example of conditional entity.

Out of Order Extraction

This happens more often than not, as it is very common in natural conversation as well. However, for an AI machine, this poses yet another challenge.

Make it Large please” when being prompted for the pizza delivery time

This out of order interaction is hard when we are prompting for entities. In this case the bot was trying to extract the delivery time, but the user answered something else.

Unknown values

How can we extract values that we not know?

I had a cheese sandwich for $16 at Sandy’s Beachhouse

If we ignore the fact that 16$ for a sandwich is an outrage, the main point here is that it is not possible for us to know all possible values for restaurants, cafes or bars. Tricky situation hard to solve without the proper tools. This very specific case can be solved with a specific type of entity, called machine learning entity. I have a post about it.

What can we do?

Oracle Digital Assistant has the out of the box tools that allow us to easily address all of the above challenges, with a mix of simple entities (DATE,CURRENCY,TIME) and complex entities (Composite Bags, Machine Learning), among other extended capabilities. In the next post I will explain how can we solve these challenges with the platform features.