跳到主要内容

Google组件

Bundles 包含支持与Langflow特定第三方集成的自定义组件。

本文档描述了 Google 包中可用的组件。

BigQuery

参见 BigQuery 组件

Google Generative AI

此组件使用 Google Generative AI 模型 生成文本。

Google Generative AI 参数

名称类型描述
Google API KeySecretString输入参数。用于Google Generative AI的Google API密钥。
ModelString输入参数。要使用的模型名称,如 "gemini-pro"
Max Output TokensInteger输入参数。要生成的最大令牌数。
TemperatureFloat输入参数。使用此温度运行推理。
Top KInteger输入参数。考虑前K个最可能的令牌集合。
Top PFloat输入参数。采样时要考虑的令牌的最大累积概率。
NInteger输入参数。为每个提示生成的聊天完成数量。
modelLanguageModel输出参数。使用指定参数配置的ChatGoogleGenerativeAI实例。

Google Generative AI Embeddings

Google Generative AI Embeddings 组件使用 langchain-google-genai 包中的 GoogleGenerativeAIEmbeddings 类连接到 Google 的生成式 AI 嵌入服务。

有关在流程中使用嵌入模型组件的更多信息,请参见 Embedding Model 组件

Google Generative AI Embeddings 参数

名称显示名称信息
api_keyAPI Key输入参数。用于访问 Google 生成式 AI 服务的秘密 API 密钥。必需。
model_nameModel Name输入参数。要使用的嵌入模型名称。默认值:"models/text-embedding-004"。
embeddingsEmbeddings输出参数。构建的 GoogleGenerativeAIEmbeddings 对象。

Google Search API

此组件允许您调用 Google Search API。

Google Search API 参数

名称类型描述
google_api_keySecretString输入参数。用于身份验证的 Google API 密钥。
google_cse_idSecretString输入参数。Google 自定义搜索引擎 ID。
input_valueString输入参数。搜索查询输入。
kInteger输入参数。要返回的搜索结果数量。
resultsList[Data]输出参数。搜索结果列表。
toolTool输出参数。用于 LangChain 的 Google Search 工具。

Serper Google Search API

此组件允许您调用 Serper.dev Google Search API。

Google Serper API 参数

名称类型描述
serper_api_keySecretString输入参数。用于 Serper.dev 身份验证的 API 密钥。
input_valueString输入参数。搜索查询输入。
kInteger输入参数。要返回的搜索结果数量。
resultsList[Data]输出参数。搜索结果列表。
toolTool输出参数。用于 LangChain 的 Serper Google Search 工具。

Google Vertex AI

有关 Vertex AI 组件的信息,请参见 Vertex AI

传统的 Google 组件

以下 Google 组件被视为传统组件。 您仍然可以在流程中使用它们,但它们已不再受支持,并且可能会在未来的版本中被移除。

作为这些组件的替代方案,您可以使用 Composio 组件 将您的流程连接到 Google 服务。

Google OAuth Token

Google OAuth Token 组件已在 Langflow 1.4.0 中弃用。

要将您的流程连接到 Google OAuth 服务,请使用 Composio 组件

Gmail Loader

此组件使用 Service Account JSON 凭据和标签 ID 过滤器从 Gmail 加载电子邮件。

作为替代方案,您可以使用 Composio 组件 将您的流程连接到 Google 服务。

Google Drive Loader

此组件使用 Service Account JSON 凭据和文档 ID 过滤器从 Google Drive 加载文档。

虽然没有直接替代方案,但可以考虑使用 API Request 组件 来调用 Google Drive API。

Google Drive Search

此组件使用 Service Account JSON 凭据和各种查询字符串和过滤器来搜索 Google Drive。

虽然没有直接替代方案,但可以考虑使用 API Request 组件 来调用 Google Drive API。

另请参阅

Search