def testWolframQuery(self): result = ExternalAPI.wolframQuery('who are you ?', os.environ.get('SMARTBOT_WOLFRAM_APPID')) self.assertEqual(result, 'My name is Wolfram|Alpha.')
def testWolframQueryForMathInWords(self): result = ExternalAPI.wolframQuery('calculate one plus one', os.environ.get('SMARTBOT_WOLFRAM_APPID')) self.assertEqual(result, '2')
def query(self, queryEnglish): return ExternalAPI.wolframQuery(queryEnglish, appId=self.wolframAppId)