报错提示:
OSError: Can't load tokenizer for 'bert-base-chinese'. If you were trying to load it from 'https://huggingface.co/models', make sure you don't have a local directory with the same name. Otherwise, make sure 'bert-base-chinese' is the correct path to a directory containing all relevant files for a BertTokenizer tokenizer.
解决方法:
HF_ENDPOINT=https://hf-mirror.com python test.py
在运行.py命令前加上HF_ENDPOINT=https://hf-mirror.com就可以成功解决。