5 min readUpdated Mar 2, 2026

bulkMessageAnalysis Documentation

Purpose

The bulkMessageAnalysis component is designed for sending a batch of messages to an AI service for aggregate analysis. This functionality allows users to gain insights from message data, such as sentiment analysis, topic extraction, and trend identification. It provides summaries and detailed breakdowns that are useful for understanding communication patterns over time across various channels.

Settings

The bulkMessageAnalysis component is configured with the following settings, each outlined in detail below:

1. messageColumn

2. analysisType

3. customPrompt

4. maxRows

5. includeMetadata

How It Works

  1. Data Preparation: The component first checks the input data. It attempts to extract message data from a potentially complex structure. If valid messages are not found, it returns an empty analysis result.

  2. Data Limitation: The configuration of maxRows limits the number of messages sent to the AI, ensuring the payload does not exceed manageable sizes.

  3. Payload Construction: Based on the includeMetadata setting, the component constructs the payload that will be sent to the AI. This payload is formatted according to the chosen messageColumn and captures all relevant details.

  4. Prompt Resolution: The prompt for analysis is decided based on the analysisType and potentially modified by the customPrompt. The template used is replaced with the message data to create a tailored request for the AI.

  5. AI Integration: The AI integration is retrieved based on user and client details. If successful, the constructed prompt is sent to the AI backend for processing.

  6. Response Handling: The response from the AI is captured, and the resulting summary and other details are structured and returned to the caller.

Data Expectations

The bulkMessageAnalysis component expects the input data to be in an array format, where each element represents an individual message object. Each message should ideally contain the following structure (though it can include other fields as well):

json
{
  "body": "The content of the message...",
  "timestamp": "2023-01-01T12:00:00Z",
  "channel": "Email",
  "category": "Support"
  // other metadata fields as needed
}

Use Cases & Examples

Use Cases

  1. Customer Support Analysis:

    • A customer support team can analyze trends in support tickets to understand most common issues, measure response times, and assess overall sentiment towards service resolutions.
  2. Social Media Engagement:

    • A marketing team might want to analyze social media messages to identify topics currently trending among customers, sentiment related to recent campaigns, and feedback on products.
  3. Internal Communication Insights:

    • An HR team can assess internal communication patterns to gauge employee sentiment, highlight common themes in feedback, and identify areas needing improvement.

Detailed Example

Use Case: Customer Support Analysis

To analyze support messages for trends and insights, the following configuration may be employed:

json
{
  "inputs": {
    "input1": [
      {"body": "I am having issues with my order.", "timestamp": "2023-10-01T10:00:00Z", "channel": "Support"},
      {"body": "The product did not meet my expectations.", "timestamp": "2023-10-01T12:00:00Z", "channel": "Support"},
      {"body": "How do I return an item?", "timestamp": "2023-10-02T09:15:00Z", "channel": "Support"}
      // add more messages as needed
    ]
  },
  "config": {
    "messageColumn": "body",
    "analysisType": "trends",
    "customPrompt": "",
    "maxRows": 100,
    "includeMetadata": true
  },
  "context": {
    "clientId": "client_123",
    "userId": "user_456"
  }
}

In this configuration: