A low-bit quantization method and system for large language models

By dividing and analyzing the data of the large language model, establishing a quantitative evaluation model, and monitoring the quantification effect, the problem of insufficient efficiency and integration of low-bit quantization methods in the existing technology is solved, and efficient data processing and device compatibility are achieved to ensure improve the stability and performance of the model.

CN118485044BActive Publication Date: 2024-09-20XINGFAN XINGQI (CHENGDU) TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410931755.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-07-12
Publication Date
2024-09-20
Estimated Expiration
2044-07-12

AI Technical Summary

Technical Problem

Existing low-bit quantization methods for large language models have deficiencies in data processing efficiency and device integration, resulting in low processing time and possible islanding phenomena, which limits the overall performance of the model.

Method used

Through the steps of training data set division, data collection, data analysis and comprehensive analysis, we establish quantitative parameter reduction data, quantitative perception training data and post-training quantitative data analysis models, calculate the comprehensive quantitative evaluation index, and monitor the quantitative effect through early warning processing steps to achieve Low-bit quantization for precise tracking and real-time monitoring.

Benefits of technology

It improves the evaluation accuracy and efficiency of low-bit quantization, reduces memory overhead, speeds up processing performance, detects and solves potential problems in a timely manner, and ensures good quantification effects and system stability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118485044B
    Figure CN118485044B
Patent Text Reader

Abstract

The present invention discloses a low-bit quantization method and system for a large language model, which specifically relates to the field of deep learning technology, including a training data set division step, a data collection step, a data analysis step, a comprehensive data analysis step, and an early warning processing step. The present invention establishes a quantization parameter reduction data analysis model, a quantization perception training data analysis model, and a post-training quantization data analysis model through the data analysis step, and can perform in-depth analysis on the collected data. These analyses are conducive to identifying potential problems in bitization and providing data support for subsequent fine-tuning. The advantage of the present invention is that it accurately acquires and analyzes low-bit quantized data, providing a powerful solution for large enterprises.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of deep learning technology, and more specifically, to a low-bit quantization method and system for a large language model. Background Art

[0002] With the development of artificial intelligence, large language models refer to artificial intelligence models trained through huge corpora, integrating various language knowledge and language laws. Its basic principle is to model the statistical laws and potential semantic information of language through deep learning technology, especially multi-layer neural networks. During the training process, the model will learn and abstract a large amount of text data, so as to generate language output with logic and coherence.

[0003] The low bit rate method is a technology used in digital signal processing, data compression, transmission and storage. It achieves efficient data processing by reducing the bit rate of data. This method is usually applied to the compression and transmission of multimedia data such as audio, video, and images. It has a wide range of applications in real-time communications, mobile devices, low-bandwidth environments, and multimedia content distribution.

[0004] Although great progress has been made in the traditional low-bit quantization methods of large language models, existing methods still have some defects. For example, for large amounts of data, traditional data processing methods cannot analyze and predict in a timely manner, which leads to decreased data processing efficiency. Existing low-bit stream methods may not be able to integrate various devices, resulting in low timeliness in data processing. There may also be island phenomena, which makes it impossible to directly share data between different systems, thereby limiting the overall performance of large language models. Summary of the invention

[0005] In order to overcome the above defects of the prior art, the embodiments of the present invention provide a low-bit quantization method and system for a large language model, which solves the problems raised in the above background technology by using the field of degree learning technology.

[0006] To achieve the above object, the present invention provides the following technical solution: a low-bit quantization method for a large language model, comprising:

[0007] Step 1: Training data set division: It is used to determine the data of the target large language model as the target data area, divide the target data area into various sub-data areas in equal amounts, and mark them as 1, 2...n, and distribute them to downstream tasks. Each downstream task is represented by a training data set of a set of context-target key-value pairs: , where Z is the training data set, and They are all token sequences;

[0008] Step 2: Data collection: used to collect the quantization parameter reduction data, quantization perception training data and post-training quantization data of each sub-data, and transmit the collected data to the data analysis step;

