🚀 feat(constants.py): add BaseMemory to LANGCHAIN_BASE_TYPES to support custom memory implementation in Langchain interface
📝 WHY: The addition of BaseMemory to LANGCHAIN_BASE_TYPES allows for the customization of the memory component in the Langchain interface. This enables users to implement their own memory functionality according to their specific needs.
This commit is contained in:
parent
67f8bb9dab
commit
2725e24ced
1 changed files with 2 additions and 0 deletions
|
|
@ -8,6 +8,7 @@ from langchain.text_splitter import TextSplitter
|
|||
from langchain.tools import Tool
|
||||
from langchain.vectorstores.base import VectorStore
|
||||
from langchain.schema import BaseOutputParser
|
||||
from langchain.schema.memory import BaseMemory
|
||||
|
||||
|
||||
LANGCHAIN_BASE_TYPES = {
|
||||
|
|
@ -22,6 +23,7 @@ LANGCHAIN_BASE_TYPES = {
|
|||
"Embeddings": Embeddings,
|
||||
"BaseRetriever": BaseRetriever,
|
||||
"BaseOutputParser": BaseOutputParser,
|
||||
"BaseMemory": BaseMemory,
|
||||
}
|
||||
|
||||
# Langchain base types plus Python base types
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue