Monday, 25 March 2019

Indonesia Presidential Debate Transcription Service in A Nutshell

I was writing this article when I was a software engineer at Bahasa Kita and Indonesia was going to have president election in 2019. As a way to educate the voters about their choice in the election, KPU (General Election Commissions) held debates. The debates were held five times with different topics discussed. The topics were as follows :

  1. Law, Human Right, Corruption, and Terrorism (17 January 2019 at Hotel Bidakara)
  2. Energy and Food, Natural Resources and the Environment, and Infrastructure (17 February 2019 at Hotel Sultan)
  3. Education, Health, Employment and Social and Culture (17 March 2019 at Hotel Sultan)
  4. Ideology, Government, Defense and Security and International Relations (30 March 2019)
  5. Social Economy and Welfare, Finance and Investment and Trade and Industry

As machine learning startup focused on voice, we at Bahasa Kita wanted to contribute to the election through the voice technology. In the time we look for the ideas, we remembered that our founder once had made use the voice technology for the deaf. Thus we decide to do the same thing upon the presidential debate. This was still relevant since we also found many comments from the disabled people hoping there was such technology to help them at Youtube video which has no caption available. Surprisingly, the idea is also needed by normal people when they miss a certain part while the debate is live. They want to review and dig deeper on the candidate’s speech. In short, we propose to transcribe the debate using our automatic speech recognition service and present the transcription quickly while the debate is still ongoing.

We had no long time to implement the idea because we had talked about how to contribute just 8 hours before the first debate. However, during the discussion, other thought appeared. It said that it feels incomplete when we just show the debate verbatim. Then, we searched references from the previous election and found an analytics company that do analytics on the debate verbatim. After analyzing the content, we realized that this analytics can be used as it is neutral. This neutrality is important as we were aware that anything in the political year can be assumed to be not neutral. The interesting thing was just hours or days after our website (debatcapres.bahasakita.co.id) went online, there was one of the candidate’s party contacted us to claim the website for their needs. It is surely a huge amount of money before our eyes. But we chose to decline the offers and keep providing the presidential debate independently for free.

Actually, it is too much if we call them by analytics, so I prefer to call them as a summary. The summary only counts the words statistic without prior knowledge about political, economics, or other needed. The summary comes initially in three forms: the total word count, the topic-specific word count, and word cloud. Word count is just a counting upon words uttered by each candidate. While topic specific word count must relate to the topics. The topics appeared to have other words association. We use these associations to count the topic related to word count. The last, word cloud shows a self-explaining visualization resembling a cloud.

If we take a look at Natural Language Processing (NLP) and Natural Language Understanding (NLU) state-of-the-art, there are still so many kinds of analysis that we can do and we are able to implement. For example, we can define whether utterances tend to polarize to a particular opinion or another way. Or we can display fact based on the news on the internet from the utterance told by the candidates. The most extreme one is we can show the personality and its description based on the given speech. All of them are done using artificial intelligence that we work on every day. But once again, it is too risky to release such information to the public as it is too subjective to judge the quality of analysis. Then we remain on the summary that I just mentioned and give further interpretation to the reader.

Later we were informed that our website is used by journalists to research and find the truth about each statement surfaced during the debate. We were quite happy that our website is useful to others.

Wednesday, 28 November 2018

CMU Dictionary Adaptation to Bahasa Indonesia Lexicon Building

While creating lexicon in voice recognition in Bahasa Indonesia, we need to define the phoneme set by ourselves since there are not such a widely used standard in Bahasa Indonesia. Instead of creating new definition, there is an idea to adapt from existing phoneme set. Obtained from Kaldi resources, we can adapt the phoneme set from English issued by Carnegie Mellon University (CMU Dictionary) which contains 134,000 words.

Bahasa Indonesia is quite simplelook here also as in major case the pronunciation and written letter are the same compared to English. Thus, it is not a tedious work to start building lexicon based on CMU Dictionary although we need to add new phonemes and leave some phonemes.

Table 1 CMU Dictionary Phoneme Set

