ERROR: Failed building wheel for sentencepiece while installing flair on python 3.10

3.8k views Asked by At

While installing flair using pip install flair in python 3.10 virtual environment on mac-os Ventura, I get the following error:

ERROR: Failed building wheel for sentencepiece

Seperately installing sentencepeice using pip install sentenpeice did not work.

Upgrading pip did not work.

I am using Intel macbook.

2

There are 2 answers

2
Deepak Tatyaji Ahire On

The answer suggested by Github user @millnerryan is crisp and precise.

0
emcdnetmeta On

Try downgrading Python.

I was having this same issue, also with an intel mac, everytime I tried to use the transformers library, went through a lot of possible solutions without success, even with multiple chatGPT advices. I uninstalled python 3.11 and got back to the 3.9.13 version and the issue was gone! It seems there's some issue with wheels for latest python versions