LLM Prompt
Generates text using a specified Large Language Model (LLM).
Inputs#
| Port | Description |
|---|---|
| The name of the model to use. Check the documentation for supported models. | |
| The text prompt to send to the LLM. | |
| The text prompt to send to the LLM. | |
| The API key for the selected cloud provider. |
Outputs#
| Port | Description |
|---|---|
| Executes if the text generation is successful. | |
| Executes if there is an error during text generation. | |
| The text generated by the LLM. |
Addendum#
This node sends a prompt to an LLM service and outputs the generated response.
Model Providers#
The provider is automatically selected based on the model name prefix:
- OpenAI: gpt- (e.g., gpt-4o)
- xAI (Grok): grok- (e.g., grok-4)
- Anthropic: claude- (e.g., claude-3-5-sonnet-20240620)
- Google AI: gemini- (e.g., gemini-1.5-pro)
- Mistral AI: mistral- or mixtral-
- Ollama: Any other name (e.g., llama3) is assumed to be a local model served by Ollama.
Authentication#
For LLM providers, you must provide an API key via the API key input. For local Ollama models, no key is needed.
ID: llm-prompt@v1