Phoneme IPA Symbol Indonesian Words Example English Words Example
AA ɑ ternak, gembala odd, balm
AE æ - at, bat
AH ʌ ambil hut, butt
AO ɔ bakpao cow, story
AW saung ought, bout
AY kait, senarai hide, bite
B b lebah, beli bee, buy
CH cuka, ceri cheese, china
D d diam, duduk dump, did
DH ð ridho the, thy
EH ɛ enak, sepak education, bet
ER ɝ bageur*, reueus* hurt
EY - ate, bait
F ɾ faedah, fana fee, forest
G g gerbang, guna green, gate
HH h hampar, unggah he, hair
IH ɪ singgah, ikatan it, implication
IY i - eat, sheep
JH adiraja, keganjilan genuine, jimmy
K k kenangan, batuk key, camp
L l lingkaran, betul luck, love
M m minum, temaram mama, mine
N n naik, menikah knee, nice
NG ŋ yang, ngengat bank, sink
OW bongkar, bogor oat, boat
OY ɔɪ - toy, boy
P p pulsa, peluh pulp, pen
R ɹ ranjau, rintangan right, row
S s sakit, sayang sea, sun
SH ʃ masyarakat, syaikh* shine, she
T t tikung, timpa tea, tone
TH θ rabiul tsani* thug, theta
UH ʊ - hood, book
UW u kuku, suku two, coup
V v viral, vas vee, vocal
W w wejangan, wayang we, wide
Y j yakin, yoga yam, yield
Z z zaman, zamrud zoo, zee
ZH ʒ jangkrik, jerapah seizure, pleasure

From table above, it’s clear that there are phonemes that are not (commonly) used in Bahasa Indonesia. Yet these phoneme set does not cover all Bahasa Indonesia lemma regarding to the root of Bahasa Indonesia which come from majorly Malay, Dutch, Arabic, Chinese, Javanese, and Sundanese. To create the things short, here is list of phonemes that needs to be added to CMU Dictionary for Bahasa Indonesia

Table 2 Addition Phoneme Set

Phoneme IPA Symbol Indonesian Words Example Notes
NY ɲ kenyang, nyamuk alveolo palatal
KH x kholifah voiceless velar fricative
Q ʔ qurban
KX ʕ sa’at voiced pharyngeal fricative
DL dhuhur voiced alveolar sibilant with pharyngealization
GH ɣ ghaib voiced velar fricative

sources :
[1] http://kaldi-asr.org/doc/examples.html
[2] http://www.speech.cs.cmu.edu/cgi-bin/cmudict
[3] https://en.wikipedia.org/wiki/ARPABET
[4] https://open-dict-data.github.io/ipa-lookup/ma/

Saturday, 30 December 2017

Kalender Puasa 2018

Kalender Puasa 2018

Dari Abu Hurairah ra., bahwa Nabi shallallahu alaihi wasallam bersabda:

Demi Dzat yang jiwa Muhammad berada di tangan-Nya, sesungguhnya bau mulut orang yang berpuasa lebih harum di sisi Allah pada hari kiamat daripada bau misk atau kasturi. Dan bagi orang yang berpuasa ada dua kegembiraan, ketika berbuka mereka bergembira dengan bukanya dan ketika bertemu Allah mereka bergembira karena puasanya.”

(HR. Bukhari dan Muslim)

Maka saya hadiahkan, terutama untuk diri sendiri, saudara dan saudariku sebagai pengingat Kalender Puasa 2018 yang dapat diunduh di

Versi bahasa Indonesia

PNG : https://goo.gl/T7Nw6C

PDF : https://goo.gl/EDbgmk

English Version

PNG : https://goo.gl/UZuKsW

PDF : https://goo.gl/qbtQA6

Semoga Allah memberikan kemudahan dan menerima semua amal ibadah kita. Tiada daya dan upaya melainkan dari Allah. Silakan untuk disebarkan kepada keluarga dan kerabat.

Jazakumullahu khairan katsiran.

NB:

1. Kalender ini hanya sebagai perkiraan. Jika di kemudian hari terdapat selisih tanggal, harap menyesuaikan dengan penanggalan yang sesuai.

2. Korespondensi lebih lanjut, mohon melalui www.github.com/linerocks/FastingCalendar2018 di kolom issues

Muslim Fasting Calendar 2018

Muslim Fasting Calendar 2018

The Prophet Muhammad , peace be upon him, said :

By Him in Whose Hands my soul is, the smell coming out from the mouth of fasting person is better in sight of Allah than the smell of musk. (allah says about the fasting person), “He has left his food, drink, and desires for My Sake. The fast is for Me. So I will reward (the fasting person) for it and the reward of good deeds is multiplied ten times.”

^reference : Sahih al-Bukhari 1894^

So , I present to, especially myself, my brother, and sister as a reminder this Muslim Fasting Calendar 2018 which can be obtained in this repository or simply download at :

English Version

PNG : https://goo.gl/UZuKsW

PDF : https://goo.gl/qbtQA6

Bahasa Version

PNG : https://goo.gl/T7Nw6C

PDF : https://goo.gl/EDbgmk

May Allah grant us ease to do good deeds and accept our good deeds. There is no power and no strength except with Allah. Feel free to share to relatives and family.

Jazakumullahu khairan katsiran.

NB:

1. This calendar is only a prediction. If you find any unmatch date, please adjust with the correct one.

2. If you have issues related to this, please kindly contact me via www.github.com/linerocks/FastingCalendar2018 on tab issues