> ## Documentation Index
> Fetch the complete documentation index at: https://docs.reliantlabs.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Node Types Reference

> Auto-generated API reference for workflow node type Input/Output schemas

This auto-generated reference documents the Input and Output schemas for workflow node types.
Descriptions are extracted from proto annotations in workflow\_v2.proto.

## Common Node Fields

These fields are available on **all** node types. They provide shared functionality for node identification, conditional execution, thread management, and output handling.

| Field          | Type              | Required | Description |
| -------------- | ----------------- | -------- | ----------- |
| `id`           | string            | Yes      |             |
| `type`         | string            | Yes      |             |
| `condition`    | string            | No       |             |
| `timeout`      | string            | No       |             |
| `save_message` | SaveMessageConfig | No       |             |
| `daemon`       | CelDaemonSelector | No       |             |
| `outcome`      | string            | No       |             |

### Thread Configuration

The `thread` field controls conversation context:

```yaml theme={null}
- id: analyze
  type: call_llm
  thread:
    mode: fork      # fork, new, or inherit (default)
    memo: true      # reuse across loop iterations
    inject:
      role: user
      content: "Analyze: {{inputs.data}}"
```

### Conditional Execution

Use `condition` to skip nodes based on runtime state:

```yaml theme={null}
- id: cleanup
  type: run
  condition: "{{nodes.process.exit_code != 0}}"
  run: "rm -rf temp/"
```

### Automatic Message Saving

Use `save_message` to capture output without a separate save\_message node:

```yaml theme={null}
- id: summarize
  type: workflow
  ref: builtin://summarizer
  thread:
    mode: fork
  save_message:
    role: assistant
    content: "{{output.summary}}"
```

***

## Agent

Invoke an agent or sub-workflow

### Inputs

