Team Ai
Apppublic

Underground-Digital/Workflow-Engine

sourceHugging Faceupdated 2y agoView on Hugging Face
0likes
helper.py10 linesDownload Raw Back to utils
1import pydantic2from pydantic import BaseModel3 4 5def dump_model(model: BaseModel) -> dict:6    if hasattr(pydantic, "model_dump"):7        return pydantic.model_dump(model)8    else:9        return model.model_dump()10