--- license: mit datasets: - shhossain/book-text-classifier language: - en pipeline_tag: text-classification widget: - text: "Shen Yuanye didn’t expect to go back to Huang Ni’s matter again, this matter of being killed without finding the murderer, who else could be beside her." example_title: "Book Text" - text: "I am so sorry this is a day late, guys. Unfortunately, my internet was down so it was out of my control. Its still intermittent but hopefully it will be fine by next week." example_title: "Normal Text" metrics: - accuracy model-index: - name: shhossain/bert-tiny-book-text-classifier results: - task: type: text-classification name: Text Classification dataset: type: shhossain/book-text-classifier name: book-text-classifier split: test metrics: - type: accuracy value: 0.999128 --- # Book Test Classifier Classify book text (mostly fictional book) ## Model Details ### Model Description This model is finetuned on bert-tiny for classifying book text. - **Developed by:** [shhossain](https://github.com/shhossain) - **Model type:** [Bert] - **Language(s) (NLP):** [English] - **License:** [MIT] - **Finetuned from model [Bert-Tiny]:** [bert-tiny](https://huggingface.co/prajjwal1/bert-tiny) ## Uses ```python from transformers import pipeline, AutoTokenizer tokenizer = AutoTokenizer.from_pretrained('prajjwal1/bert-tiny') pipe = pipeline('text-classification', model='shhossain/bert-tiny-book-text-classifier') book_text = """Shen Yuanye didn’t expect to go back to Huang Ni’s matter again, this matter of being killed without finding the murderer, who else could be beside her.""" pipe(book_text) # LABEL_1 >> [{'label': 'LABEL_1', 'score': 0.9998537302017212}] normal_text = """I am so sorry this is a day late, guys. Unfortunately, my internet was down so it was out of my control. Its still intermittent but hopefully it will be fine by next week. Hopefully the fact that Skye and Pietro are back in form will help make up for it.""" pipe(normal_text) # LABEL_0 >> [{'label': 'LABEL_0', 'score': 0.9984021782875061}] ```