Help your Chatbot Understand Plural and Singular in Teneo
Sometimes you may want to make sure that your bot is able to distinguish between plural and singular inputs, like “show my next appointments” versus “show my next appointment”. To achieve this in Teneo, you can use part-of-speech tags (POS-tags).
Teneo annotates each word in an input with POS-tags that tell you whether it’s a verb, noun, if it is plural or singular, etc. The full list of POS-tags can be found in the Annotations Reference. You can also inspect them in Try out, which is explained on the Annotations page.
Appointments vs Appointment
So how do you use a POS-tag to differentiate between appointments and appointment in a language condition?
To match on a synonym of ‘appointment’ and also to make sure it is plural/singular, you would use the SAME MATCH-operator (&=). Like this:
(%APPOINTMENT.NN.SYN &= %$PL.POS)
The condition above will match only on plural (%$PL.POS) synonyms of appointment (appointments, meetings etc).
(%APPOINTMENT.NN.SYN &= %$SG.POS)
This condition will match only on singular (%$SG.POS) synonyms of appointment (appointment, meeting etc).
Try Before You Buy.
Build. Deploy. Analyze.
Sign up to get your own developer sandbox of Teneo containing all the tools needed to build and manage advanced conversational solutions.