Hub
Pricing About
ComponentComponent

Twitter RoBERTa Sentiment

SentimentBERTTransformer
vitaliikaplan profile image
VersionStable Created on  Aug 16, 2025 6:13 PM
Drag & drop
Like
Use or download

Twitter RoBERTa Sentiment Node

This node applies the twitter-roberta-base-sentiment-latest model from Hugging Face (CardiffNLP) to perform sentiment analysis on text data. The model is a RoBERTa-base transformer trained on Twitter data, designed to classify text into positive, neutral, or negative sentiment.

The node accepts two parameters:

  • Path to the Model: Absolute path to the directory containing the pre-downloaded Hugging Face model (for example: /Users/username/models/twitter-roberta-base-sentiment-latest).

  • Column From: The name of the column containing the text to be analyzed.

For each row of input text, the node produces three output columns:

  • positive_mean – mean confidence score across chunks classified as positive.

  • neutral_mean – mean confidence score across chunks classified as neutral.

  • negative_mean – mean confidence score across chunks classified as negative.

Additionally, a sentiment_status column is returned to indicate "ok" if processing succeeded, or the error message if it failed.

Requirements

You must have a Python environment with the following packages installed:

pip install torch torchvision torchaudio
pip install transformers

On macOS with Apple Silicon (M1/M2/M3), the node uses Metal (MPS) acceleration if available; on other systems it prefers CUDA (NVIDIA GPUs), else CPU.

Component details

Input ports
  1. Type: Table
    Text source
    The table containing the text to be evaluated.
Output ports
  1. Type: Table
    Results of evaluation
    The original table with additional columns containing the analysis results.

External resources

  • Hugging Face Transformers library

Used extensions & nodes

Created with KNIME Analytics Platform version 5.4.4
  • Go to item
    KNIME Base nodesTrusted extension

    KNIME AG, Zurich, Switzerland

    Version 5.4.4

    knime
  • Go to item
    KNIME Python IntegrationTrusted extension

    KNIME AG, Zurich, Switzerland

    Version 5.4.1

    knime
  • Go to item
    KNIME Quick FormsTrusted extension

    KNIME AG, Zurich, Switzerland

    Version 5.4.4

    knime

This component does not have nodes, extensions, nested components and related workflows

Legal

By using or downloading the component, you agree to our terms and conditions.

KNIME
Open for Innovation

KNIME AG
Talacker 50
8001 Zurich, Switzerland
  • Software
  • Getting started
  • Documentation
  • Courses + Certification
  • Solutions
  • KNIME Hub
  • KNIME Forum
  • Blog
  • Events
  • Partner
  • Developers
  • KNIME Home
  • Careers
  • Contact us
Download KNIME Analytics Platform Read more about KNIME Business Hub
© 2026 KNIME AG. All rights reserved.
  • Trademarks
  • Imprint
  • Privacy
  • Terms & Conditions
  • Data Processing Agreement
  • Credits