Example #1
0
    def __init__(self):
        self.how_dict = {}
        self.what_dict = {}
        self.where_dict = {}
        self.who_dict = {}

        self.keywords = ['How', 'What', 'Where', 'Who', 'Why', 'Is']
        self.question_mark = chr(0x3F)

        self.question_answers = {
            'What type of triangle is ': QA('What type of triangle is ', get_triangle_type),
            'What type of quadrilateral is ': QA('What type of quadrilateral is ', get_object_shape_type_2),
            'What time is it': QA('What time is it', check_current_time()),
            'How many days?': QA('How many days?', 'How many days?'),
            'Is the file path in the repo': QA('Is the  in the repo', is_file_in_repo),
            'What is the status of the file path?'
            : QA('What is the status of the file path', get_git_file_info),
            'What is the deal with the file path'
            : QA('What is the deal with the file path', get_file_info),
            'What branch is file path'
            : QA('What branch is file path?',get_repo_branch),
            'What is the repo url'
            : QA('What is the path file come from?', get_repo_url)


        }
        self.last_question = None
Example #2
0
    def __init__(self):
        self.how_dict = {}
        self.what_dict = {}
        self.where_dict = {}
        self.who_dict = {}

        self.keywords = ['How', 'What', 'Where', 'Who', "Why"]
        self.question_mark = chr(0x3F)

        self.question_answers = {
            'What type of triangle is ': QA('What type of triangle is ', get_triangle_type),
            'What type of quadrilateral is ': QA('What type of quadrilateral is ', get_object_shape_type_2),
            'What time is it': QA('What time is it', check_current_time()),
        }
        self.last_question = None