AI visual [Technical Preview]

Cloudera Data Visualization enables you to embed interactive and actionable elements within your dashboards and applications. The AI visual introduces a natural language interface for interacting with dashboards and datasets. It leverages text input and speech detection with interactive data visualization to provide an intuitive user experience. The AI visual is a powerful tool for enhancing your dashboards. It helps you to obtain data insights through interactive conversations about the information stored in a dataset.

How does it work?

When added to a dashboard, the AI visual connects to a vector database (Solr 9 or SQLite). It queries this database based on user-entered text, providing augmented chat support. Results resembling your query are sent to the specified large language completion model defined in the site settings. The model processes the information and displays the results within the visual as a text response.

How to use it?

You can simply ask a question and the AI visual provides a textual response. After configuring and adding the visual to your dahsboard, you can interact with it by entering your question into the text box. You can also use the [microphone] icon to ask your question. The system will detect your speech, convert it to text, and enter it to the text box. The AI visual will provide a response based on the underlying data. You can ask further questions or refine your queries through voice or text, and the system will offer additional insights by updating the visualizations accordingly.

To explore the data behind the AI visual's response, you can click the [info] button to reveal the underlying data. The information displayed is based on the settings defined for Tooltips when the visual was created. Additionally, you can explore other components of the dashboard to validate your insights and enhance your analysis.

The following steps demonstrate how to create an AI visual. For an overview of the shelves that specify this visual, see Shelves for AI visual.

Before using the AI visual in Cloudera Data Visualization, ensure the following prerequisites are met:

  • Enable the AI visual feature in Site Settings > AI Settings > General > Enable AI visual (Tech Preview). For more information, see Managing AI settings.
  • Select the AI engine and configure the necessary settings for the selected engine. For more information, see Managing AI settings.
  • Ensure the data you intend to use with the AI visual has been vectorized.
  • Ensure that a data connection has been configured for a data source that supports columns of vector type.
    • If using Solr as the vector database, note that Solr vector database integration in Cloudera Data Visualization requires Solr 9 and does not work with Solr 8.
  1. Upload a CSV file that contains the required data to a supported vector database connection type.
    For data upload instructions, see Importing data in CSV format.
  2. Create a dataset from the uploaded data.
    For instructions, see Creating a dataset.
  3. Create a new dashboard.
    For instructions, see Creating a dashboard.
  4. Add the AI visual to the dashboard.
    1. In the VISUALS menu, click the icon of the AI visual.
    2. Populate the shelves from the fields available in the DATA pane.
      1. Embeddings: Add vector fields containing embeddings.
      2. Embedding Context: Add fields that you want to include in the chat prompt.
      3. Tooltip: Define the source information to be included in the result. This information appears when the user hovers over the response's Info icon, but it is not sent to the completion service.
      4. Limit: Define the number of data rows from the vector database that are processed by the visual.

      For more information, see Shelves for AI visual .

  5. Configure the visual settings by clicking Settings in the right-side VISUAL menu.
    1. Display
      1. Customize the chat welcome message, which is displayed as the first chat message from the AI visual.
      2. Set the display format for the conversation.

        You have two options: plain text or markdown

    2. Embeddings
      1. Maximum tokens: Set the maximum number of tokens. You can provide a zero or negative value to disable this setting.
      2. Selected profile: Displays the default profile, which you can change if needed.
    3. Completion
      1. Selected profile: Displays the default profile, which you can change if needed.
      2. Maximum tokens: Set a limit for the tokens. If exceeded, the request is not sent to the service and an error message is displayed.
      3. Context Overflow Policy: Choose how to handle situations where the length of generated tokens exceeds the context window size:
        • Throw an error: Raises an error when the conversation length exceeds the defined context window.
        • Remove old conversation first: Automatically manages conversation length by removing old tokens.
        • Truncate embedding context first: Truncates the embedding context, retaining the latest tokens.
      4. Context prompt: Specify the first prompt message for the chat.
      5. Question prompt: Specify the formatting of the user question.