Utilities for pydantic.
Check if the given class is Pydantic v1-like.
Check if the given class is Pydantic v2-like.
Check if the given class is a subclass of Pydantic BaseModel.
Check if the given class is a subclass of any of the following:
pydantic.BaseModel in Pydantic 2.xpydantic.v1.BaseModel in Pydantic 2.xCheck if the given class is an instance of Pydantic BaseModel.
Check if the given class is an instance of any of the following:
pydantic.BaseModel in Pydantic 2.xpydantic.v1.BaseModel in Pydantic 2.xDecorator to run a function before model initialization.
Return the field names of a Pydantic model.
Create a Pydantic model with the given field definitions.
Please use create_model_v2 instead of this function.
Create a Pydantic model with the given field definitions.
Do not use outside of langchain packages. This API is subject to change at any time.
DEPRECATED - Get the major version of Pydantic.
Use PYDANTIC_VERSION.major instead.