agenthub · transform.compose_message
Assemble the canonical messages array — system, then history, then the current user turn — from three independent sources.
Why the node earns its place
It exists so Prompt Template, Memory Fetch and Chat Input can each stay focused on one job. The system prompt comes from one, the prior turns from another, the current text from a third, and this node is the only place that knows what order a model expects them in.
How it works at run time
system as the system message when present.history — prior turns, as Memory Fetch emits them.user text last.What you wire
Configuration
Nothing to configure — this node has no settings of its own.
What usually goes wrong
Watch for this
If the model complains about an empty messages array, the missing piece is usually user — Chat Input resolved nothing and emitted an empty string. Check there before rewiring this node.
Behaviour & provenance