langflow-base-nightly 0.5.0.dev38__py3-none-any.whl → 0.5.0.dev39__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- langflow/alembic/versions/0882f9657f22_encrypt_existing_mcp_auth_settings_.py +122 -0
- langflow/api/v1/mcp_projects.py +373 -52
- langflow/api/v1/schemas.py +1 -2
- langflow/components/FAISS/__init__.py +34 -0
- langflow/components/agents/agent.py +246 -52
- langflow/components/cassandra/__init__.py +40 -0
- langflow/components/chroma/__init__.py +34 -0
- langflow/components/clickhouse/__init__.py +34 -0
- langflow/components/couchbase/__init__.py +34 -0
- langflow/components/datastax/__init__.py +3 -3
- langflow/components/elastic/__init__.py +37 -0
- langflow/components/milvus/__init__.py +34 -0
- langflow/components/mongodb/__init__.py +34 -0
- langflow/components/ollama/ollama.py +1 -0
- langflow/components/perplexity/perplexity.py +3 -13
- langflow/components/pgvector/__init__.py +34 -0
- langflow/components/pinecone/__init__.py +34 -0
- langflow/components/qdrant/__init__.py +34 -0
- langflow/components/redis/__init__.py +36 -2
- langflow/components/redis/redis.py +75 -29
- langflow/components/redis/redis_chat.py +43 -0
- langflow/components/supabase/__init__.py +37 -0
- langflow/components/upstash/__init__.py +34 -0
- langflow/components/vectara/__init__.py +37 -0
- langflow/components/vectorstores/__init__.py +0 -69
- langflow/components/vectorstores/local_db.py +1 -0
- langflow/components/weaviate/__init__.py +34 -0
- langflow/custom/dependency_analyzer.py +165 -0
- langflow/custom/utils.py +34 -16
- langflow/frontend/assets/{SlackIcon-BhW6H3JR.js → SlackIcon-Cr3Q15Px.js} +1 -1
- langflow/frontend/assets/{Wikipedia-Dx5jbiy3.js → Wikipedia-GxM5sPdM.js} +1 -1
- langflow/frontend/assets/{Wolfram-CIyonzwo.js → Wolfram-BN3-VOCA.js} +1 -1
- langflow/frontend/assets/{index-DOEvKC2X.js → index-28oOcafk.js} +1 -1
- langflow/frontend/assets/{index-Bhv79Zso.js → index-2wSXqBtB.js} +1 -1
- langflow/frontend/assets/{index-BRmSeoWR.js → index-3wW7BClE.js} +1 -1
- langflow/frontend/assets/{index-eUkS6iJM.js → index-6pyH3ZJB.js} +1 -1
- langflow/frontend/assets/{index-Cr5v2ave.js → index-AWCSdofD.js} +1 -1
- langflow/frontend/assets/{index-C27Jj_26.js → index-B2Zgv_xv.js} +1 -1
- langflow/frontend/assets/{index-BKKrUElc.js → index-B2ptVQGM.js} +1 -1
- langflow/frontend/assets/{index-BnAFhkSN.js → index-B3TANVes.js} +1 -1
- langflow/frontend/assets/{index-hZUcL0MZ.js → index-B4yCvZKV.js} +1 -1
- langflow/frontend/assets/{index-BPR2mEFC.js → index-BC65VuWx.js} +1 -1
- langflow/frontend/assets/{index-CgU7KF4I.js → index-BCDSei1q.js} +1 -1
- langflow/frontend/assets/{index-CzHzeZuA.js → index-BJy50PvP.js} +1 -1
- langflow/frontend/assets/{index-DkGhPNeA.js → index-BKseQQ2I.js} +1 -1
- langflow/frontend/assets/{index-BVFaF7HW.js → index-BLTxEeTi.js} +1 -1
- langflow/frontend/assets/{index-cEXY6V06.js → index-BRg1f4Mu.js} +1 -1
- langflow/frontend/assets/{index-C2eQmQsn.js → index-BS8Vo8nc.js} +1 -1
- langflow/frontend/assets/{index-gdb7XMS8.js → index-BTKOU4xC.js} +1 -1
- langflow/frontend/assets/{index-U9GWm1eH.js → index-BVwJDmw-.js} +1 -1
- langflow/frontend/assets/{index-BWt5xGeA.js → index-BWYuQ2Sj.js} +1 -1
- langflow/frontend/assets/{index-Dx-Z87KT.js → index-BWdLILDG.js} +1 -1
- langflow/frontend/assets/{index-paQEWYGT.js → index-BZcw4827.js} +1 -1
- langflow/frontend/assets/{index-BDQrd7Tj.js → index-Bbi87Ve4.js} +1 -1
- langflow/frontend/assets/{index-vJOO5U8M.js → index-Bf0IYKLd.js} +1 -1
- langflow/frontend/assets/{index-1Q3VBqKn.js → index-Bg5nrMRh.js} +1 -1
- langflow/frontend/assets/{index-BFQ8KFK0.js → index-BiC280Nx.js} +1 -1
- langflow/frontend/assets/{index-CFNTYfFK.js → index-BiKKN6FR.js} +1 -1
- langflow/frontend/assets/{index-BPfdqCc_.js → index-Bief6eyJ.js} +1 -1
- langflow/frontend/assets/{index-Cxy9sEpy.js → index-BkXec1Yf.js} +1 -1
- langflow/frontend/assets/{index-D4tjMhfY.js → index-Bnl6QHtP.js} +1 -1
- langflow/frontend/assets/{index-BD7Io1hL.js → index-BpxbUiZD.js} +1978 -1978
- langflow/frontend/assets/{index-Ch5r0oW6.js → index-BrJV8psX.js} +1 -1
- langflow/frontend/assets/{index-DOQDkSoK.js → index-BwLWcUXL.js} +1 -1
- langflow/frontend/assets/{index-CMHpjHZl.js → index-Bx7dBY26.js} +1 -1
- langflow/frontend/assets/{index-CbnWRlYY.js → index-C-EdnFdA.js} +1 -1
- langflow/frontend/assets/{index-DljpLeCW.js → index-C-Xfg4cD.js} +1 -1
- langflow/frontend/assets/{index-Bwi4flFg.js → index-C1f2wMat.js} +1 -1
- langflow/frontend/assets/index-C1xroOlH.css +1 -0
- langflow/frontend/assets/{index-D6CSIrp1.js → index-C3KequvP.js} +1 -1
- langflow/frontend/assets/{index-BYjw7Gk3.js → index-C3ZjKdCD.js} +1 -1
- langflow/frontend/assets/{index-DIKUsGLF.js → index-C3l0zYn0.js} +1 -1
- langflow/frontend/assets/{index-CfPBgkqg.js → index-C3yvArUT.js} +1 -1
- langflow/frontend/assets/{index-CsLQiWNf.js → index-C9Cxnkl8.js} +1 -1
- langflow/frontend/assets/{index-mzl9ULw5.js → index-CBc8fEAE.js} +1 -1
- langflow/frontend/assets/{index-CEJNWPhA.js → index-CBvrGgID.js} +1 -1
- langflow/frontend/assets/{index-DwfHWnX7.js → index-CD-PqGCY.js} +1 -1
- langflow/frontend/assets/{index-dyXKnkMi.js → index-CGO1CiUr.js} +1 -1
- langflow/frontend/assets/{index-Dka_Rk4-.js → index-CH5UVA9b.js} +1 -1
- langflow/frontend/assets/{index-uiKla4UR.js → index-CLJeJYjH.js} +1 -1
- langflow/frontend/assets/{index-D9kwEzPB.js → index-CMZ79X-Y.js} +1 -1
- langflow/frontend/assets/{index-BrVhdPZb.js → index-CMzfJKiW.js} +1 -1
- langflow/frontend/assets/{index-Bct1s6__.js → index-CNw1H-Wc.js} +1 -1
- langflow/frontend/assets/{index-B7uEuOPK.js → index-CPHEscq9.js} +1 -1
- langflow/frontend/assets/{index-ekfMOqrF.js → index-CRPKJZw9.js} +1 -1
- langflow/frontend/assets/{index-G4ro0MjT.js → index-CRPyCfYy.js} +1 -1
- langflow/frontend/assets/{index-CSu8KHOi.js → index-CRcMqCIj.js} +1 -1
- langflow/frontend/assets/{index-DsoX2o1S.js → index-CUVDws8F.js} +1 -1
- langflow/frontend/assets/{index-r_8gs4nL.js → index-CVWQfRYZ.js} +1 -1
- langflow/frontend/assets/{index-7hzXChQz.js → index-CVl6MbaM.js} +1 -1
- langflow/frontend/assets/{index-B8UR8v-Q.js → index-CVwWoX99.js} +1 -1
- langflow/frontend/assets/{index-Dda2u_yz.js → index-CWPzZtSx.js} +1 -1
- langflow/frontend/assets/{index-BKeZt2hQ.js → index-CZqRL9DE.js} +1 -1
- langflow/frontend/assets/{index-DHngW1k8.js → index-CdIf07Rw.js} +1 -1
- langflow/frontend/assets/{index-C--IDAyc.js → index-Cewy7JZE.js} +1 -1
- langflow/frontend/assets/{index-DZP_SaHb.js → index-CfwLpbMM.js} +1 -1
- langflow/frontend/assets/{index-CuCM7Wu7.js → index-CiR1dxI4.js} +1 -1
- langflow/frontend/assets/{index-Xi4TplbI.js → index-CiixOzDG.js} +1 -1
- langflow/frontend/assets/{index-BLYw9MK2.js → index-ClsuDmR6.js} +1 -1
- langflow/frontend/assets/{index-DMCWDJOl.js → index-CmEYYRN1.js} +1 -1
- langflow/frontend/assets/{index-CrAF-31Y.js → index-Co20d-eQ.js} +1 -1
- langflow/frontend/assets/{index-DXAfIEvs.js → index-CpzXS6md.js} +1 -1
- langflow/frontend/assets/{index-BmYJJ5YS.js → index-Cqpzl1J4.js} +1 -1
- langflow/frontend/assets/{index-KWY77KfV.js → index-CtVIONP2.js} +1 -1
- langflow/frontend/assets/{index-B3KCdQ91.js → index-CuFXdTx4.js} +1 -1
- langflow/frontend/assets/{index-p2kStSPe.js → index-Cyd2HtHK.js} +1 -1
- langflow/frontend/assets/{index-CkjwSTSM.js → index-D-1tA8Dt.js} +1 -1
- langflow/frontend/assets/{index-BFf0HTFI.js → index-D-KY3kkq.js} +1 -1
- langflow/frontend/assets/{index-BYhcGLTV.js → index-D-_B1a8v.js} +1 -1
- langflow/frontend/assets/{index-Dr6pVDPI.js → index-D14EWPyZ.js} +1 -1
- langflow/frontend/assets/{index-BDuk0d7P.js → index-D2N3l-cw.js} +1 -1
- langflow/frontend/assets/{index-BvGQfVBD.js → index-D5ETnvJa.js} +1 -1
- langflow/frontend/assets/{index-D1oynC8a.js → index-D7kquVv2.js} +1 -1
- langflow/frontend/assets/{index-B1XqWJhG.js → index-DA6-bvgN.js} +1 -1
- langflow/frontend/assets/{index-DzIv3RyR.js → index-DDWBeudF.js} +1 -1
- langflow/frontend/assets/{index-BKlQbl-6.js → index-DDcMAaG4.js} +1 -1
- langflow/frontend/assets/{index-CkK25zZO.js → index-DHgomBdh.js} +1 -1
- langflow/frontend/assets/{index-Bj3lSwvZ.js → index-DJP-ss47.js} +1 -1
- langflow/frontend/assets/{index-DDXsm8tz.js → index-DQ7VYqQc.js} +1 -1
- langflow/frontend/assets/{index-BNQIbda3.js → index-DTqbvGC0.js} +1 -1
- langflow/frontend/assets/{index-BzoRPtTY.js → index-DUpri6zF.js} +1 -1
- langflow/frontend/assets/{index-35sspuLu.js → index-DV3utZDZ.js} +1 -1
- langflow/frontend/assets/{index-BpmqDOeZ.js → index-DXRfN4HV.js} +1 -1
- langflow/frontend/assets/{index-C0E3_MIK.js → index-Db9dYSzy.js} +1 -1
- langflow/frontend/assets/{index-C8K0r39B.js → index-DdtMEn6I.js} +1 -1
- langflow/frontend/assets/{index-BLsVo9iW.js → index-DfDhMHgQ.js} +1 -1
- langflow/frontend/assets/{index-BZFljdMa.js → index-Dfe7qfvf.js} +1 -1
- langflow/frontend/assets/{index-CyP3py8K.js → index-DhtZ5hx8.js} +1 -1
- langflow/frontend/assets/{index-w72fDjpG.js → index-DiB3CTo8.js} +1 -1
- langflow/frontend/assets/{index-CY7_TBTC.js → index-DiGWASY5.js} +1 -1
- langflow/frontend/assets/{index-CmSFKgiD.js → index-Dl5amdBz.js} +1 -1
- langflow/frontend/assets/{index-B0m53xKd.js → index-DlD4dXlZ.js} +1 -1
- langflow/frontend/assets/{index-DnVYJtVO.js → index-DmeiHnfl.js} +1 -1
- langflow/frontend/assets/index-Dmu-X5-4.js +1 -0
- langflow/frontend/assets/{index-CWYiSeWV.js → index-DpVWih90.js} +1 -1
- langflow/frontend/assets/{index-CjsommIr.js → index-DrDrcajG.js} +1 -1
- langflow/frontend/assets/{index-Un9pWxnP.js → index-Du-pc0KE.js} +1 -1
- langflow/frontend/assets/{index-oxHBZk2v.js → index-DwPkMTaY.js} +1 -1
- langflow/frontend/assets/{index-CgwykVGh.js → index-DwQEZe3C.js} +1 -1
- langflow/frontend/assets/{index-BmIx1cws.js → index-DyJFTK24.js} +1 -1
- langflow/frontend/assets/{index-0XQqYgdG.js → index-J38wh62w.js} +1 -1
- langflow/frontend/assets/{index-H7J7w7fa.js → index-Kwdl-e29.js} +1 -1
- langflow/frontend/assets/{index-CUKmGsI6.js → index-OwPvCmpW.js} +1 -1
- langflow/frontend/assets/{index-zV82kQ6k.js → index-Tw3Os-DN.js} +1 -1
- langflow/frontend/assets/{index-8cuhogZP.js → index-X0guhYF8.js} +1 -1
- langflow/frontend/assets/{index-BUse-kxM.js → index-dJWNxIRH.js} +1 -1
- langflow/frontend/assets/{index-DyqITq51.js → index-dcJ8-agu.js} +1 -1
- langflow/frontend/assets/{index-Cg53lrYh.js → index-eo2mAtL-.js} +1 -1
- langflow/frontend/assets/{index-DqbzUcI5.js → index-hG24k5xJ.js} +1 -1
- langflow/frontend/assets/{index-BQrVDjR1.js → index-h_aSZHf3.js} +1 -1
- langflow/frontend/assets/{index-kkA-qHB_.js → index-hbndqB9B.js} +1 -1
- langflow/frontend/assets/{index-DZxUIhWh.js → index-iJngutFo.js} +1 -1
- langflow/frontend/assets/{index-Dg8N3NSO.js → index-lTpteg8t.js} +1 -1
- langflow/frontend/assets/{index-DDhJVVel.js → index-lZX9AvZW.js} +1 -1
- langflow/frontend/assets/{index-BHhnpSkW.js → index-m8QA6VNM.js} +1 -1
- langflow/frontend/assets/{index-Bk4mTwnI.js → index-o0D2S7xW.js} +1 -1
- langflow/frontend/assets/{index-DJESSNJi.js → index-ovFJ_0J6.js} +1 -1
- langflow/frontend/assets/{index-DH6o91_s.js → index-pYJJOcma.js} +1 -1
- langflow/frontend/assets/{index-Bo-ww0Bb.js → index-sI75DsdM.js} +1 -1
- langflow/frontend/assets/{index-BcAgItH4.js → index-xvFOmxx4.js} +1 -1
- langflow/frontend/assets/{index-_cbGmjF4.js → index-z3SRY-mX.js} +1 -1
- langflow/frontend/assets/lazyIconImports-D97HEZkE.js +2 -0
- langflow/frontend/assets/{use-post-add-user-CvtuazTg.js → use-post-add-user-C0MdTpQ5.js} +1 -1
- langflow/frontend/index.html +2 -2
- langflow/graph/graph/base.py +1 -1
- langflow/initial_setup/starter_projects/Basic Prompt Chaining.json +26 -0
- langflow/initial_setup/starter_projects/Basic Prompting.json +26 -0
- langflow/initial_setup/starter_projects/Blog Writer.json +56 -0
- langflow/initial_setup/starter_projects/Custom Component Generator.json +35 -0
- langflow/initial_setup/starter_projects/Document Q&A.json +26 -0
- langflow/initial_setup/starter_projects/Financial Report Parser.json +43 -0
- langflow/initial_setup/starter_projects/Hybrid Search RAG.json +83 -1
- langflow/initial_setup/starter_projects/Image Sentiment Analysis.json +43 -0
- langflow/initial_setup/starter_projects/Instagram Copywriter.json +49 -1
- langflow/initial_setup/starter_projects/Invoice Summarizer.json +40 -1
- langflow/initial_setup/starter_projects/Knowledge Ingestion.json +71 -0
- langflow/initial_setup/starter_projects/Knowledge Retrieval.json +63 -0
- langflow/initial_setup/starter_projects/Market Research.json +57 -1
- langflow/initial_setup/starter_projects/Meeting Summary.json +95 -0
- langflow/initial_setup/starter_projects/Memory Chatbot.json +35 -0
- langflow/initial_setup/starter_projects/News Aggregator.json +61 -1
- langflow/initial_setup/starter_projects/Nvidia Remix.json +67 -2
- langflow/initial_setup/starter_projects/Pok/303/251dex Agent.json" +48 -1
- langflow/initial_setup/starter_projects/Portfolio Website Code Generator.json +43 -0
- langflow/initial_setup/starter_projects/Price Deal Finder.json +53 -1
- langflow/initial_setup/starter_projects/Research Agent.json +40 -1
- langflow/initial_setup/starter_projects/Research Translation Loop.json +66 -0
- langflow/initial_setup/starter_projects/SEO Keyword Generator.json +17 -0
- langflow/initial_setup/starter_projects/SaaS Pricing.json +27 -1
- langflow/initial_setup/starter_projects/Search agent.json +40 -1
- langflow/initial_setup/starter_projects/Sequential Tasks Agents.json +72 -3
- langflow/initial_setup/starter_projects/Simple Agent.json +57 -1
- langflow/initial_setup/starter_projects/Social Media Agent.json +77 -1
- langflow/initial_setup/starter_projects/Text Sentiment Analysis.json +34 -0
- langflow/initial_setup/starter_projects/Travel Planning Agents.json +51 -3
- langflow/initial_setup/starter_projects/Twitter Thread Generator.json +80 -0
- langflow/initial_setup/starter_projects/Vector Store RAG.json +109 -2
- langflow/initial_setup/starter_projects/Youtube Analysis.json +82 -1
- langflow/initial_setup/starter_projects/vector_store_rag.py +1 -1
- langflow/processing/process.py +3 -0
- langflow/services/auth/mcp_encryption.py +104 -0
- langflow/services/settings/feature_flags.py +1 -1
- {langflow_base_nightly-0.5.0.dev38.dist-info → langflow_base_nightly-0.5.0.dev39.dist-info}/METADATA +1 -1
- {langflow_base_nightly-0.5.0.dev38.dist-info → langflow_base_nightly-0.5.0.dev39.dist-info}/RECORD +229 -211
- langflow/components/vectorstores/redis.py +0 -89
- langflow/frontend/assets/index-BWgIWfv2.js +0 -1
- langflow/frontend/assets/index-CqS7zir1.css +0 -1
- langflow/frontend/assets/lazyIconImports-DTNgvPE-.js +0 -2
- /langflow/components/{vectorstores → FAISS}/faiss.py +0 -0
- /langflow/components/{vectorstores → cassandra}/cassandra.py +0 -0
- /langflow/components/{datastax/cassandra.py → cassandra/cassandra_chat.py} +0 -0
- /langflow/components/{vectorstores → cassandra}/cassandra_graph.py +0 -0
- /langflow/components/{vectorstores → chroma}/chroma.py +0 -0
- /langflow/components/{vectorstores → clickhouse}/clickhouse.py +0 -0
- /langflow/components/{vectorstores → couchbase}/couchbase.py +0 -0
- /langflow/components/{vectorstores → datastax}/astradb.py +0 -0
- /langflow/components/{vectorstores → datastax}/astradb_graph.py +0 -0
- /langflow/components/{vectorstores → datastax}/graph_rag.py +0 -0
- /langflow/components/{vectorstores → datastax}/hcd.py +0 -0
- /langflow/components/{vectorstores → elastic}/elasticsearch.py +0 -0
- /langflow/components/{vectorstores → elastic}/opensearch.py +0 -0
- /langflow/components/{vectorstores → milvus}/milvus.py +0 -0
- /langflow/components/{vectorstores → mongodb}/mongodb_atlas.py +0 -0
- /langflow/components/{vectorstores → pgvector}/pgvector.py +0 -0
- /langflow/components/{vectorstores → pinecone}/pinecone.py +0 -0
- /langflow/components/{vectorstores → qdrant}/qdrant.py +0 -0
- /langflow/components/{vectorstores → supabase}/supabase.py +0 -0
- /langflow/components/{vectorstores → upstash}/upstash.py +0 -0
- /langflow/components/{vectorstores → vectara}/vectara.py +0 -0
- /langflow/components/{vectorstores → vectara}/vectara_rag.py +0 -0
- /langflow/components/{vectorstores → weaviate}/weaviate.py +0 -0
- {langflow_base_nightly-0.5.0.dev38.dist-info → langflow_base_nightly-0.5.0.dev39.dist-info}/WHEEL +0 -0
- {langflow_base_nightly-0.5.0.dev38.dist-info → langflow_base_nightly-0.5.0.dev39.dist-info}/entry_points.txt +0 -0
|
@@ -31,9 +31,7 @@ class PerplexityComponent(LCModelComponent):
|
|
|
31
31
|
],
|
|
32
32
|
value="llama-3.1-sonar-small-128k-online",
|
|
33
33
|
),
|
|
34
|
-
IntInput(
|
|
35
|
-
name="max_output_tokens", display_name="Max Output Tokens", info="The maximum number of tokens to generate."
|
|
36
|
-
),
|
|
34
|
+
IntInput(name="max_tokens", display_name="Max Output Tokens", info="The maximum number of tokens to generate."),
|
|
37
35
|
SecretStrInput(
|
|
38
36
|
name="api_key",
|
|
39
37
|
display_name="Perplexity API Key",
|
|
@@ -57,20 +55,13 @@ class PerplexityComponent(LCModelComponent):
|
|
|
57
55
|
"Note that the API may not return the full n completions if duplicates are generated.",
|
|
58
56
|
advanced=True,
|
|
59
57
|
),
|
|
60
|
-
IntInput(
|
|
61
|
-
name="top_k",
|
|
62
|
-
display_name="Top K",
|
|
63
|
-
info="Decode using top-k sampling: consider the set of top_k most probable tokens. Must be positive.",
|
|
64
|
-
advanced=True,
|
|
65
|
-
),
|
|
66
58
|
]
|
|
67
59
|
|
|
68
60
|
def build_model(self) -> LanguageModel: # type: ignore[type-var]
|
|
69
61
|
api_key = SecretStr(self.api_key).get_secret_value()
|
|
70
62
|
temperature = self.temperature
|
|
71
63
|
model = self.model_name
|
|
72
|
-
|
|
73
|
-
top_k = self.top_k
|
|
64
|
+
max_tokens = self.max_tokens
|
|
74
65
|
top_p = self.top_p
|
|
75
66
|
n = self.n
|
|
76
67
|
|
|
@@ -78,8 +69,7 @@ class PerplexityComponent(LCModelComponent):
|
|
|
78
69
|
model=model,
|
|
79
70
|
temperature=temperature or 0.75,
|
|
80
71
|
pplx_api_key=api_key,
|
|
81
|
-
top_k=top_k or None,
|
|
82
72
|
top_p=top_p or None,
|
|
83
73
|
n=n or 1,
|
|
84
|
-
|
|
74
|
+
max_tokens=max_tokens,
|
|
85
75
|
)
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING, Any
|
|
4
|
+
|
|
5
|
+
from langflow.components._importing import import_mod
|
|
6
|
+
|
|
7
|
+
if TYPE_CHECKING:
|
|
8
|
+
from .pgvector import PGVectorStoreComponent
|
|
9
|
+
|
|
10
|
+
_dynamic_imports = {
|
|
11
|
+
"PGVectorStoreComponent": "pgvector",
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
__all__ = [
|
|
15
|
+
"PGVectorStoreComponent",
|
|
16
|
+
]
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
def __getattr__(attr_name: str) -> Any:
|
|
20
|
+
"""Lazily import pgvector components on attribute access."""
|
|
21
|
+
if attr_name not in _dynamic_imports:
|
|
22
|
+
msg = f"module '{__name__}' has no attribute '{attr_name}'"
|
|
23
|
+
raise AttributeError(msg)
|
|
24
|
+
try:
|
|
25
|
+
result = import_mod(attr_name, _dynamic_imports[attr_name], __spec__.parent)
|
|
26
|
+
except (ModuleNotFoundError, ImportError, AttributeError) as e:
|
|
27
|
+
msg = f"Could not import '{attr_name}' from '{__name__}': {e}"
|
|
28
|
+
raise AttributeError(msg) from e
|
|
29
|
+
globals()[attr_name] = result
|
|
30
|
+
return result
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
def __dir__() -> list[str]:
|
|
34
|
+
return list(__all__)
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING, Any
|
|
4
|
+
|
|
5
|
+
from langflow.components._importing import import_mod
|
|
6
|
+
|
|
7
|
+
if TYPE_CHECKING:
|
|
8
|
+
from .pinecone import PineconeVectorStoreComponent
|
|
9
|
+
|
|
10
|
+
_dynamic_imports = {
|
|
11
|
+
"PineconeVectorStoreComponent": "pinecone",
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
__all__ = [
|
|
15
|
+
"PineconeVectorStoreComponent",
|
|
16
|
+
]
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
def __getattr__(attr_name: str) -> Any:
|
|
20
|
+
"""Lazily import Pinecone components on attribute access."""
|
|
21
|
+
if attr_name not in _dynamic_imports:
|
|
22
|
+
msg = f"module '{__name__}' has no attribute '{attr_name}'"
|
|
23
|
+
raise AttributeError(msg)
|
|
24
|
+
try:
|
|
25
|
+
result = import_mod(attr_name, _dynamic_imports[attr_name], __spec__.parent)
|
|
26
|
+
except (ModuleNotFoundError, ImportError, AttributeError) as e:
|
|
27
|
+
msg = f"Could not import '{attr_name}' from '{__name__}': {e}"
|
|
28
|
+
raise AttributeError(msg) from e
|
|
29
|
+
globals()[attr_name] = result
|
|
30
|
+
return result
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
def __dir__() -> list[str]:
|
|
34
|
+
return list(__all__)
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING, Any
|
|
4
|
+
|
|
5
|
+
from langflow.components._importing import import_mod
|
|
6
|
+
|
|
7
|
+
if TYPE_CHECKING:
|
|
8
|
+
from .qdrant import QdrantVectorStoreComponent
|
|
9
|
+
|
|
10
|
+
_dynamic_imports = {
|
|
11
|
+
"QdrantVectorStoreComponent": "qdrant",
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
__all__ = [
|
|
15
|
+
"QdrantVectorStoreComponent",
|
|
16
|
+
]
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
def __getattr__(attr_name: str) -> Any:
|
|
20
|
+
"""Lazily import Qdrant components on attribute access."""
|
|
21
|
+
if attr_name not in _dynamic_imports:
|
|
22
|
+
msg = f"module '{__name__}' has no attribute '{attr_name}'"
|
|
23
|
+
raise AttributeError(msg)
|
|
24
|
+
try:
|
|
25
|
+
result = import_mod(attr_name, _dynamic_imports[attr_name], __spec__.parent)
|
|
26
|
+
except (ModuleNotFoundError, ImportError, AttributeError) as e:
|
|
27
|
+
msg = f"Could not import '{attr_name}' from '{__name__}': {e}"
|
|
28
|
+
raise AttributeError(msg) from e
|
|
29
|
+
globals()[attr_name] = result
|
|
30
|
+
return result
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
def __dir__() -> list[str]:
|
|
34
|
+
return list(__all__)
|
|
@@ -1,3 +1,37 @@
|
|
|
1
|
-
from
|
|
1
|
+
from __future__ import annotations
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
from typing import TYPE_CHECKING, Any
|
|
4
|
+
|
|
5
|
+
from langflow.components._importing import import_mod
|
|
6
|
+
|
|
7
|
+
if TYPE_CHECKING:
|
|
8
|
+
from .redis import RedisVectorStoreComponent
|
|
9
|
+
from .redis_chat import RedisIndexChatMemory
|
|
10
|
+
|
|
11
|
+
_dynamic_imports = {
|
|
12
|
+
"RedisVectorStoreComponent": "redis",
|
|
13
|
+
"RedisIndexChatMemory": "redis_chat",
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
__all__ = [
|
|
17
|
+
"RedisIndexChatMemory",
|
|
18
|
+
"RedisVectorStoreComponent",
|
|
19
|
+
]
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
def __getattr__(attr_name: str) -> Any:
|
|
23
|
+
"""Lazily import Redis components on attribute access."""
|
|
24
|
+
if attr_name not in _dynamic_imports:
|
|
25
|
+
msg = f"module '{__name__}' has no attribute '{attr_name}'"
|
|
26
|
+
raise AttributeError(msg)
|
|
27
|
+
try:
|
|
28
|
+
result = import_mod(attr_name, _dynamic_imports[attr_name], __spec__.parent)
|
|
29
|
+
except (ModuleNotFoundError, ImportError, AttributeError) as e:
|
|
30
|
+
msg = f"Could not import '{attr_name}' from '{__name__}': {e}"
|
|
31
|
+
raise AttributeError(msg) from e
|
|
32
|
+
globals()[attr_name] = result
|
|
33
|
+
return result
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
def __dir__() -> list[str]:
|
|
37
|
+
return list(__all__)
|
|
@@ -1,43 +1,89 @@
|
|
|
1
|
-
from
|
|
1
|
+
from pathlib import Path
|
|
2
2
|
|
|
3
|
-
from
|
|
3
|
+
from langchain.text_splitter import CharacterTextSplitter
|
|
4
|
+
from langchain_community.vectorstores.redis import Redis
|
|
4
5
|
|
|
5
|
-
from langflow.base.
|
|
6
|
-
from langflow.
|
|
7
|
-
from langflow.
|
|
6
|
+
from langflow.base.vectorstores.model import LCVectorStoreComponent, check_cached_vector_store
|
|
7
|
+
from langflow.helpers.data import docs_to_data
|
|
8
|
+
from langflow.io import HandleInput, IntInput, SecretStrInput, StrInput
|
|
9
|
+
from langflow.schema.data import Data
|
|
8
10
|
|
|
9
11
|
|
|
10
|
-
class
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
12
|
+
class RedisVectorStoreComponent(LCVectorStoreComponent):
|
|
13
|
+
"""A custom component for implementing a Vector Store using Redis."""
|
|
14
|
+
|
|
15
|
+
display_name: str = "Redis"
|
|
16
|
+
description: str = "Implementation of Vector Store using Redis"
|
|
17
|
+
name = "Redis"
|
|
14
18
|
icon = "Redis"
|
|
15
19
|
|
|
16
20
|
inputs = [
|
|
21
|
+
SecretStrInput(name="redis_server_url", display_name="Redis Server Connection String", required=True),
|
|
17
22
|
StrInput(
|
|
18
|
-
name="
|
|
19
|
-
|
|
20
|
-
IntInput(name="port", display_name="port", required=True, value=6379, info="Redis Port Number."),
|
|
21
|
-
StrInput(name="database", display_name="database", required=True, value="0", info="Redis database."),
|
|
22
|
-
MessageTextInput(
|
|
23
|
-
name="username", display_name="Username", value="", info="The Redis user name.", advanced=True
|
|
23
|
+
name="redis_index_name",
|
|
24
|
+
display_name="Redis Index",
|
|
24
25
|
),
|
|
25
|
-
|
|
26
|
-
|
|
26
|
+
StrInput(name="code", display_name="Code", advanced=True),
|
|
27
|
+
StrInput(
|
|
28
|
+
name="schema",
|
|
29
|
+
display_name="Schema",
|
|
27
30
|
),
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
name="
|
|
31
|
+
*LCVectorStoreComponent.inputs,
|
|
32
|
+
IntInput(
|
|
33
|
+
name="number_of_results",
|
|
34
|
+
display_name="Number of Results",
|
|
35
|
+
info="Number of results to return.",
|
|
36
|
+
value=4,
|
|
37
|
+
advanced=True,
|
|
31
38
|
),
|
|
39
|
+
HandleInput(name="embedding", display_name="Embedding", input_types=["Embeddings"]),
|
|
32
40
|
]
|
|
33
41
|
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
42
|
+
@check_cached_vector_store
|
|
43
|
+
def build_vector_store(self) -> Redis:
|
|
44
|
+
# Convert DataFrame to Data if needed using parent's method
|
|
45
|
+
self.ingest_data = self._prepare_ingest_data()
|
|
46
|
+
|
|
47
|
+
documents = []
|
|
48
|
+
for _input in self.ingest_data or []:
|
|
49
|
+
if isinstance(_input, Data):
|
|
50
|
+
documents.append(_input.to_lc_document())
|
|
51
|
+
else:
|
|
52
|
+
documents.append(_input)
|
|
53
|
+
Path("docuemnts.txt").write_text(str(documents), encoding="utf-8")
|
|
54
|
+
|
|
55
|
+
if not documents:
|
|
56
|
+
if self.schema is None:
|
|
57
|
+
msg = "If no documents are provided, a schema must be provided."
|
|
58
|
+
raise ValueError(msg)
|
|
59
|
+
redis_vs = Redis.from_existing_index(
|
|
60
|
+
embedding=self.embedding,
|
|
61
|
+
index_name=self.redis_index_name,
|
|
62
|
+
schema=self.schema,
|
|
63
|
+
key_prefix=None,
|
|
64
|
+
redis_url=self.redis_server_url,
|
|
65
|
+
)
|
|
66
|
+
else:
|
|
67
|
+
text_splitter = CharacterTextSplitter(chunk_size=1000, chunk_overlap=0)
|
|
68
|
+
docs = text_splitter.split_documents(documents)
|
|
69
|
+
redis_vs = Redis.from_documents(
|
|
70
|
+
documents=docs,
|
|
71
|
+
embedding=self.embedding,
|
|
72
|
+
redis_url=self.redis_server_url,
|
|
73
|
+
index_name=self.redis_index_name,
|
|
74
|
+
)
|
|
75
|
+
return redis_vs
|
|
76
|
+
|
|
77
|
+
def search_documents(self) -> list[Data]:
|
|
78
|
+
vector_store = self.build_vector_store()
|
|
79
|
+
|
|
80
|
+
if self.search_query and isinstance(self.search_query, str) and self.search_query.strip():
|
|
81
|
+
docs = vector_store.similarity_search(
|
|
82
|
+
query=self.search_query,
|
|
83
|
+
k=self.number_of_results,
|
|
84
|
+
)
|
|
41
85
|
|
|
42
|
-
|
|
43
|
-
|
|
86
|
+
data = docs_to_data(docs)
|
|
87
|
+
self.status = data
|
|
88
|
+
return data
|
|
89
|
+
return []
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
from urllib import parse
|
|
2
|
+
|
|
3
|
+
from langchain_community.chat_message_histories.redis import RedisChatMessageHistory
|
|
4
|
+
|
|
5
|
+
from langflow.base.memory.model import LCChatMemoryComponent
|
|
6
|
+
from langflow.field_typing.constants import Memory
|
|
7
|
+
from langflow.inputs.inputs import IntInput, MessageTextInput, SecretStrInput, StrInput
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class RedisIndexChatMemory(LCChatMemoryComponent):
|
|
11
|
+
display_name = "Redis Chat Memory"
|
|
12
|
+
description = "Retrieves and store chat messages from Redis."
|
|
13
|
+
name = "RedisChatMemory"
|
|
14
|
+
icon = "Redis"
|
|
15
|
+
|
|
16
|
+
inputs = [
|
|
17
|
+
StrInput(
|
|
18
|
+
name="host", display_name="hostname", required=True, value="localhost", info="IP address or hostname."
|
|
19
|
+
),
|
|
20
|
+
IntInput(name="port", display_name="port", required=True, value=6379, info="Redis Port Number."),
|
|
21
|
+
StrInput(name="database", display_name="database", required=True, value="0", info="Redis database."),
|
|
22
|
+
MessageTextInput(
|
|
23
|
+
name="username", display_name="Username", value="", info="The Redis user name.", advanced=True
|
|
24
|
+
),
|
|
25
|
+
SecretStrInput(
|
|
26
|
+
name="password", display_name="Password", value="", info="The password for username.", advanced=True
|
|
27
|
+
),
|
|
28
|
+
StrInput(name="key_prefix", display_name="Key prefix", info="Key prefix.", advanced=True),
|
|
29
|
+
MessageTextInput(
|
|
30
|
+
name="session_id", display_name="Session ID", info="Session ID for the message.", advanced=True
|
|
31
|
+
),
|
|
32
|
+
]
|
|
33
|
+
|
|
34
|
+
def build_message_history(self) -> Memory:
|
|
35
|
+
kwargs = {}
|
|
36
|
+
password: str | None = self.password
|
|
37
|
+
if self.key_prefix:
|
|
38
|
+
kwargs["key_prefix"] = self.key_prefix
|
|
39
|
+
if password:
|
|
40
|
+
password = parse.quote_plus(password)
|
|
41
|
+
|
|
42
|
+
url = f"redis://{self.username}:{self.password}@{self.host}:{self.port}/{self.database}"
|
|
43
|
+
return RedisChatMessageHistory(session_id=self.session_id, url=url, **kwargs)
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING, Any
|
|
4
|
+
|
|
5
|
+
from langflow.components._importing import import_mod
|
|
6
|
+
|
|
7
|
+
if TYPE_CHECKING:
|
|
8
|
+
from .supabase import SupabaseVectorStoreComponent
|
|
9
|
+
from .supabase_composio import SupabaseComposioComponent
|
|
10
|
+
|
|
11
|
+
_dynamic_imports = {
|
|
12
|
+
"SupabaseVectorStoreComponent": "supabase",
|
|
13
|
+
"SupabaseComposioComponent": "supabase_composio",
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
__all__ = [
|
|
17
|
+
"SupabaseComposioComponent",
|
|
18
|
+
"SupabaseVectorStoreComponent",
|
|
19
|
+
]
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
def __getattr__(attr_name: str) -> Any:
|
|
23
|
+
"""Lazily import Supabase components on attribute access."""
|
|
24
|
+
if attr_name not in _dynamic_imports:
|
|
25
|
+
msg = f"module '{__name__}' has no attribute '{attr_name}'"
|
|
26
|
+
raise AttributeError(msg)
|
|
27
|
+
try:
|
|
28
|
+
result = import_mod(attr_name, _dynamic_imports[attr_name], __spec__.parent)
|
|
29
|
+
except (ModuleNotFoundError, ImportError, AttributeError) as e:
|
|
30
|
+
msg = f"Could not import '{attr_name}' from '{__name__}': {e}"
|
|
31
|
+
raise AttributeError(msg) from e
|
|
32
|
+
globals()[attr_name] = result
|
|
33
|
+
return result
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
def __dir__() -> list[str]:
|
|
37
|
+
return list(__all__)
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING, Any
|
|
4
|
+
|
|
5
|
+
from langflow.components._importing import import_mod
|
|
6
|
+
|
|
7
|
+
if TYPE_CHECKING:
|
|
8
|
+
from .upstash import UpstashVectorStoreComponent
|
|
9
|
+
|
|
10
|
+
_dynamic_imports = {
|
|
11
|
+
"UpstashVectorStoreComponent": "upstash",
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
__all__ = [
|
|
15
|
+
"UpstashVectorStoreComponent",
|
|
16
|
+
]
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
def __getattr__(attr_name: str) -> Any:
|
|
20
|
+
"""Lazily import Upstash components on attribute access."""
|
|
21
|
+
if attr_name not in _dynamic_imports:
|
|
22
|
+
msg = f"module '{__name__}' has no attribute '{attr_name}'"
|
|
23
|
+
raise AttributeError(msg)
|
|
24
|
+
try:
|
|
25
|
+
result = import_mod(attr_name, _dynamic_imports[attr_name], __spec__.parent)
|
|
26
|
+
except (ModuleNotFoundError, ImportError, AttributeError) as e:
|
|
27
|
+
msg = f"Could not import '{attr_name}' from '{__name__}': {e}"
|
|
28
|
+
raise AttributeError(msg) from e
|
|
29
|
+
globals()[attr_name] = result
|
|
30
|
+
return result
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
def __dir__() -> list[str]:
|
|
34
|
+
return list(__all__)
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING, Any
|
|
4
|
+
|
|
5
|
+
from langflow.components._importing import import_mod
|
|
6
|
+
|
|
7
|
+
if TYPE_CHECKING:
|
|
8
|
+
from .vectara import VectaraVectorStoreComponent
|
|
9
|
+
from .vectara_rag import VectaraRagComponent
|
|
10
|
+
|
|
11
|
+
_dynamic_imports = {
|
|
12
|
+
"VectaraVectorStoreComponent": "vectara",
|
|
13
|
+
"VectaraRagComponent": "vectara_rag",
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
__all__ = [
|
|
17
|
+
"VectaraRagComponent",
|
|
18
|
+
"VectaraVectorStoreComponent",
|
|
19
|
+
]
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
def __getattr__(attr_name: str) -> Any:
|
|
23
|
+
"""Lazily import Vectara components on attribute access."""
|
|
24
|
+
if attr_name not in _dynamic_imports:
|
|
25
|
+
msg = f"module '{__name__}' has no attribute '{attr_name}'"
|
|
26
|
+
raise AttributeError(msg)
|
|
27
|
+
try:
|
|
28
|
+
result = import_mod(attr_name, _dynamic_imports[attr_name], __spec__.parent)
|
|
29
|
+
except (ModuleNotFoundError, ImportError, AttributeError) as e:
|
|
30
|
+
msg = f"Could not import '{attr_name}' from '{__name__}': {e}"
|
|
31
|
+
raise AttributeError(msg) from e
|
|
32
|
+
globals()[attr_name] = result
|
|
33
|
+
return result
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
def __dir__() -> list[str]:
|
|
37
|
+
return list(__all__)
|
|
@@ -5,83 +5,14 @@ from typing import TYPE_CHECKING, Any
|
|
|
5
5
|
from langflow.components._importing import import_mod
|
|
6
6
|
|
|
7
7
|
if TYPE_CHECKING:
|
|
8
|
-
from .astradb import AstraDBVectorStoreComponent
|
|
9
|
-
from .astradb_graph import AstraDBGraphVectorStoreComponent
|
|
10
|
-
from .cassandra import CassandraVectorStoreComponent
|
|
11
|
-
from .cassandra_graph import CassandraGraphVectorStoreComponent
|
|
12
|
-
from .chroma import ChromaVectorStoreComponent
|
|
13
|
-
from .clickhouse import ClickhouseVectorStoreComponent
|
|
14
|
-
from .couchbase import CouchbaseVectorStoreComponent
|
|
15
|
-
from .elasticsearch import ElasticsearchVectorStoreComponent
|
|
16
|
-
from .faiss import FaissVectorStoreComponent
|
|
17
|
-
from .graph_rag import GraphRAGComponent
|
|
18
|
-
from .hcd import HCDVectorStoreComponent
|
|
19
8
|
from .local_db import LocalDBComponent
|
|
20
|
-
from .milvus import MilvusVectorStoreComponent
|
|
21
|
-
from .mongodb_atlas import MongoVectorStoreComponent
|
|
22
|
-
from .opensearch import OpenSearchVectorStoreComponent
|
|
23
|
-
from .pgvector import PGVectorStoreComponent
|
|
24
|
-
from .pinecone import PineconeVectorStoreComponent
|
|
25
|
-
from .qdrant import QdrantVectorStoreComponent
|
|
26
|
-
from .redis import RedisVectorStoreComponent
|
|
27
|
-
from .supabase import SupabaseVectorStoreComponent
|
|
28
|
-
from .upstash import UpstashVectorStoreComponent
|
|
29
|
-
from .vectara import VectaraVectorStoreComponent
|
|
30
|
-
from .vectara_rag import VectaraRagComponent
|
|
31
|
-
from .weaviate import WeaviateVectorStoreComponent
|
|
32
9
|
|
|
33
10
|
_dynamic_imports = {
|
|
34
|
-
"AstraDBVectorStoreComponent": "astradb",
|
|
35
|
-
"AstraDBGraphVectorStoreComponent": "astradb_graph",
|
|
36
|
-
"CassandraVectorStoreComponent": "cassandra",
|
|
37
|
-
"CassandraGraphVectorStoreComponent": "cassandra_graph",
|
|
38
|
-
"ChromaVectorStoreComponent": "chroma",
|
|
39
|
-
"ClickhouseVectorStoreComponent": "clickhouse",
|
|
40
|
-
"CouchbaseVectorStoreComponent": "couchbase",
|
|
41
|
-
"ElasticsearchVectorStoreComponent": "elasticsearch",
|
|
42
|
-
"FaissVectorStoreComponent": "faiss",
|
|
43
|
-
"GraphRAGComponent": "graph_rag",
|
|
44
|
-
"HCDVectorStoreComponent": "hcd",
|
|
45
11
|
"LocalDBComponent": "local_db",
|
|
46
|
-
"MilvusVectorStoreComponent": "milvus",
|
|
47
|
-
"MongoVectorStoreComponent": "mongodb_atlas",
|
|
48
|
-
"OpenSearchVectorStoreComponent": "opensearch",
|
|
49
|
-
"PGVectorStoreComponent": "pgvector",
|
|
50
|
-
"PineconeVectorStoreComponent": "pinecone",
|
|
51
|
-
"QdrantVectorStoreComponent": "qdrant",
|
|
52
|
-
"RedisVectorStoreComponent": "redis",
|
|
53
|
-
"SupabaseVectorStoreComponent": "supabase",
|
|
54
|
-
"UpstashVectorStoreComponent": "upstash",
|
|
55
|
-
"VectaraVectorStoreComponent": "vectara",
|
|
56
|
-
"VectaraRagComponent": "vectara_rag",
|
|
57
|
-
"WeaviateVectorStoreComponent": "weaviate",
|
|
58
12
|
}
|
|
59
13
|
|
|
60
14
|
__all__ = [
|
|
61
|
-
"AstraDBGraphVectorStoreComponent",
|
|
62
|
-
"AstraDBVectorStoreComponent",
|
|
63
|
-
"CassandraGraphVectorStoreComponent",
|
|
64
|
-
"CassandraVectorStoreComponent",
|
|
65
|
-
"ChromaVectorStoreComponent",
|
|
66
|
-
"ClickhouseVectorStoreComponent",
|
|
67
|
-
"CouchbaseVectorStoreComponent",
|
|
68
|
-
"ElasticsearchVectorStoreComponent",
|
|
69
|
-
"FaissVectorStoreComponent",
|
|
70
|
-
"GraphRAGComponent",
|
|
71
|
-
"HCDVectorStoreComponent",
|
|
72
15
|
"LocalDBComponent",
|
|
73
|
-
"MilvusVectorStoreComponent",
|
|
74
|
-
"MongoVectorStoreComponent",
|
|
75
|
-
"OpenSearchVectorStoreComponent",
|
|
76
|
-
"PGVectorStoreComponent",
|
|
77
|
-
"PineconeVectorStoreComponent",
|
|
78
|
-
"QdrantVectorStoreComponent",
|
|
79
|
-
"RedisVectorStoreComponent",
|
|
80
|
-
"SupabaseVectorStoreComponent",
|
|
81
|
-
"UpstashVectorStoreComponent",
|
|
82
|
-
"VectaraRagComponent",
|
|
83
|
-
"VectaraVectorStoreComponent",
|
|
84
|
-
"WeaviateVectorStoreComponent",
|
|
85
16
|
]
|
|
86
17
|
|
|
87
18
|
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
from typing import TYPE_CHECKING, Any
|
|
4
|
+
|
|
5
|
+
from langflow.components._importing import import_mod
|
|
6
|
+
|
|
7
|
+
if TYPE_CHECKING:
|
|
8
|
+
from .weaviate import WeaviateVectorStoreComponent
|
|
9
|
+
|
|
10
|
+
_dynamic_imports = {
|
|
11
|
+
"WeaviateVectorStoreComponent": "weaviate",
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
__all__ = [
|
|
15
|
+
"WeaviateVectorStoreComponent",
|
|
16
|
+
]
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
def __getattr__(attr_name: str) -> Any:
|
|
20
|
+
"""Lazily import Weaviate components on attribute access."""
|
|
21
|
+
if attr_name not in _dynamic_imports:
|
|
22
|
+
msg = f"module '{__name__}' has no attribute '{attr_name}'"
|
|
23
|
+
raise AttributeError(msg)
|
|
24
|
+
try:
|
|
25
|
+
result = import_mod(attr_name, _dynamic_imports[attr_name], __spec__.parent)
|
|
26
|
+
except (ModuleNotFoundError, ImportError, AttributeError) as e:
|
|
27
|
+
msg = f"Could not import '{attr_name}' from '{__name__}': {e}"
|
|
28
|
+
raise AttributeError(msg) from e
|
|
29
|
+
globals()[attr_name] = result
|
|
30
|
+
return result
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
def __dir__() -> list[str]:
|
|
34
|
+
return list(__all__)
|