Merge branch 'main' of https://huggingface.co/THUDM/chatglm3-6b
Browse files
README.md
CHANGED
|
@@ -19,24 +19,31 @@ tags:
|
|
| 19 |
📍Experience the larger-scale ChatGLM model at <a href="https://www.chatglm.cn">chatglm.cn</a>
|
| 20 |
</p>
|
| 21 |
|
| 22 |
-
## 介绍
|
| 23 |
ChatGLM3-6B 是 ChatGLM 系列最新一代的开源模型,在保留了前两代模型对话流畅、部署门槛低等众多优秀特性的基础上,ChatGLM3-6B 引入了如下特性:
|
| 24 |
|
| 25 |
1. **更强大的基础模型:** ChatGLM3-6B 的基础模型 ChatGLM3-6B-Base 采用了更多样的训练数据、更充分的训练步数和更合理的训练策略。在语义、数学、推理、代码、知识等不同角度的数据集上测评显示,ChatGLM3-6B-Base 具有在 10B 以下的预训练模型中最强的性能。
|
| 26 |
2. **更完整的功能支持:** ChatGLM3-6B 采用了全新设计的 [Prompt 格式](https://github.com/THUDM/ChatGLM3/blob/main/PROMPT.md),除正常的多轮对话外。同时原生支持[工具调用](https://github.com/THUDM/ChatGLM3/blob/main/tool_using/README.md)(Function Call)、代码执行(Code Interpreter)和 Agent 任务等复杂场景。
|
| 27 |
3. **更全面的开源序列:** 除了对话模型 ChatGLM3-6B 外,还开源了基础模型 ChatGLM-6B-Base、长文本对话模型 ChatGLM3-6B-32K。以上所有权重对学术研究**完全开放**,在填写[问卷](https://open.bigmodel.cn/mla/form)进行登记后**亦允许免费商业使用**。
|
| 28 |
|
|
|
|
| 29 |
|
| 30 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 31 |
|
| 32 |
```shell
|
| 33 |
pip install protobuf transformers==4.30.2 cpm_kernels torch>=2.0 gradio mdtex2html sentencepiece accelerate
|
| 34 |
```
|
| 35 |
|
| 36 |
-
## 代码调用
|
| 37 |
|
| 38 |
可以通过如下代码调用 ChatGLM3-6B 模型来生成对话:
|
| 39 |
|
|
|
|
|
|
|
| 40 |
```ipython
|
| 41 |
>>> from transformers import AutoTokenizer, AutoModel
|
| 42 |
>>> tokenizer = AutoTokenizer.from_pretrained("THUDM/chatglm3-6b", trust_remote_code=True)
|
|
@@ -64,14 +71,18 @@ pip install protobuf transformers==4.30.2 cpm_kernels torch>=2.0 gradio mdtex2ht
|
|
| 64 |
For more instructions, including how to run CLI and web demos, and model quantization, please refer to our [Github Repo](https://github.com/THUDM/ChatGLM).
|
| 65 |
|
| 66 |
|
| 67 |
-
## 协议
|
| 68 |
|
| 69 |
本仓库的代码依照 [Apache-2.0](LICENSE) 协议开源,ChatGLM3-6B 模型的权重的使用则需要遵循 [Model License](MODEL_LICENSE)。
|
| 70 |
|
| 71 |
-
|
|
|
|
|
|
|
| 72 |
|
| 73 |
如果你觉得我们的工作有帮助的话,请考虑引用下列论文。
|
| 74 |
|
|
|
|
|
|
|
| 75 |
```
|
| 76 |
@article{zeng2022glm,
|
| 77 |
title={Glm-130b: An open bilingual pre-trained model},
|
|
|
|
| 19 |
📍Experience the larger-scale ChatGLM model at <a href="https://www.chatglm.cn">chatglm.cn</a>
|
| 20 |
</p>
|
| 21 |
|
| 22 |
+
## 介绍 (Introduction)
|
| 23 |
ChatGLM3-6B 是 ChatGLM 系列最新一代的开源模型,在保留了前两代模型对话流畅、部署门槛低等众多优秀特性的基础上,ChatGLM3-6B 引入了如下特性:
|
| 24 |
|
| 25 |
1. **更强大的基础模型:** ChatGLM3-6B 的基础模型 ChatGLM3-6B-Base 采用了更多样的训练数据、更充分的训练步数和更合理的训练策略。在语义、数学、推理、代码、知识等不同角度的数据集上测评显示,ChatGLM3-6B-Base 具有在 10B 以下的预训练模型中最强的性能。
|
| 26 |
2. **更完整的功能支持:** ChatGLM3-6B 采用了全新设计的 [Prompt 格式](https://github.com/THUDM/ChatGLM3/blob/main/PROMPT.md),除正常的多轮对话外。同时原生支持[工具调用](https://github.com/THUDM/ChatGLM3/blob/main/tool_using/README.md)(Function Call)、代码执行(Code Interpreter)和 Agent 任务等复杂场景。
|
| 27 |
3. **更全面的开源序列:** 除了对话模型 ChatGLM3-6B 外,还开源了基础模型 ChatGLM-6B-Base、长文本对话模型 ChatGLM3-6B-32K。以上所有权重对学术研究**完全开放**,在填写[问卷](https://open.bigmodel.cn/mla/form)进行登记后**亦允许免费商业使用**。
|
| 28 |
|
| 29 |
+
ChatGLM3-6B is the latest open-source model in the ChatGLM series. While retaining many excellent features such as smooth dialogue and low deployment threshold from the previous two generations, ChatGLM3-6B introduces the following features:
|
| 30 |
|
| 31 |
+
1. **More Powerful Base Model:** The base model of ChatGLM3-6B, ChatGLM3-6B-Base, employs a more diverse training dataset, more sufficient training steps, and a more reasonable training strategy. Evaluations on datasets such as semantics, mathematics, reasoning, code, knowledge, etc., show that ChatGLM3-6B-Base has the strongest performance among pre-trained models under 10B.
|
| 32 |
+
2. **More Comprehensive Function Support:** ChatGLM3-6B adopts a newly designed [Prompt format](https://github.com/THUDM/ChatGLM3/blob/main/PROMPT_en.md), in addition to the normal multi-turn dialogue. It also natively supports [function call](https://github.com/THUDM/ChatGLM3/blob/main/tool_using/README_en.md), code interpreter, and complex scenarios such as agent tasks.
|
| 33 |
+
3. **More Comprehensive Open-source Series:** In addition to the dialogue model ChatGLM3-6B, the base model ChatGLM-6B-Base and the long-text dialogue model ChatGLM3-6B-32K are also open-sourced. All the weights are **fully open** for academic research, and after completing the [questionnaire](https://open.bigmodel.cn/mla/form) registration, they are also **allowed for free commercial use**.
|
| 34 |
+
|
| 35 |
+
## 软件依赖 (Dependencies)
|
| 36 |
|
| 37 |
```shell
|
| 38 |
pip install protobuf transformers==4.30.2 cpm_kernels torch>=2.0 gradio mdtex2html sentencepiece accelerate
|
| 39 |
```
|
| 40 |
|
| 41 |
+
## 代码调用 (Code Usage)
|
| 42 |
|
| 43 |
可以通过如下代码调用 ChatGLM3-6B 模型来生成对话:
|
| 44 |
|
| 45 |
+
You can generate dialogue by invoking the ChatGLM3-6B model with the following code:
|
| 46 |
+
|
| 47 |
```ipython
|
| 48 |
>>> from transformers import AutoTokenizer, AutoModel
|
| 49 |
>>> tokenizer = AutoTokenizer.from_pretrained("THUDM/chatglm3-6b", trust_remote_code=True)
|
|
|
|
| 71 |
For more instructions, including how to run CLI and web demos, and model quantization, please refer to our [Github Repo](https://github.com/THUDM/ChatGLM).
|
| 72 |
|
| 73 |
|
| 74 |
+
## 协议 (License)
|
| 75 |
|
| 76 |
本仓库的代码依照 [Apache-2.0](LICENSE) 协议开源,ChatGLM3-6B 模型的权重的使用则需要遵循 [Model License](MODEL_LICENSE)。
|
| 77 |
|
| 78 |
+
The code in this repository is open-sourced under the [Apache-2.0 license](LICENSE), while the use of the ChatGLM3-6B model weights needs to comply with the [Model License](MODEL_LICENSE).
|
| 79 |
+
|
| 80 |
+
## 引用 (Citation)
|
| 81 |
|
| 82 |
如果你觉得我们的工作有帮助的话,请考虑引用下列论文。
|
| 83 |
|
| 84 |
+
If you find our work helpful, please consider citing the following papers.
|
| 85 |
+
|
| 86 |
```
|
| 87 |
@article{zeng2022glm,
|
| 88 |
title={Glm-130b: An open bilingual pre-trained model},
|