Baichuan-7B is an open-source large-scale pre-trained model developed by Baichuan Intelligent Technology. Based on the Transformer architecture, it is a model with 7 billion parameters trained on approximately 1.2 trillion tokens. It supports both Chinese and English, with a context window length of 4096. It achieves the best performance of its size on standard Chinese and English authoritative benchmarks (C-EVAL/MMLU).
If you wish to use Baichuan-7B (for inference, finetuning, etc.), we recommend using the accompanying code library Baichuan-7B.
The following is a task of performing 1-shot inference using Baichuan-7B, where the author's name is given based on the work, with the correct output being "One Hundred Years of Solitude->Gabriel Garcia Marquez"
The overall model is based on the standard Transformer structure, and we have adopted the same model design as LLaMA:
Position Embedding: We use rotary-embedding, which is the position encoding scheme adopted by most models at this stage, and it has excellent extrapolation capabilities.
Feedforward Layer: We use SwiGLU. The feedforward changes to (8/3) times the size of the hidden layer, that is, 11008.
Layer Normalization: Pre-Normalization based on RMSNorm.
We have also open-sourced the training code that accompanies this model, allowing for efficient finetuning for downstream tasks. For more details, please refer to Baichuan-7B.
Out-of-Scope Use
在没有充分评估风险和采取缓解措施的情况下投入生产使用;任何可能被视为不负责任或有害的使用案例。
Production use without adequate assessment of risks and mitigation; any use cases which may be considered irresponsible or harmful.
Baichuan-7B can produce factually incorrect output, and should not be relied on to produce factually accurate information. Baichuan-7B was trained on various public datasets. While great efforts have been taken to clean the pretraining data, it is possible that this model could generate lewd, biased or otherwise offensive outputs.
In addition to Chinese, we also tested the model's performance in English.
MMLU
MMLU is an English evaluation dataset that includes 57 multiple-choice tasks, covering elementary mathematics, American history, computer science, law, etc. The difficulty ranges from high school level to expert level, making it a mainstream LLM evaluation dataset.
We adopted the open-source evaluation scheme, and the final 5-shot results are as follows:
Model
Humanities
Social Sciences
STEM
Other
Average
LLaMA-7B2
34.0
38.3
30.5
38.1
35.1
Falcon-7B1
-
-
-
-
35.0
mpt-7B1
-
-
-
-
35.6
ChatGLM-6B0
35.4
41.0
31.3
40.5
36.9
BLOOM 7B0
25.0
24.4
26.5
26.4
25.5
BLOOMZ 7B0
31.3
42.1
34.4
39.0
36.1
moss-moon-003-base (16B)0
24.2
22.8
22.4
24.4
23.6
moss-moon-003-sft (16B)0
30.5
33.8
29.3
34.4
31.9
Baichuan-7B0
38.4
48.9
35.6
48.1
42.3
The superscript in the Model column indicates the source of the results.