Modalities

Manage and set up advanced payloads with Modalities in NLX

What are Modalities?

Modalities are reusable structured UI components that bring richer interactivity to NLX conversations. They're sent on the final message of a turn and complement text responses by helping users take action or view richer content; for example, selecting from a carousel, reviewing a card, rendering a video player, or confirming a date.

When a modality is sent, it’s rendered by your application’s frontend (chat, web, or mobile) and may guide the next user input or system action.

  • Where they may be used: Only on User choice, User input, or agentic Generative Journey nodes

  • Reusable blocks: Define once in the workspace and reuse across flows (e.g., the same carousel structure used for resort selection may be reused for credit card selection)

  • Structured payloads: Can include nested data (titles, images, links, metadata), unlike simple text

circle-info

Each workspace comes equipped with pre-defined Touchpoint modalities that you may use in your flows and can be rendered easily in test chats, or you may create modalities to add custom interactivity to your apps.

To access, click Resources in your workspace menu and choose Modalities:

spinner

Pre-defined modalities

NLX now includes a growing set of built-in Touchpoint modalities—pre-designed UI components that work out-of-the-box in both your workspace and Touchpoint. These modalities require no custom code, are already wired into NLX's Touchpoint SDK, and come with powerful data-mapping features that make it easy to plug real API responses into rich UI elements. They can be used in any conversation step that supports modalities (e.g., User choice, User input, or Agentic Generative Journey nodes).

They behave just like custom modalities but with two major advantages:

  1. Instant rendering: They appear automatically in Touchpoint without writing frontend code

  2. Schema-backed transformation: Transform node tools (Morph, Map, Loop, Define) help you reshape raw API data into exactly the schema the modality expects

This lets you create interactive multimodal conversations (date pickers, carousels, cards) directly in NLX, even when the upstream API returns data in a completely different structure.

Show users multiple options in a horizontally browsable card layout. Fully supports dynamic data via mapping or LLM-driven transforms.

Best if users need to:

  • Browse and select from multiple choices

  • Confirm or edit existing selections

Included schema:

Card

A single, focused card perfect for confirmations, summaries, or spotlighting information.

Best if users need to:

  • Review a specific item (e.g., reservation details, payment info)

  • A selected item preview after choosing from a carousel or list

  • Display a confirmation or summary

Included schema:

Date input

Let users pick a date using a native date selector.

Best if users need to:

  • Select a date or time for an event, appointment, reservation

  • Confirm an existing scheduled date

  • Capture a date for aa downstream data request

Included schema: No custom schema required. This modality simply triggers the built-in date picker and returns the selected date to the conversation.


Custom modalities

When your use case calls for unique visuals or interaction patterns beyond the predefined set, you can create custom modalities tailored to your application’s needs.

Each custom modality is defined as a reusable resource in your workspace with its own schema and frontend component.

  • Schema: Defines the structure of data your modality accepts (e.g., text, image URLs, links)

  • Component: Defines how that data is displayed in your front-end (via Touchpoint SDK or your own custom UI)

When a conversation reaches an end-of-turn node with your custom modality attached, NLX sends the structured payload to your front-end for rendering, just like predefined ones.

Begin by selecting New modality from the Modalities resource:

spinner
  • Enter a name

  • On the Schema tab, manually input schema or choose <>Auto-generate schema to easily generate a data structure based on sample JSON

  • Provide a description for each property if planning to assign the modality to an agent application or attached as a tool in an Agentic Generative Journey node

  • Click Save

Optional property settings (expand each property to view):

  • Sensitive setting: Enable to redact this data field's value from conversation logs for personally identifiable information (PII)

circle-info

Select the Code generation tab of your modality to easily retrieve the JSON or Typescript schema and copy it into your codebase for validation or type-safe rendering.

Use a modality

Once a modality has been created, you may enable its use easily in any flow:

For pre-defined modalities:

  • Select a flow > Place a User choice, User input, or Agentic Generative Journey node on the Canvas

    • For user nodes: Select the + Add functionality on the node's configuration panel > Choose Modality and select from the predefined modalities

    • For agentic Generative Journey: Attach the modality as a tool

  • [Optional] If the modality requires input (e.g., list of cards), map variables or enter values directly in the fields

  • Click Save on the Canvas

For custom modalities:

  • Select a flow > Place a User choice, User input, or Agentic Generative Journey node on the Canvas

    • For user nodes: Select the + Add functionality on the node's configuration panel > Choose Modality and select your custom modality created earlier

    • For agentic Generative Journey: Attach your modality as a tool

  • Enter payload details manually or use dynamic placeholders (slot values, data request output) into schema fields

  • Click Save on the Canvas

circle-info

Have mismatched schema? NLX can transform your data to match a modality’s schema with three different options (no code required!):

  1. Transform node using Morph

Quickly reshape API responses into a modality schema using generative AI. Great for prototyping or when the structure is highly variable.

  1. Transform node using Generative map

A new, high-performance transform that maps each item of an API list into the expected list-item schema of a modality.

For complex data models (deeply nested lists, objects), combine Loop + Define to extract schema properties and build deeply structured modality payloads deterministically (at any depth).

WhatsApp modalities

WhatsApp requires businesses to use templates for outbound messaging. NLX can send a template message to initiate a conversation with an end user via a modality.

Create a modality named WhatsAppTemplate

  • The schema should be an object with a single string property name (e.g., paste { "name": "" } using the <> Auto-generate schema option)

You may also send images that are cloud hosted. Create a modality named WhatsAppImage

  • The schema should be an object with the following schema (the caption is the "alt text", the link is the web-accessible link to the image)"

circle-info

When done, enable your WhatsApp modality on node(s) in your flow(s).

Last updated