0

i try to arabic vector with spacy, so i try code from this github https://github.com/bakrianoo/aravec/blob/master/aravec-with-spacy.ipynb

when i use this code

!python -m spacy  init-model ar spacy.aravec.model --vectors-loc ./spacyModel/aravec.txt.gz

it apear this error

Error: No such command 'init-model'.

so i try to fix it by change init-model to init and add vector but this error apear:

!python -m spacy init vectors ar ./spacyModel/spacy.aravec.model --vectors-loc ./spacyModel/aravec.txt.gz

error :

Usage: python -m spacy init vectors [OPTIONS] LANG VECTORS_LOC OUTPUT_DIR
Try 'python -m spacy init vectors --help' for help.

Error: No such option: --vectors-loc

how can i fix it ?

  • Did you able to download the file shown in notebook as below shown? ```!wget "https://bakrianoo.sfo2.digitaloceanspaces.com/aravec/full_grams_cbow_100_twitter.zip" !unzip "full_grams_cbow_100_twitter.zip"``` Because bucket already deleted, right? – Sanatbek_Matlatipov Feb 25 '23 at 12:33
  • I didn't use this command, I downloaded this file directly. – Roqiua mohammad Feb 25 '23 at 12:58
  • ```python -m spacy init vectors ar ./spacyModel/spacy.aravec.model ./spacyModel/aravec.txt.gz``` - can you try this? – Sanatbek_Matlatipov Feb 25 '23 at 13:30

1 Answers1

0

Can you try this solution.

!python -m spacy init vectors ar ./spacyModel/spacy.aravec.model ./spacyModel/aravec.txt.gz

According to this information (https://github.com/explosion/spaCy/discussions/7509) and this(In spacy, how to use your own word2vec model created in gensim?), the latest version of the command is changed to the following format without --vectors-loc :

python -m spacy init vectors [OPTIONS] LANG VECTORS_LOC OUTPUT_DIR