Giter Club home page Giter Club logo

indolem's Introduction

🇮🇩 Welcome to IndoLEM and IndoBERT! 👋

Paper

Fajri Koto, Afshin, Rahimi, Jey Han Lau, and Timothy Baldwin. IndoLEM and IndoBERT: A Benchmark Dataset and Pre-trained Language Model for Indonesian NLP. In Proceedings of the 28th COLING, December 2020.

1. About IndoBERT

IndoBERT is the Indonesian version of BERT model. We train the model using over 220M words, aggregated from three main sources:

  • Indonesian Wikipedia (74M words)
  • news articles from Kompas, Tempo (Tala et al., 2003), and Liputan6 (55M words in total)
  • an Indonesian Web Corpus (Medved and Suchomel, 2017) (90M words).

We trained the model for 2.4M steps (180 epochs) with the final perplexity over the development set being 3.97 (similar to English BERT-base).

How to use

Load model and tokenizer (tested with transformers==3.5.1)

from transformers import AutoTokenizer, AutoModel
tokenizer = AutoTokenizer.from_pretrained("indolem/indobert-base-uncased")
model = AutoModel.from_pretrained("indolem/indobert-base-uncased")

2. About IndoLEM

IndoLEM (“Indonesian Language Evaluation Montage”) is a comprehensive Indonesian benchmark that comprises of seven tasks for the Indonesian language. This benchmark is categorized into three pillars of NLP tasks: morpho-syntax, semantics, and discourse.

We provide README file for each task. To find further information regarding each task, please click the related repository.

Experimental result over IndoLEM using mBERT, malayBERT and our IndoBERT:

Task Metric Bi-LSTM mBERT MalayBERT IndoBERT
POS Tagging Acc 95.4 96.8 96.8 96.8
NER UGM F1 70.9 71.6 73.2 74.9
NER UI F1 82.2 82.2 87.4 90.1
Dep. Parsing (GSD) UAS/LAS 85.25/80.35 86.85/81.78 86.99/81.87 87.12/82.32
Dep. Parsing (PUD) UAS/LAS 84.04/79.01 90.58/85.44 88.91/83.56 89.23/83.95
Sentiment Analysis F1 71.62 76.58 82.02 84.13
IndoSum R1/RL 67.96/67.24 68.40/67.67 68.44/67.71 69.93/69.21
Liputan6 (Sum) R1/RL 36.10/33.56 39.81/37.02 --/-- 41.08/38.01
Next Tweet Prediction Acc 73.6 92.4 93.1 93.7
Tweet Ordering Corr (ρ) 0.45 0.53 0.51 0.59

indolem's People

Contributors

afshinrahimi avatar andreaschandra avatar fajri91 avatar indolem avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

indolem's Issues

Bagaimana cara submit score?

Halo, saya ingin submit score dari benchmark IndoLEM pada sentiment analysis. Cara submitnya bagaimana ya?

Terimakasih :)

Documentation for using trained models

Amazing work!
Is there any documentation for using the models during the inference stage?
If not then could you please share some resources for the same?

Thanks!

Using Indobert

Hi, I am learning to use this repo. This is the code script I'm trying to run:

from transformers import AutoTokenizer, AutoModel
from transformers import pipeline 
tokenizer = AutoTokenizer.from_pretrained("indolem/indobert-base-uncased")
model = AutoModel.from_pretrained("indolem/indobert-base-uncased")
nlp = pipeline("ner", model=model, tokenizer=tokenizer)
twit = "Dia makan coklat di rumahnya simbah."

ner_results = nlp(twit)
print(ner_results)

Then I get an error message:

PipelineException: The model 'BertModel' is not supported for ner. Supported models are ['LayoutLMForTokenClassification', 'DistilBertForTokenClassification', 'CamembertForTokenClassification', 'FlaubertForTokenClassification', 'XLMForTokenClassification', 'XLMRobertaForTokenClassification', 'LongformerForTokenClassification', 'RobertaForTokenClassification', 'SqueezeBertForTokenClassification', 'BertForTokenClassification', 'MobileBertForTokenClassification', 'XLNetForTokenClassification', 'AlbertForTokenClassification', 'ElectraForTokenClassification', 'FunnelForTokenClassification']

How to use indoBERT correctly?
Thank you

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.