[0009] Step 3: Data analysis: including a quantization parameter reduction data analysis method, a quantization perception training data analysis method, and a post-training quantization data analysis method, which are used to analyze the data transmitted in the data acquisition step and transmit the analysis results to the comprehensive analysis step;

[0010] Step 4: Comprehensive analysis: used to establish a comprehensive analysis model, import the data collected and transmitted into the comprehensive analysis model, calculate the comprehensive quantitative evaluation index of each sub-data area, and transmit it to the early warning processing step;

[0011] Step 5: Early warning processing: used to accurately compare the comprehensive quantitative evaluation value with the preset comprehensive quantitative evaluation value, calculate the difference between the comprehensive quantitative evaluation value and the preset comprehensive quantitative evaluation value, judge the difference value and the preset difference value, and issue an early warning signal based on the judgment result.

[0012] Preferably, the token sequence: for the summary task, It is the content of an article. is its summary content; for SQL, is a natural language query, is the corresponding SQL command.

[0013] Preferably, the data of the target large language model is determined as a target data region, and the target data region is divided into sub-data regions of equal size and marked as 1, 2, ..., n.

[0014] Preferably, the quantization parameter reduction data includes: loss amount, number of fine-tuning times and rank reduction efficiency, respectively denoted as Sn, Sw and Sj; the quantization perception training data includes: training time, memory space size, processor clock cycle, and access volume, respectively denoted as Lx, Lc, Ls, and Lf; the post-training quantization data includes: the number of trainable parameters, pre-trained weights, the size of the intrinsic rank, and the pre-trained weights, respectively denoted as A, W, R, and .

[0015] Preferably, the quantization parameter reduction data analysis method is used to establish a quantization parameter reduction data analysis model, import the quantization parameter reduction data transmitted in the data acquisition and analysis step into the quantization parameter reduction data analysis model, and calculate the quantization parameter reduction evaluation value of each sub-data area, and the specific acquisition method is: ,in represents the quantization parameter reduction evaluation value of the i-th sub-data region, Indicates the maximum loss amount of the target data area, represents the loss amount of the ith sub-data area, Indicates the number of fine-tuning times of the (i-1)th sub-data area, Indicates the number of fine-tuning times of the ith sub-data area, represents the rank reduction efficiency of the i-th sub-region.

[0016] Preferably, the quantitative perception training data analysis method is used to establish a quantitative perception training data analysis model, the quantitative perception training data transmitted in the data collection and analysis step is imported into the quantitative perception training data analysis model, and the quantitative perception training evaluation value of each sub-data area is calculated, and the specific acquisition method is: ,in represents the quantization-aware training evaluation value of the ith sub-data region, represents the training time of the ith sub-data region, Indicates the memory space size of the (i-1)th sub-data area, Indicates the memory space size of the i-th sub-data area, represents the clock cycle of the processor for the ith sub-data area, represents the number of visits to the (i-1)th sub-data area, Indicates the number of visits to the i-th sub-data area.

[0017] Preferably, the post-training quantitative data analysis method is used to establish a post-training quantitative data analysis model, import the post-training quantitative data transmitted in the data acquisition and analysis step into the post-training quantitative data analysis model, and calculate the post-training quantitative evaluation value of each sub-data area. The specific acquisition method is:

[0018] Assume a target large language model, denoted as , A general multi-task learning model based on the Transformer architecture, such as GPT; the model sub-data area initializes the pre-trained weights , updated by repeated gradients , the modeling target sub-area is as follows: , ,in Represents the post-training quantitative evaluation value of the sub-data region; Perform low-rank decomposition into and , Represents the initialization of the pre-trained weights of the sub-data region by using a low-rank decomposition Perform constraint updates, where , , and the order , where d and k are the rows and columns of the rank respectively; initialized with a random Gaussian and ,so Initialized to zero, Ratio scaling ,in is a constant in r, It represents the influencing factor of rank reduction; the model reduces parameters by rank reduction, thereby achieving low-bit quantization.

