def generate(self, title=None, version=None, base_path=None,<EOL>info=None, swagger=None, **kwargs):
title = title or self.api_title<EOL>version = version or self.api_version<EOL>info = info or self.swagger.get('<STR_LIT:info>', {})<EOL>swagger = swagger or self.swagger<EOL>base_path = base_path or self.base_path<EOL>swagger = swagger.copy()<EOL>info.update(title=title, version=version)<EOL>swagger.update(swagger='<STR_LIT>', info=info, basePath=base_path)<EOL>paths, tags = self._build_paths()<EOL>if tags:<EOL><INDENT>swagger.setdefault('<STR_LIT>', [])<EOL>tag_names = {t['<STR_LIT:name>'] for t in swagger['<STR_LIT>']}<EOL>for tag in tags:<EOL><INDENT>if tag['<STR_LIT:name>'] not in tag_names:<EOL><INDENT>swagger['<STR_LIT>'].append(tag)<EOL><DEDENT><DEDENT><DEDENT>if paths:<EOL><INDENT>swagger.setdefault('<STR_LIT>', {})<EOL>merge_dicts(swagger['<STR_LIT>'], paths)<EOL><DEDENT>definitions = self.definitions.definition_registry<EOL>if definitions:<EOL><INDENT>swagger.setdefault('<STR_LIT>', {})<EOL>merge_dicts(swagger['<STR_LIT>'], definitions)<EOL><DEDENT>parameters = self.parameters.parameter_registry<EOL>if parameters:<EOL><INDENT>swagger.setdefault('<STR_LIT>', {})<EOL>merge_dicts(swagger['<STR_LIT>'], parameters)<EOL><DEDENT>responses = self.responses.response_registry<EOL>if responses:<EOL><INDENT>swagger.setdefault('<STR_LIT>', {})<EOL>merge_dicts(swagger['<STR_LIT>'], responses)<EOL><DEDENT>return swagger<EOL>
Generate a Swagger 2.0 documentation. Keyword arguments may be used
        to provide additional information to build methods as such ignores.

        :param title:
            The name presented on the swagger document.
        :param version:
            The version of the API presented on the swagger document.
        :param base_path:
            The path that all requests to the API must refer to.
        :param info:
            Swagger info field.
        :param swagger:
            Extra fields that should be provided on the swagger documentation.

        :rtype: dict
        :returns: Full OpenAPI/Swagger compliant specification for the application.