explosion / explosion/spaCy

`spacy download nl_core_news_sm` downgrades transformers installation

Open
#13,673 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
33.9k
Forks
4.7k
Avg merge
3m
Merged PRs (30d)
1

Description

Since models are in fact pip modules, it makes sense that they have their own dependencies. However, I was very surprised to find out that `nl_core_news_sm` required me to downgrade my `transformers` version. I am running on the main branch of `transformers` so ahead of 4.45.2 (`4.46.0.dev0`). yet when installing `nl-core-news-sm` I find the transformers version to be downgraded to the pip release. To me that sounds like a bug but maybe this is intended behavior to avoid conflicts for the average user.

As a power user that restriction is a bit too strong, though. As per semver, no breaking changes ought to be introduced with minor version bumps so it would be surprising to see major shifts. (Disclaimer: I'm not sure how closely HF follows semver.)

spaCy version 3.8.2
Location /home/local/vanroy/defgen/.venv/lib/python3.10/site-packages/spacy
Platform Linux-5.14.0-427.20.1.el9_4.x86_64-x86_64-with-glibc2.34
Python version 3.10.15
Pipelines nl_core_news_sm (3.8.0)

If the restriction cannot be relieved a bit, do you have another suggestion to by-pass this? I am willing to build things from source if needed, though I am not sure how to do that with the mode files.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.