[2024/06/28] Updated tokenizers. [2024/01/16] Released the long-sequence model XVERSE-13B-256K. This model version supports a maximum window length of 256K, accommodating approximately 250,000 words for tasks such as literature summarization and report analysis. [2023/11/06] The new versions of the XVERSE-13B-2 base model and the XVERSE-13B-Chat-2 model have been released. Compared to the original versions, the new models have undergone more extensive training (increasing from 1.4T to 3.2T), resulting in significant improvements in all capabilities, along with the addition of Function Call abilities. [2023/09/26] Released the XVERSE-7B base model and XVERSE-7B-Chat instruct-finetuned model with 7B size, which support deployment and operation on a single consumer-grade graphics card while maintaining high performance, full open source, and free for commercial use. [2023/08/22] Released the aligned instruct-finetuned model XVERSE-13B-Chat. [2023/08/07] Released the XVERSE-13B base model.
For tokenizer versions below 0.19, you can directly use the tokenizer.json and tokenizer_config.json files from the repository. For versions 0.19 and above, please utilize the tokenizer.json.update and tokenizer_config.json.update files. You need to copy all the contents from these two files and paste them over the existing tokenizer.json and tokenizer_config.json files.
XVERSE-13B-256K is the long-sequence version of model XVERSE-13B-2,
updated by Continual-Pre-Training based on ABF and supervised fine-tuning based on NTK.
XVERSE-13B-256K is a multilingual large language model, independently developed by Shenzhen Yuanxiang Technology. Below are the main practical techniques:
ABF: Adjusted Base Frequency means that changing the frequency of Rotary Position Embedding(RoPE) from 10,000 to 500,000.
Continual-Pre-Training: Based on XVERSE-13B-2, 32K long sequence continuation pre-training is conducted using 20% of the pre-training data. This approach significantly reduces the training volume for pre-training by utilizing a small amount of long sequence data for continuation pre-training instead of starting from scratch with long sequence pre-training.
NTK: Neural Tangent Kernel is a tool used for understanding and analyzing the behavior of deep neural networks. RoPE, employing NTK, enables dynamic interpolation of its frequencies. This involves scaling in the frequency domain while maintaining resolution, thereby achieving spatial interpolation in the positional domain.
Data for SFT: We autonomously construct a diverse range of long sequence data, encompassing single-document question-answering (QA), multi-document QA, summarization, code completion, and other types. The sequence lengths vary from 32K to 256K.
To assess the performance of long sequences, we employed the LongBench dataset. LongBench stands as the inaugural multi-task, bilingual (English-Chinese), evaluation benchmark specifically designed to gauge the long-text comprehension capabilities of large language models. Comprising six major categories and twenty-one distinct tasks, LongBench encompasses critical long-text application scenarios such as single-document QA, multi-document QA, summarization, few-shot tasks, synthetic tasks, and code completion. The dataset consists of 14 English tasks, 5 Chinese tasks, and 2 code tasks, with the majority of tasks having an average length ranging from 5,000 to 15,000 tokens, totaling 4,750 test instances. The evaluation results are presented below:
Capability Dimension
Dataset
XVERSE-13B-256K
GPT-3.5-Turbo-16K
Yi-6B-200K
LongChat-7B-16K
Llama2-7B-Chat-4K
multi-document QA
HotpotQA
58.3
51.6
48.3
22.4
24.3
DuReader
28.9
28.7
14.2
19.1
1.9
single-document QA
NarrativeQA
24.1
23.6
14.5
21.6
19.1
Qasper
30.2
43.3
21.6
21.6
19.6
summarization
VCSUM
11.3
16.0
8.2
14.0
0.2
Few shot
TREC
72.0
68.0
71.0
61.5
60.5
LSHT
35.0
29.2
38.0
20.8
19.8
synthetic tasks
PassageRetrieval-en
63.0
71.0
6.0
24.0
9.2
PassageRetrieval-zh
44.0
77.5
7.9
4.8
0.5
code completion
RepoBench-P
55.6
53.6
61.5
54.7
42.4
For all the comparison models mentioned above, we prioritize the disclosure of their officially published results. In the absence of official data, we refer to the results derived from our own evaluation pipeline.
Loading with Transformers
环境安装:
Environment Setup:
pip install -r requirements.txt
可通过以下代码加载 XVERSE-13B-256K 模型进行对话:
The XVERSE-13B-256K model can be loaded for chat using the following code:
Like all other Large Language Models (LLMs), XVERSE-13B-256K may produce inaccurate, biased, or otherwise offensive content under certain circumstances. Therefore, please use the content generated by the model with caution and refrain from disseminating harmful content. Before deploying any application of XVERSE-13B-256K, developers should conduct safety tests and optimization of the model according to its specific application.
We strongly warn against the use of the XVERSE-13B-256K model for producing or spreading harmful information, or conducting any activities that might harm the public, national, or social security, or violate regulations. We assume no responsibility for any problems arising from the use of the XVERSE-13B-256K model, whether it be data security issues, public opinion risks, or any risks and issues caused by misunderstanding, misuse, dissemination, or non-compliance with the model.
The use of the source code in this repository must follow the Apache-2.0 open-source license, while the use of the model weights of XVERSE-13B-256K needs to adhere to the Model License Agreement.
The XVERSE-13B-256K model weights are fully open to academic research and support free commercial use. To apply for a commercial license, please fill in the application form. For other questions or collaborations, please contact opensource@xverse.cn.