
Stambecco是一种基于Llama模型的意大利指令遵循模型。它有两个版本:7b和13b参数。整个项目都是使用Google Colab构建的。
该存储库包含用于在意大利语中复制斯坦福羊驼的代码?使用提供的低级适应(LORA)?拥抱脸的peft图书馆。我们提供了与文本davinci-003相似的指示模型,该模型可以在Raspberry Pi上运行(用于研究),并且该代码很容易扩展到13B。
为了推进LLM的教学教学技术的状态,我们提出了首次尝试使用GPT-4生成的指令数据以LLM Fineting在意大利语中。看看研究结果:GPT-4-LLM
除了在单个RTX 4090或A100 40GB上运行的训练代码外,我们还提供了使用Gradio的图形接口下载和推断基础模型和Stambecco的笔记本。
如果我进一步看到,那就是站在巨人的害虫上。 - 艾萨克·牛顿(Isaac Newton)
我们以此引用开始了这一部分,因为我们所做的一切都是由于社区的强大而做出的,并且其他人和团体都做到了。在我们的工作中,我们主要依靠:Llama,Stanford羊驼,羊驼Lora,Cabrita,Cleaned Alpaca DataSet,GPT-4-LLM,羊驼毛 - 洛拉 - 索尔帕卡 - 索尔帕卡,Chatgpt,Chatgpt和Hugging Face。因此,感谢大家的出色工作,并与世界分享!
用法和许可声明:与斯坦福羊驼相同,Stambecco仅用于研究用途和许可。数据集由NC SA 4.0(仅允许非商业用途)为CC,并且不应在研究目的之外使用使用数据集进行培训的模型。
请注意,模型输出很有可能包含有偏见,阴谋家,令人反感或其他不适当且可能有害的内容。该模型仅用于研究目的,应谨慎使用自己的风险。不允许生产使用。
我们将alpaca_data_cleaned.json和alpaca_gpt4_data.json转换为意大利语,添加检查(例如,如果文本为代码 - >不要翻译它)以优化翻译的输出。我们建议使用OpenAI gpt-3.5-turbo模型来翻译数据集以降低成本。即使是这种翻译也不是最好的,成本和结果之间的权衡是。如果您想了解更多有关数据集的构建方式的更多信息,请参阅:Stanford羊驼,清洁羊驼数据集,GPT-4-LLM。
我们使用拥抱脸的PEFT对美洲驼模型进行了挑战。为了在Llama-7B和Llama-13B上运行COLAB上的Finetuning,建议使用A100 40GB GPU。用于培训的数据集是Italian版本的GPT-4-LLM数据集,该数据集是该模型的plus的GPT-4生成的指令遵循数据的数据集,以及基本版本的MCHL-LABS/Stambecco_data_it。
有关培训超参数的更多信息,请参见Huggingface上的型号卡。
用户注意:Facebook尚未使官方的Llama模型权重开源,尽管可以在线提供各种第三方下载链接,例如在拥抱面部模型库中的decapoda-research/llama-7b-hf 。应该注意的是,使用这些链接可能不符合Facebook的政策。由于上述原因,该项目无法释放微调模型的完整权重。但是,只能提供Lora重量,可以将其视为原始Llama模型的“补丁”。
可以使用微调的指令跟踪Stambecco型号吗?拥抱脸:
您可以使用以下Google COLAB笔记本来推断这些模型。
我们发布了一个翻译的数据集(Stambecco_data_it.json-现在也在拥抱Face的数据集上),模型(在拥抱面的集线器上可用)和代码以重现结果。
@article{touvron2023llama,
title={LLaMA: Open and Efficient Foundation Language Models},
author={Touvron, Hugo and Lavril, Thibaut and Izacard, Gautier and Martinet, Xavier and Lachaux, Marie-Anne and Lacroix, Timoth{'e}e and Rozi{`e}re, Baptiste and Goyal, Naman and Hambro, Eric and Azhar, Faisal and Rodriguez, Aurelien and Joulin, Armand and Grave, Edouard and Lample, Guillaume},
journal={arXiv preprint arXiv:2302.13971},
year={2023}
}
@misc{selfinstruct,
title={Self-Instruct: Aligning Language Model with Self Generated Instructions},
author={Wang, Yizhong and Kordi, Yeganeh and Mishra, Swaroop and Liu, Alisa and Smith, Noah A. and Khashabi, Daniel and Hajishirzi, Hannaneh},
journal={arXiv preprint arXiv:2212.10560},
year={2022}
}
@misc{alpaca,
author = {Rohan Taori and Ishaan Gulrajani and Tianyi Zhang and Yann Dubois and Xuechen Li and Carlos Guestrin and Percy Liang and Tatsunori B. Hashimoto },
title = {Stanford Alpaca: An Instruction-following LLaMA model},
year = {2023},
publisher = {GitHub},
journal = {GitHub repository},
howpublished = {url{https://github.com/tatsu-lab/stanford_alpaca}},
}
@misc{hu2021lora,
title={LoRA: Low-Rank Adaptation of Large Language Models},
author={Hu, Edward and Shen, Yelong and Wallis, Phil and Allen-Zhu, Zeyuan and Li, Yuanzhi and Wang, Lu and Chen, Weizhu},
year={2021},
eprint={2106.09685},
archivePrefix={arXiv},
primaryClass={cs.CL}
}
@inproceedings{wolf-etal-2020-transformers,
title = "Transformers: State-of-the-Art Natural Language Processing",
author = "Thomas Wolf and Lysandre Debut and Victor Sanh and Julien Chaumond and Clement Delangue and Anthony Moi and Pierric Cistac and Tim Rault and Rémi Louf and Morgan Funtowicz and Joe Davison and Sam Shleifer and Patrick von Platen and Clara Ma and Yacine Jernite and Julien Plu and Canwen Xu and Teven Le Scao and Sylvain Gugger and Mariama Drame and Quentin Lhoest and Alexander M. Rush",
booktitle = "Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: System Demonstrations",
month = oct,
year = "2020",
address = "Online",
publisher = "Association for Computational Linguistics",
url = "https://www.aclweb.org/anthology/2020.emnlp-demos.6",
pages = "38--45"
}
@Misc{peft,
title = {PEFT: State-of-the-art Parameter-Efficient Fine-Tuning methods},
author = {Sourab Mangrulkar, Sylvain Gugger, Lysandre Debut, Younes Belkada, Sayak Paul},
howpublished = {url{https://github.com/huggingface/peft}},
year = {2022}
}
@article{peng2023gpt4llm,
title={Instruction Tuning with GPT-4},
author={Baolin Peng, Chunyuan Li, Pengcheng He, Michel Galley, Jianfeng Gao},
journal={arXiv preprint arXiv:2304.03277},
year={2023}
}
如果Stambecco启发您和Stambecco代码,您的研究中使用了Stambecco模型或Stambecco数据集,请引用:
@misc{stambecco,
author = {Michael},
title = {Stambecco: Italian Instruction-following LLaMA Model},
year = {2023},
publisher = {GitHub},
journal = {GitHub repository},
howpublished = {url{https://github.com/mchl-labs/stambecco}},
}