https://github.com/khanh1998/vietnamese-name-api
An NLP project specializes in Vietnamese name
https://github.com/khanh1998/vietnamese-name-api
bert flask lstm pytorch
Last synced: 2 months ago
JSON representation
An NLP project specializes in Vietnamese name
- Host: GitHub
- URL: https://github.com/khanh1998/vietnamese-name-api
- Owner: khanh1998
- Created: 2020-11-30T12:13:03.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2020-11-30T12:54:04.000Z (over 5 years ago)
- Last Synced: 2025-07-25T21:44:24.474Z (11 months ago)
- Topics: bert, flask, lstm, pytorch
- Language: Python
- Homepage:
- Size: 8.66 MB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# Predict the gender of a Vietnamese name
LSTM version: [](https://colab.research.google.com/drive/16dUaD15aL86htijqE6hlBvf6KiJ26RMU)
BERT version: [](https://colab.research.google.com/drive/1-XxeLfPBermYxKJxeQNHMsTCdllGFmQg)
The version of the deployed model is a two-layer bidirectional LSTM.
Send a POST request to https://gender-regconition.herokuapp.com/gender with only one parameter named `names` which contains names separated by a comma. The response is the probability of the name being male or female.
Example: https://gender-regconition.herokuapp.com/gender?names=quốc khánh,nguyễn thanh nhàn,hương,lan hương
Response:
```json
{
"result": [
[
"quốc khánh",
"nam",
99.99995422363281
],
[
"nguyễn thanh nhàn",
"nữ",
99.87543487548828
],
[
"hương",
"nam",
61.728614807128906
],
[
"lan hương",
"nữ",
97.12590789794922
]
]
}
```
# Generate names
[](https://colab.research.google.com/drive/10TScnpluI6Cgfw3wqb0moDWxHXxRFvD3)
Character level base, four layers LSTM.
Here a some generated names by the model with seed `b`:
bùi chí công
bùi kiên giang
bùi lọ khuê
bùi sơn lâm
bùi bảo lễ
bùi ngọc khanh
bùi thanh hoa
bùi văn nhật
bùi thành nhung
bùi hoài giang
The model has not deployed yet.