Can you force Dialogflow to extract the date-time

2019-06-03 11:00发布

问题:

I'm building a Google Home skill using Dialogflow. I want the user to be able to say a date time such as "today at 3pm", "Wednesday at 11am", or "August 10 at 5pm."

Dialogflow has several prebuilt entities including: date, time, and date-time. For some reason the system seems to always parse date and time separately instead of just as date-time. I've tried putting in several examples and manually setting the entity type to date-time but whenever I add another one it always parses them separately.

Any ideas how I could force it to extract date-time as one entity?

回答1:

You can use @sys.date-time or can have a composite custom entity and use it for the intents. There could be any combination of the entity that you can put there. Once you extract it, you can use regex to extract date and time in your webhook.

Entity


Intent



标签: dialogflow