IBM Watson NLC - How to retrain an existing classifier in Java SDK

134 views Asked by At

I want do add more examples to my classifier by java sdk. The idea is periodically increase the data size and improving the classifier. However, the docs only shows training option to create new classifier.

If I can't retrain, can I get the used data in the original classifier to train a new classifier by sdk?

In case of this features don't existing, what's the best approach? Increase my data locally and create new classifiers in each new train sending the whole database?

1

There are 1 answers

12
chughts On BEST ANSWER

There is no API to either update/retrain a classifier, nor to retrieve the training data of an existing classifier.

The corpora that the service generates do not have an update or reinforced learning option. Hence the need to generate a new corpus if there is a change in the training data.

Which also means that when the corpus is created there is no need for the service to keep the training data.

Summary of the discussion in comments:

If you want to get the effect of re-training a classifier, there are 2 approaches:

  • Use Watson studio to create your classifier / train classifier, after the initial train you will see an option to retrain the classifier
  • If you want to do it programmatically using the SDK, you can create and train the classifier as you would normally, and then delete the existing classifier and creating a new classifier with the new data set .

P.S: Under the hood Watson studio also deletes and creates a new classifier when you attempt to re-train