<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def from_dict(doc):
 """Create a model output object from a dictionary. """

        return ModelOutputs(
            ModelOutputFile.from_dict(doc['prediction']),
            [ModelOutputFile.from_dict(a) for a in doc['attachments']]
        )