Skip to content

Latest commit

 

History

History
31 lines (20 loc) · 662 Bytes

README.md

File metadata and controls

31 lines (20 loc) · 662 Bytes

html2emoji

Convert HTML escape sequence to emoji with explanation (Chinese/English).

将HTML中的Emoji转义序列转换成Unicode形式,并可转换成其中英文含义。

适用于NLP分析等场景

其中中文词典来自apple-emoji-dict

Requirement

emoji

Setup:

pip install emoji

Usage

import html2emoji
emj = html2emoji.html('��')
print(emj.show)

'🎂'

print(emj.meanc)

['庆祝', '生日', '蛋糕', '慶祝', '生日蛋糕']

print(emj.meanc[0])

'庆祝'

print(emj.meane)

'birthday_cake'