daily llama
1.0.0
该项目提出了一个专为新闻内容量身定制的检索增强生成框架。通过采用FAISS索引进行高效的相似性搜索,检索相关文档。利用 LLAMA-2 模型,这些检索到的文档可作为生成全面且上下文准确的答案的基础。
python3 daily-llama.py --dataset_path data/news-small.json --load_in_4bit True --query " What happened with Dimuth's cricket career? "
响应样本
Based on past newspaper contents, it appears that Dimuth Karunaratne's cricket career has been impacted by recent legal issues. According to a news article from March 2023, he was charged with driving under the influence of liquor and was released on bail after being produced before the Colombo Fort Magistrate Court. Additionally, he has requested the national cricket selection committee to reconsider his request to step down as Sri Lanka's Test captain due to personal reasons. However, it is unclear at this time how these legal issues will affect his playing career moving forward.
git clone https://github.com/Ransaka/daily-llama.git
cd /content/daily-llama
pip install -r requirements.txt --q
python server.py --dataset_path data/news-small.json --load_in_4bit True # you may require `huggingface-cli login` prior to this step