| Field         | Type   | Required | Default | Description                                           |
| ------------- | ------ | -------- | ------- | ----------------------------------------------------- |
| `ref`         | string | No       | -       | Workflow reference (builtin://name or project://name) |
| `args`        | map    | No       | -       | Input values for the sub-workflow                     |
| `presets`     | map    | No       | -       | Preset configurations for sub-workflow inputs         |
| `passthrough` | string | No       | -       | Input names to forward from parent to child workflow  |

***

## Ask Question

Pause workflow execution to ask the user a question

### Inputs

| Field      | Type   | Required | Default | Description                                  |
| ---------- | ------ | -------- | ------- | -------------------------------------------- |
| `metadata` | string | No       | -       | JSON metadata with question text and options |

### Outputs

| Field          | Type    | Description |
| -------------- | ------- | ----------- |
| `has_feedback` | boolean | -           |
| `response`     | string  | -           |

***

## Call LLM

Send a prompt to a language model and get a response

### Inputs

| Field            | Type   | Required | Default | Description                                                                          |
| ---------------- | ------ | -------- | ------- | ------------------------------------------------------------------------------------ |
| `model`          | model  | No       | -       | Model selector using tags (e.g. flagship) or explicit ID                             |
| `temperature`    | number | No       | 0.7     | Temperature (0-1) controls randomness (range: 0-2)                                   |
| `thinking_level` | string | No       | none    | Extended thinking level for complex reasoning (enum: none\|low\|medium\|high\|xhigh) |
| `system_prompt`  | string | No       | -       | System message for this LLM call                                                     |
| `skills`         | array  | No       | -       | Namespaced skill paths to preload for this call (seeded as skill tool-interactions)  |

### Outputs

| Field                  | Type    | Description |
| ---------------------- | ------- | ----------- |
| `response_text`        | string  | -           |
| `token_count`          | integer | -           |
| `upstream_request_id`  | string  | -           |
| `upstream_proxyman_id` | string  | -           |
| `cost`                 | number  | -           |
| `compaction_threshold` | integer | -           |
| `model`                | string  | -           |
| `pending_inbox`        | boolean | -           |
| `message_id`           | string  | -           |
| `last_stream_seq`      | integer | -           |

***

## Compact

Compact conversation context to reduce token usage

### Inputs

| Field   | Type  | Required | Default | Description                                                                            |
| ------- | ----- | -------- | ------- | -------------------------------------------------------------------------------------- |
| `model` | model | No       | -       | Model used to summarize the conversation (defaults to the built-in summarization tier) |

***

## Create Worktree

Create a git worktree for isolated development

### Inputs

| Field         | Type    | Required | Default | Description                                  |
| ------------- | ------- | -------- | ------- | -------------------------------------------- |
| `name`        | string  | No       | -       | Worktree name, used in path                  |
| `base_branch` | string  | No       | -       | Base branch to branch from                   |
| `copy_files`  | string  | No       | -       | Files to copy from source repo (e.g. .env)   |
| `force`       | boolean | No       | -       | Force creation by deleting existing worktree |

### Outputs

| Field         | Type   | Description |
| ------------- | ------ | ----------- |
| `id`          | string | -           |
| `name`        | string | -           |
| `path`        | string | -           |
| `branch`      | string | -           |
| `base_branch` | string | -           |
| `repo_id`     | string | -           |
| `status`      | string | -           |

***

## Execute Tools

Execute tool calls from an LLM response

### Inputs

| Field        | Type   | Required | Default | Description                              |
| ------------ | ------ | -------- | ------- | ---------------------------------------- |
| `tool_calls` | string | No       | -       | CEL expression for tool calls to execute |

### Outputs

| Field                | Type    | Description |
| -------------------- | ------- | ----------- |
| `thread_token_count` | integer | -           |
| `total_result_chars` | integer | -           |

***

## Join

Wait for parallel branches to complete before continuing

***

## Loop

Execute a sub-workflow in a loop with conditions

### Inputs

| Field         | Type    | Required | Default | Description                                                                    |
| ------------- | ------- | -------- | ------- | ------------------------------------------------------------------------------ |
| `while`       | boolean | No       | -       | CEL condition: loop continues while true                                       |
| `parallel`    | boolean | No       | -       | Execute all iterations concurrently                                            |
| `items`       | string  | No       | -       | CEL expression evaluating to a list or map to iterate over                     |
| `key`         | string  | No       | -       | CEL expression for output map key per iteration                                |
| `on_failure`  | string  | No       | -       | Failure policy for parallel iterations (enum: continue\|fail\_fast\|fail\_all) |
| `passthrough` | string  | No       | -       | Input names to forward from parent to child workflow                           |

### Outputs

| Field        | Type    | Description |
| ------------ | ------- | ----------- |
| `iterations` | integer | -           |
| `results`    | map     | -           |
| `completed`  | integer | -           |
| `failed`     | integer | -           |
| `parallel`   | boolean | -           |

***

## Router

Route to a workflow or node based on LLM classification

### Inputs

| Field           | Type   | Required | Default | Description                                          |
| --------------- | ------ | -------- | ------- | ---------------------------------------------------- |
| `system_prompt` | string | No       | -       | Custom system prompt for the routing LLM             |
| `model`         | model  | No       | -       | Model for routing decision (defaults to fast model)  |
| `fallback`      | string | No       | -       | Fallback preset or node ID if routing decision fails |
| `outputs`       | map    | No       | -       | Declared output mappings (name → CEL expression)     |

### Outputs

| Field               | Type   | Description |
| ------------------- | ------ | ----------- |
| `selected_workflow` | string | -           |
| `selected_preset`   | string | -           |
| `prompt`            | string | -           |
| `reasoning`         | string | -           |
| `selected_node`     | string | -           |

***

## Run Command

Execute a shell command

### Inputs

| Field     | Type   | Required | Default | Description              |
| --------- | ------ | -------- | ------- | ------------------------ |
| `command` | string | No       | -       | Shell command to execute |

### Outputs

| Field         | Type    | Description |
| ------------- | ------- | ----------- |
| `exit_code`   | integer | -           |
| `stdout`      | string  | -           |
| `stderr`      | string  | -           |
| `working_dir` | string  | -           |
| `log_file`    | string  | -           |

***

## Save Message

Save a message to the conversation thread

### Inputs

| Field           | Type   | Required | Default | Description                                                  |
| --------------- | ------ | -------- | ------- | ------------------------------------------------------------ |
| `role`          | string | No       | -       | Message role (enum: user\|assistant\|system\|tool)           |
| `content`       | string | No       | -       | Message content                                              |
| `tool_calls`    | string | No       | -       | Tool calls from LLM response                                 |
| `display_style` | string | No       | -       | UI display style hint (enum: info\|warning\|success\|hidden) |

### Outputs

| Field                         | Type    | Description |
| ----------------------------- | ------- | ----------- |
| `message`                     | object  | -           |
| `message.id`                  | string  |             |
| `message.role`                | string  |             |
| `message.text`                | string  |             |
| `message_id`                  | string  | -           |
| `thread`                      | string  | -           |
| `tool_calls`                  | array   | -           |
| `tool_calls[].id`             | string  |             |
| `tool_calls[].name`           | string  |             |
| `tool_calls[].input`          | string  |             |
| `tool_results`                | array   | -           |
| `tool_results[].tool_call_id` | string  |             |
| `tool_results[].name`         | string  |             |
| `tool_results[].content`      | string  |             |
| `tool_results[].is_error`     | bool    |             |
| `thread_token_count`          | integer | -           |
| `message_count`               | integer | -           |

***
