Skip to content

Sentiment Analysis

Analyze the sentiment of a text using a LLM

Sends the input text to a language model and asks it to classify the sentiment as one of positive, negative, or neutral by default, or into a custom set of categories you define. The model is instructed to respond with only the category name, with no explanation.

Use this node to classify the tone of customer feedback, reviews, support tickets, or social media text — for example, routing negative feedback to a different workflow branch than positive feedback.

SettingNotes
TextThe text to analyze the sentiment of. Rendered as a text area.
Options → Custom categoriesComma-separated list of custom sentiment categories to use instead of the default positive/negative/neutral. Rendered as a text area.
Options → System messageOptional additional system message appended to the analysis instructions. Rendered as a text area.

Returns { sentiment }, a string with the trimmed category name returned by the model (one of the default three categories, or one of your custom categories).

  • Model (required) — connect a language model dependency (e.g. Chat OpenAI). Used to classify the sentiment.

Connect a Chat OpenAI node to the Model dependency, feed text from an upstream node into Text, optionally set Custom categories (e.g. “angry, satisfied, confused”), then branch downstream logic on the sentiment output using a router or condition node.

  • If the output includes extra words instead of just the category, add a stronger instruction via the System message option, or verify the connected model follows instructions well.
  • Verify the Model dependency is connected — the node throws if no model is found.
  • Keep Custom categories short and mutually exclusive so the model can reliably pick one.