Skip to content

详细双语注释版word2vec源码,well-annotated word2vec

Notifications You must be signed in to change notification settings

catqaq/NLP-Notes

Repository files navigation

NLP-Notes

Some fun NLP projects based on Pytorch.

  • Pytorch: 1.0.1
  • Python: 3.6

1. LSTM part-of-speech tagger with character-level features

Train and test

  • The following command starts training.
python lstm_tag_plus.py

Refs

2. 普通话-四川话翻译器

Train and test

  • The following command starts training.
python main.py
  • Examples:
    • 普通话> 你想做什么 四川话: 你想做啥子
    • 普通话> 你怎么这么那个 四川话: 你啷个这么那个
    • 普通话> 我明天不上班 四川话: 老子明天不上班
  • A jupyter-notebook version can be found in pt-sc/pt_sc.ipynb.

Refs

3. compare the sum embeddings and average embeddings based on BOW(bag of words) model

4. Dive-into-DL-PyTorch

  • 只截取了其中第10章NLP部分,包括word2vec, glove, seq2seq, machine translation..., 详见Dive-into-DL-PyTorch