mirror of
https://github.com/langflow-ai/langflow.git
synced 2026-07-25 04:10:28 +08:00
36 lines
1.8 KiB
Plaintext
36 lines
1.8 KiB
Plaintext
---
|
|
title: OpenRouter
|
|
slug: /bundles-openrouter
|
|
---
|
|
|
|
import Icon from "@site/src/components/icon";
|
|
import PartialParams from '@site/docs/_partial-hidden-params.mdx';
|
|
|
|
<Icon name="Blocks" aria-hidden="true" /> [**Bundles**](/components-bundle-components) contain custom components that support specific third-party integrations with Langflow.
|
|
|
|
This page describes the components that are available in the **OpenRouter** bundle.
|
|
|
|
For more information about OpenRouter features and functionality used by OpenRouter components, see the [OpenRouter documentation](https://openrouter.ai/docs).
|
|
|
|
## OpenRouter text generation
|
|
|
|
This component generates text using OpenRouter's unified API for multiple AI models from different providers.
|
|
|
|
It can output either a **Model Response** ([`Message`](/data-types#message)) or a **Language Model** ([`LanguageModel`](/data-types#languagemodel)).
|
|
|
|
Use the **Language Model** output when you want to use an OpenRouter model as the LLM for another LLM-driven component, such as an **Agent** or **Smart Transform** component.
|
|
|
|
For more information, see [Language model components](/components-models).
|
|
|
|
### OpenRouter text generation parameters
|
|
|
|
<PartialParams />
|
|
|
|
| Name | Type | Description |
|
|
|------|------|-------------|
|
|
| api_key | SecretString | Input parameter. Your OpenRouter API key for authentication. |
|
|
| model_name | Dropdown | Input parameter. The model to use for chat completion. Options are fetched live from the OpenRouter model catalog. |
|
|
| temperature | Float | Input parameter. Controls randomness in the output. Range: [0.0, 2.0]. Default: 0.7. |
|
|
| max_tokens | Integer | Input parameter. The maximum number of tokens to generate. |
|
|
| site_url | String | Input parameter. Your site URL for attribution in OpenRouter rankings. |
|
|
| app_name | String | Input parameter. Your app name for attribution in OpenRouter rankings. | |