How to handle "it"? TEDPolicy?

I’ve been reading through the forums, blogs, Master series, papers (all great documentation!) but I still don’t understand how to handle “it”. Here’s my example:

User: I would like to buy the car you are advertising for sale.

Bot: Sure, I can help you with that!

User: How much does it cost?

I’m looking for ideas on things to try. Forms don’t work for our real use cases and the many-turn conversations would cause an combinatoric explosion in stories.

Is the TEDPolicy the best approach? Or Keras policy? (We don’t have a huge amount of real-world data to train with.) Or best to handle in custom Python code?

Thanks!

P.S. Could use fallback in some way (maybe?) but I’d prefer that the bot didn’t respond with, “Are you asking about the price of the car?”

Ask yourself:

  • Is car only what you are selling?
  • If it is then, obviously, it means car.
  • If you have different products not only car or different brands of car, train the nlu data with entities - product, brand. For example:

intent:buy_car

  • I would like to buy the car you are advertising for sale
  • I want to buy Ferrari

Now depending on your slots are filled or not you can either ask for more information or respond with correct answer. Hope it helps

Thanks for replying. We’re not selling anything, that was just an example.

How do we, in the general case, fill in what “it” is? “It” simply refers to the subject or object of the previous turn. But it could reference an entity from an earlier turn.

The word “that” is also used in the same way. Example:

User: Tell me about communications tools.

Bot: Do you want me to tell you about Google Hangouts?

User: What is that?

“That”, in the last turn, refers to Google Hangouts. How does the bot know? For example, is the subject & object of the bot’s previous utterance identified as such and passed into the next action selection? What if the user’s “it” or “that” refers to an entity from an earlier turn?