Cannot run Starspace using bash in Google Colab

Viewed 581

I am trying to run this code in google colab.

%%bash
./Starspace/starspace train \
-trainFile "data/prepared_train.tsv" \
-model model/stackoverflow_duplicate \
-trainMode = 3 \
-adagrad true \
-ngrams 1 \
-epoch 5 \
-dim 100 \
-similarity "cosine" \
-minCount 2 \
-verbose true \
-fileFormat labelDoc \
-negSearchLimit 10 \
-lr 0.05 \
-thread 10

But every time I get this error Provided argument without a dash!.
And some instruction about how to use. Actually I tried to use sample codes in Facebook Github repository, but I get same error.

Thanks for any advice.

2 Answers

I'm guessing this is causing you trouble -trainMode = 3, I think it should be -trainMode 3 without the =

Try to remove quotes in file-names, in model name and in fileFormat:

######### TRAINING HAPPENING HERE #############
%%bash
./Starspace/starspace train \
-trainFile data/train_prepare.tsv \
-model Starspace_embeddings \
-trainMode 3 \
-adagrad true \
-ngrams 1 \
-epoch 5 \
-dim 100 \
-similarity "cosine" \
-minCount 2 \
-verbose true \
-fileFormat labelDoc \
-negSearchLimit 10 \
-lr 0.05
Related