AI Zone Admin Forum Add your forum

NEWS: Chatbots.org survey on 3000 US and UK consumers shows it is time for chatbot integration in customer service!read more..

aiml capture amount decimal value
 
 
<pattern>amount *</pattern>  
 <
template>show value <star/></template


it will capture as two sentence if key in 100.99

show value 100 i have no answer for that.

how to capture full decimal amount ?

 

 
  [ # 1 ]

You need to add something like this to your normal.txt file:

[".0"" point 0"],
[".1"" point 1"],
[".2"" point 2"],
[".3"" point 3"],
[".4"" point 4"],
[".5"" point 5"],
[".6"" point 6"],
[".7"" point 7"],
[".8"" point 8"],
[".9"" point 9"]

This will tell the interpreter to convert “100.99” into “100 point 99” rather than treating it as a sentence splitter.

 

 
  [ # 2 ]

thanks alot, now can show decimal ady.

Steve Worswick - Dec 14, 2018:

You need to add something like this to your normal.txt file:

[".0"" point 0"],
[".1"" point 1"],
[".2"" point 2"],
[".3"" point 3"],
[".4"" point 4"],
[".5"" point 5"],
[".6"" point 6"],
[".7"" point 7"],
[".8"" point 8"],
[".9"" point 9"]

This will tell the interpreter to convert “100.99” into “100 point 99” rather than treating it as a sentence splitter.

 

 
  login or register to react