{"data":{"slug":"ymcui-chinese-llama-alpaca","name":"Chinese-LLaMA-Alpaca","tagline":"Chinese LLaMA & Alpaca Large Language Models for Local CPU/GPU Training and Deployment","github_url":"https://github.com/ymcui/Chinese-LLaMA-Alpaca","owner":"ymcui","repo":"Chinese-LLaMA-Alpaca","owner_avatar_url":"https://avatars.githubusercontent.com/u/16095339?v=4","primary_language":"Python","stars":18933,"forks":1839,"topics":["alpaca","alpaca-2","large-language-models","llama","llama-2","llm","lora","nlp","plm","pre-trained-language-models","quantization"],"archived":false,"github_pushed_at":"2026-04-19T00:58:05+00:00","maintenance_label":"Slowing","stars_delta_30d":-9,"url":"https://www.graphcanon.com/tools/ymcui-chinese-llama-alpaca","markdown_url":"https://www.graphcanon.com/tools/ymcui-chinese-llama-alpaca.md","api_url":"https://www.graphcanon.com/api/graphcanon/tools/ymcui-chinese-llama-alpaca","graph_url":"https://www.graphcanon.com/api/graphcanon/graph?tool=ymcui-chinese-llama-alpaca","description":"中文LLaMA&Alpaca大语言模型+本地CPU/GPU训练部署 (Chinese LLaMA & Alpaca LLMs)","homepage_url":"https://github.com/ymcui/Chinese-LLaMA-Alpaca/wiki","license":"Apache-2.0","open_issues":6,"watchers":180,"ai_summary":"A repository that includes Chinese versions of the LLaMA and Alpaca large language models, designed with additional Chinese vocabulary and fine-tuned on Chinese instruction data for better comprehension and execution. The repository provides scripts for pre-training and instruction tuning.","readme_excerpt":"# [Chinese-LLaMA-Alpaca-3](https://github.com/ymcui/Chinese-LLaMA-Alpaca-3)项目启动！\n\n[**🇨🇳中文**](./README.md) | [**🌐English**](./README_EN.md) | [**📖文档/Docs**](https://github.com/ymcui/Chinese-LLaMA-Alpaca/wiki) | [**❓提问/Issues**](https://github.com/ymcui/Chinese-LLaMA-Alpaca/issues) | [**💬讨论/Discussions**](https://github.com/ymcui/Chinese-LLaMA-Alpaca/discussions) | [**⚔️竞技场/Arena**](http://llm-arena.ymcui.com/)\n\n<p align=\"center\">\n    <br>\n    <img src=\"./pics/banner.png\" width=\"700\"/>\n    <br>\n</p>\n<p align=\"center\">\n    <img alt=\"GitHub\" src=\"https://img.shields.io/github/license/ymcui/Chinese-LLaMA-Alpaca.svg?color=blue&style=flat-square\">\n    <img alt=\"GitHub release (latest by date)\" src=\"https://img.shields.io/github/v/release/ymcui/Chinese-LLaMA-Alpaca\">\n    <img alt=\"GitHub top language\" src=\"https://img.shields.io/github/languages/top/ymcui/Chinese-LLaMA-Alpaca\">\n    <img alt=\"GitHub last commit\" src=\"https://img.shields.io/github/last-commit/ymcui/Chinese-LLaMA-Alpaca\">\n    <a href=\"https://app.codacy.com/gh/ymcui/Chinese-LLaMA-Alpaca/dashboard?utm_source=gh&utm_medium=referral&utm_content=&utm_campaign=Badge_grade\"><img src=\"https://app.codacy.com/project/badge/Grade/1710faac5e634acaabfc26b0a778cdde\"/></a>\n</p>\n\n\n\n本项目开源了**中文LLaMA模型和指令精调的Alpaca大模型**，以进一步促进大模型在中文NLP社区的开放研究。这些模型**在原版LLaMA的基础上扩充了中文词表**并使用了中文数据进行二次预训练，进一步提升了中文基础语义理解能力。同时，中文Alpaca模型进一步使用了中文指令数据进行精调，显著提升了模型对指令的理解和执行能力。\n\n**技术报告（V2）**：[[Cui, Yang, and Yao] Efficient and Effective Text Encoding for Chinese LLaMA and Alpaca](https://arxiv.org/abs/2304.08177)\n\n**本项目主要内容：**\n\n- 🚀 针对原版LLaMA模型扩充了中文词表，提升了中文编解码效率 \n- 🚀 开源了使用中文文本数据预训练的中文LLaMA以及经过指令精调的中文Alpaca\n- 🚀 开源了预训练脚本、指令精调脚本，用户可根据需要进一步训练模型\n- 🚀 快速使用笔记本电脑（个人PC）的CPU/GPU本地量化和部署体验大模型\n- 🚀 支持[🤗transformers](https://github.com/huggingface/transformers), [llama.cpp](https://github.com/ggerganov/llama.cpp), [text-generation-webui](https://github.com/oobabooga/text-generation-webui), [LlamaChat](https://github.com/alexrozanski/LlamaChat), [LangChain](https://github.com/hwchase17/langchain), [privateGPT](https://github.com/imartinez/privateGPT)等生态\n- 目前已开源的模型版本：7B（基础版、**Plus版**、**Pro版**）、13B（基础版、**Plus版**、**Pro版**）、33B（基础版、**Plus版**、**Pro版**）\n\n💡 下图是中文Alpaca-Plus-7B模型在本地CPU量化部署后的实际体验速度和效果。\n\n\n\n----\n\n[**中文LLaMA-2&Alpaca-2大模型**](https://github.com/ymcui/Chinese-LLaMA-Alpaca-2) | [多模态中文LLaMA&Alpaca大模型](https://github.com/airaria/Visual-Chinese-LLaMA-Alpaca) | [多模态VLE](https://github.com/iflytek/VLE) | [中文MiniRBT](https://github.com/iflytek/MiniRBT) | [中文LERT](https://github.com/ymcui/LERT) | [中英文PERT](https://github.com/ymcui/PERT) | [中文MacBERT](https://github.com/ymcui/MacBERT) | [中文ELECTRA](https://github.com/ymcui/Chinese-ELECTRA) | [中文XLNet](https://github.com/ymcui/Chinese-XLNet) | [中文BERT](https://github.com/ymcui/Chinese-BERT-wwm) | [知识蒸馏工具TextBrewer](https://github.com/airaria/TextBrewer) | [模型裁剪工具TextPruner](https://github.com/airaria/TextPruner)\n\n## 新闻\n\n**[2024/04/30] Chinese-LLaMA-Alpaca-3 已正式发布，开源基于Llama-3的Llama-3-Chinese-8B和Llama-3-Chinese-8B-Instruct，推荐所有一期、二期项目用户升级至三代模型，请参阅：https://github.com/ymcui/Chinese-LLaMA-Alpaca-3**\n\n[2024/03/27] 本项目已入驻机器之心SOTA!模型平台，欢迎关注：https://sota.jiqizhixin.com/project/chinese-llama-alpaca\n\n[2023/08/14] Chinese-LLaMA-Alpaca-2 v2.0版本已正式发布，开源Chinese-LLaMA-2-13B和Chinese-Alpaca-2-13B，推荐所有一期用户升级至二代模型，请参阅：https://github.com/ymcui/Chinese-LLaMA-Alpaca-2\n\n[2023/07/31] Chinese-LLaMA-Alpaca-2 v1.0版本已正式发布，请参阅：https://github.com/ymcui/Chinese-LLaMA-Alpaca-2\n\n[2023/07/19] [v5.0版本](https://github.com/ymcui/Chinese-LLaMA-Alpaca/releases/tag/v5.0): 发布Alpaca-Pro系列模型，显著提升回复长度和质量；同时发布Plus-33B系列模型。\n\n[2023/07/19] 🚀启动[中文LLaMA-2、Alpaca-2开源大模型项目](https://github.com/ymcui/Chinese-LLaMA-Alpaca-2)，欢迎关注了解最新信息。\n\n[2023/07/10] Beta测试预览，提前了解即将到来的更新：详见[讨论区](https://github.com/ymcui/Chinese-LLaMA-Alpaca/discussions/732)\n\n[2023/07/07] Chinese-LLaMA-Alpaca家族再添新成员，推出面向视觉问答与对话的[多模态中文LLaMA&Alpaca大模型](https://github.com/airaria/Visual-Chinese-LLaMA-Alpaca)，发布了7B测试版本。\n\n[2023/06/30] llama.cpp下8K context支持（无需对模型做出修改），相关方法","github_created_at":"2023-03-15T11:09:39+00:00","created_at":"2026-07-07T17:33:23.037294+00:00","updated_at":"2026-08-17T00:02:08.325081+00:00","categories":[{"slug":"llm-frameworks","name":"LLM Frameworks","url":"https://www.graphcanon.com/categories/llm-frameworks","markdown_url":"https://www.graphcanon.com/categories/llm-frameworks.md","api_url":"https://www.graphcanon.com/api/graphcanon/categories/llm-frameworks"},{"slug":"model-training","name":"Model Training","url":"https://www.graphcanon.com/categories/model-training","markdown_url":"https://www.graphcanon.com/categories/model-training.md","api_url":"https://www.graphcanon.com/api/graphcanon/categories/model-training"}],"tags":[{"slug":"alpaca","name":"alpaca"},{"slug":"large-language-models","name":"large language models"},{"slug":"llama","name":"llama"},{"slug":"nlp","name":"nlp"},{"slug":"pre-trained-language-models","name":"pre-trained-language-models"}],"trust":{"provenance":{"is_fork":false,"github_id":614325365,"owner_type":"User","methodology":"github_public_v1","parent_repo":null,"near_duplicate_slugs":[]},"computed_at":"2026-08-17T00:02:07.564Z","maintenance":{"label":"Slowing","score":36,"methodology":"github_public_v1","releases_90d":0,"days_since_push":119,"last_release_at":"2023-07-19T08:21:15Z","stars_delta_30d":-9,"open_issues_delta_30d":0},"security_summary":{"status":"findings","scanner":"osv@v1","low_count":73,"high_count":0,"last_scan_at":"2026-07-11T11:00:49.111Z","medium_count":0,"scan_profile":"deps","critical_count":0}},"capability_facts":{"scan":{"source":"repo_scan","observed_at":"2026-08-17T00:02:08.012Z"},"languages":{"value":["python"],"source":"github.language","observed_at":"2026-08-17T00:02:08.012Z"},"license_spdx":{"value":"Apache-2.0","source":"github.license","observed_at":"2026-08-17T00:02:08.012Z"}},"decision_facts":{"hosting":null,"pricing":{"model":"freemium","summary":"Access to `Chinese-LLaMA-Alpaca` models and documentation is free, but commercial usage should adhere to open-source licensing requirements."},"requirements":null,"constraints":{"pricing_model":"freemium"},"when_to_use":["You should consider using `Chinese-LLaMA-Alpaca` if your project involves local deployment and training using CPUs or GPUs, particularly if the focus is on Chinese language texts. These models are pre","If you need advanced command comprehension and execution in Mandarin, where traditional models may fall short.","Suitable for those looking to integrate into existing ecosystems such as `🤗 transformers`, `llama.cpp`, or `text-generation-webui` with specific support built-in."],"when_not_to_use":["`Chinese-LLaMA-Alpaca` might not be the best fit if your project requires extensive multi-language support beyond Chinese.","If you are exclusively targeting markets where English is the primary language, and fine-tuning or additional pre-training on Chinese data does not add value to your application.","Avoid using this tool if you require a model that has been extensively trained across global datasets for broad international comprehension, as `Chinese-LLaMA-Alpaca` is focused heavily on Chinese."],"source":"enrich:decision_facts","observed_at":"2026-07-11T14:24:59.380Z"},"constraint_facets":{"pricing_model":"freemium"},"decision_summary":[{"label":"Pricing","value":"freemium - Access to `Chinese-LLaMA-Alpaca` models and documentation is free, but commercial usage should adhere to open-source licensing requirements."},{"label":"Adopt for","value":"`Chinese-LLaMA-Alpaca` is a repository that includes Chinese versions of the LLaMA and Alpaca large language models, specifically designed with extended Chinese vocabulary and fine-tuned on Chinese instruction data for a"},{"label":"License detail","value":"The repository is licensed under Apache-2.0 which allows you to use the content openly in both commercial and non-commercial projects provided you adhere to the licensing terms."}]}}