Skip to main content

Creating vocabularies

Vocabulary enables you to add terms for Insight Advisor to use that are not present in the data. Vocabulary does not require you to have a custom logical model.

Vocabularies enable you to use terms to define values or selections of values from your data model.

Why create vocabularies?

Vocabulary is a key tool for preparing your app for natural language queries. Insight Advisor attempts to link all natural language queries to field names and values in your data. It cannot know all possible search terms that your app users might enter. Vocabulary lets you fill these terminology gaps, linking terms to fields and field values.

For example, in the tutorial app, you have some products that are swimwear. These items are in the category Beachwear in the data. In Insights, if you search for swimwear, you will not get any results. Similarly, you cannot search for footwear and get results for both men's and women's footwear.

Creating beachwear vocabulary

  1. From Prepare, click Vocabulary.

  2. Click Create vocabulary.

  3. In Terms, enter the following terms:

    • swimwear

    • swimsuits

  4. Under Applies to, select CategoryName.

  5. Under Condition, select In.

  6. Under In, select the following values:

    • Beachwear

  7. Click Create.

Creating footwear vocabulary

  1. From Prepare, click Vocabulary.

  2. Click Create vocabulary.

  3. In Terms, enterfootwear.

  4. Under Applies to, select CategoryName.

  5. Under Condition, select In.

  6. Under In, select the following values:

    • men's footwear
    • women's footwear

  7. Click Create.

Results

Navigate to Insights. Search for what is the average freight for footwear. You now receive results for both men's and women's footwear.

Next, search for gross profit for swimwear in 2019. You now get results for beachwear while searching with swimwear.

Thank you!

Now you have finished this tutorial, and hopefully you have gained some more knowledge about business logic and Insight Advisor in Qlik Sense.