<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_arg_value_as_type(self, key, default=None, convert_int=False):
 """Allow users to pass through truthy type values like true, yes, no and get to a typed variable in your code :param str val: The string reprensentation of the value you want to convert :returns: adapted value :rtype: dynamic """


        val = self.get_query_argument(key, default)

        if isinstance(val, int):
            return val

        if val.lower() in ['true', 'yes']:
            return True

        if val.lower() in ['false', 'no']:
            return False

        return val