Pydantic Validation Example for Ml Models