[0019] Preferably, the comprehensive analysis model is specifically obtained in the following manner: ,in Represents the comprehensive quantitative evaluation value of the target area, represents the quantization parameter reduction evaluation value of the i-th sub-data region, represents the quantization-aware training evaluation value of the ith sub-data region, Represents the post-training quantized evaluation value of the sub-data region, The weight of the quantitative parameter reduction evaluation value representing the target data area, represents the weight of the quantization-aware training evaluation value of the target data region, represents the weight of the post-training quantized evaluation value of the target data region, Represents other influencing factors of the comprehensive quantitative evaluation value of the target data area, and i represents the number of the i-th sub-data area.

[0020] Preferably, the preset comprehensive quantitative evaluation value is the average of the comprehensive quantitative evaluation values ​​of previous years, wherein the average removes the maximum value and the minimum value, and the maximum value and the minimum value are both extreme values ​​of external factors. The preset comprehensive quantitative evaluation value is recorded as , the preset difference value is the difference between the theoretical comprehensive quantization evaluation value and the actual comprehensive quantization evaluation value. When the difference value is less than the preset difference value, it means that the quantization effect of the target data area is good. When the difference value is greater than the preset difference value, it means that the quantization effect of the target data area is abnormal, and an early warning signal is sent to the management terminal, and the corresponding low-bit quantization operation is adjusted.

[0021] Preferably, a low-bit quantization system for a large language model specifically includes:

[0022] Training data set partitioning module: used to determine the data of the target large language model as the target data area, divide the target data area into equal parts, and mark them as 1, 2...n, and distribute them to downstream tasks. Each downstream task is represented by a training data set of a set of context-target key-value pairs: , where Z is the training data set, and They are all token sequences;

[0023] Data acquisition module: used to collect the quantization parameter reduction data, quantization perception training data and post-training quantization data of each sub-data, and transmit the collected data to the data analysis module;

[0024] Data analysis module: including quantization parameter reduction data analysis method, quantization perception training data analysis method and post-training quantization data analysis method, used for analyzing the data transmitted by the data acquisition module and transmitting the analysis results to the comprehensive analysis module;

[0025] Comprehensive analysis module: used to establish a comprehensive analysis model, import the data collected and transmitted into the comprehensive analysis model, calculate the comprehensive quantitative evaluation index of each sub-data area, and transmit it to the early warning processing module;

[0026] Early warning processing module: used to accurately compare the comprehensive quantitative evaluation value with the preset comprehensive quantitative evaluation value, calculate the difference between the comprehensive quantitative evaluation value and the preset comprehensive quantitative evaluation value, judge the difference value and the preset difference value, and issue an early warning signal based on the judgment result.

[0027] Technical effects and advantages of the present invention:

[0028] 1. The present invention can accurately track low-bit quantization through the training data set division step, which helps to timely discover and solve low-bit problems. In addition, the marking of sub-data areas makes data analysis more reasonable and well-founded, greatly improving the accuracy and efficiency of evaluation;

[0029] 2. The present invention collects quantization parameter reduction data, quantization perception training data and post-training quantization data through the data collection step, which can comprehensively evaluate the status after low-bit quantization, reduce a large amount of parameter data, and thus speed up the efficiency of the processor. These data are important evaluation criteria, which are conducive to reducing memory overhead and speeding up data processing performance;

[0030] 3. The present invention establishes a quantization parameter reduction data analysis model, a quantization perception training data analysis model and a post-training quantization data analysis model through a data analysis step, and can perform in-depth analysis on the collected data to calculate the quantization parameter reduction evaluation value, the quantization perception training evaluation value and the post-training quantization evaluation value of each sub-data area. These analyses are helpful in identifying potential problems in bitization and providing data support for subsequent fine-tuning. A comprehensive analysis model is established through a comprehensive analysis step, and the results of the data analysis step are analyzed to calculate the comprehensive quantization evaluation value of each sub-data area, making low-bit quantization more intuitive. BRIEF DESCRIPTION OF THE DRAWINGS

