Added :code:`pydantic` v2.5 support.