How to use LangChain with different Pydantic versions
As of the0.3
release, LangChain uses Pydantic 2 internally.
Users should install Pydantic 2 and are advised toavoid using thepydantic.v1
namespace of Pydantic 2 withLangChain APIs.
If you're working with prior versions of LangChain, please see the following guideonPydantic compatibility.