All Projects → kylecorry31 → ML4K-AI-Extension

kylecorry31 / ML4K-AI-Extension

Licence: MIT license
Use machine learning in AppInventor, with easy training using text, images, or numbers through the Machine Learning for Kids website.

Programming Languages

java
68154 projects - #9 most used programming language
javascript
184084 projects - #8 most used programming language
HTML
75241 projects
shell
77523 projects
Batchfile
5799 projects
Makefile
30231 projects
python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to ML4K-AI-Extension

DynamicComponents-AI2
An App Inventor extension to add full support for creating any type of component at runtime, in your app.
Stars: ✭ 47 (+161.11%)
Mutual labels:  aix, appinventor, appinventorextension
Ml Classify Text Js
Machine learning based text classification in JavaScript using n-grams and cosine similarity
Stars: ✭ 38 (+111.11%)
Mutual labels:  classifier, text-classification, classification
text2class
Multi-class text categorization using state-of-the-art pre-trained contextualized language models, e.g. BERT
Stars: ✭ 15 (-16.67%)
Mutual labels:  classifier, text-classification, classification
Keras transfer cifar10
Object classification with CIFAR-10 using transfer learning
Stars: ✭ 120 (+566.67%)
Mutual labels:  classifier, classification, image-classification
Rmdl
RMDL: Random Multimodel Deep Learning for Classification
Stars: ✭ 375 (+1983.33%)
Mutual labels:  text-classification, classification, image-classification
support-tickets-classification
This case study shows how to create a model for text analysis and classification and deploy it as a web service in Azure cloud in order to automatically classify support tickets. This project is a proof of concept made by Microsoft (Commercial Software Engineering team) in collaboration with Endava http://endava.com/en
Stars: ✭ 142 (+688.89%)
Mutual labels:  classifier, text-classification, classification
tensorflow-image-classifier
Easily train an image classifier and then use it to label/tag other images
Stars: ✭ 29 (+61.11%)
Mutual labels:  classifier, image-classification, image-classifier
Sytora
A sophisticated smart symptom search engine
Stars: ✭ 111 (+516.67%)
Mutual labels:  classifier, classification
tensorflow-image-classifier
image classifier, retrained for specific classes
Stars: ✭ 58 (+222.22%)
Mutual labels:  image-classification, image-classifier
NN-scratch
Coding up a Neural Network Classifier from Scratch
Stars: ✭ 78 (+333.33%)
Mutual labels:  classifier, classification
awesome-text-classification
Text classification meets word embeddings.
Stars: ✭ 27 (+50%)
Mutual labels:  text-classification, classification
Nepali-News-Classifier
Text Classification of Nepali Language Document. This Mini Project was done for the partial fulfillment of NLP Course : COMP 473.
Stars: ✭ 13 (-27.78%)
Mutual labels:  classifier, text-classification
Relation-Classification
Relation Classification - SEMEVAL 2010 task 8 dataset
Stars: ✭ 46 (+155.56%)
Mutual labels:  text-classification, classification
Multi Matcher
simple rules engine
Stars: ✭ 84 (+366.67%)
Mutual labels:  classifier, classification
Custom-CNN-based-Image-Classification-in-PyTorch
No description or website provided.
Stars: ✭ 41 (+127.78%)
Mutual labels:  image-classification, image-classifier
Fasttext.py
A Python interface for Facebook fastText
Stars: ✭ 1,091 (+5961.11%)
Mutual labels:  classifier, text-classification
backprop
Backprop makes it simple to use, finetune, and deploy state-of-the-art ML models.
Stars: ✭ 229 (+1172.22%)
Mutual labels:  text-classification, image-classification
classy
Super simple text classifier using Naive Bayes. Plug-and-play, no dependencies
Stars: ✭ 12 (-33.33%)
Mutual labels:  classifier, classification
classifier multi label
multi-label,classifier,text classification,多标签文本分类,文本分类,BERT,ALBERT,multi-label-classification
Stars: ✭ 127 (+605.56%)
Mutual labels:  text-classification, text-classifier
COVID-19-Tweet-Classification-using-Roberta-and-Bert-Simple-Transformers
Rank 1 / 216
Stars: ✭ 24 (+33.33%)
Mutual labels:  text-classification, classification

ML4K AppInventor Extension

Use machine learning in AppInventor, with easy training using text, images, or numbers through the Machine Learning for Kids website.

