<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def format_response(self, response):
 """ formats a response in a binary """

        conversion = self.shell_ctx.config.BOOLEAN_STATES
        if response in conversion:
            if conversion[response]:
                return 'yes'
            return 'no'
        raise ValueError('Invalid response: input should equate to true or false')