five

kailinjiang/punkt

收藏
Hugging Face2024-07-05 更新2024-07-06 收录
下载链接:
https://hf-mirror.com/datasets/kailinjiang/punkt
下载链接
链接失效反馈
官方服务:
资源简介:
## 🛠️ Requirements and Installation ```text # clone ICE git clone https://github.com/Yofuria/ICE.git cd ICE # create conda env conda create -n ICE python=3.10 conda activate ICE # install package pip install -r requirements.txt ``` In **lines 32 and 33** of **` examples/run_knowedit_llama2.py`**, you need to download the **` punkt `** package. - If your Internet **speed is fast** enough, you can **run the code directly** from the command line. ```text if __name__ == "__main__": # If you have a slow Internet connection and can't download nltk quickly, comment these two lines and use the second method of Requirements and Installation in README.md import nltk nltk.download('punkt') ``` - If your Internet **speed is slow**, **comment lines 32 and 33** and download punkt manually. And place it in the ICE environment directory you created, create a **nltk_data/tokenizers** folder, and **unpack punkt** into this directory. <div align="center"> <img src="punkt.png" width="650px"> </div>

## 🛠️ 环境要求与安装 text # 克隆ICE仓库 git clone https://github.com/Yofuria/ICE.git cd ICE # 创建Conda虚拟环境 conda create -n ICE python=3.10 conda activate ICE # 安装依赖包 pip install -r requirements.txt 在`examples/run_knowedit_llama2.py`的第32行与第33行中,需下载`punkt`工具包。 - 若网络速度充足,可直接通过命令行运行下述代码: python if __name__ == "__main__": # 若网络连接较慢无法快速下载自然语言工具包(Natural Language Toolkit,NLTK)资源,请注释以下两行代码,并采用README文档中「环境要求与安装」的第二种方案 import nltk nltk.download('punkt') - 若网络速度较慢,请注释第32行与第33行代码,并手动下载`punkt`包。将其放置于你所创建的ICE虚拟环境目录中,新建`nltk_data/tokenizers`文件夹,并将`punkt`解压至该目录下。 <div align="center"> <img src="punkt.png" width="650px"> </div>
提供机构:
kailinjiang
二维码
社区交流群
二维码
科研交流群
商业服务