Redis
Bundles 包含支援特定第三方整合的自訂Components,與 AgentBuilder 搭配使用。
此頁面描述 Redis bundle 中可用的Components。
Redis Chat Memory
Redis Chat Memory Components使用 Redis 記憶體儲存來擷取和儲存聊天訊息。
聊天記憶體作為 Memory 資料類型在記憶體儲存Components之間傳遞。
如需在FLOW中使用外部聊天記憶體的詳細資訊,請參閱 Message History Components。
Redis Chat Memory 參數
某些參數在視覺編輯器中預設為隱藏。 您可以透過 Components的標頭選單 中的 Controls 修改所有參數。
| Name | Display Name | Info |
|---|---|---|
| host | hostname | 輸入參數。IP 地址或主機名稱。 |
| port | port | 輸入參數。Redis 連接埠號碼。 |
| database | database | 輸入參數。Redis 資料庫。 |
| username | Username | 輸入參數。Redis 使用者名稱。 |
| password | Password | 輸入參數。使用者名稱的密碼。 |
| key_prefix | Key prefix | 輸入參數。金鑰前綴。 |
| session_id | Session ID | 輸入參數。訊息的唯一工作階段識別碼。 |
Redis 向量儲存
Redis 向量儲存Components使用 RedisVectorStore 實例讀取和寫入 Redis 向量儲存。
關於向量儲存實例
Because AgentBuilder is based on LangChain, vector store components use an instance of LangChain vector store to drive the underlying read and write functions. These instances are provider-specific and configured according to the component's parameters, such as the connection string, index name, and schema.
In component code, this is often instantiated as vector_store, but some vector store components use a different name, such as the provider name.
Some LangChain classes don't expose all possible options as component parameters. Depending on the provider, these options might use default values or allow modification through environment variables, if they are supported in AgentBuilder. For information about specific options, see the LangChain API reference and vector store provider's documentation.
如果您使用向量儲存Components查詢您的向量資料庫,它會產生搜尋結果,您可以將其作為 Data 物件清單或表格 DataFrame 傳遞給FLOW中的下游Components。
如果支援兩種類型,您可以在視覺編輯器中向量儲存Components的輸出連接埠附近設定格式。
如需在 Flow中使用向量資料庫的教學,請參閱建立向量 RAG 聊天機器人。
Redis 向量儲存參數
您可以檢查向量儲存Components的參數,以了解它接受的輸入、支援的功能以及如何配置它。
某些參數在視覺編輯器中預設為隱藏。 您可以透過 Components的標頭選單 中的 Controls 修改所有參數。
某些參數是條件性的,只有在您設定其他參數或為其他參數選取特定選項後才可用。 條件參數在您設定所需的依賴項之前,可能不會在 Controls 窗格中顯示。
如需接受值和功能的資訊,請參閱 Redis 文件 或檢查Components程式碼。
| Name | Type | Description |
|---|---|---|
| redis_server_url | SecretString | 輸入參數。Redis 伺服器連線字串。 |
| redis_index_name | String | 輸入參數。Redis 索引的名稱。 |
| code | String | 輸入參數。Redis 的其他自訂程式碼(如支援)。 |
| schema | String | 輸入參數。Redis 索引的結構描述。 |
| ingest_data | Data | 輸入參數。要擷取到向量儲存的資料。 |
| search_query | String | 輸入參數。相似性搜尋的查詢。 |
| embedding | Embeddings | 輸入參數。要使用的嵌入函數。 |
| number_of_results | Integer | 輸入參數。搜尋中要返回的結果數量。 |