Skip to main content
Glama

add_for_each_loop_node

Adds a For Each Loop node to a Blueprint to iterate over array elements, with optional break input and custom graph position.

Instructions

Add a 'For Each Loop' node (iterates over an Array).

Args: blueprint_name: Blueprint name with_break: Include a Break input to exit early node_position: Optional [X, Y] graph position

Returns: Dict with 'node_id'; pins: 'Array' input, 'Loop Body'/'Completed' outputs, 'Array Element' and 'Array Index' loop body outputs

KB: see knowledge_base/07_DATA_STRUCTURES.md#overview Example: add_for_each_loop_node(blueprint_name="/Game/MCP_Test/BP_Example")

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
with_breakNo
node_positionNo
blueprint_nameYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

B3.4/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the burden of behavioral disclosure. It explains that the tool adds node, iterates over an Array, and returns a dict with node_id and pin details, which is useful. It does not mention side effects such as whether the blueprint must be saved or compiled afterward, or whether the mutation is transactional, but the return-value disclosure partially compensates.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured with an opening summary, Args, Returns, KB pointer, and Example. Each section adds value without excessive verbosity. The only minor inefficiency is the duplication of parameter names between the Args block and what the schema already provides.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a relatively simple node-adding tool, the description is nearly complete: it covers parameters, return value, key pins, and an example invocation. The output schema exists and the description further details the returned dictionary. The main gap is the lack of usage guidance and differentiation from similar sibling tools.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, but the description documents all three parameters: blueprint_name, with_break, and node_position, with meaningful explanations and optionality hints. The example clarifies the expected blueprint_name format. This goes well beyond the schema, which only provides titles and types.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description uses a specific verb and resource: 'Add a For Each Loop node (iterates over an Array).' It clearly identifies what the tool creates and the fundamental behavior of the node. However, it does not distinguish itself from the sibling 'add_blueprint_for_each_loop_node', which appears to serve a similar role.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No explicit guidance is given for when to use this tool versus alternatives such as add_blueprint_for_each_loop_node, add_blueprint_for_loop_node, or add_while_loop_node. The KB reference and example provide incidental context, but the description does not state when this tool is the right choice or when another node-adding tool would be preferred.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools