Пример #1
0
 def testEviQueryForMathInWords(self):
     result = ExternalAPI.eviQuery('calculate one plus one')
     self.assertEqual(result, 'The sum of 1 and 1 is 2.')
Пример #2
0
 def testEviQuery(self):
     result = ExternalAPI.eviQuery('who are you ?')
     self.assertEqual(result, 'I\'m Evi, your thinking, talking, computerised assistant.')
Пример #3
0
 def testEviQueryForMathInNumbers(self):
     result = ExternalAPI.eviQuery('calculate 1 + 1')
     self.assertEqual(result, 'Sorry, that looks like a maths question. Try asking it in words rather than using symbols like + or *.')
Пример #4
0
 def query(self, queryEnglish):
     return ExternalAPI.eviQuery(queryEnglish)