Download (.aix)

Example

Text classification

ML4K Text Example

Image classification

ML4K Image Example

Note: The ClassifyImage block takes the path to an image, which you can get from the Selected property of an ImagePicker.

Numbers classification

ML4K Number Example

Live examples

See example .aia projects in the examples directory of this repo (Created by Joe Mazzone). Look at the code blocks for where to add your API key (API key is not included), they are set in the click method - though you can set it anywhere you choose as long as it is before the classification occurs.

Installation

Download the latest extension file (.aix) from the releases page and follow section "2. How to use extensions components" of this website to add the extension to your App Inventor project.

Guide


If you received this extension from the ML4K website, your API key will be set for you and you don't need the block to set it - skip to step 1 and 2.


  1. After installing the extension, you need to get an API key, which can be obtained from Machine Learning for Kids. This API Key is not the IBM Watson API keys used to create your Machine Learning for Kids account. This key is created by Machine Learning for Kids and is specific to your project. It can be found on the App Inventor project page in the unique URL for your project.

       Or, the key can be found on the Python project page.

      Do not use the keys displayed in the images above. Use the keys from your project pages.

  1. Copy and paste the API Key into the ML4K component’s “Key” property on the Designer screen or use the "set Key" block on the Blocks screen. Note: API Key must be set before you can use any of the ML4K extension blocks for classification. If you choose to set the key using the “set Key” block, be sure to set the key in the Screen.Initialize event or any time before you use a classification method (purple block).

Set Key

  1. Classify the text, image, or numbers:
    a. If classifying text, use the "ClassifyText" block with the text to classify.

    b. If classifying images, use the "ClassifyImage" block with the image path to classify.

    c. If classifying numbers, use the "ClassifyNumbers" block with a list of numbers to classify.

  2. Use the "GotClassification" event block to retrieve the classification once it is completed.

  3. Use the "GotError" event block to retrieve any errors which occur during classification.

  4. Add data to your machine learning project with code:
    a. To add data to a text project use the "AddTextTrainingData" block, identifying the text data to add and label to add it to.

    b. To add data to an image project use the "AddImageTrainingData" block, identifying the image file to add and label to add it to.

    c. To add data to a numbers project use the "AddNumbersTrainingData" block, identifying the list of numbers and label to add it to.

  5. Use the "GetModelStatus" block to see if your model is ready to use or still in the process of training.

  6. Use the "GotStatus" event block to retrieve the status of the model.

    • statusCode 2 - "Ready" - The model is trained and ready to use.
    • statusCode 1 - "Training in progress" - The model is still training and cannot be used.
    • statusCode 0 - Something went wrong (or there isn't a model) - the 'message' variable will contain information on the issue.
  7. Use the "TrainNewModel" block to train your machine learning model with App Inventor.

    • Note: Using this block is optional for text or numbers projects, as models can be trained on the Machine Learning for Kids server from the "Learn & Test" page. However for Image projects, using this block is essential and must be used to create a model before an ML model can be used (because models are created and used on the mobile device)

Handling Errors

Upon an error, the "GotError" event block will be called with the error that occurred. Please use this event block fro debugging.

Building with preset API key

To build the extension, open a terminal and navigate to the release folder. Run the build_aix.py script, passing in the API key.

cd release
python build_aix.py <API KEY>

This will generate a ML4K.aix file which contains a preset API key.

To do this without the Python script, the file com.kylecorry.ml4k/assets/api.txt needs to be modified to have the API key in it. Then the whole folder (com.kylecorry.ml4k directory needs to be present in the top level of the zip file) needs to be zipped and renamed to have the .aix extension instead of .zip.

Building from source

Unix (Linux / Mac)

To build the extension from sources, you can use the makefile.

Requirements

  • make
  • ant
  • git

Building

make

This will create a directory called _build/dist which will contain the .aix file (without an API key).

Windows

To build the extension from sources, you can use the build.bat.

Requirements

  • ant
  • git

Building

.\build.bat

This will create a directory called _build/dist which will contain the .aix file (without an API key).

FAQ

The extension crashes while using an emulator: See this issue

License

This project is licensed under the MIT License.

Featured projects

Here are some community contributed projects which demonstrate awesome uses of the ML4K extension. All credits belong to the creators of these projects:

Credits

Contribute

Please feel free to contribute to this extension, or if you find an issue be sure to report it under issues.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].