Create your own custom text classifier model and deploy it on an Android app using TensorFlow Lite.
-
Clone the repository on your local machine.
-
Sign in to your Google account and upload the
Custom_Text_Classification.ipynbnotebook on Colab. -
Run the notebook cells one-by-one by following the instructions.
-
Once the TF Lite model is downloaded, copy the
.tflitemodel file insideCustom-Text-Classification-on-Android-using-TF-Lite/Android_App/lib_task_api/src/main/assetsdirectory. -
Open the project in Android Studio and let it build itself for some time.
-
Open
TextClassificationClient.javafile underlib_task_apiand edit Line 31 by replacing<your_model.tflite>with the name of your actual TF Lite model. -
Build the project and install it on your phone. Enjoy your own custom-build text classifier app.
Note: To build your custom dataset, refer the train.csv file for the format.
