Skip to content

tks10/ELMo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Example of embeddings using ELMo on TensorFlow Hub

This repository is an example of word embeddings using ELMo (Embeddings from Language Models) on TensorFlow Hub.

The comparison_test module can calculate cosine similarity between given two sentences.

Usage

  • In case of using exmaple.sh
sh example.sh
  • In case of executing on your terminal
python comparison_test.py [sentence1] [sentence2]

Example

bash-3.2$ python comparison_test.py "people read the book" "the book people read"

[Cosine Similarity]
"people read the book" vs "the book people read"
ELMo: 0.83875865
NNLM: 1.0

About

An example of word embeddings using ELMo on TensorFlow Hub.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published