Using huggingface + bert for sequences binary classification

Uri Valevski
1 min readJun 15, 2020

So you want to train a binary classifier over strings, using state of the art language models. All you really want is an API that gets two groups of strings and an example usage. You don’t really want to know about masks and encodings and special tokens just yet, you just want to experiment a bit. Well there you go.

In this example we learn to identify past vs present tense in <50 examples.

--

--