This is Part 2 of the BERT Explanation & Implementation series. If you have not read Part 1 yet, it’s best to start from there. Let us continue from where we left off.

Data that I’m using have the following assumptions:

(1) The dataset contains multi-class labels, so we will be solving a multi-class classification problem. The label column is named “Scenario”.

(2) We will treat each message as a single sentence instead of multiple sentences. Thus each row in the “Message” column will be treated as one sentence. The reason for this is that we are not solving a question-and-answer type of problem. Rather, we want to solve a classification problem where we classify labels based on a message provided. We’d need to develop another parameter called token type ID to denote sentence separation in a given message to analyze the differences between one sentence and another if we were to solve a question-and-answer type of a problem. I will post another blog to specifically talk about this type of a problem in the future. A figure(a) below shows the difference.

#neural-networks #bert #python #nlp #deep-learning

Step-by-Step BERT Explanation & Implementation Part 2— Data Formatting & Loading
1.80 GEEK