Skip to content

sandeepsainath/BERT-Classifier-Rasa

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

BERT Classifier for Rasa NLU

This is Google's BERT Classifier implemented using the bert-sklearn wrapper for a Rasa chatbot. This component is only compatible with either Python 3.5 or Python 3.6.

A default config.yml file for a Rasa project is included in this repo. It replaces the default classifier (also uses scikit-learn) in the pre-configured Rasa pipeline pretrained_embeddings_spacy with this classifier.

The template of the component largely follows the same default scikit-learn intent classifier that uses Support Vector Machines (SVM) and GridSearchCV to optimize hyperparameters, but tweaked to implement the bert-sklearn wrapper as mentioned above.

This version currently uses the smallest possible version of BERT for fastest performance. To tweak the type of BERT model and other hyperparameters, modify the defaults dictionary values defined right under the BertClassifier class definition.

Note: Your bash_profile's PYTHONPATH must be modified for Rasa to identify your custom component. More information on this is in the custom component tutorial linked below.

Other Resources

About

BERT classifier as a Rasa NLU custom component

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages