> ## Documentation Index
> Fetch the complete documentation index at: https://dripart-docs-custom-nodes-sdk-v2-frontend.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# ClaudeNode - ComfyUI Built-in Node Documentation

> Generate text responses from Anthropic's Claude models.

Generate text responses from Anthropic's Claude models. Provide a text prompt and optionally one or more images for multimodal context, and the node returns the model's generated text response.

## Inputs

Inputs are grouped into common settings, model-specific settings that appear when a model is selected, and optional reference images.

### Common Inputs

| Parameter       | Description                                                                                                  | Data Type      | Required | Range                                                                                                                                                          |
| --------------- | ------------------------------------------------------------------------------------------------------------ | -------------- | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `model`         | The Claude model used to generate the response. Selecting a model reveals model-specific settings below.     | DYNAMIC\_COMBO | Yes      | `"Opus 5"`<br />`"Opus 4.8"`<br />`"Fable 5"`<br />`"Sonnet 5"`<br />`"Opus 4.7"`<br />`"Opus 4.6"`<br />`"Sonnet 4.6"`<br />`"Sonnet 4.5"`<br />`"Haiku 4.5"` |
| `prompt`        | Text input to the model. (default: empty string)                                                             | STRING         | Yes      | N/A                                                                                                                                                            |
| `seed`          | Seed controls whether the node should re-run; results are non-deterministic regardless of seed. (default: 0) | INT            | Yes      | 0 to 2147483647                                                                                                                                                |
| `system_prompt` | Foundational instructions that dictate the model's behavior. (default: empty string)                         | STRING         | No       | N/A                                                                                                                                                            |

### Opus 5 and Fable 5 Inputs

These two models share the same settings. They do not expose a temperature setting, and reasoning is always enabled.

| Parameter          | Description                                                                                     | Data Type | Required | Range                                 |
| ------------------ | ----------------------------------------------------------------------------------------------- | --------- | -------- | ------------------------------------- |
| `max_tokens`       | Maximum number of tokens to generate (includes reasoning tokens when enabled). (default: 32768) | INT       | Yes      | 4096 to 64000                         |
| `reasoning_effort` | Extended thinking effort. Reasoning is always enabled for this model. (default: "high")         | COMBO     | Yes      | `"low"`<br />`"medium"`<br />`"high"` |

### Opus 4.8 and Sonnet 5 Inputs

These two models share the same settings. They do not expose a temperature setting.

| Parameter          | Description                                                                                     | Data Type | Required | Range                                              |
| ------------------ | ----------------------------------------------------------------------------------------------- | --------- | -------- | -------------------------------------------------- |
| `max_tokens`       | Maximum number of tokens to generate (includes reasoning tokens when enabled). (default: 32768) | INT       | Yes      | 4096 to 64000                                      |
| `reasoning_effort` | Extended thinking effort. `"off"` disables reasoning. (default: "off")                          | COMBO     | Yes      | `"off"`<br />`"low"`<br />`"medium"`<br />`"high"` |

### Opus 4.7, Opus 4.6, Sonnet 4.6, and Sonnet 4.5 Inputs

These four models share the same settings.

| Parameter          | Description                                                                                                                                      | Data Type | Required | Range                                              |
| ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------ | --------- | -------- | -------------------------------------------------- |
| `max_tokens`       | Maximum number of tokens to generate (includes reasoning tokens when enabled). (default: 32768)                                                  | INT       | Yes      | 4096 to 64000                                      |
| `temperature`      | Controls randomness. 0.0 is deterministic, 1.0 is most random. Ignored for Opus 4.7 and any model when `reasoning_effort` is set. (default: 1.0) | FLOAT     | Yes      | 0.0 to 1.0 (step: 0.01)                            |
| `reasoning_effort` | Extended thinking effort. `"off"` disables reasoning. (default: "off")                                                                           | COMBO     | Yes      | `"off"`<br />`"low"`<br />`"medium"`<br />`"high"` |

### Haiku 4.5 Inputs

This model does not expose a `reasoning_effort` setting.

| Parameter     | Description                                                                                                                                      | Data Type | Required | Range                   |
| ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------ | --------- | -------- | ----------------------- |
| `max_tokens`  | Maximum number of tokens to generate (includes reasoning tokens when enabled). (default: 32768)                                                  | INT       | Yes      | 4096 to 64000           |
| `temperature` | Controls randomness. 0.0 is deterministic, 1.0 is most random. Ignored for Opus 4.7 and any model when `reasoning_effort` is set. (default: 1.0) | FLOAT     | Yes      | 0.0 to 1.0 (step: 0.01) |

### Reference Inputs

| Parameter | Description                                                                                                                          | Data Type | Required | Range          |
| --------- | ------------------------------------------------------------------------------------------------------------------------------------ | --------- | -------- | -------------- |
| `images`  | Optional image(s) to use as context for the model. Up to 20 images. Growable slot: connect 1 to 20 items (`image_1` ... `image_20`). | IMAGE     | No       | 0 to 20 images |

### Parameter Constraints

* **Image limit:** A maximum of 20 images can be provided per request. Connecting more than 20 images raises an error.
* **Prompt required:** The prompt must contain at least one non-whitespace character. An empty prompt raises a validation error.
* **Temperature handling:** When thinking is enabled, the Anthropic API requires temperature to be unset (it defaults to 1.0). Opus 5, Opus 4.8, Fable 5, and Sonnet 5 do not expose a temperature setting. Opus 4.7 ignores `temperature`, and any model with `reasoning_effort` set to `"low"`, `"medium"`, or `"high"` also ignores it.
* **Reasoning/thinking behavior:** The `reasoning_effort` setting controls whether thinking is enabled. Opus 5 and Fable 5 always have reasoning enabled. Haiku 4.5 does not support reasoning. When thinking is enabled, the node uses the appropriate thinking mode for the selected model, either adaptive or budget-based. In budget mode, the reasoning token budget is capped to leave at least 1024 tokens for the actual response.
* **Safety refusal:** If Claude declines to answer the request for safety reasons, the node raises an error asking you to rephrase the prompt or try a different model.
* **Output text:** Thinking and reasoning blocks are not included in the output; only generated text is returned.

## Outputs

| Output Name | Description                                                                                                                                                         | Data Type |
| ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------- |
| `output`    | The generated text response from the Claude model. Thinking/reasoning blocks are not included. If no text is generated, returns "Empty response from Claude model." | STRING    |

> This documentation was AI-generated. If you find any errors or have suggestions for improvement, please feel free to contribute! [Edit on GitHub](https://github.com/Comfy-Org/embedded-docs/blob/main/comfyui_embedded_docs/docs/ClaudeNode/en.md)

***

**Source fingerprint (SHA-256):** `b0381e7981e5886d66b6976c7ddcad3f142bdd803271a6ac8567293dcddaa98a`
