def create_scoped_session(self, options=None):
if options is None:<EOL><INDENT>options = {}<EOL><DEDENT>scopefunc = options.pop('<STR_LIT>', _app_ctx_stack.__ident_func__)<EOL>options.setdefault('<STR_LIT>', self.Query)<EOL>return orm.scoped_session(<EOL>self.create_session(options), scopefunc=scopefunc<EOL>)<EOL>
Create a :class:`~sqlalchemy.orm.scoping.scoped_session`
        on the factory from :meth:`create_session`.

        An extra key ``'scopefunc'`` can be set on the ``options`` dict to
        specify a custom scope function.  If it's not provided, Flask's app
        context stack identity is used. This will ensure that sessions are
        created and removed with the request/response cycle, and should be fine
        in most cases.

        :param options: dict of keyword arguments passed to session class  in
            ``create_session``