pkuseg.py内容如下:import pkusegseg = pkuseg.pkuseg()text = seg.cut('我爱北京天安门')print(text) 原因是py文件名于包名一样导致的。把py文件改下名字就可以了。