I've created a python package and built it with the help of python packaging instructions. Now I'm trying to add all the dependencies and extra packages that need to be downloaded and used in this package, such as tqdm, termcolor, and spacy. As I saw in a sample project here, I have to include these packages in the install_requires
in the setup.py
file, Although, because I use one of SpaCy pipelines in my package, I need to run the following command too:
!python -m spacy download en_core_web_lg
I tried adding this command to entry_point in the setup.py, though I couldn't rebuild the package after
entry_points={
'console_scripts': [
'!python -m spacy download en_core_web_lg',
],
}
Here is the Github code. Any suggestions?
In this case, you can provide the model package as one of the requirements like this, but note that this points to one particular version of the model:
https://github.com/explosion/spacy-models/releases/download/en_core_web_sm-3.0.0/en_core_web_sm-3.0.0.tar.gz#egg=en_core_web_sm