1 前提环境 需要安装gcc、g++ yum install gcc gcc-c++ 查看是否安装成功 gcc --version g++ --version 2 安装fasttext 为避免直接pip安装过程中产生的一系列报错,我们采用源码安装 git clone https://github.com/facebookresearch/fastText.git cd fastText-main/ pip install . 测试