kylecorry31/ML4K-AI-Extension

AddNumbersTrainingData

Opened this issue · 2 comments

Can you give an example to AddNumbersTrainingData?

When I try GotError gives

train
invalid data

Thanks

If you have a project with fields specified like this:

image

and labels like this:

image

then you can add training data from App Inventor like this:

image

which would result in this:

image

However, I think you have found a valid bug here, because if you have a project with multiple choice fields like this:

image

and labels like this

image

then the App Inventor blocks don't work, because if you do this:

image

you will get an "Invalid double" error.

@kylecorry31 I think we can't assume that number values are always double because Strings are valid for multiple-choice fields.
e.g.

public void addTrainingData(String label, List<Double> numbers) throws ML4KException {

I think numbers there should be a List<String> and so on.