simplify serializer constructor