Icon

Cleaning Data with Gen AI & KNIME

<p>Cleaning data in the classical way requires time and a lot of rules and calculations. In the following examples we are using Gen AI to help us clean data from a dataset to correct country names, customer names or date and time.</p>

🏦 Cleaning Data with Gen AI & KNIME

Cleaning data in the classical way requires time and a lot of rules and calculations. In the following examples we are using Gen AI to help us clean data from a dataset to correct country names, customer names or date and time.

🌎 1. Cleaning Country Names

Very simple use case. In our database (which will be provided by other suppliers, source countries may have their own data, different languages...). We will use KNIME to prepare the data and Gen AI to correct them. We just prepare the data, create a prompt and use value lookup to correct the data in the same column.


🕺 2. Cleaning Customer Names

Very similar to the previous use case. However in this case we also add the possibility of keeping "to revise" the name of the customer in case is too confusing that the LLM cannot really decide from the different names in our database. This will require human review using the T



🕰️ 3. Cleaning Date & Time

For this use case we do not use a “Golden Table” because we only need to correct the dates to a standard format in order to be able to work with this data afterwards.

Prompt Example

Your job is to clean and parse the date "2022-09-05 16:46:00 Please eliminate the timestamps and other additions. The Output should be in this format "DD-mm-YY" and just the correct date and nothing else. For example a correct output will be just "02-12-24".

Prompt Example

Your job is to find out what country the user means when they say "Allemagne" based on the following countries "Brazil, Canada, China, France, Germany, India, Italy, Spain, United Kingdom, United States" The Output should be just the correct country.

Prompt Example

Your job is to find out what customer name the user means when they say "Lis@ Br@ndt" based on the following countries "John Ryan, Patricia Peterson, David Bradley, Stacey Ward, Katie Rodriguez, Steven Hayes, ..." The Output should be just the correct name. If you are not sure give as output "to revise"

Sending the Promptsand Generating the Response
LLM Prompter
Generating the promptfor ChatGPT
Dynamic Prompt Builder
Generating the promptfor ChatGPT
String Manipulation
Replacing with the correctCustomerName
Value Lookup
Financial Transaction
Excel Reader
Financial Transaction
Excel Reader
Filtering 100
Row Filter
Column Renamer
We create a listwith correct name of countries
GroupBy
Table Row to Variable
Generating the promptfor ChatGPT
String Manipulation
Table Row to Variable
Filtering 100
Row Filter
Replacing with the correct DateTime
Value Lookup
We create a listwith correct name ofour customers
GroupBy
Provide yourOpen AI Credentialskeep "User" empty
Open AI Connection
Replacing with the correctCountryName
Value Lookup
Sending the Promptsand Generating the Response
LLM Prompter
Customer Names
Excel Reader
Filtering 100
Row Filter
Financial Transaction
Excel Reader
Correct Countries
Excel Reader
Provide yourOpen AI Credentialskeep "User" empty
Open AI Connection
Sending the Promptsand Generating the Response
LLM Prompter
Provide yourOpen AI Credentialskeep "User" empty
Open AI Connection

Nodes

Extensions

Links