<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def writeTraining(self, file_obj):
 # pragma: no cover """ Write to a json file that contains labeled examples Keyword arguments: file_obj -- file object to write training data to """


        json.dump(self.training_pairs,
                  file_obj,
                  default=serializer._to_json,
                  tuple_as_array=False,
                  ensure_ascii=True)