About data classes in the Unified Data Classification method

Important 

In Collibra 2024.05, we've launched a new user interface (UI) for Collibra Data Intelligence Platform! You can learn more about this latest UI in the UI overview.

Use the following options to see the documentation in the latest UI or in the previous, classic UI:

Data classes are the different groups you want to use to classify your data, for example, email, phone number, and web browser. You can create, update, and remove data classes. You can also import out-of-the-box data classes and update them.

The automatic data classification method uses the classification rules defined in a data class to verify whether an asset can be classified with the data class. A data class can contain multiple classification rules and the rules can have different types.

A data class in the Unified Data Classification method consists of the following elements:

Data class element Description
Name The name of the data class.
Enabled

Switch to indicate whether this data class needs to be taken into account during the data classification process.
If a data class is not enabled, the automatic data classification process doesn't consider this data class and the data class is also unavailable when you manually classify a column.
However, if a column is already classified with that data class, the classification is still valid.

This option can be useful if the data class is not ready for use or if it is in testing phase.

Description

The description of the data class.

The description can't exceed 10,000 characters.

Details  
Minimum confidence threshold

The confidence percentage that must be reached for the data class to be considered as a possible classification result. The confidence percentage refers to the percentage of values in a column that match at least one of the classification rules in a data class, for example, the regular expression.

Enter a value between 0 and 100.
The default value is 0.

Example If you add value 80 in this field, this data class will be suggested by the automatic data classification process only if the confidence percentage reaches 80 percent or higher.

Tip Confidence scores of 0 are never taken into account.

Include empty values

Indicates if you want to include empty values in the confidence percentage calculation.
The possible values are:

  • True True: If the value is set to true, empty values are taken into account by the data classification process when calculating the confidence percentage of a matching data class.
  • False False (Default): If the value is set to false, only the non-empty values are taken into account by the data classification process when calculating the confidence percentage of a matching data class.

This option can be used to receive an accurate confidence score for all data in a column.

Example 

You have a column Z with 40 empty values and 60 phone numbers. You have a data class A with a regular expression to detect US phone numbers.

  • If you set this option to False and you classify column Z, data class A could be suggested with a confidence percentage of 100.
  • If you set this option to True and you classify column Z , data class A could be suggested but with a confidence percentage of only 60.

Important Some regular expressions are constructed to allow a match with empty values. This means that, through the regular expression, empty values can be matched to the data class, which affects the confidence score.
Example:
This expression won't match empty values with the email data class:
^([a-zA-Z0-9._%\-]+@[a-zA-Z0-9.\-]+\.[a-zA-Z]{2,6})$
This expression will match empty values with the email data class:
^([a-zA-Z0-9._%\-]+@[a-zA-Z0-9.\-]+\.[a-zA-Z]{2,6})*$

Examples

Some examples of values that match the classification rule for the data class.

Add one example per line.

Classification rules

A data classification rule is used by the data classification process to calculate the confidence score, which is a percentage that indicates the likelihood that the data class fits the data in an asset.

A data class can contain multiple classification rules. Each rule is verified against the data, and the data class is assigned as soon as one of the rules applies.

Tip 
  • The maximum number of rules in a data class is 25.

  • A data class can also contain various types of classification rules.

    Example  You have defined the email data class with a regular expression. However, the values “unknown”, “invalid”, and “missing” are also acceptable email values in your data source. You can add a list of values as a second rule on the email data class. For the full example, go to Example: Configuring a data class with two classification rules.

Type

This is the type of classification rule. The possible values are: Regular expression or List of values.
Depending on your selection other fields appear.

Regular expression

This field appears if you select a classification rule of the type Regular expression.

A regular expression, also referred to as regex or regexp, is a sequence of characters that specifies a match pattern in text. Multiple regular expression grammar variants exist. We use the Java variant.

Example A regular expression for an email address can be ^[a-zA-Z0-9._%\-]+@[a-zA-Z0-9.\-]+\.[a-zA-Z]{2,6}$

Tip 
  • Multiple websites provide guidelines and examples of regular expressions, for example, Regexlib and RegexBuddy, or even ChatGPT.
  • You can also test your regular expression on various websites, for example, Regex101 (Select the Java 8 option in the Flavor panel).

The referenced websites serve only as examples. The use of ChatGPT or other generative AI products and services is at your own risk. Collibra is not responsible for the privacy, confidentiality, or protection of the data you submit to such products or services, and has no liability for such use.

Important 

The required format of the regular expression is different between the UI and the API. In the API backslashes must be added twice (escaped). In the UI, this is not needed. For example: In the
UI, use ^\+?\d{1,3}?\d{1,4}$, and in the API, use ^\\+?\d{1,3}?\\d{1,4}$.

Upload a file

This field appears if you select a classification rule of the type List of values.

Use this to upload a csv file with possible data class values. The file must contain one value per line. The maximum file size of 100 MB.

This method is mandatory if you want to add more than 1,000 values.

Download file

This field appears if you select a classification rule of the type List of values.
If you download a file, the name of the file is: listofvalues_ID of the data class rule.

Values

This field appears if you select a classification rule of the type List of values.

Add the values that define a specific data class.

Example 

A data class for T-shirt sizes based on a list of values could be:

S

M

L

small

medium

large

Important 
  • Add only one value per line.
  • The maximum number of characters in a single list value is 10,000.
  • Don’t add any leading or trailing blank characters in a value.
  • The values are not case-sensitive, the value “small” in the list will also be a match with the values “Small” and “SMALL”.
  • The maximum total number of values in one data class is 25,000. This number can be spread over multiple classification rules.
Description

A description of the classification rule.