[0031] Figure 1 It is a schematic diagram of the overall structure of the present invention. DETAILED DESCRIPTION

[0032] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0033] refer to Figure 1 A low-bit quantization method for a large language model is shown, and the specific steps include:

[0034] Step 1: Training data set division: It is used to determine the data of the target large language model as the target data area, divide the target data area into various sub-data areas in equal amounts, and mark them as 1, 2...n, and distribute them to downstream tasks. Each downstream task is represented by a training data set of a set of context-target key-value pairs: , where Z is the training data set, and They are all token sequences.

[0035] In this embodiment, the token sequence needs to be specifically explained: for the summary task, It is the content of an article. is its summary content; for SQL, is a natural language query, is the corresponding SQL command.

[0036] Step 2: Data collection: used to collect the quantization parameter reduction data, quantization perception training data and post-training quantization data of each sub-data, and transmit the collected data to the data analysis step.

[0037] In this embodiment, it should be specifically noted that the quantization parameter reduction data includes: loss amount, number of fine-tuning times and rank reduction efficiency, respectively denoted as Sn, Sw and Sj; the quantization perception training data includes: training time, memory space size, processor clock cycle, and access volume, respectively denoted as Lx, Lc, Ls, and Lf; the post-training quantization data includes: the number of trainable parameters, pre-trained weights, the size of the intrinsic rank, and the pre-trained weights, respectively denoted as A, W, R, and .

[0038] Step 3: Data analysis: including quantization parameter reduction data analysis method, quantization perception training data analysis method and post-training quantization data analysis method, which are used to analyze the data transmitted in the data acquisition step and transmit the analysis results to the comprehensive analysis step.

[0039] In this embodiment, it is specifically required to explain that the quantization parameter reduction data analysis method is used to establish a quantization parameter reduction data analysis model, import the quantization parameter reduction data transmitted in the data acquisition and analysis step into the quantization parameter reduction data analysis model, and calculate the quantization parameter reduction evaluation value of each sub-data area. The specific acquisition method is: ,in represents the quantization parameter reduction evaluation value of the i-th sub-data region, Indicates the maximum loss amount of the target data area, represents the loss amount of the ith sub-data area, Indicates the number of fine-tuning times of the (i-1)th sub-data area, Indicates the number of fine-tuning times of the ith sub-data area, represents the rank reduction efficiency of the i-th sub-region.

[0040] In this embodiment, it is specifically necessary to explain that the quantitative perception training data analysis method is used to establish a quantitative perception training data analysis model, the quantitative perception training data transmitted in the data collection and analysis step is imported into the quantitative perception training data analysis model, and the quantitative perception training evaluation value of each sub-data area is calculated. The specific acquisition method is: ,in represents the quantization-aware training evaluation value of the ith sub-data region, represents the training time of the ith sub-data region, Indicates the memory space size of the (i-1)th sub-data area, Indicates the memory space size of the i-th sub-data area, represents the clock cycle of the processor for the ith sub-data area, represents the number of visits to the (i-1)th sub-data area, Indicates the number of visits to the i-th sub-data area.

[0041] In this embodiment, it is specifically necessary to explain that the post-training quantitative data analysis method is used to establish a post-training quantitative data analysis model, the post-training quantitative data transmitted in the data acquisition and analysis step is imported into the post-training quantitative data analysis model, and the post-training quantitative evaluation value of each sub-data area is calculated. The specific acquisition method is:

[0042] Assume a target large language model, denoted as , A general multi-task learning model based on the Transformer architecture, such as GPT; the model sub-data area initializes the pre-trained weights , updated by repeated gradients , the modeling target sub-area is as follows: , ,in Represents the post-training quantitative evaluation value of the sub-data region; Perform low-rank decomposition into and , Represents the initialization of the pre-trained weights of the sub-data region by using a low-rank decomposition Perform constraint updates, where , , and the order , where d and k are the rows and columns of the rank respectively; initialized with a random Gaussian and ,so Initialized to zero, Ratio scaling ,in is a constant in r, It represents the influencing factor of rank reduction; the model reduces parameters by rank reduction, thereby achieving low-bit quantization.

