Most of the logic of these two functions is identical. There's lots of code duplication.
The primary difference is that the texts and metadata are separate arguments in add_texts, and bound as a list of Document(containing you guessed it metadata and "page+content". add_documents need only call add_texts.
It makes sense to do this refactoring while working on INTPYTHON-431
- related to
-
INTPYTHON-431 LangChain: MongoDBAtlasVectorSearch: Implement async versions of add_texts & add_documents
-
- Closed
-