<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def as_text(self, is_proof=True, is_pretty=False):
 """Return the DDO as a JSON text. :param if is_proof: if False then do not include the 'proof' element. :param is_pretty: If True return dictionary in a prettier way, bool :return: str """

        data = self.as_dictionary(is_proof)
        if is_pretty:
            return json.dumps(data, indent=2, separators=(',', ': '))

        return json.dumps(data)