[0043] Step 4: Comprehensive analysis: used to establish a comprehensive analysis model, import the data transmitted by data collection into the comprehensive analysis model, calculate the comprehensive quantitative evaluation index of each sub-data area, and transmit it to the early warning processing step.

[0044] In this embodiment, it is specifically necessary to explain the specific method of obtaining the comprehensive analysis model: ,in Represents the comprehensive quantitative evaluation value of the target area, represents the quantization parameter reduction evaluation value of the i-th sub-data region, represents the quantization-aware training evaluation value of the ith sub-data region, Represents the post-training quantized evaluation value of the sub-data region, The weight of the quantitative parameter reduction evaluation value representing the target data area, represents the weight of the quantization-aware training evaluation value of the target data region, represents the weight of the post-training quantized evaluation value of the target data region, Represents other influencing factors of the comprehensive quantitative evaluation value of the target data area, and i represents the number of the i-th sub-data area.

[0045] Step 5: Early warning processing: used to accurately compare the comprehensive quantitative evaluation value with the preset comprehensive quantitative evaluation value, calculate the difference between the comprehensive quantitative evaluation value and the preset comprehensive quantitative evaluation value, judge the difference value and the preset difference value, and issue an early warning signal based on the judgment result.

[0046] In this embodiment, it should be specifically noted that the preset comprehensive quantitative evaluation value is the average of the comprehensive quantitative evaluation values ​​of previous years, wherein the average removes the maximum and minimum values, and the maximum and minimum values ​​are both extreme values ​​of external factors. The preset comprehensive quantitative evaluation value is recorded as , the preset difference value is the difference between the theoretical comprehensive quantization evaluation value and the actual comprehensive quantization evaluation value. When the difference value is less than the preset difference value, it means that the quantization effect of the target data area is good. When the difference value is greater than the preset difference value, it means that the quantization effect of the target data area is abnormal, and an early warning signal is sent to the management terminal, and the corresponding low-bit quantization operation is adjusted.

[0047] A low-bit quantization system for a large language model, specifically comprising:

[0048] Training data set partitioning module: used to determine the data of the target large language model as the target data area, divide the target data area into equal parts, and mark them as 1, 2...n, and distribute them to downstream tasks. Each downstream task is represented by a training data set of a set of context-target key-value pairs: , where Z is the training data set, and They are all token sequences;

[0049] Data acquisition module: used to collect the quantization parameter reduction data, quantization perception training data and post-training quantization data of each sub-data, and transmit the collected data to the data analysis module;

[0050] Data analysis module: including quantization parameter reduction data analysis method, quantization perception training data analysis method and post-training quantization data analysis method, used for analyzing the data transmitted by the data acquisition module and transmitting the analysis results to the comprehensive analysis module;

[0051] Comprehensive analysis module: used to establish a comprehensive analysis model, import the data collected and transmitted into the comprehensive analysis model, calculate the comprehensive quantitative evaluation index of each sub-data area, and transmit it to the early warning processing module;

[0052] Early warning processing module: used to accurately compare the comprehensive quantitative evaluation value with the preset comprehensive quantitative evaluation value, calculate the difference between the comprehensive quantitative evaluation value and the preset comprehensive quantitative evaluation value, judge the difference value and the preset difference value, and issue an early warning signal based on the judgment result.

