ComfyUI > Nodes > ComfyUI-ListHelper > OpenRouter LLM

ComfyUI Node: OpenRouter LLM

Class Name

OpenRouterLLM

Category
ListHelper
Author
dseditor (Account age: 1543days)
Extension
ComfyUI-ListHelper
Latest Updated
2025-12-09
Github Stars
0.05K

How to Install ComfyUI-ListHelper

Install this extension via the ComfyUI Manager by searching for ComfyUI-ListHelper
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter ComfyUI-ListHelper in the search bar
After installation, click the Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • 16GB VRAM to 80GB VRAM GPU machines
  • 400+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 200+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

OpenRouter LLM Description

Facilitates OpenRouter API interactions through language model interface for text analysis and generation.

OpenRouter LLM:

The OpenRouterLLM node is designed to facilitate interactions with the OpenRouter API, enabling users to process requests through a language model interface. This node is particularly beneficial for those looking to integrate language model capabilities into their workflows, allowing for the analysis and generation of text based on user prompts. The primary goal of the OpenRouterLLM is to provide a seamless connection to the OpenRouter API, ensuring that users can leverage the power of language models without needing extensive technical knowledge. By handling API key management and request processing internally, the node simplifies the process of utilizing advanced language model features, making it accessible to a broader audience.

OpenRouter LLM Input Parameters:

api_key

The api_key parameter is a string input that requires the user's OpenRouter API key. This key is essential for authenticating requests to the OpenRouter API, allowing the node to access the language model services. Without a valid API key, the node cannot function properly, and users will be unable to process their requests. The default value is an empty string, and users must provide their own API key to enable the node's functionality.

user_prompt

The user_prompt parameter is a string input that allows users to specify the text they wish to analyze or generate responses for using the language model. This parameter supports multiline input, enabling users to provide detailed prompts for more complex interactions. The default value is a generic prompt, "Please analyze the provided content," but users can customize this to suit their specific needs and objectives.

enable_resize

The enable_resize parameter is a boolean flag that determines whether the output should be resized to specific dimensions. When set to True, the node will adjust the output size according to the target_width and target_height parameters. If False, the node will use a default size of 512x512 pixels. This parameter is crucial for users who need outputs of specific dimensions for their projects.

target_width

The target_width parameter specifies the desired width of the output when enable_resize is set to True. It allows users to define the horizontal dimension of the output, ensuring it meets their requirements. The default value is 512 pixels, but users can adjust this to fit their specific needs.

target_height

The target_height parameter specifies the desired height of the output when enable_resize is set to True. It allows users to define the vertical dimension of the output, ensuring it meets their requirements. The default value is 512 pixels, but users can adjust this to fit their specific needs.

resize_method

The resize_method parameter determines the algorithm used for resizing the output when enable_resize is True. The default method is "lanczos," which is known for its high-quality results. Users can choose other methods if they have specific preferences or requirements for the resizing process.

image_input_1, image_input_2, image_input_3

These parameters allow users to input images that can be processed alongside the text prompt. They are optional and can be used to provide additional context or data for the language model to consider during processing. Each parameter can accept an image input, and users can choose to provide one, two, or all three images depending on their needs.

OpenRouter LLM Output Parameters:

output_tensor

The output_tensor is a tensor that represents the processed result from the language model. It is the primary output of the node, containing the data generated or analyzed based on the user's prompt and any provided images. This output is crucial for users who need to further process or visualize the results in their workflows.

error_message

The error_message is a string output that provides feedback on the success or failure of the request. If the node encounters an issue, such as an invalid API key, this output will contain an error message detailing the problem. This is important for troubleshooting and ensuring that users can quickly identify and resolve any issues that arise during processing.

OpenRouter LLM Usage Tips:

  • Ensure that you provide a valid OpenRouter API key to avoid authentication errors and enable the node's functionality.
  • Customize the user_prompt to suit your specific needs, as a well-defined prompt can significantly enhance the quality of the language model's output.
  • Use the enable_resize parameter to control the dimensions of the output, especially if you have specific size requirements for your project.

OpenRouter LLM Common Errors and Solutions:

❌ 錯誤: 請提供OpenRouter API金鑰

  • Explanation: This error occurs when the node does not receive a valid API key, preventing it from authenticating with the OpenRouter API.
  • Solution: Ensure that you have entered a valid OpenRouter API key in the api_key parameter. Double-check the key for any typos or errors and try again.

OpenRouter LLM Related Nodes

Go back to the extension to check out more related nodes.
ComfyUI-ListHelper
RunComfy
Copyright 2025 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals. RunComfy also provides AI Models, enabling artists to harness the latest AI tools to create incredible art.