||
StarSpace是一个对于各种实体进行表示学习的工具(StarSpace is a general-purpose neural model for efficient learning of entity embeddings for solving a wide variety of problems)
主要可以解决的问题包括:
(1)Learning word, sentence or document level embeddings
(2)Text classification, or any other labeling task.
(3)Metric/similarity learning, e.g. learning sentence or document similarity.
(4)Embedding graphs, e.g. multi-relational graphs such as Freebase.
环境要求:linux系统,(gcc-4.6.3 or newer) or (clang-3.3 or newer)
Compilation is carried out using a Makefile, so you will need to have a working make.
install Boost library and specify the path of boost library in makefile in order to run StarSpace
Boost安装:
$wget https://dl.bintray.com/boostorg/release/1.63.0/source/boost_1_63_0.zip $unzip boost_1_63_0.zip $sudo mv boost_1_63_0 /usr/local/bin
build StarSpace
git clone https://github.com/facebookresearch/Starspace.git cd Starspace make
输入数据格式:
Each line will be one input example, in the simplest case the input has k words, and each labels 1..r is a single word
word_1 word_2 ... word_k __label__1 ... __label__r
数据格式和fasttext一样:
参考:
https://github.com/facebookresearch/Starspace
Archiver|手机版|科学网 ( 京ICP备07017567号-12 )
GMT+8, 2024-9-19 17:03
Powered by ScienceNet.cn
Copyright © 2007- 中国科学报社