[0053] The present invention can accurately track low-bit quantization through the training data set division step, which is helpful to timely discover and solve low-bit problems. In addition, the marking of sub-data areas makes data analysis more reasonable and well-founded, greatly improving the accuracy and efficiency of evaluation; through the data collection step, quantization parameter reduction data, quantization perception training data and post-training quantization data are collected, and the status after low-bit quantization can be comprehensively evaluated, and a large amount of parameter data can be reduced, thereby accelerating the efficiency of the processor. These data are important evaluation criteria, which is conducive to reducing memory overhead and accelerating data processing performance; through the data analysis step, a quantization parameter reduction data analysis model and a quantization perception training data division model are established. The analysis model and the post-training quantization data analysis model can conduct in-depth analysis of the collected data, calculate the quantization parameter reduction evaluation value, quantization perception training evaluation value and post-training quantization evaluation value of each sub-data area, and these analyses are conducive to identifying potential problems in bitization and providing data support for subsequent fine-tuning; through the comprehensive analysis step to establish a comprehensive analysis model, the results of the data analysis step are analyzed, and the comprehensive quantization evaluation value of each sub-data area can be calculated, making the low-bit quantization more intuitive; through the early warning processing step, this step realizes real-time monitoring and early warning of low-bit quantization, which is conducive to quickly discovering and handling problems and ensuring the stability and security of low-bit quantization.

[0054] Secondly, in the drawings of the embodiments disclosed in the present invention, only the structures related to the embodiments disclosed in the present invention are involved, and other structures can refer to the general design. In the absence of conflict, the same embodiment and different embodiments of the present invention can be combined with each other;

[0055] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims

1. A low-bit quantization method for a large language model, characterized in that: include: Step 1: Training data set division: It is used to determine the data of the target large language model as the target data area, divide the target data area into various sub-data areas in equal amounts, and mark them as 1, 2...n, and distribute them to downstream tasks. Each downstream task is represented by a training data set of a set of context-target key-value pairs: , where Z is the training data set, and They are all token sequences; Step 2: Data collection: used to collect the quantization parameter reduction data, quantization perception training data and post-training quantization data of each sub-data, and transmit the collected data to the data analysis step; Step 3: Data analysis: including a quantization parameter reduction data analysis method, a quantization perception training data analysis method, and a post-training quantization data analysis method, which are used to analyze the data transmitted in the data acquisition step and transmit the analysis results to the comprehensive analysis step; Step 4: Comprehensive analysis: used to establish a comprehensive analysis model, import the data collected and transmitted into the comprehensive analysis model, calculate the comprehensive quantitative evaluation index of each sub-data area, and transmit it to the early warning processing step; Step 5: Early warning processing: used to accurately compare the comprehensive quantitative evaluation value with the preset comprehensive quantitative evaluation value, calculate the difference between the comprehensive quantitative evaluation value and the preset comprehensive quantitative evaluation value, judge the difference between the difference and the preset difference, and issue an early warning signal according to the judgment result; The quantization parameter reduction data analysis method is used to establish a quantization parameter reduction data analysis model, import the quantization parameter reduction data transmitted in the data acquisition and analysis step into the quantization parameter reduction data analysis model, and calculate the quantization parameter reduction evaluation value of each sub-data area. The specific acquisition method is: , in represents the quantization parameter reduction evaluation value of the i-th sub-data region, Indicates the maximum loss amount of the target data area, represents the loss amount of the ith sub-data area, Indicates the number of fine-tuning times of the (i-1)th sub-data area, Indicates the number of fine-tuning times of the ith sub-data area, represents the rank reduction efficiency of the i-th sub-region; The quantitative perception training data analysis method is used to establish a quantitative perception training data analysis model, import the quantitative perception training data transmitted in the data collection and analysis step into the quantitative perception training data analysis model, and calculate the quantitative perception training evaluation value of each sub-data area. The specific acquisition method is: , in represents the quantization-aware training evaluation value of the ith sub-data region, represents the training time of the ith sub-data region, Indicates the memory space size of the (i-1)th sub-data area, Indicates the memory space size of the i-th sub-data area, represents the clock cycle of the processor for the ith sub-data area, represents the number of visits to the (i-1)th sub-data area, Indicates the number of visits to the ith sub-data area; The post-training quantitative data analysis method is used to establish a post-training quantitative data analysis model, import the post-training quantitative data transmitted in the data acquisition and analysis step into the post-training quantitative data analysis model, and calculate the post-training quantitative evaluation value of each sub-data area. The specific acquisition method is: Assume a target large language model, denoted as , A general multi-task learning model based on the Transformer architecture; the model initializes the pre-trained weights in the sub-data region , updated by repeated gradients , the modeling target sub-area is as follows: , , in Represents the post-training quantitative evaluation value of the sub-data region; Perform low-rank decomposition into and , Represents the initialization of the pre-trained weights of the sub-data region by using a low-rank decomposition Perform constraint updates, where , , and the order , where d and k are the rows and columns of the rank respectively; initialized with a random Gaussian and ,so Initialized to zero, Ratio scaling ,in is a constant in r, It indicates the influence factor of rank reduction; The specific method of obtaining the comprehensive analysis model is as follows: , in Represents the comprehensive quantitative evaluation value of the target area, represents the quantization parameter reduction evaluation value of the i-th sub-data region, represents the quantization-aware training evaluation value of the ith sub-data region, Represents the post-training quantized evaluation value of the sub-data region, The weight of the quantitative parameter reduction evaluation value representing the target data area, represents the weight of the quantization-aware training evaluation value of the target data region, represents the weight of the post-training quantized evaluation value of the target data region, Represents other influencing factors of the comprehensive quantitative evaluation value of the target data area, and i represents the number of the i-th sub-data area.

2. The low-bit quantization method for a large language model according to claim 1, characterized in that: The token sequence: For the summary task, It is the content of an article. is its summary content; for SQL, is a natural language query, is the corresponding SQL command.

3. The low-bit quantization method for a large language model according to claim 1, characterized in that: The quantization parameter reduction data includes: loss amount, number of fine-tuning times and rank reduction efficiency, respectively denoted as Sn, Sw and Sj; the quantization-aware training data includes: training time, memory space size, processor clock cycle, and access volume, respectively denoted as Lx, Lc, Ls, and Lf; the post-training quantization data includes: the number of trainable parameters, pre-trained weights, the size of the intrinsic rank, and the pre-trained weights, respectively denoted as A, W, R, and .

4. The low-bit quantization method for a large language model according to claim 1, characterized in that: The preset comprehensive quantitative evaluation value is the average of the comprehensive quantitative evaluation values ​​of previous years, where the maximum and minimum values ​​are removed from the average. The maximum and minimum values ​​are both extreme values ​​of external factors. The preset comprehensive quantitative evaluation value is recorded as , the preset difference value is the difference between the theoretical comprehensive quantitative evaluation value and the actual comprehensive quantitative evaluation value. When the difference value is less than the preset difference value, it indicates that the quantization effect of the target data area is good; When the difference value is greater than the preset difference value, it indicates that the quantization effect of the target data area is abnormal, and an early warning signal is sent to the management terminal, and the corresponding low-bit quantization operation is adjusted.

5. A low-bit quantization system for a large language model, used to implement the low-bit quantization method for a large language model as described in any one of claims 1 to 4, characterized in that: include: Training data set partitioning module: used to determine the data of the target large language model as the target data area, divide the target data area into equal parts, and mark them as 1, 2...n, and distribute them to downstream tasks. Each downstream task is represented by a training data set of a set of context-target key-value pairs: , where Z is the training data set, and They are all token sequences; Data acquisition module: used to collect the quantization parameter reduction data, quantization perception training data and post-training quantization data of each sub-data, and transmit the collected data to the data analysis module; Data analysis module: including quantization parameter reduction data analysis method, quantization perception training data analysis method and post-training quantization data analysis method, used for analyzing the data transmitted by the data acquisition module and transmitting the analysis results to the comprehensive analysis module; Comprehensive analysis module: used to establish a comprehensive analysis model, import the data collected and transmitted into the comprehensive analysis model, calculate the comprehensive quantitative evaluation index of each sub-data area, and transmit it to the early warning processing module; Early warning processing module: used to accurately compare the comprehensive quantitative evaluation value with the preset comprehensive quantitative evaluation value, calculate the difference between the comprehensive quantitative evaluation value and the preset comprehensive quantitative evaluation value, judge the difference value and the preset difference value, and issue an early warning signal based on the judgment result.