code: def is_valid(data):
          
          return bool(data) and \
              isinstance(data, dict) and \
              bool(data.get("swagger")) and \
              isinstance(data.get('paths'), dict)
docs: Checks if the input data is a Swagger document
  
          :param dict data: Data to be validated
          :return: True, if data is a Swagger