Government data classification storage method and related device
By performing word segmentation processing and Bayesian classification of government data, combined with the ten-fold cross-algorithm optimization model, the problems of low efficiency and error in classification storage of government data are solved, and accurate evidence storage and archiving of government data are realized.
Patent Information
- Application Number
- CN202011526719.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-12-22
- Publication Date
- 2024-12-20
- Estimated Expiration
- 2040-12-22
AI Technical Summary
The lack of effective government data classification storage methods in the prior art leads to low efficiency in government data storage and prone to classification storage errors.
By obtaining the item description information, word segmentation processing and TF-IDF algorithm to filter keywords, use Bayesian classifier to classify and identify the items, and associate the items with the category to which they belong, and use the ten-fold cross-section algorithm to optimize the Bayesian model Classification accuracy.
It improves the efficiency and accuracy of classification storage of government data, reduces artificial classification errors, and realizes accurate evidence storage and archiving of government data.
Smart Images

Figure CN114722801B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to a government data classification storage method and related devices. Background Art
[0002] With the advent of the big data era, e-government systems have been widely used. E-government is the application of modern information and communication technology to integrate management and services through network technology, transcending the limitations of time, space and separation between departments on the Internet, and providing the society with high-quality, comprehensive, standardized, transparent and internationally qualified management and services. In related technologies, e-government departments are divided into several departments. There are many matters managed by each department. When the description information of each matter is recorded, the description information of matters belonging to the same department is stored uniformly.
[0003] The inventors found that in the related art, when storing the item description information of each item under each department (i.e., performing government data storage), all item description information under the same department is often placed together, and the relevant personnel who manage the government data storage classify and store them. That is, the related art lacks a method for classifying and storing government data. Summary of the invention
[0004] The purpose of this application is to provide a method for classified storage of government data and related devices, so as to solve the lack of a method for classified storage of government data in the related art.
[0005] In a first aspect, an embodiment of the present application provides a method for classified storage of government data, the method comprising:
[0006] Obtain the item description information of the target item;
[0007] Extracting features from the item description information to obtain item feature information of the target item;
[0008] Classify and identify the target item based on the item feature information to obtain the category to which the target item belongs;
[0009] The item description information of the target item is associated with the category described in the target item and stored.
[0010] In some possible embodiments, extracting features from the item description information to obtain item feature information of the target item includes:
[0011] Performing word segmentation processing on the item description information to obtain a word segmentation result;
[0012] Determine multiple keywords of the item description information from the word segmentation results;
[0013] Determining a weight of each keyword in the plurality of keywords;
[0014] The matter feature information is constructed based on the multiple keywords.
[0015] In some possible embodiments, determining multiple keywords of the item description information of the multiple tables from the word segmentation results includes:
[0016] A term frequency-inverse document frequency (TF-IDF) algorithm is used to determine the TF-IDF value of each term in the word segmentation result, and terms whose TF-IDF value is greater than or equal to a preset threshold are determined as the keywords.
[0017] In some possible embodiments, classifying and identifying the target item based on the item feature information to obtain the category to which the target item belongs includes:
[0018] The multiple keywords and the preset weight of each keyword are input into a Bayesian classifier for classification and identification to obtain the category to which the target item belongs.
[0019] In some possible embodiments, each of the keywords corresponds to a preset weight. If the keyword belongs to the table content in the matter description information, the keyword corresponds to a first preset weight; if the keyword does not belong to the table content, the keyword corresponds to a second preset weight; wherein the weight value of the first preset weight is greater than the weight value of the second preset weight.
[0020] In some possible embodiments, the categories used for classification and identification are constructed in advance based on the association relationships between different items.
[0021] In some possible embodiments, the different items classified into the same category are distinguished by item codes; wherein each item and the corresponding item code satisfy a one-to-one correspondence.
[0022] In some possible embodiments, after storing the item description information of the target item in association with the category to which the target item belongs, the method further includes:
[0023] Determining the classification accuracy of the new Bayesian model from the stored item description information of the target item using a ten-fold crossover algorithm;
[0024] If the classification accuracy of the new Bayesian model is higher than the accuracy of the classification model in the Bayesian classifier, the new Bayesian model is used as the classification model in the Bayesian classifier.
[0025] In a second aspect, an embodiment of the present application provides a device for storing government data by classification, the device comprising:
[0026] A description information acquisition module is used to obtain the item description information of the target item;
[0027] A feature information acquisition module is used to extract features from the item description information to obtain item feature information of the target item;
[0028] A category confirmation module, used to classify and identify the target item based on the item feature information to obtain the category to which the target item belongs;
[0029] The item storage module is used to store the item description information of the target item in association with the category of the target item.
[0030] In some possible embodiments, the feature information acquisition module includes:
[0031] A word segmentation result confirmation unit, used to perform word segmentation processing on the matter description information to obtain a word segmentation result;
[0032] A keyword acquisition unit, used to determine a plurality of keywords of the item description information from the word segmentation result;
[0033] A weight confirmation unit, used to determine the weight of each keyword in the plurality of keywords;
[0034] The feature information constructing unit is used to construct the event feature information based on the multiple keywords.
[0035] In some possible embodiments, when the keyword acquisition unit determines the multiple keywords of the item description information of the multiple tables from the word segmentation results, it is configured as follows:
[0036] A term frequency-inverse document frequency (TF-IDF) algorithm is used to determine the TF-IDF value of each term in the word segmentation result, and terms whose TF-IDF value is greater than or equal to a preset threshold are determined as the keywords.
[0037] In some possible embodiments, the category confirmation module is configured to:
[0038] The multiple keywords and the preset weight of each keyword are input into a Bayesian classifier for classification and identification to obtain the category to which the target item belongs.
[0039] In some possible embodiments, each of the keywords corresponds to a preset weight. If the keyword belongs to the table content in the matter description information, the keyword corresponds to a first preset weight; if the keyword does not belong to the table content, the keyword corresponds to a second preset weight; wherein the weight value of the first preset weight is greater than the weight value of the second preset weight.
[0040] In some possible embodiments, the categories used for classification and identification are constructed in advance based on the association relationships between different items.
[0041] In some possible embodiments, the different items classified into the same category are distinguished by item codes; wherein each item and the corresponding item code satisfy a one-to-one correspondence.
[0042] In some possible embodiments, after the item storage module associates and stores the item description information of the target item with the category to which the target item belongs, it is further configured to:
[0043] Determining the classification accuracy of the new Bayesian model from the stored item description information of the target item using a ten-fold crossover algorithm;
[0044] If the classification accuracy of the new Bayesian model is higher than the accuracy of the classification model in the Bayesian classifier, the new Bayesian model is used as the classification model in the Bayesian classifier.
[0045] In the third aspect, another embodiment of the present application also provides an electronic device, comprising at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute any government data classification storage method provided in the embodiment of the present application.
[0046] In a fourth aspect, another embodiment of the present application further provides a computer storage medium, wherein the computer storage medium stores a computer program, and the computer program is used to enable a computer to execute any government data classification and storage method provided in an embodiment of the present application.
[0047] In the embodiment of the present application, the item description information of the target item is obtained, and the item feature information corresponding to the target item is obtained by extracting features from the item description information. The item feature information is classified and identified to determine the category to which the target item corresponding to each item feature information belongs. The item description information of each target item is associated with the category corresponding to the target item and stored. Through the above method, the problem of the lack of a method for classified storage of government data in the related technology is solved as much as possible.
[0048] Other features and advantages of the present application will be described in the following description, and partly become apparent from the description, or be understood by practicing the present application. The purpose and other advantages of the present application can be realized and obtained by the structures specifically pointed out in the written description, claims, and drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0049] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments of the present application will be briefly introduced below. Obviously, the drawings introduced below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0050] Figure 1 is a schematic diagram of an application environment according to an embodiment of the present application;
[0051] Figure 2a A flowchart of a method for classifying and storing government data according to an embodiment of the present application;
[0052] Figure 2b This is a schematic diagram of matter description information according to an embodiment of the present application;
[0053] Figure 3 A diagram of a device for classifying and storing government data according to an embodiment of the present application;
[0054] Figure 4 The figure is a structural diagram of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION
[0055] The technical solutions in the embodiments of the present application will be described clearly and in detail below in conjunction with the accompanying drawings. In the description of the embodiments of the present application, unless otherwise specified, " / " means or, for example, A / B can mean A or B; "and / or" in the text is only a description of the association relationship of associated objects, indicating that there can be three relationships, for example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, in the description of the embodiments of the present application, "multiple" means two or more than two.
[0056] In the description of the embodiments of the present application, unless otherwise specified, the term "multiple" refers to two or more, and other quantifiers are similar and should be understood. The preferred embodiments described herein are only used to illustrate and explain the present application, and are not used to limit the present application. In addition, the embodiments of the present application and the features therein may be combined with each other if there is no conflict.
[0057] To further illustrate the technical solution provided by the embodiment of the present application, this is described in detail below in conjunction with the accompanying drawings and specific implementation methods. Although the embodiment of the present application provides the method operation steps as shown in the following embodiments or drawings, more or fewer operation steps may be included in the method based on routine or no creative labor. In the steps where there is no necessary causal relationship logically, the execution order of these steps is not limited to the execution order provided by the embodiment of the present application. The method can be executed in the order of the method shown in the embodiment or drawings or in parallel during the actual processing process or when the control device is executed.
[0058] The inventors have discovered that in the related art, when storing the matter description information under each department, most of the time, the relevant personnel who manage the government data storage will classify and store the matter description information after placing all the matter description information under the same department together. Since the classification storage operation is performed manually, there are problems such as low efficiency and classification storage errors, which is not conducive to the accurate evidence archiving of government data. Based on this, multiple categories can be preset according to all the matters managed by each department, and the matter description information with similar application scenarios and / or fields corresponding to the matters can be placed in the same preset category for storage. The inventive concept of the present application is to obtain the matter description information corresponding to each target matter from each target matter used by each department for government data storage. The description information of each matter is segmented, and the word segmentation processing can specifically include removing sensitive words, interjections, stop words in each word, and correcting typos in each word. After performing word segmentation on the description information of each item, the TF-IDF (Term Frequency–Inverse Document Frequency) algorithm can be used to obtain the TD-IDF value of each word, and the words with a TD-IDF value greater than the preset threshold are determined as keywords. All keywords under the same target item are grouped into keyword groups, and the keyword groups are used as feature information for classification using a Bayesian classifier. Finally, the classification result of the target item is associated with the item description information corresponding to the target item and stored. Through the above method, the problem of the lack of a method for classified storage of government data in the relevant technology is solved as much as possible.
[0059] Other features and advantages of the present application will be described in the following description, and partly become apparent from the description, or be understood by practicing the present application. The purpose and other advantages of the present application can be realized and obtained by the structures specifically pointed out in the written description, claims, and drawings.
[0060] The following is a detailed description of the government data classification and storage method in the embodiment of the present application with reference to the accompanying drawings.
[0061] See also Figure 1, is a schematic diagram of an application environment according to an embodiment of the present application.
[0062] like Figure 1 As shown, the application environment may include, for example, a network 10 , a server 20 , at least one terminal device 30 , and a database 40 .
[0063] The server 20 is associated with a database 40, in which target items under each preset classification and item description information corresponding to the target items are stored. The terminal device 30 can be a terminal device with networking function such as a smart phone, a desktop computer, a laptop computer, etc. The terminal device 30 can upload the target items belonging to each department and the item description information corresponding to each target item to the server 20 based on the network 10. When each department performs government information storage, each target item and the item description information of the target item are reported to the server 20 by the network 10 in units of the departments to which each target item belongs. After receiving the target items and the item description information of the target items submitted by each department, the server 20 performs a word segmentation operation on each item description information, and uses the TF-IDF algorithm to filter out the keywords used to determine the preset category to which the target items corresponding to each item description information belong. Taking the same item description information as a unit, the keywords filtered under the same item description information are combined into a keyword group. The keyword group is used as the item feature information to determine the preset category to which the target item corresponding to the keyword group belongs through the Bayesian classifier. After determining the preset category to which each target item belongs, each target item is associated with the preset category to which it belongs and stored in the database 40 .
[0064] In some possible embodiments, multiple keywords extracted from the item description information of each target item and the preset weight of each keyword are input into a Bayesian classifier for classification and identification, so as to obtain the preset category to which the target item belongs.
[0065] In some possible embodiments, each keyword in each item feature information corresponds to a preset weight value. Since the table content in the item description information usually only appears under the same target item, and the non-table content may appear multiple times under different target items, in order to ensure the classification accuracy of the target item, when extracting keywords from the item description information through the TF-IDF algorithm, the preset weight value corresponding to the keyword extracted from the table content in the item description information is 1. The preset weight value corresponding to the remaining keywords is 0.5.
[0066] In some possible embodiments, when searching for routes, passengers can further search for routes based on screening conditions. The screening conditions may include the total distance of the trip, the total time of the trip, and the number of transfer vehicles. After selecting the screening conditions, passengers can obtain the sorting of the routes according to the total distance of the trip from short to long, the total time of the trip from short to long, and the number of transfer vehicles from few to many.
[0067] In order to facilitate understanding of the government data classification storage method provided by an embodiment of the present application, the present application provides the overall process of the government data classification storage method. Figure 2a , such as Figure 2a As shown, the following steps are included:
[0068] Step 201: Obtain the item description information of the target item.
[0069] The existing e-government departments include several departments. Each department manages multiple target items. For example, some departments include many target items such as the declaration of civil homesteads, the declaration of enterprise names, and the declaration of business addresses. When storing the item description information of each target item under each department (the item description information is the information form filled in by the user when applying for the target item and the positive materials submitted), it is necessary to obtain the target items belonging to the department and the item description information corresponding to each target item from the text data submitted by each department (the text data includes the item description information corresponding to each target item).
[0070] In the related art, the text data submitted by the department is archived through manual classification storage operations. This method has problems such as low efficiency and classification storage errors. To solve this problem, this application presets multiple categories from all the target items managed by the department, and regards each target item with similar application scenarios and / or fields as related target items, and stores the item description information corresponding to each related target item in the same preset category. For example, the item description information related to the enterprise, such as "company name registration" and "limited liability company", can be stored in the preset category of "commercial declaration".
[0071] Since the execution process of classifying and storing text data of each department is the same, in order to facilitate understanding of this solution, the following only explains how to classify and store text data submitted by one department.
[0072] After extracting each target item and the item description information corresponding to each target item from the text data submitted by the department, step 202 is executed: feature extraction is performed on the item description information to obtain item feature information of the target item.
[0073] To determine the preset classification corresponding to each matter description information, the method of preset keywords can be adopted to perform feature extraction operations on the matter description information, form a keyword group with all the keywords extracted from the matter description information, and use the keyword group as the feature information corresponding to the matter description information.
[0074] When presetting keywords, multiple words that can be used to represent the characteristics unique to the target matter can be selected according to the actual situation as keywords. Taking Figure 2b the matter description information corresponding to the target matter of "enterprise name declaration" shown (i.e., each table in the figure) as an example, the keywords that can be set include "enterprise name declaration", "list of submitted materials", and "business scope", etc.
[0075] When performing feature extraction on the matter description information, the matter description information is segmented to obtain each word that makes up the matter description information, that is, the segmentation result. Since the purpose of performing segmentation processing is to screen out keywords from the obtained words. Since there are usually some sensitive words, tone interjections, and stop words in the matter description information that cannot be used as keywords, in order to reduce the workload of screening keywords, during the segmentation processing, sensitive words such as "ah", "ya", etc., their interjections, and stop words used to represent non-searchable characters in computer retrieval need to be removed.
[0076] In some possible embodiments, in order to ensure the accuracy of screening keywords, when performing the segmentation processing operation on the matter description information, a legal third-party platform software can be used to correct the text of the matter description information. Thus, avoiding the situation where preset keywords are not recognized due to typos in the matter description information.
[0077] After obtaining all the words corresponding to the matter description information according to the segmentation result, the TF-IDF algorithm can be used to calculate the TF-IDF values of each word in the segmentation result. The TF-IDF algorithm is used to calculate the importance of a word to the text (the larger the TF-IDF value of a word, the greater the importance of the word in the text). Based on this, the words whose TF-IDF values meet the preset threshold can be determined as keywords. The TF-IDF algorithm formula is shown as the following formula (1):
[0078]
[0079] Among them, TF (Term Frequency) is used to represent the frequency of a word appearing in the matter description information; IDF (Inverse Document Frequency) is used to represent the discrimination ability of the word; i represents the 1ˉi-th word in the segmentation result.
[0080] After the TF-IDF value of each word is obtained according to the above formula, the keyword corresponding to the item description information is determined from each word by comparing it with the preset threshold value. Each keyword is grouped into a keyword group, and the keyword group is used as the item feature information of the target item.
[0081] After acquiring the item characteristic information of the target item, step 203 is executed: classifying and identifying the target item based on the item characteristic information to obtain the category to which the target item belongs.
[0082] During implementation, a Bayesian classifier may be used to perform classification and identification operations on the feature information of an event, determine the preset category to which the feature information of the event belongs, and further determine the preset category to which the target event corresponding to the feature information of the event belongs.
[0083] The basic principle of classifying and identifying item feature information through the Bayesian classifier is to calculate the probability that each keyword in the item feature information belongs to a preset category. In implementation, the probability that each keyword in the item feature information belongs to a preset category can be calculated through the Bayesian formula, and the probabilities corresponding to each keyword are summed up. Based on the comparison between the summed result and the preset probability threshold, it is determined whether the target item corresponding to the item feature information belongs to the preset category. The Bayesian formula is shown in the following formula (2):
[0084]
[0085] Among them, class k Represented as the kth preset category; W i represents the i-th keyword in the event feature information; p(w i |class k ) represents the keyword W i Belongs to the default category class k probability.
[0086] The inventors considered that in the problem of text classification, when there is a word that has not appeared in the trained samples, that is, the call rate of the word is 0, the numerator in formula (2) will be 0. Based on the principle of Laplace smoothing, assuming that the number of Wi is large, the estimated probability change caused by adding 1 to the count of each Wi can be ignored, but the zero probability problem can be conveniently and effectively avoided. For example, suppose that in text classification, there are 3 classes, C1, C2, and C3. In the specified training samples, the observed counts in each class are 0, 990, and 10, respectively. Then the probability of K1 is 0, 0.99, and 0.01. The calculations using Laplace smoothing for these three words are: (0+1) / (1000+1*3)=0.001; (990+1) / (1000+1*3)=0.988; (10+1) / (1000+1*3)=0.011; It can be seen that after performing the +1 operation on each of the above categories and performing the + number of categories operation in the denominator, the difference between the obtained result and the original result is negligible, and the zero probability problem is effectively avoided. Based on this, formula (2) can be optimized to the following formula (3):
[0087]
[0088] Among them, class k Represented as the kth preset category; W i represents the i-th keyword in the event feature information; p(w i |class k ) is represented by the keyword W i Belongs to the default category class k probability; n is the number of keywords included in the event feature information, n≥i.
[0089] In addition, the inventors also considered that in actual application scenarios, the item descriptions corresponding to some target items not only include Figure 2b In addition to the form shown, you also need to submit the material content. Since the same material content may be used as the content of the item description in different target items, for example, in multiple target items such as "maternal and child health care business application" and "personal food business company application", "health certificate" needs to be submitted as the material content. In the item description information corresponding to different target items, usually Figure 2b The table contents shown are different. Therefore, in order to ensure the accuracy of classification, the table content in the item description information can be preset with a weight of 1, and the material content can be preset with a weight of 0.5. When using the above formula (3) to calculate the probability of each keyword, it is necessary to bring in the product of the keyword and the corresponding weight. For example, W in the above formula (3) i If it is the table content in the event description information, then determine the W iThe above formula (3) is still used to calculate the probability. i The content of the submitted materials in the matter description information is determined as follows: i The probability of should be calculated using the following formula (4):
[0090]
[0091] Among them, class k Represented as the kth preset category; W i represents the i-th keyword in the event feature information; p(w i |class k ) represents the keyword W i Belongs to the default category class k probability; n is the number of keywords included in the event feature information, n≥i.
[0092] After obtaining the probability of each keyword in the item feature information through the above formula (3) and formula (4), the probabilities corresponding to each keyword are summed. If the sum result is greater than the probability threshold of the preset classification, it means that the target item corresponding to the item feature information belongs to the preset classification. If the sum result is less than the probability threshold of the preset classification, it means that the target item corresponding to the item feature information does not belong to the preset classification.
[0093] Step 204: Store the item description information of the target item in association with the category of the target item.
[0094] To ensure that after the numerous target items belonging to the department are classified, the item description information of each target item can be accurately found. Considering that the item description information of the target item has a unique identifier, the unique identifier can be added to each form and submitted material in the item description information. The identifier can be Figure 2b The item codes in the table. Based on this, different target items classified into the same category can be distinguished according to the item codes.
[0095] In some possible embodiments, after all target items of a department are classified and stored, when the archived government data is retrieved, the item description information corresponding to the target item can be quickly found based on the preset classification name and the item code of the target item to be extracted.
[0096] In addition, to ensure the accuracy of the classification results, the Bayesian classifier can be modified based on the stored item description information corresponding to each target item. The system can periodically extract item feature information corresponding to n target items from the stored classification records. The Bayesian classifier can compare the accuracy of the newly trained Bayesian model with the currently used model based on the ten-fold crossover algorithm used to test the accuracy of the classifier. If the accuracy of the new model is higher than that of the existing model, the new model will be used as the Bayesian classifier.
[0097] In some possible embodiments, item description information of n target items is selected from the stored classified records of government affairs evidence, and the item description information is randomly divided into ten equal parts. Nine of them are taken for Bayesian model training each time, and the tenth data is used to verify the accuracy of the model. This is repeated ten times, and the accuracy of the new Bayesian classifier is recorded. The accuracy of the newly trained Bayesian model is compared with the current model. If the accuracy of the new model is higher than that of the existing model, the model is updated.
[0098] Based on the same inventive concept, the present application also provides a government data classification storage device 300, such as Figure 3 As shown, the device comprises:
[0099] A description information acquisition module 301 is used to acquire item description information of a target item;
[0100] The feature information acquisition module 302 is used to extract features from the item description information to obtain item feature information of the target item;
[0101] A category confirmation module 303 is used to classify and identify the target item based on the item feature information to obtain the category to which the target item belongs;
[0102] The item storage module 304 is used to store the item description information of the target item in association with the category of the target item.
[0103] In some possible embodiments, the feature information acquisition module includes:
[0104] A word segmentation result confirmation unit, used to perform word segmentation processing on the matter description information to obtain a word segmentation result;
[0105] A keyword acquisition unit, used to determine a plurality of keywords of the item description information from the word segmentation result;
[0106] A weight confirmation unit, used to determine the weight of each keyword in the plurality of keywords;
[0107] The feature information constructing unit is used to construct the event feature information based on the multiple keywords.
[0108] In some possible embodiments, when the keyword acquisition unit determines the multiple keywords of the item description information of the multiple tables from the word segmentation results, it is configured as follows:
[0109] A term frequency-inverse document frequency (TF-IDF) algorithm is used to determine the TF-IDF value of each term in the word segmentation result, and terms whose TF-IDF value is greater than or equal to a preset threshold are determined as the keywords.
[0110] In some possible embodiments, the category confirmation module is configured to:
[0111] The multiple keywords and the preset weight of each keyword are input into a Bayesian classifier for classification and identification to obtain the category to which the target item belongs.
[0112] In some possible embodiments, each of the keywords corresponds to a preset weight. If the keyword belongs to the table content in the matter description information, the keyword corresponds to a first preset weight; if the keyword does not belong to the table content, the keyword corresponds to a second preset weight; wherein the weight value of the first preset weight is greater than the weight value of the second preset weight.
[0113] In some possible embodiments, the categories used for classification and identification are constructed in advance based on the association relationships between different items.
[0114] In some possible embodiments, the different items classified into the same category are distinguished by item codes; wherein each item and the corresponding item code satisfy a one-to-one correspondence.
[0115] In some possible embodiments, after the item storage module associates and stores the item description information of the target item with the category to which the target item belongs, it is further configured to:
[0116] Determining the classification accuracy of the new Bayesian model from the stored item description information of the target item using a ten-fold crossover algorithm;
[0117] If the classification accuracy of the new Bayesian model is higher than the accuracy of the classification model in the Bayesian classifier, the new Bayesian model is used as the classification model in the Bayesian classifier.
[0118] Refer to the following Figure 4 The electronic device 130 according to this embodiment of the present application is described. Figure 4 The electronic device 130 shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.
[0119] like Figure 4 As shown, the electronic device 130 is in the form of a general electronic device. The components of the electronic device 130 may include but are not limited to: the at least one processor 131, the at least one memory 132, and a bus 133 connecting different system components (including the memory 132 and the processor 131).
[0120] Bus 133 represents one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, a processor, or a local bus using any of a variety of bus architectures.
[0121] The memory 132 may include a readable medium in the form of a volatile memory, such as a random access memory (RAM) 1321 and / or a cache memory 1322 , and may further include a read-only memory (ROM) 1323 .
[0122] The memory 132 may also include a program / utility 1325 having a set (at least one) of program modules 1324, such program modules 1324 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.
[0123] The electronic device 130 may also communicate with one or more external devices 134 (e.g., keyboards, pointing devices, etc.), may also communicate with one or more devices that enable a user to interact with the electronic device 130, and / or communicate with any device that enables the electronic device 130 to communicate with one or more other electronic devices (e.g., routers, modems, etc.). Such communication may be performed via an input / output (I / O) interface 135. Furthermore, the electronic device 130 may also communicate with one or more networks (e.g., local area networks (LANs), wide area networks (WANs), and / or public networks, such as the Internet) via a network adapter 136. As shown, the network adapter 136 communicates with other modules for the electronic device 130 via a bus 133. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the electronic device 130, including but not limited to: microcode, device drivers, redundant processors, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.
[0124] In some possible implementations, various aspects of a method for classifying and storing government data provided in the present application may also be implemented in the form of a program product, which includes program code. When the program product runs on a computer device, the program code is used to enable the computer device to execute the steps in a monitoring method described above in this specification according to various exemplary implementations of the present application.
[0125] The program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination thereof. More specific examples of readable storage media (a non-exhaustive list) include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0126] The program product for classified storage of government data of the embodiment of the present application may adopt a portable compact disk read-only memory (CD-ROM) and include program code, and may be run on an electronic device. However, the program product of the present application is not limited thereto, and in this document, a readable storage medium may be any tangible medium containing or storing a program, which may be used by or in combination with an instruction execution system, apparatus, or device.
[0127] The readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, wherein the readable program code is carried. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The readable signal medium may also be any readable medium other than a readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.
[0128] The program code embodied on the readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wired, optical cable, RF, etc., or any suitable combination of the foregoing.
[0129] The program code for performing the operation of the present application can be written in any combination of one or more programming languages, including object-oriented programming languages, such as Java, C++, etc., and also conventional procedural programming languages, such as "C" language or similar programming languages. The program code can be executed entirely on the user electronic device, partially on the user device, as an independent software package, partially on the user electronic device and partially on the remote electronic device, or completely on the remote electronic device or server. In the case of a remote electronic device, the remote electronic device can be connected to the user electronic device through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external electronic device (for example, using an Internet service provider to connect through the Internet).
[0130] It should be noted that, although several units or subunits of the device are mentioned in the above detailed description, this division is merely exemplary and not mandatory. In fact, according to the embodiments of the present application, the features and functions of two or more units described above can be embodied in one unit. Conversely, the features and functions of one unit described above can be further divided into multiple units to be embodied.
[0131] In addition, although the operations of the method of the present application are described in a specific order in the drawings, this does not require or imply that the operations must be performed in this specific order, or that all the operations shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps.
[0132] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code.
[0133] The present application is described with reference to the flowcharts and block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and block diagram, as well as the combination of the processes and boxes in the flowchart and block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and block diagram. Figure 1 Process or multiple processes and boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0134] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 Process or multiple processes and boxes Figure 1 A function specified in one or more boxes.
[0135] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 Process or multiple processes and boxes Figure 1 The steps for the functions specified in one or more boxes.
[0136] Although the preferred embodiments of the present application have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications falling within the scope of the present application.
[0137] Obviously, those skilled in the art can make various changes and modifications to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is also intended to include these modifications and variations.
Claims
1. A method for classifying and storing government data, characterized in that: The method comprises: Obtaining the item description information of the target item; the item description information is the content of the form and materials filled in when applying for the target item; Performing word segmentation processing on the item description information to obtain a word segmentation result; Determine multiple keywords of the item description information from the word segmentation results; For each keyword, if a keyword belongs to the table content in the matter description information, the keyword corresponds to a first preset weight; if the keyword belongs to the material content, the keyword corresponds to a second preset weight; based on the content source of the keyword in the matter description information, the weight of the keyword is determined; wherein the weight value of the first preset weight is greater than the weight value of the second preset weight; Constructing event feature information based on the multiple keywords; Based on the item characteristic information and the weights corresponding to the multiple keywords in the item characteristic information, the target item is classified and identified to obtain the category to which the target item belongs; The item description information of the target item is stored in association with the category to which the target item belongs.
2. The method according to claim 1, characterized in that The step of determining a plurality of keywords of the item description information from the word segmentation result includes: A term frequency-inverse document frequency (TF-IDF) algorithm is used to determine the TF-IDF value of each term in the word segmentation result, and terms whose TF-IDF value is greater than or equal to a preset threshold are determined as the keywords.
3. The method according to claim 1, characterized in that Classifying and identifying the target item based on the item feature information to obtain the category to which the target item belongs includes: The multiple keywords and the preset weight of each keyword are input into a Bayesian classifier for classification and identification to obtain the category to which the target item belongs.
4. The method according to any one of claims 1 to 3, characterized in that: The categories used for classification and identification are constructed in advance based on the associations between different items.
5. The method according to claim 4, characterized in that The different items classified into the same category are distinguished by item codes; wherein each item and the corresponding item code satisfy a one-to-one correspondence.
6. The method according to claim 1, characterized in that After storing the item description information of the target item in association with the category to which the target item belongs, the method further includes: Determining the classification accuracy of the new Bayesian model from the stored item description information of the target item using a ten-fold crossover algorithm; If the classification accuracy of the new Bayesian model is higher than the accuracy of the classification model in the Bayesian classifier, the new Bayesian model is used as the classification model in the Bayesian classifier.
7. A device for storing classified government data, characterized in that: The device comprises: A description information acquisition module is used to acquire the item description information of the target item; the item description information is the content of the form and materials filled in when applying for the target item; The feature information acquisition module is used to perform word segmentation processing on the item description information to obtain a word segmentation result; determine multiple keywords of the item description information from the word segmentation result; for each keyword, if a keyword belongs to the table content in the item description information, the keyword corresponds to a first preset weight; if the keyword belongs to the material content, the keyword corresponds to a second preset weight; based on the content source of the keyword in the item description information, determine the weight of the keyword; wherein the weight value of the first preset weight is greater than the weight value of the second preset weight; construct item feature information based on the multiple keywords; A category confirmation module, used to classify and identify the target item based on the item feature information and the weights corresponding to the multiple keywords in the item feature information, so as to obtain the category to which the target item belongs; The item storage module is used to store the item description information of the target item in association with the category to which the target item belongs.
8. An electronic device, characterized in that: It comprises at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the method as described in any one of claims 1-6.
9. A computer storage medium, characterized in that The computer storage medium stores a computer program, and the computer program is used to enable a computer to execute the method according to any one of claims 1 to 6.
Citation Information
Patent Citations
Text semantic relativity based network public opinion information analysis method
CN103544255A
Information processing method based on text classification technology
CN106126659A
A text classification method based on machine learning and a terminal device thereof
CN109471937A
Policy information processing method and device, storage medium and electronic device
CN110275935A
Media information integration and utilization system based on government affair work
CN110633375A
