langchain-ai/langchain
Auf GitHub ansehencore: docstrings shouldn't inherit from parents
Open
#32.066 geöffnet am 16. Juli 2025
corehelp wantedinternalv1
Beschreibung
from langchain_core.tools import tool from pydantic import BaseModel class MyTool(BaseModel): """Parent Tool""" foo: str @tool class ChildTool(MyTool): bar: strFor 0.4 release we could consider updating the behavior so that doc-strings are not inherited from their parents. It's fairly odd that doc-strings are inherited for BaseModels as in general the descriptions need to be different
Originally posted by @eyurtsev in #31606