Fix vectorstores/Redis to support output component "Chains"
This commit is contained in:
parent
5e615c0c14
commit
f1b1a3919f
1 changed files with 3 additions and 3 deletions
|
|
@ -1,11 +1,11 @@
|
|||
from typing import Optional
|
||||
from typing import Optional, List, Union
|
||||
from langflow import CustomComponent
|
||||
|
||||
from langchain.vectorstores.redis import Redis
|
||||
from langchain.schema import Document
|
||||
from langchain.vectorstores.base import VectorStore
|
||||
from langchain.embeddings.base import Embeddings
|
||||
|
||||
from langchain.schema import BaseRetriever
|
||||
|
||||
class RedisComponent(CustomComponent):
|
||||
"""
|
||||
|
|
@ -42,7 +42,7 @@ class RedisComponent(CustomComponent):
|
|||
redis_server_url: str,
|
||||
redis_index_name: str,
|
||||
documents: Optional[Document] = None,
|
||||
) -> VectorStore:
|
||||
) -> Union[VectorStore, BaseRetriever]:
|
||||
"""
|
||||
Builds the Vector Store or BaseRetriever object.
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue