A label noise learning method for taxpayer industry classification

By estimating the conditional transfer matrix and improving the mixed proportion estimation method, combined with XLNet and TextCNN networks, the problem of label noise and anchor point dependence in taxpayer industry classification is solved, a risk-consistent classifier in multi-classification scenarios is realized, and classification accuracy is improved ity and applicability.

CN114817546BActive Publication Date: 2024-09-10SERVYOU SOFTWARE GRP
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210498954.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-05-09
Publication Date
2024-09-10
Estimated Expiration
2042-05-09

AI Technical Summary

Technical Problem

The existing technology relies on strict annotation of data and semantic clustering methods in taxpayer industry classification. Classification errors occur when there is label noise. Moreover, the traditional mixture proportion estimation method is only suitable for two classifications, is difficult to generalize to multi-classification scenarios and relies on anchor points. Label.

Method used

By estimating the conditional transfer matrix, a risk-consistent classifier based on label noise data is constructed. The XLNet text pre-training network and the TextCNN network are combined to improve the hybrid proportion estimation method and extend it to multi-classification scenarios to overcome the anchor dependence problem.

Benefits of technology

It achieves the construction of a risk-consistent taxpayer industry classifier without relying on additional clustering methods and anchor annotations, improves classification accuracy and applicability, and avoids errors introduced by semantic clustering methods.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114817546B
    Figure CN114817546B
Patent Text Reader

Abstract

The present invention discloses a label noise learning method for taxpayer industry classification, comprising: firstly, extracting text information and non-text information from taxpayer industry information, performing text embedding and non-text encoding processing based on XLNet text pre-training network and encoding technology respectively, and obtaining feature information; secondly, constructing a TextCNN network for taxpayer industry classification, determining the number of network layers, convolution kernel shapes, and input and output dimensions of each layer according to feature information and target classification number, and connecting the XLNet text pre-training network and the TextCNN network in series, combining noisy taxpayer industry label data as supervision, and constructing an end-to-end training device; thirdly, estimating a conditional transfer matrix based on an improved mixed ratio estimation method; finally, learning network parameters in the training device, and using the conditional transfer matrix as a linear layer after the TextCNN network, realizing the conversion from noise label prediction to real taxpayer industry label prediction, and performing taxpayer industry classification.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of text classification with label noise, and in particular relates to a label noise learning method for taxpayer industry classification. Background Art

[0002] In recent years, the market economy has continued to prosper, the number of enterprises has increased, and the division of labor among enterprises has continued to refine. As a result, the upgrading and further construction of the tax system has become an urgent need.

[0003] Taxpayer industry classification is a prerequisite for determining tax subject policies and preferential treatment, and is an important part of tax collection. At present, my country mainly divides taxpayer industries into 20 categories and 97 major categories. Due to the large number of categories, the traditional manual classification method requires a lot of human resources. At the same time, it is limited by the professional knowledge and experience of the classifier, and it will inevitably introduce classification errors, that is, the label noise of taxpayer industry classification, which has caused a series of adverse effects on the country's statistics, taxation, and industrial and commercial management.

[0004] In recent years, with the accelerated arrival of the "smart +" era, the artificial intelligence industry has developed rapidly and applied to various fields, providing possibilities for the exploration and development of smart taxation. Researching the industry classification of corporate taxpayers is the basic work of tax source classification management and the key prerequisite for smart taxation informatization. Therefore, how to use machine learning to train classifiers based on existing label noise data to correctly classify taxpayer industries has become an urgent problem to be solved.

[0005] The technical solutions for taxpayer industry classification issues involve the following invention patents:

[0006] Reference 1: A two-level classification method for taxpayer industries based on MIMO recurrent neural network (201910024324.1)

[0007] Literature 2: A taxpayer industry classification method based on noise label learning (202110201214.5)

[0008] Reference 1 designed a multi-input multi-output neural network structure based on GRU, established a mapping relationship from industry categories to industry details, and constructed a two-layer classification structure to achieve the industry classification of taxpayers. However, this method relies on strict data labeling and lacks practical value in the presence of label noise.

[0009] Reference 2 designed a BERT-CNN network for text classification. Based on the semantic clustering method, it used label noisy data to build a classifier with consistent classification. However, the performance limitations of the semantic clustering method introduced new errors into the classifier.

[0010] In view of the defects of the above-mentioned technical solutions, the present invention aims to not rely on additional manual annotation, and overcome the classification bias caused by the semantic clustering method used in the existing technical solutions, and construct a risk-consistent classifier based only on labeled noise data, so that in a statistical sense, the classifier constructed based on labeled noise data has the same classification risk as the classifier constructed using real annotated data.

[0011] The core of constructing a risk-consistent classifier based on labeled noise data is to construct a statistically consistent classifier by estimating the conditional transfer matrix (a matrix consisting of the conditional probabilities of the true labels given the noise labels). The present invention creatively transforms the conditional transfer matrix estimation problem into a mixture ratio estimation problem, and obtains an approximate conditional transfer matrix by estimating the mixture ratio coefficient. However, the traditional mixture ratio estimation method is only applicable to binary classification scenarios and depends on anchor points (samples that clearly belong to a certain category), while the taxpayer industry classification problem has many industry categories and belongs to a multi-classification problem, and the anchor points are difficult to label and obtain. Therefore, generalizing the mixture ratio estimation problem from binary classification to multi-classification and overcoming the anchor point dependency problem are the main challenges that the present invention solves. Summary of the invention

[0012] The purpose of the present invention is to provide a label noise learning method for taxpayer industry classification, which constructs a risk consistency classifier based on the label noise data estimating the conditional transfer matrix (a matrix consisting of the conditional probability of the true label given the noise label).

[0013] The present invention is achieved by adopting the following technical solutions:

[0014] A label noise learning method for taxpayer industry classification, including:

[0015] Firstly, the text information and non-text information in the taxpayer's industry information are extracted, and text embedding and non-text encoding processing are performed based on the XLNet text pre-trained network and encoding technology to obtain feature information; secondly, a TextCNN network for taxpayer industry classification is constructed, and the number of network layers, convolution kernel shape, and input and output dimensions of each layer are determined according to the feature information and the number of target classifications. The XLNet text pre-trained network and the TextCNN network are connected in series, and the noisy taxpayer industry label data is used as supervision to construct an end-to-end training device; thirdly, the conditional transfer matrix is ​​estimated based on the improved mixed ratio estimation method; finally, the network parameters in the training device are learned, and the conditional transfer matrix is ​​used as the linear layer after the TextCNN network to realize the conversion from noise label prediction to real taxpayer industry label prediction, and perform taxpayer industry classification.

[0016] A further improvement of the present invention is that the method specifically comprises the following steps:

[0017] 1) Taxpayer industry information processing

[0018] Taxpayer industry information processing includes text information processing and non-text information processing. First, based on the XLNet text pre-training network, the taxpayer text information is segmented and embedded to form the corresponding word vector, and then concatenated to generate text features. Secondly, the numerical features and category features in the taxpayer non-text information are pre-processed using standardization and one-hot encoding technology, and then a linear network layer is established for feature mapping to generate non-text features consistent with the text feature dimension. Finally, the text features and non-text features are concatenated to form feature information.

[0019] 2) Construction of taxpayer industry classification network and initialization of training device

[0020] Construct a TextCNN network for taxpayer industry classification. The network consists of three layers: convolutional layer, pooling layer, and fully connected layer. Based on the feature information obtained in step 1) and the number of target classifications, determine the number of layers of the TextCNN network, the shape of the convolution kernel, and the input and output dimensions of each layer. Then, connect the XLNet pre-trained network and the TextCNN network in series, and use the noisy taxpayer industry information labels as supervision to construct an end-to-end training device.

[0021] 3) Conditional transfer matrix estimation

[0022] Based on the kernel density estimation method, the probability density function is estimated according to the noisy taxpayer industry information data, the conditional transfer matrix estimation problem is transformed into a mixture ratio estimation problem, and the corresponding mixture ratio coefficient is solved based on the improved mixture ratio estimation method, thereby obtaining the conditional transfer matrix;

[0023] 4) Training device network parameter learning and taxpayer industry classification

[0024] Based on the label noise data, the network parameters of the training device are learned. After the training is completed, the estimated conditional transfer matrix is ​​added as a linear transformation layer after the training device to complete the transformation from noise label prediction to true label prediction, thereby realizing the taxpayer industry classification.

[0025] A further improvement of the present invention is that in step 1), the taxpayer industry information processing specifically includes the following steps:

[0026] Step 1: Preprocessing of taxpayer industry text information

[0027] Extract the text information of the taxpayer's industry, delete the special symbols, numbers and meaningless symbols of quantifiers in the text information, and complete the preprocessing of the taxpayer's text information;

[0028] Step 2: Text word embedding based on XLNet pre-trained network

[0029] The text is encoded based on the XLNet pre-trained network to generate word vectors. The XLNet pre-trained model is based on the transformer design and captures the relationship between the two-way context. It improves the inconsistency between the pre-training stage and the fine-tuning stage caused by the mask mechanism of the BERT model, and uses a two-stream self-attention mechanism to make the pre-training effect more significant. The XLNet model applied to Chinese uses a 24-layer network structure and uses sentencepiec for word segmentation. The text features obtained in Step 1 are encoded using the Chinese version of XLNet to obtain word vectors.

[0030] Step 3: Generate taxpayer industry text features

[0031] Assuming that the taxpayer has a total of k text features, a word element will be mapped to a t-dimensional word vector by the XLNet pre-trained network, and the i-th text feature has h i word units, the i-th text feature will be mapped to an h i ×t matrix; the feature matrices of each text feature mapping are concatenated, and the text features of the sample will be mapped into a The text feature matrix of the taxpayer is generated;

[0032] Step 4: Processing of taxpayer industry numerical characteristics

[0033] The numerical features of the taxpayer's non-text features are standardized. Assuming that there are n training samples and m numerical features, the value of the j-th numerical feature of the i-th sample is X ij , the mean of the j-th numerical feature is μ j ,satisfy The standard deviation of the j-th numerical feature is σ j ,satisfy The numerical features after standardization are

[0034] Step 5: Processing of taxpayer industry category characteristics

[0035] Encode the category features in the taxpayer's non-text features. Assuming that the category features have N possible values, an N-dimensional vector is used to encode the category features. Specifically, the corresponding position of the category feature value is set to 1, and the remaining positions are set to 0, that is, the one-hot encoding method is used. After all category features are encoded, the longest encoding length in the category features is selected for padding, and the padded vectors are concatenated to form a category feature matrix.

[0036] Step 6: Generate non-text features of taxpayer industry

[0037] After Step 4 and Step 5, we get m standardized numerical features and a shape of υ×N. max The category feature matrix of max Represents the longest category encoding length. After that, two linear network layers are established for feature mapping. The first linear layer network shape is 1×t, which is used to convert the standardized numerical features into m×t numerical feature matrices. The second linear network layer shape is N max ×t, used to map the category features into a υ×t category feature matrix, and concatenate the two mapped feature matrices to obtain a final non-text feature matrix of (v+m)×t;

[0038] Step 7: Generate taxpayer characteristic information

[0039] The text feature matrix generated by Step 3 and the non-text feature matrix generated by Step 6 are concatenated to produce a matrix with the shape of The matrix is ​​used as the final feature information.

[0040] A further improvement of the present invention is that in step 2), the taxpayer industry classification network is constructed and the training device is initialized: a TextCNN network is established for text classification, and the TextCNN network includes three layers, namely: (1) a convolutional layer, (2) a maximum pooling layer, and (3) a fully connected layer, and the XLNet pre-trained network in step 1) is connected in series with the TextCNN network to construct a training device, and end-to-end training is performed using taxpayer label noise data as supervision; the specific implementation details are as follows:

[0041] Step 1: Construction of taxpayer industry classification network

[0042] The TextCNN network is constructed for taxpayer industry classification. The TextCNN network includes three layers, namely, convolution layer, pooling layer and fully connected layer. Specifically, the convolution layer of TextCNN uses a convolution kernel of shape n×t to perform convolution operation to extract row features, and the values ​​of n are {2, 3, 4, 5, 6}. TextCNN uses the maximum pooling layer as the pooling layer to extract the maximum value of the feature map after convolution, further compress the extracted features, and then establish a fully connected layer. Assuming that the total number of categories to be classified in the taxpayer industry classification is c, if the number of features is s after the maximum pooling layer, a fully connected layer with a shape of s×c is established to map the feature information into a c-dimensional vector, and then perform taxpayer industry classification.

[0043] Step 2: Initialize the training device

[0044] The XLNet text pre-trained network in step 1) and the constructed TextCNN network are connected in series to form a training device; the taxpayer's industry label noise data is used as input, the noise label is predicted, an end-to-end device is formed for training, and the network parameters of the training device are initialized.

[0045] A further improvement of the present invention is that in step 2), let the network parameter be α, the sample be X, and the noise label be The network parameter set is w, and the output of sample X under the mapping of the training device is for and As cross entropy loss, a regularization term is added to prevent overfitting, where λ is the control coefficient of the regularization term, minimizing the loss function, and the optimization objective is as follows:

[0046]

[0047] A further improvement of the present invention is that in step 3), conditional transfer matrix estimation: the conditional transfer matrix estimation problem in the label noise learning problem is converted into a mixture ratio estimation problem, and the mixture ratio coefficient is solved based on the improved mixture ratio estimation method, thereby obtaining the conditional transfer matrix; the specific implementation details are as follows:

[0048] Step 1: Mixture ratio estimation problem construction

[0049] Assume that the noise label in the taxpayer registration information is The true label of the sample is Y, assuming that the sample X is the same as the noise label are independent of each other, then for any category c∈C:

[0050]

[0051] remember P i =P(X|Y=i), Where Q represents the conditional migration probability of the noise label to the true label, then the above equation is expressed in the form of a matrix as follows:

[0052]

[0053] The above matrix is ​​further decomposed to obtain the following form; where H is a c×c matrix with diagonal elements being 0, and the matrix G is a real diagonal matrix with a shape of c×c;

[0054]

[0055] According to the properties of matrix transformation, it can be known that matrix H, matrix G and matrix Q satisfy the following relationships respectively:

[0056]

[0057] (iH) -1 G=Q T

[0058] Here is the Q T The matrix is ​​the conditional transfer matrix in label noise learning. The above relationship shows that if the matrix H is solved, the conditional transfer matrix is ​​further solved. The decomposition of the matrix is ​​equivalent to the following c equations:

[0059]

[0060] This equation can be further expressed as follows:

[0061]

[0062] Which meets:

[0063]

[0064] The standard mixture ratio estimation problem is expressed as follows: F = kH + (1-k) G (k ≥ 0), where FHG is the probability distribution function, and it is assumed that the samples sampled from the distributions F and H are known, where F is the mixture and H and G are the components; the equation obtained by the above matrix decomposition is: It is the standard mixture ratio estimation problem. The mixture ratio coefficient H estimated by the mixture ratio estimation problem is ij It is the element of matrix H; therefore, by solving a series of mixture ratio estimation problems, the H matrix can be solved, and then the conditional transfer matrix Q can be estimated based on the matrix relationship T , so as to construct a risk-consistent classifier based on label noise data and classify taxpayers by industry;

[0065] Step 2: Regeneration of components

[0066] The solution to the mixture ratio estimation problem depends on the annotation of the anchor points. Specifically, if the anchor point samples exist and are known, the maximum estimator of the mixture ratio coefficient is It is an unbiased estimator of the true mixing ratio coefficient k;

[0067] Specifically, we first mark the mixture F sample as a positive sample class Y = 1, mark the component H sample as a negative sample class Y = -1, and build an MLP network for binary classification prediction. Assume that the output of the network is f η(X), where X is the sample feature, η is the network parameter, and the MLP network is supervised by using noisy positive and negative samples. After training, the network is used to predict the posterior probability of the positive sample class, and a threshold τ is selected. The positive sample class sample set is recorded as The negative sample set is The samples of the positive sample class are input into the network for prediction, and the sample set whose predicted value is less than the selected threshold is recorded as Then there is The samples whose posterior probability rate is less than the threshold are included in the negative sample set, and the reconstructed positive and negative sample sets are obtained respectively: and satisfy as well as This completes the regeneration of the composition samples and solves the problem of the traditional mixture ratio estimation method's dependence on anchor points;

[0068] Step 3: Probability density estimation based on kernel density estimation

[0069] On the basis of the reconstructed components in Step 2, the probability density function of the sample distribution is estimated based on the kernel density estimation method; specifically, a kernel function is established to represent the probability density estimation of the existing samples for any point in the feature space, where x is a point in the feature space, and x is i is a known sample; and μ is the sample mean, ∑=ρ 2 Q is the covariance matrix of the sample. When using the Gaussian kernel function, the sample x i The contribution to the probability density at x represents the form of the kernel function as follows:

[0070]

[0071] Then on all sample sets, the probability density function estimator is: in is a set of samples, based on the positive and negative sample sets already obtained The estimated probability density function of the reconstructed positive and negative samples is as follows:

[0072]

[0073]

[0074] Step 4: Conditional transfer matrix estimation

[0075] Solve the c mixture ratio estimation problems constructed in Step 1 in sequence. For any mixture ratio estimation problem, solve the corresponding c-1 mixture ratio coefficients. Suppose the noise label of the mixture is The noise label class of the components is The original sample set As the positive and negative sample sets in the mixture ratio estimation problem Generate new positive and negative sample sets based on the method in Step 2 and And according to the kernel density estimation method of Step 3, the probability density is estimated, and we get as well as Then, the maximum estimation method of the mixing ratio problem in Step 1 is used to estimate the maximum estimator of the mixing ratio coefficient. Here G is a legal probability density function, and the estimated That is the element H ij The estimated value of (i≠j) is obtained by looping and repeating the process Step 2, 3, and 4 to solve all the elements of the H matrix. Then, the G matrix can be obtained according to the following properties, and then the conditional transfer matrix Q can be obtained. T ;

[0076]

[0077] (IH) -1 G=Q T .

[0078] A further improvement of the present invention is that in step 4), the training device network parameter learning is related to the taxpayer industry classification, and the specific steps are as follows:

[0079] Step 1: Training device learning based on label noisy data

[0080] Assume that the network parameter in the training device is η and the noise sample is The network parameter set is w, and the labeled noise data is used as supervision to learn the network parameters in the training device. The output of sample X under the mapping of the training device is g η (X), for g η (X) and As cross entropy loss, a regularization term is added to prevent overfitting, where λ is the control coefficient of the regularization term, minimizing the loss function, and the optimization objective is as follows:

[0081]

[0082] Under the control of this optimization objective, the training device network is used to predict the noisy label of the input sample Output result g η (X) After the softmax layer is operated, the softmax operation exponentially normalizes the original output and expresses the original output as the predicted value of the posterior probability; specifically, assuming that the original network output is Then softmax performs exponential operation on the output vector and normalizes it, and the output is in the following form:

[0083]

[0084] Step 2: Construct the conditional transfer matrix layer

[0085] After completing the network parameter learning of the training device, the network output g η (X) After softmax operation, the posterior probability of the sample is output For predicting noise labels, a conditional transfer layer is added after the softmax layer as a transfer layer to achieve the conversion from noise label prediction to true label prediction;

[0086] Step 3: Taxpayer industry classification

[0087] On the basis of constructing the conditional transfer layer, for the new input sample X, the output of the TextCNN network is q(X), which is calculated by The subscript r corresponding to the maximum component of q(X) is the industry classification corresponding to the taxpayer.

[0088] A further improvement of the present invention is that in Step 2 of step 4), the specific method is as follows: Let the noise label be The real sample label is Y, the total number of categories is C, and it is assumed that the sample feature X and the noise label are independent of each other, then for any category have:

[0089]

[0090] So the original network output g η (X) through the conditional transfer matrix Q T The original output can be converted into a new output Q(x), satisfying q(X) = Q T g(X), where the new output q(X) is the posterior probability of the true label where q i (X)(i=1, 2, ..., C) is the i-th component of q(X), representing the probability prediction value P(Y=i|X) that X is the true label of the i-th category.

[0091] The present invention has at least the following beneficial technical effects:

[0092] The present invention aims at the problem of taxpayer industry classification and provides a label noise learning method for taxpayer industry classification. Compared with the existing technology, the present invention has the following advantages:

[0093] (1) The present invention creatively transforms the conditional transfer matrix estimation problem in label noise learning into a mixture ratio estimation problem. By solving the mixture ratio estimation problem, a risk-consistent classifier is constructed based on label noise data. Different from the prior art solution that relies on semantic clustering, the present invention does not rely on additional clustering methods, thereby avoiding new errors introduced due to the performance limitations of clustering methods.

[0094] (2) The present invention extends the traditional mixture ratio estimation method from binary classification to multi-classification scenarios. Different from the traditional method which is limited to binary classification, the improved mixture ratio estimation method can be applied to multi-classification scenarios and has a wider application scenario.

[0095] (3) The present invention overcomes the problem of traditional mixture ratio estimation methods' reliance on anchor points. Different from the traditional methods' requirement for anchor point annotation, the present invention constructs a new mixture ratio estimation problem based on a method of regenerating components, thereby realizing direct estimation of the mixture ratio coefficient without relying on anchor point annotation. BRIEF DESCRIPTION OF THE DRAWINGS

[0096] Figure 1 This is the overall framework flow chart.

[0097] Figure 2 Flowchart for taxpayer industry information processing.

[0098] Figure 3 Flowchart for initializing the taxpayer industry classification network construction and training device.

[0099] Figure 4 Estimation flow chart for the conditional transition matrix.

[0100] Figure 5 Flowchart of training device network parameter learning and taxpayer industry classification.

[0101] Figure 6 Schematic diagram of the label noise learning network. DETAILED DESCRIPTION

[0102] Exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although exemplary embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided in order to enable a more thorough understanding of the present disclosure and to be able to fully convey the scope of the present disclosure to those skilled in the art. It should be noted that, in the absence of conflict, the embodiments of the present invention and the features described in the embodiments can be combined with each other. The present invention will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.

[0103] like Figure 1As shown, in a specific implementation of the present invention, a label noise learning method for taxpayer industry classification of the present invention includes the following steps:

[0104] Step 1. Processing of taxpayer industry information

[0105] like Figure 2 As shown, the text information and non-text information of the taxpayer are extracted respectively, and information processing is performed, which specifically includes the following steps:

[0106] S101. Preprocessing of taxpayer industry text information

[0107] Delete special symbols, numbers, quantifiers and other illegal characters in taxpayer text information ( Figure 2 S101). In the embodiment, a total of 3 text features are extracted as text information features of the taxpayer, including: {taxpayer name, registered address, business scope}. Assuming that the taxpayer name is "Xi'an Xinyao Ceramics SI Co., Ltd.", first delete the special symbol SI ( Figure 2 S101), by performing sequence segmentation according to the words, we can get {Xi’an City Xinyao Ceramic Co., Ltd. Science and Technology Co., Ltd.}.

[0108] S102. Text word embedding based on XLNet pre-trained network

[0109] Based on the text pre-training network XLNet, the text is embedded in the word ( Figure 2 S102) to form a word vector. In this embodiment, assuming that the encoding length is t, the XLNet text pre-training network embeds the original word into a word vector of length t. If the original text sequence length is 13, the XLNet pre-training network can map the text into a 13×t text feature. Specifically, in this embodiment, t=528 is selected, and a 13×528 text feature ( Figure 2 S102).

[0110] S103. Taxpayer industry text feature generation

[0111] Based on the XLNet text pre-training network, repeat the S102 process to embed words for all text feature sequences, and then concatenate the embedded word vectors to form the taxpayer text features ( Figure 2 S103).

[0112] Specifically, in the embodiment, it is assumed that there are three taxpayer industry text features, including: {taxpayer name, registered address, business scope}, and the three text features are mapped to 13×528, 7×528, and 10×528 text features respectively. The text features are concatenated to obtain the overall taxpayer text features (such as Figure 2S103) Its shape is 30×528.

[0113] S104. Processing of taxpayer industry numerical characteristics

[0114] Extract the numerical characteristics of the taxpayer's industry, including {registered capital, total investment, total assets, interest-bearing liabilities}, a total of 4 numerical characteristics, and perform standardized operations.

[0115] Specifically, in this embodiment, the sample means μ1, μ2, ..., μ4 and sample variances σ1, σ2, ..., σ4 of the above four columns of features are first calculated, and X is recorded as i is the value of the i-th numerical feature of sample X, then the z-score formula is used Standardize the numerical features ( Figure 2 S104).

[0116] S105. Processing of taxpayer industry category characteristics

[0117] The category information is encoded based on one-hot encoding technology. In this embodiment, two category features are selected for encoding, including: {unit nature, accounting method}, where the unit nature includes five situations: enterprise, private non-enterprise unit, institution, social group, and others. The corresponding one-hot encoding is {10000, 01000, 00100, 00010, 00001}, and all category feature information is encoded by one-hot encoding ( Figure 2 S105).

[0118] S106. Generation of non-text features of taxpayer industry

[0119] Construct a linear network mapping layer to map the obtained numerical features and categorical features to the same dimension as the text feature dimension, and then concatenate the two to form the taxpayer's industry non-text features.

[0120] Specifically, in the embodiment, linear network mapping layers with shapes of 1×528 and 5×528 are established respectively. It is used to map numerical features and category features to the same dimension of text features, and then concatenate them to form a non-text feature matrix ( Figure 2 S106).

[0121] S107. Generation of taxpayer characteristic information

[0122] The taxpayer text features obtained in S103 and the taxpayer non-text features obtained in S106 are concatenated to finally form the taxpayer industry feature information.

[0123] In the embodiment, the text features with a shape of 30×528 and the non-text features with a shape of 6×258 are spliced ​​to form the final taxpayer industry feature information with a shape of 36×528 ( Figure 2 S107).

[0124] Step 2. Construction of taxpayer industry classification network and initialization of training device

[0125] like Figure 3 As shown, a TextCNN network is established for taxpayer industry classification. According to the generated taxpayer industry characteristics and the total number of targets to be classified, the shape of the TextCNN convolution kernel and the input and output dimensions are determined in turn. The XLNet text pre-training network and the TextCNN network are connected in series to form a training device, and the training device is end-to-end trained based on label noise data to initialize the network parameters of the training device.

[0126] S201. Construction of taxpayer industry classification network

[0127] Construct a TextCNN network for taxpayer industry classification. The TextCNN network consists of three layers: convolutional layer, pooling layer, and fully connected layer.

[0128] Specifically, in the embodiment, according to the characteristics of the taxpayer's text, a convolution kernel is established to extract the row features of the feature map. In this embodiment, a convolution kernel with a shape of n×528 is used, where n={2, 3, 4, 5, 6}, and a maximum pooling layer is established to further compress and extract the features after the convolution, and finally a fully connected layer is established. Assuming that the total number of features of the feature map output after the pooling layer is n1 and the total number of categories is c, a fully connected layer with a shape of n1×c is established. In this embodiment, c=97 (such as Figure 3 S201).

[0129] S204. Training device initialization

[0130] The XLNet text pre-trained network in step 1) and the constructed TextCNN network are connected in series to form a training device. End-to-end training is performed based on the labeled noise data to initialize the network parameters of the training device.

[0131] In the embodiment, the taxpayer industry label noise data is used as input, the noise label is predicted, and end-to-end training is performed to initialize network parameters (such as Figure 3 S202). Assume that the network parameter is α and the noise sample is The network parameter set is w, and the output of sample X under the mapping of the training device is for and As cross entropy loss, a regularization term is added to prevent overfitting, where λ is the control coefficient of the regularization term, minimizing the loss function, and the optimization objective is as follows:

[0132]

[0133] Step 3. Solve the conditional transfer matrix

[0134] like Figure 4 As shown, firstly, a mixture ratio estimation problem is constructed, thereby converting the original conditional transfer matrix estimation problem into a mixture ratio estimation problem. Secondly, a new mixture ratio estimation problem is constructed based on the method of regenerating components, and the probability density is estimated according to the kernel density estimation method, and then the mixture ratio coefficient is solved and the conditional transfer matrix is ​​estimated. The specific steps are as follows:

[0135] S301. Mixture Proportion Estimation Problem Construction

[0136] In this embodiment, it is assumed that the noisy label in the taxpayer registration information is The sample is X, and the true label of the sample is Y. If the sample X is Independent of each other, the relationship is as follows:

[0137]

[0138] At the same time, the above relationship can be converted into the following form:

[0139]

[0140] It can be seen that the above c equations are equivalent to c standard mixing ratio problems. In the embodiment, the total number of items to be classified is c = 97. If the matrix H and the matrix G can be obtained, the original equation can be obtained. Then the overall conditional transfer matrix is ​​obtained, so the original conditional transfer matrix estimation problem is transformed into a mixture ratio estimation problem ( Figure 4 S301).

[0141] S302. Regeneration of the composition

[0142] In the embodiment, it is assumed that the noise label class The sample sets are and Class {i, j} is used as the positive and negative sample sets respectively. and Design a two-class network for prediction, assuming that the output of the network is f η(X), where X is the sample feature after dimensionality reduction of the input. η is the parameter of the network. Use positive and negative samples to conduct supervised training on the perceptron network. After completing the network training. Use the network to make a posterior probability prediction for the samples of the positive sample class. Select a threshold τ and record the sample set of the positive sample class as The negative sample set is The sample set whose network prediction output is less than the selected threshold is recorded as Then there is The posterior probability rate is less than the threshold The sample set is copied to the negative sample set, and the reconstructed positive sample set and negative sample set can be obtained: and And satisfy as well as This completes the regeneration of the sample (such as Figure 4 S302).

[0143] S303. Probability density function estimation

[0144] For the new sample obtained from S302 and The probability density function of the sample set is estimated by using the kernel density estimation method to obtain the estimated function (such as Figure 4 S303) are as follows:

[0145]

[0146]

[0147] S304. Solving the conditional transfer matrix

[0148] Establish a double loop structure, and traverse the outer and inner loops in turn as well as And i≠j. Execute the process of S302 and S303 cyclically to obtain the mixing ratio coefficient The mixing ratio coefficient is H ij , and then according to the following relationship, we get the G matrix;

[0149]

[0150] Based on the obtained H matrix and G matrix, we can follow the relationship: (IH) -1 G=Q T Get the conditional transfer matrix Q T (like Figure 4 S304).

[0151] Step 4. Training device network parameter learning and taxpayer industry classification

[0152] like Figure 5 As shown, the training device is trained based on the label noise data to learn the network parameters of the training device, and a conditional transfer layer is added after the training device to complete the taxpayer industry classification. The specific steps are as follows:

[0153] S401. Training device learning based on label noise data

[0154] In this embodiment, it is assumed that the input of the training device is a noise data sample Where X is the 36×528 input feature vector, which is mapped to g through the network η (X) is a 97-dimensional output vector. For the noisy label and the network output g η (X) is used as the cross entropy loss. According to the loss function, the network parameters are trained. The trained network parameters are recorded as η( Figure 5 S401)

[0155] S402. Constructing conditional transfer matrix layer

[0156] A conditional transfer matrix layer is added after the training device to make predictions for new samples.

[0157] Specifically, in this embodiment, the calculated 97×97 conditional transfer matrix Q T , as a conditional transfer layer. The original output g η (X) is converted to q(X), that is, q(X) = Q T g η (x), where q(X) represents the prediction of the true label of sample X. i (X) is the i-th component of q(X), which indicates the probability that sample X belongs to category i ( Figure 5 S402).

[0158] S403. Taxpayer industry classification

[0159] like Figure 6 As shown, the text information and non-text feature information of the taxpayer are extracted respectively, the industry features of the taxpayer are extracted through the feature extraction module, and the conditional transfer matrix is ​​estimated based on the extracted features, which is used as the final conditional transfer layer of the training device to classify the taxpayer industry based on the training device. Specifically, in the embodiment, assuming that the taxpayer feature information is X, the output of the training device is denoted as q(X), where q(X) is the true label prediction of sample X, and q i (X)(i=1,2,...,97) is the i-th component of q(X), and the subscript corresponding to the largest component is selected. As a taxpayer's industry classification ( Figure 5 S403).

[0160] It will be easily understood by those skilled in the art that the above description is merely an embodiment of the method of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.

Claims

1. A label noise learning method for taxpayer industry classification, characterized by: include: Firstly, the text information and non-text information in the taxpayer's industry information are extracted, and text embedding and non-text encoding are performed based on the XLNet text pre-training network and encoding technology to obtain feature information. Secondly, a TextCNN network for taxpayer industry classification is constructed. The number of network layers, convolution kernel shapes, and input and output dimensions of each layer are determined according to feature information and the number of target classifications. The XLNet text pre-trained network and the TextCNN network are connected in series, and noisy taxpayer industry label data is used as supervision to construct an end-to-end training device. Secondly, the conditional transfer matrix is ​​estimated based on the improved mixed ratio estimation method; finally, the network parameters in the training device are learned, and the conditional transfer matrix is ​​used as the linear layer after the TextCNN network to achieve the conversion from noise label prediction to real taxpayer industry label prediction and perform taxpayer industry classification; The specific steps include: 1) Taxpayer industry information processing Taxpayer industry information processing includes text information processing and non-text information processing. First, based on the XLNet text pre-training network, the taxpayer text information is segmented and embedded to form the corresponding word vector, and then concatenated to generate text features. Secondly, the numerical features and category features in the taxpayer non-text information are pre-processed using standardization and one-hot encoding technology, and then a linear network layer is established for feature mapping to generate non-text features consistent with the text feature dimension. Finally, the text features and non-text features are concatenated to form feature information. 2) Construction of taxpayer industry classification network and initialization of training device Construct a TextCNN network for taxpayer industry classification. The network consists of three layers: convolutional layer, pooling layer, and fully connected layer. Based on the feature information obtained in step 1) and the number of target classifications, determine the number of layers of the TextCNN network, the shape of the convolution kernel, and the input and output dimensions of each layer. Then, connect the XLNet pre-trained network and the TextCNN network in series, and use the noisy taxpayer industry information labels as supervision to construct an end-to-end training device. 3) Conditional transfer matrix estimation Based on the kernel density estimation method, the probability density function is estimated according to the noisy taxpayer industry information data, and the conditional transfer matrix estimation problem is converted into a mixed proportion estimation problem. The corresponding mixed proportion coefficient is solved based on the improved mixed proportion estimation method to obtain the conditional transfer matrix; Conditional transfer matrix estimation: The conditional transfer matrix estimation problem in the label noise learning problem is converted into a mixed proportion estimation problem, and the mixed proportion coefficient is solved based on the improved mixed proportion estimation method to obtain the conditional transfer matrix; The specific implementation details are as follows: Step 1: Mixture ratio estimation problem construction Assume that the noise label in the taxpayer registration information is The true label of the sample is Y, assuming that the sample X is the same as the noise label are independent of each other, then for any category c∈C: remember P i =P(X|Y=i), Where Q represents the conditional migration probability of the noise label to the true label, then the above equation is expressed in the form of a matrix as follows: The above matrix is ​​further decomposed to obtain the following form; where H is a c×c matrix with diagonal elements being 0, and the matrix G is a real diagonal matrix with a shape of c×c; According to the properties of matrix transformation, it can be known that matrix H, matrix G and matrix Q satisfy the following relationships respectively: (I-H) -1 G=Q T Here is the Q T The matrix is ​​the conditional transfer matrix in label noise learning. The above relationship shows that if the matrix H is solved, the conditional transfer matrix is ​​further solved. The decomposition of the matrix is ​​equivalent to the following c equations: This equation can be further expressed as follows: Which meets: The standard mixture ratio estimation problem is expressed as follows: F = kH + (1-k) G (k ≥ 0), where FHG is the probability distribution function, and it is assumed that the samples sampled from the distributions F and H are known, where F is the mixture and H and G are the components; the equation obtained by the above matrix decomposition is: It is the standard mixture ratio estimation problem. The mixture ratio coefficient H estimated by the mixture ratio estimation problem is ij It is the element of matrix H; therefore, by solving a series of mixture ratio estimation problems, the H matrix can be solved, and then the conditional transfer matrix Q can be estimated based on the matrix relationship T , so as to construct a risk-consistent classifier based on label noise data and classify taxpayers by industry; Step 2: Regeneration of components The solution to the mixture ratio estimation problem depends on the annotation of the anchor points. Specifically, if the anchor point samples exist and are known, the maximum estimator of the mixture ratio coefficient is It is an unbiased estimator of the true mixing ratio coefficient k; Specifically, we first mark the mixture F sample as a positive sample class Y = 1, mark the component H sample as a negative sample class Y = -1, and build an MLP network for binary classification prediction. Assume that the output of the network is f η (X), where X is the sample feature, η is the network parameter, and the MLP network is supervised by using noisy positive and negative samples. After training, the network is used to predict the posterior probability of the positive sample class, and a threshold τ is selected. The positive sample class sample set is recorded as The negative sample set is The samples of the positive sample class are input into the network for prediction, and the sample set whose predicted value is less than the selected threshold is recorded as Then there is The samples whose posterior probability rate is less than the threshold are included in the negative sample set, and the reconstructed positive and negative sample sets are obtained respectively: and satisfy as well as This completes the regeneration of the composition samples and solves the problem of the traditional mixture ratio estimation method's dependence on anchor points; Step 3: Probability density estimation based on kernel density estimation On the basis of the reconstructed components in Step 2, the probability density function of the sample distribution is estimated based on the kernel density estimation method; specifically, a kernel function is established to represent the probability density estimation of the existing samples for any point in the feature space, where x is a point in the feature space, and x is i is a known sample; and μ is the sample mean, ∑=ρ 2 Q is the covariance matrix of the sample. When using the Gaussian kernel function, the sample x i The contribution to the probability density at x represents the form of the kernel function as follows: Then on all sample sets, the probability density function estimator is: in is a set of samples, based on the positive and negative sample sets already obtained The estimated probability density function of the reconstructed positive and negative samples is as follows: Step 4: Conditional transfer matrix estimation Solve the c mixture ratio estimation problems constructed in Step 1 in sequence. For any mixture ratio estimation problem, solve the corresponding c-1 mixture ratio coefficients. Suppose the noise label of the mixture is The noise label class of the components is The original sample set As the positive and negative sample sets in the mixture ratio estimation problem Generate new positive and negative sample sets based on the method in Step 2 and And according to the kernel density estimation method of Step 3, the probability density is estimated, and we get as well as Then, the maximum estimation method of the mixing ratio problem in Step 1 is used to estimate the maximum estimator of the mixing ratio coefficient. Here G is a legal probability density function, and the estimated That is the element H ij The estimated value of (i≠j) is obtained by looping and repeating the process Step 2, 3, and 4 to solve all the elements of the H matrix. Then, the G matrix can be obtained according to the following properties, and then the conditional transfer matrix Q can be obtained. T ; (I-H) -1 G=Q T 4) Training device network parameter learning and taxpayer industry classification Based on the label noise data, the network parameters of the training device are learned. After the training is completed, the estimated conditional transfer matrix is ​​added as a linear transformation layer after the training device to complete the transformation from noise label prediction to true label prediction, thereby realizing the taxpayer industry classification.

2. According to claim 1, a label noise learning method for taxpayer industry classification is characterized by: In step 1), the taxpayer industry information processing includes the following steps: Step 1: Preprocessing of taxpayer industry text information Extract the text information of the taxpayer's industry, delete the special symbols, numbers and meaningless symbols of quantifiers in the text information, and complete the preprocessing of the taxpayer's text information; Step 2: Text word embedding based on XLNet pre-trained network The text is encoded based on the XLNet pre-trained network to generate word vectors. The XLNet pre-trained model is based on the transformer design and captures the relationship between the two-way context. It improves the inconsistency between the pre-training stage and the fine-tuning stage caused by the mask mechanism of the BERT model, and uses a two-stream self-attention mechanism to make the pre-training effect more significant. The XLNet model applied to Chinese uses a 24-layer network structure and uses sentencepiec for word segmentation. The text features obtained in Step 1 are encoded using the Chinese version of XLNet to obtain word vectors. Step 3: Generate taxpayer industry text features Assuming that the taxpayer has a total of k text features, a word element will be mapped to a t-dimensional word vector by the XLNet pre-trained network, and the i-th text feature has h i word units, the i-th text feature will be mapped to an h i ×t matrix; the feature matrices of each text feature mapping are concatenated, and the text features of the sample will be mapped into a The text feature matrix of the taxpayer is generated; Step 4: Processing of taxpayer industry numerical characteristics The numerical features of the taxpayer's non-text features are standardized. Assuming that there are n training samples and m numerical features, the value of the j-th numerical feature of the i-th sample is X ij , the mean of the j-th numerical feature is μ j ,satisfy The standard deviation of the j-th numerical feature is σ j ,satisfy The numerical features after standardization are Step 5: Processing of taxpayer industry category characteristics Encode the category features in the taxpayer's non-text features. Assuming that the category features have N possible values, an N-dimensional vector is used to encode the category features. Specifically, the corresponding position of the category feature value is set to 1, and the remaining positions are set to 0, that is, the one-hot encoding method is used. After all category features are encoded, the longest encoding length in the category features is selected for padding, and the padded vectors are concatenated to form a category feature matrix. Step 6: Generate non-text features of taxpayer industry After Step 4 and Step 5, we get m standardized numerical features and a shape of v×N. max The category feature matrix of max Represents the longest category encoding length. After that, two linear network layers are established for feature mapping. The first linear layer network shape is 1×t, which is used to convert the standardized numerical features into m×t numerical feature matrices. The second linear network layer shape is N max ×t, used to map the category features into a v×t category feature matrix, and concatenate the two mapped feature matrices to obtain a final non-text feature matrix of (v+m)×t; Step 7: Generate taxpayer characteristic information The text feature matrix generated by Step 3 and the non-text feature matrix generated by Step 6 are concatenated to produce a matrix with the shape of The matrix is ​​used as the final feature information.

3. The label noise learning method for taxpayer industry classification according to claim 2 is characterized in that: In step 2), the taxpayer industry classification network is constructed and the training device is initialized: a TextCNN network is established for text classification. The TextCNN network includes three layers: (1) convolutional layer, (2) maximum pooling layer, and (3) fully connected layer. The XLNet pre-trained network in step 1) is connected in series with the TextCNN network to construct a training device. The taxpayer label noise data is used as supervision to perform end-to-end training. The specific implementation details are as follows: Step 1: Construction of taxpayer industry classification network The TextCNN network is constructed for taxpayer industry classification. The TextCNN network includes three layers, namely, convolution layer, pooling layer and fully connected layer. Specifically, the convolution layer of TextCNN uses a convolution kernel of shape n×t to perform convolution operation to extract row features, and the values ​​of n are {2, 3, 4, 5, 6}. TextCNN uses the maximum pooling layer as the pooling layer to extract the maximum value of the feature map after convolution, further compress the extracted features, and then establish a fully connected layer. Assuming that the total number of categories to be classified in the taxpayer industry classification is c, if the number of features is s after the maximum pooling layer, a fully connected layer with a shape of s×c is established to map the feature information into a c-dimensional vector, and then perform taxpayer industry classification. Step 2: Initialize the training device The XLNet text pre-trained network in step 1) and the constructed TextCNN network are connected in series to form a training device; the taxpayer's industry label noise data is used as input, the noise label is predicted, an end-to-end device is formed for training, and the network parameters of the training device are initialized.

4. According to claim 3, a label noise learning method for taxpayer industry classification is characterized in that: In Step 2), let the network parameter be α, the sample be X, and the noise label be The network parameter set is w, and the output of sample X under the mapping of the training device is for and As cross entropy loss, a regularization term is added to prevent overfitting, where λ is the control coefficient of the regularization term, minimizing the loss function, and the optimization objective is as follows:

5. According to claim 4, a label noise learning method for taxpayer industry classification is characterized in that: In step 4), the training device network parameter learning and taxpayer industry classification, the specific steps are as follows: Step 1: Training device learning based on label noisy data Assume that the network parameter in the training device is η and the noise sample is The network parameter set is w, and the labeled noise data is used as supervision to learn the network parameters in the training device. The output of sample X under the mapping of the training device is g η (X), for g η (X) and As cross entropy loss, a regularization term is added to prevent overfitting, where λ is the control coefficient of the regularization term, minimizing the loss function, and the optimization objective is as follows: Under the control of this optimization objective, the training device network is used to predict the noisy label of the input sample Output result g η (X) After the softmax layer is operated, the softmax operation exponentially normalizes the original output and expresses the original output as the predicted value of the posterior probability; specifically, assuming that the original network output is Then softmax performs exponential operation on the output vector and normalizes it, and the output is in the following form: Step 2: Construct the conditional transfer matrix layer After completing the network parameter learning of the training device, the network output g η (X) After softmax operation, the posterior probability of the sample is output For predicting noise labels, a conditional transfer layer is added after the softmax layer as a transfer layer to achieve the conversion from noise label prediction to true label prediction; Step 3: Taxpayer industry classification On the basis of constructing the conditional transfer layer, for the new input sample X, the output of the TextCNN network is q(X), which is calculated by The subscript r corresponding to the maximum component of q(X) is the industry classification corresponding to the taxpayer.

6. A label noise learning method for taxpayer industry classification according to claim 5, characterized in that: In Step 4), the specific method is as follows: Let the noise label be The real sample label is Y, the total number of categories is C, and it is assumed that the sample feature X and the noise label are independent of each other, then for any category have: So the original network output g η (X) through the conditional transfer matrix Q T The original output can be converted into a new output q(X), satisfying q(X) = Q T g(X), where the new output q(X) is the posterior probability of the true label where q i (X)(i=1, 2, ..., C) is the i-th component of q(X), representing the probability prediction value P(Y=i|X) that X is the true label of the i-th category.