Skip to content

How to train your own word2vec model for use with ml5.js

License

Notifications You must be signed in to change notification settings

patricoferris/training-word2vec

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Training

Python Environment

Requirements

pip install gensim

Train the model

  1. Clone this repository or download this python script
git clone https://github.com/ml5js/training-word2vec/
  1. The script in its current form only supports training from a single text file. Copy your text file into this directory and run train.py with the name of the file.
python train.py data.txt
  1. The script will save a file called vectors.json. You can then use this file the ml5.js word2vec examples.

About

How to train your own word2vec model for use with ml5.js

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%