nsi319 commited on
Commit
7a6d3d7
1 Parent(s): 3a8a250

Create README.md

Browse files
Files changed (1) hide show
  1. README.md +48 -0
README.md ADDED
@@ -0,0 +1,48 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ language: "en"
3
+ thumbnail: "https://huggingface.co/nsi319"
4
+ tags:
5
+ - xlnet
6
+ - pytorch
7
+ - text-classification
8
+ - mobile
9
+ - app
10
+ - descriptions
11
+ - playstore
12
+ - classification
13
+ license: "mit"
14
+ inference: true
15
+ ---
16
+
17
+ # Mobile App Classification
18
+
19
+ ## Model description
20
+
21
+ XLNet is a new unsupervised language representation learning method based on a novel generalized permutation language modeling objective. Additionally, XLNet employs Transformer-XL as the backbone model, exhibiting excellent performance for language tasks involving long context.
22
+
23
+ The [xlnet-base-cased](https://huggingface.co/xlnet-base-cased) model is fine-tuned to classify an mobile app description into one of **6 play store categories**.
24
+ Trained on 9000 samples of English App Descriptions and associated categories of apps available in [Google Play](https://play.google.com/store/apps).
25
+
26
+ ## Fine-tuning
27
+
28
+ The model was fine-tuned for 5 epochs with a batch size of 16, a learning rate of 2e-05, and a maximum sequence length of 512. Since this was a classification task, the model was trained with a cross-entropy loss function. The best evaluation f1 score achieved by the model was 0.8951433611497919, found after 5 epochs. The accuracy of the model on the test set was 0.895.
29
+
30
+ ## How to use
31
+
32
+ ```python
33
+ from transformers import AutoTokenizer, AutoModelForSequenceClassification, pipeline
34
+
35
+ tokenizer = AutoTokenizer.from_pretrained("nsi319/xlnet-base-cased-finetuned-app")
36
+ model = AutoModelForSequenceClassification.from_pretrained("nsi319/xlnet-base-cased-finetuned-app")
37
+
38
+ classifier = pipeline('sentiment-analysis', model=model, tokenizer=tokenizer)
39
+
40
+ classifier("The official Google Photos app is made for the way you take photos today and includes essential features like shared albums, automatic creations and an advanced editing suite. Additionally every Google Account comes with 15 GB of free storage and you can choose to automatically back up all your photos and videos in High quality or Original quality. You can then access them from any connected device and on photos.google.com.")
41
+
42
+ '''Output'''
43
+ [{'label': 'Photography', 'score': 0.998849630355835}]
44
+ ```
45
+
46
+ ## Limitations
47
+ Training data consists of apps from 6 play store categories namely Education, Entertainment, Productivity, Sports, News & Magazines and Photography.
48
+