Technical docs
Alloy AI Node (Agent Step)
Public reference generated from tech docs/alloy-ai-node.md.
Overview
The builder's "Alloy AI" node is the workflow step with `type: agent`.
Where it can be used
- `agent` workflows can contain only this node type. - `structured` workflows cannot use the Alloy AI node. - In the current builder, the node is single-purpose: - it must be connected directly from `Starting Step` - it has no normal outgoing branch UI like structured nodes
Required configuration
- `prompt` - `model` - optional tool allowlist
Model rules
- The main model must be a standard text model. - Validation rejects realtime, TTS, and STT models as the main model for this node.
Tool rules
- Tools come from the agent tool catalog in `agent-tools.md`. - The runtime also adds dynamic `skill.*` tools for the teammate's other assigned skills, excluding the current workflow. - `web.search` appears only when the selected model provider exposes native search. - Voice mode additionally injects `contact.send_message`, even if it was not selected in the node. - Runtime execution also loads MCP toolsets for the current employee alongside the selected Alloy tools.
Runtime behavior
- Prompt assembly uses organization variables, mode-specific system prompt text, current organization context, employee persona, current time, recent chat history, and conversation user info when available. - Runtime context inherits `WorkflowRun.state.runtimeContext` and adds `runId`, `organizationId`, `employeeId`, and `currentStepId`. - Execution runs through `AgentStepProcessor` and `MastraAgentExecutor`, which stream output, record token usage, persist/update conversation messages, and retry configured fallback chat models on non-terminal failures. - If the node has an output schema, the backend makes a second formatting call to turn the final text into that schema. - If image attachments are present in step input, only image attachments are injected into the model request. - Final output is either the structured object or `{ message: <text> }`.
Current delegation options
- `skill.<name>`: run another skill assigned to the same teammate. - `agent.call_teammate`: run another employee's default workflow. - `agent.run_subagent`: run a temporary child agent with a selected model and subset of agent tools.