A data storage method, system, storage medium and electronic device

By parsing and performing correlation analysis on industrial software R&D data, the data types were determined and classified for storage, thus solving the problem of low data integration and achieving efficient data storage and management.

CN114398315BActive Publication Date: 2025-11-04SUPCON TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111673172.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-31
Publication Date
2025-11-04
Estimated Expiration
2041-12-31

AI Technical Summary

Technical Problem

The integration and completeness of industrial software R&D data in existing technologies are low, resulting in chaotic data storage, difficulty in finding data, and easy waste of resources and data loss.

Method used

By parsing the files to be stored, a set of words under a preset data type is selected, word frequency and relevance are calculated, the data type is determined, and storage is performed based on the relevance. Further classification of sub-data types and updating of mapping relationships are supported.

Benefits of technology

It improves the completeness and integration of data, facilitates searching, avoids data waste and loss, and enhances the efficiency and reliability of data storage.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114398315B_ABST
    Figure CN114398315B_ABST
Patent Text Reader

Abstract

Embodiments of the present application provide a data storage method, system, storage medium and electronic device. The method comprises: parsing a first to-be-stored file to obtain first data text information; based on a preset vocabulary set of each preset data type, filtering out the vocabulary under the preset data type from the first data text information to obtain a first vocabulary set; calculating the frequency of the vocabulary in the first vocabulary set appearing in the first data text information to obtain a first word frequency, determining the correlation degree of the first data text information and the preset data type based on the correlation degree coefficient of the first word frequency and each preset word frequency; comparing the correlation degrees of the first data text information and each preset data type, determining the preset data type corresponding to the maximum correlation degree as the data type of the first data text information, and storing the first to-be-stored file based on the data type of the first data text information. The present application can improve the perfection and integration of data.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of data processing, in particular to a data storage method, system, storage medium and electronic device. BACKGROUND

[0002] With the coverage of industrial software becoming wider and wider, the storage requirements of industrial software development data are gradually increasing. Since the industrial software development process involves many types of data and the data is not easy to integrate, the integration and perfection of the current development data are low, the stored data is not easy to find, and the data storage is chaotic, which will lead to a great waste of data resources and an easy risk of data loss. Therefore, how to store data and improve the perfection and integration of data is a problem to be solved. SUMMARY

[0003] The purpose of the embodiment of the present application is to provide a data storage method, system, storage medium and electronic device, which can improve the perfection and integration of data. The specific technical solutions are as follows:

[0004] The present application provides a data storage method, comprising:

[0005] The first to be stored file is parsed to obtain first data text information;

[0006] Based on the preset vocabulary set of each preset data type, the vocabulary under the preset data type is filtered out from the first data text information to obtain a first vocabulary set; the vocabulary in the preset vocabulary set at least includes the vocabulary in the first vocabulary set, and the vocabulary in the preset vocabulary set has a weight value under the preset data type;

[0007] The frequency of the vocabulary in the first vocabulary set appearing in the first data text information is calculated to obtain a first word frequency, and the association degree between the first data text information and the preset data type is determined based on the first word frequency and the association degree coefficient of each preset word frequency; the preset word frequency is the product of the word frequency of the vocabulary in the preset vocabulary set and the corresponding vocabulary weight value;

[0008] The association degrees of the first data text information and each preset data type are compared, the preset data type corresponding to the maximum association degree is determined as the data type of the first data text information, and the first to be stored file is stored based on the data type of the first data text information.

[0009] Optionally, after determining the preset data type corresponding to the maximum association degree as the data type of the first data text information, the method further comprises:

[0010] determine whether a sub data type corresponding to the maximum correlation degree exists; the sub data type belongs to the preset data type;

[0011] If the sub data type exists, filter out the words under the sub data type from the first data text information based on a sub-word set under each sub data type to obtain a second word set; the words in the sub-word set at least include the words in the second word set, and the words in the sub-word set have weight values under the sub data type;

[0012] Calculate the frequency of the words in the second word set appearing in the first data text information to obtain a second word frequency, and determine the correlation degree between the first data text information and the sub data type based on the second word frequency and the correlation degree coefficient of each sub word frequency;

[0013] Compare the correlation degrees of the first data text information and each sub data type, determine the sub data type corresponding to the maximum correlation degree as the sub data type of the first data text information, and store the first to-be-stored file based on the data type and the sub data type of the first data text information.

[0014] Optionally, the method further comprises: parsing the first to-be-stored file to obtain first data source information and first storage time information;

[0015] The method for storing the first to-be-stored file specifically comprises:

[0016] Determining a data type item based on the first data source information and the first data text information;

[0017] Mapping processing the data type item, the identifier of the data type of the first data text information, and the name of the first to-be-stored file to generate a data mapping relationship;

[0018] Storing the first to-be-stored file based on the data mapping relationship and the first storage time information.

[0019] Optionally, the method further comprises:

[0020] Parsing a second to-be-stored file to obtain second data source information and second storage time information;

[0021] Determining whether a file with the same name is stored;

[0022] If yes, searching for a data mapping relationship corresponding to the name of the second to-be-stored file to obtain a target data mapping relationship;

[0023] Searching for a data type item matching the target data mapping relationship to obtain a target data type item;

[0024] modifying the target data type item based on the second data text information and the second data source information, to obtain a modified data type item;

[0025] updating the data mapping relationship based on the modified data type item, to obtain an updated data mapping relationship;

[0026] storing the second to-be-stored file based on the updated data mapping relationship and the second storage time information.

[0027] Optionally, the method further comprises:

[0028] receiving a file deletion operation request, and parsing the file deletion operation request to obtain a file name to be deleted;

[0029] determining whether there is storage request information identical to the file name to be deleted in the data request set;

[0030] if there is, not deleting the file identical to the file name to be deleted.

[0031] Optionally, the determining the correlation degree between the first data text information and the preset data type based on the first word frequency and the correlation degree coefficients of each preset word frequency comprises:

[0032] determining the correlation degree coefficients of the first word frequency and each preset word frequency based on a grey correlation degree analysis method;

[0033] taking an average value of the plurality of correlation degree coefficients as the correlation degree between the first data text information and the preset data type.

[0034] Optionally, the weight value under the preset data type is obtained based on an analytic hierarchy process method, and the method for parsing the first to-be-stored file is an optical character recognition method.

[0035] The application further provides a data storage system, comprising:

[0036] a parsing module configured to parse a first to-be-stored file to obtain first data text information;

[0037] a screening module configured to screen, from the first data text information, a word under a preset data type based on a preset word set of each preset data type, to obtain a first word set; the words in the preset word set at least include the words in the first word set, and the words in the preset word set have a weight value under the preset data type;

[0038] The association degree calculation module is configured to calculate a frequency of a vocabulary in the first vocabulary set appearing in the first data text information to obtain a first word frequency, and determine an association degree between the first data text information and the preset data type based on the first word frequency and an association degree coefficient of each preset word frequency; the preset word frequency is a product of a word frequency of a vocabulary in the preset vocabulary set and a corresponding vocabulary weight value;

[0039] The storage module is configured to compare the association degrees between the first data text information and each of the preset data types, determine a preset data type corresponding to a maximum association degree as a data type of the first data text information, and store the first to-be-stored file based on the data type of the first data text information.

[0040] The application further provides a computer readable storage medium, wherein a program is stored on the computer readable storage medium, and the program is executed by a processor to implement the data storage method.

[0041] The application further provides an electronic device, comprising:

[0042] at least one processor and at least one memory connected to the processor;

[0043] The processor, the memory and the bus complete communication with each other; the processor is configured to invoke program instructions in the memory to execute the data storage method.

[0044] The data storage method, system, storage medium and electronic device provided by the application can analyze a first to-be-stored file to obtain first data text information, filter out a vocabulary under each preset data type from the first data text information based on a preset vocabulary set under each preset data type to obtain a first vocabulary set, calculate a frequency of a vocabulary in the first vocabulary set appearing in the first data text information to obtain a first word frequency, determine an association degree between the first data text information and the preset data type based on the first word frequency and an association degree coefficient of each preset word frequency, compare the association degrees between the first data text information and each of the preset data types, determine a preset data type corresponding to a maximum association degree as a data type of the first data text information, and store the first to-be-stored file based on the data type of the first data text information. The application can classify to-be-stored files, the stored data is easy to find, the data can be improved and integrated, and the data resources can be prevented from being wasted and the risk of data loss can be avoided.

[0045] Of course, implementing any product or method of the application does not necessarily require achieving all the advantages described above. BRIEF DESCRIPTION OF DRAWINGS

[0046] In order to make the technical solutions in the embodiments of the present application or the prior art clearer, the accompanying drawings needed in the embodiments or prior art description will be briefly introduced. Obviously, the accompanying drawings in the following description only aim to some embodiments of the present application, and other drawings can be obtained by those skilled in the art without any creative effort on the basis of these drawings.

[0047] Figure 1 The data storage method flow chart provided by the embodiment of the present application is provided.

[0048] Figure 2 The data storage system structure chart provided by the embodiment of the present application is provided.

[0049] Figure 3 The structure schematic diagram of an electronic device provided by the embodiment of the present application is provided. DETAILED DESCRIPTION

[0050] The technical solutions in the embodiments of the present application will be described clearly and completely with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without any creative effort belong to the protection scope of the present application.

[0051] The present application provides a data storage method, as shown in the figure, the method comprises: Figure 1

[0052] Step 101: parsing the first to be stored file to obtain the first data text information.

[0053] The first to be stored file can have picture information, at this time, the first to be stored file can be parsed by using an optical character recognition method to obtain the first data text information. Of course, the first to be stored file can also have sound information, at this time, the sound information can be converted into text information to obtain the first data text information.

[0054] ​When the optical character recognition method is used for analysis, the picture information in the first to-be-stored file is subjected to grayscale processing; the picture information subjected to the grayscale processing is subjected to binarization processing to separate the text from the background; the image is subjected to noise reduction processing to determine the average pixel value of the connected region in the picture and process the noise point information; the text in the picture is subjected to inclination correction based on the Hough transform, the picture is subjected to inflation processing to connect the discontinuous text into a straight line, then the straight line detection is performed to determine the inclination angle and then the text is subjected to rotation; the picture subjected to the inclination correction is segmented, the text of the picture is projected to the Y axis through horizontal scanning to determine the histogram on the Y axis, the horizontal scanning is followed by vertical scanning to obtain the cutting result; the text subjected to the cutting is subjected to text recognition, and the feature vector of the segmented picture text and the features of the feature template library are subjected to matching operation to obtain the first data text information.

[0055] Step 102: Based on the preset vocabulary set of each preset data type, the vocabulary under the preset data type is filtered out from the first data text information to obtain a first vocabulary set; the vocabulary in the preset vocabulary set at least includes the vocabulary in the first vocabulary set, and the vocabulary in the preset vocabulary set has a weight value under the preset data type.

[0056] The preset data type can be specifically divided into a large category, a medium category and a small category, and there can be multiple large categories, multiple medium categories and multiple small categories. Of course, the small category can also have various subcategories, and the preset data type is determined according to different application scenarios.

[0057] In this embodiment, the vocabulary of the large category is first filtered out from the first data text information in the order from the large category to the medium category to the small category. Optionally, the vocabulary under the preset data type is a vocabulary with a word frequency greater than a preset word frequency, and these vocabularies can be obtained by statistics, and the weight value under the preset data type can be obtained based on the analytic hierarchy process.

[0058] When the vocabulary under the preset data type is filtered out from the first data text information, it is checked whether there is a vocabulary of the preset vocabulary set in the first data text information. If so, the vocabulary is recorded in the first vocabulary set, and the weight value under the corresponding preset data type is mapped with the vocabulary in the first vocabulary set.

[0059] Step 103: The frequency of the vocabulary in the first vocabulary set in the first data text information is calculated to obtain a first word frequency, and the correlation degree between the first data text information and the preset data type is determined based on the correlation degree coefficient of the first word frequency and each preset word frequency. The preset word frequency is the product of the word frequency of the vocabulary in the preset vocabulary set and the corresponding vocabulary weight value.

[0060] Optionally, the association degree between the first data text information and the preset data type is determined based on an association degree coefficient of the first word frequency and each preset word frequency, and specifically includes: determining the association degree coefficient of the first word frequency and each preset word frequency based on a grey correlation degree analysis method; and taking an average value of the plurality of association degree coefficients as the association degree between the first data text information and the preset data type.

[0061] In the determination of the association degree coefficient of the first word frequency and each preset word frequency based on the grey correlation degree analysis method, the association degree coefficient is obtained by using the following formula:

[0062]

[0063] In the formula, ξ i (k) is the association degree coefficient of the kth first word frequency and the ith preset word frequency, x0(k) is the kth first word frequency, x i (k) is the product of the ith preset word frequency and the corresponding weight value, and σ is a resolution coefficient, 0<σ≤1.

[0064] In step 104, the association degrees between the first data text information and each preset data type are compared, the preset data type corresponding to the maximum association degree is determined as the data type of the first data text information, and the first to-be-stored file is stored based on the data type of the first data text information.

[0065] After the preset data type corresponding to the maximum association degree is determined as the data type of the first data text information, the first to-be-stored file is encoded, for example, encoded as KNWE, and Table 1 is a category matching list.

[0066] Table 1 Category Matching List

[0067]

[0068] In Table 1, R&D is a large category, which is a research and development management identifier, SP is a medium category, which is a specification identifier, M is a small category, which is a manual identifier, PF is a medium category, which is a program file identifier, R&D-SP-001 and R&D-SP-002 are serial number names under the R&D-SP category, indicating different files, R&D-SP-M-001 is a serial number name under the R&D-SP-M category, and R&D-PF-001 is a serial number name under the R&D-PF category.

[0069] When the first to-be-stored file is stored based on the data type of the first data text information, the storage information includes knowledge category identifier, to-be-stored file identifier, text content in the to-be-stored file, data collection source, data creation time, and the like, and is associated to a corresponding data category table, as shown in Table 2.

[0070] Table 2 Data Category Table

[0071] Serial number Category name Identification Collection source Creation time Associated category Remark 1 Specification class R&D-SP-001 001 2021-07-10 R&D-SP 2 Specification class R&D-SP-002 001 2021-07-10 R&D-SP 3 Manual class R&D-SP-M-001 001-01 2021-07-11 R&D-SP-M 4 Procedure file class R&D-PF-001 002 2021-07-13 R&D-PF

[0072] In Table 2, the source of collection is represented by a string, which corresponds to a data collector or a data acquisition party.

[0073] As an optional implementation, after the step 104 of determining the preset data type corresponding to the maximum correlation degree as the data type of the first data text information, the method further includes: judging whether the preset data type corresponding to the maximum correlation degree has a sub data type; the sub data type belongs to the preset data type; if so, filtering the words under the sub data type from the first data text information based on the word set under each sub data type, to obtain a second word set; the words in the word set under the sub data type at least include the words in the second word set, and the words in the word set under the sub data type have weight values under the sub data type; calculating the frequency of the words in the second word set appearing in the first data text information to obtain a second word frequency, determining the correlation degree between the first data text information and the sub data type based on the second word frequency and the correlation degree coefficient of each sub word frequency; comparing the correlation degrees between the first data text information and each sub data type, determining the sub data type corresponding to the maximum correlation degree as the sub data type of the first data text information, and storing the first to-be-stored file based on the data type and the sub data type of the first data text information.

[0074] Optionally, if the data type of the first data text information only has the large category and the medium category, but no small category, the first to-be-stored file is directly stored based on the large category and the medium category of the first data text information.

[0075] As an optional implementation, the first to-be-stored file is parsed to obtain first data source information and first storage time information. The method of storing the first to-be-stored file specifically includes: determining a data type item based on the first data source information and the first data text information; performing mapping processing on the data type item, the identifier of the data type of the first data text information, and the name of the first to-be-stored file to generate a data mapping relationship; and storing the first to-be-stored file based on the data mapping relationship and the first storage time information.

[0076] In the determination of the data type item based on the first data source information and the first data text information, as shown in Table 3 and Table 4, Table 3 is a specification class data table, and Table 4 is an associated specification class sub-item data table.

[0077] Table 3 Specification class data table

[0078]

[0079] In Table 3, the type name is Specification Class, and the corresponding data type item is Specification Class Item.

[0080] Table 4 Specification Class Sub-item Data Table

[0081]

[0082] The contents of Table 3 and Table 4 are storage data tables obtained by storing the first to-be-stored file based on the data mapping relationship and the first storage time information.

[0083] As an optional embodiment, the data storage method further comprises: parsing the second to-be-stored file to obtain second data source information and second storage time information; determining whether a file with the same name is stored; if yes, searching for a data mapping relationship corresponding to the name of the second to-be-stored file to obtain a target data mapping relationship; searching for a data type item matching the target data mapping relationship to obtain a target data type item; modifying the target data type item based on the second data text information and the second data source information to obtain a modified data type item; updating the data mapping relationship based on the modified data type item to obtain an updated data mapping relationship; and storing the second to-be-stored file based on the updated data mapping relationship and the second storage time information.

[0084] Before storing the second to-be-stored file, it is necessary to determine whether a storage file with the same name as the second to-be-stored file is stored in the database. If there is no same name, it indicates that the file with the name has not been stored before. If there is a same name, it indicates that the content of the file with the name is updated. If it is a new file, the process of steps 101-104 is executed. If it is an updated file, a data type item matching the target data mapping relationship is searched to obtain a target data type item, and the contents of Table 4 are modified based on the second data text information and the second data source information to obtain a modified data type item. The department personnel, post information and corresponding content and content description in Table 4 can be obtained from the second data source information. The standard information in Table 4 can be obtained from the target data type item. Other item information in Table 4 can be obtained from the second data source information.

[0085] As an optional embodiment, the data storage method further comprises: receiving a file deletion operation request, parsing the file deletion operation request to obtain a deletion file name; determining whether there is storage request information with the same name as the deletion file name in the data request set; if yes, not deleting the file with the same name as the deletion file name.

[0086] When the number of operation requests is large, the operation request can be a storage request or a deletion storage file request. In the embodiment, the request operations are sorted according to the request time to generate a request execution sequence set. If there is an update operation and a deletion operation for the same file name in the set, an abnormal processing will be caused. In this case, it is necessary to determine whether there is storage request information same as the deletion file name in the data request set. If there is, the file with the same deletion file name is not deleted. The file state data table is shown in Table 5.

[0087] Table 5 File state data table

[0088] Serial number Data type identification Data content Status Knowledge category 1 R&D-SP-011 "Industrial software usability specification V2.0" Update R&D-SP 2 R&D-SP-012 "Industrial software XXX front-end code specification V2.0" Update R&D-SP 3 R&D-SP-013 "Industrial software XX language coding specification V1.0" Add R&D-SP 4 R&D-SP-014 "Industrial software interface test specification V1.0" Add R&D-SP 5 R&D-SP-015 "Industrial software performance test specification V0.1" Update R&D-SP 6 R&D-SP-016 "Industrial software other specification V0.1" Other R&D-SP

[0089] In Table 5, the state of other can include a deleted file. In addition, the file processing priority, the file content confidentiality, the operation execution risk level and the like can be recorded in Table 5.

[0090] For the stored files, when various routes are formulated, such as a development skill knowledge route, a test skill knowledge route, a management skill knowledge route, a product knowledge route and the like, each route needs to be formulated based on a plurality of stored files, and the classified storage data can facilitate the search of the required files when various routes are formulated.

[0091] The application further provides a data storage system, as shown in Figure 2 The system comprises:

[0092] The analysis module 201 is configured to analyze the first to-be-stored file to obtain first data text information. The analysis method of the first to-be-stored file is an optical character recognition method.

[0093] The screening module 202 is configured to screen the words under the preset data type from the first data text information based on the preset word set of each preset data type to obtain a first word set. The words in the preset word set at least include the words in the first word set, and the words in the preset word set have a weight value under the preset data type. The weight value under the preset data type is obtained based on an analytic hierarchy process.

[0094] The correlation calculation module 203 is configured to calculate the frequency of the words in the first word set in the first data text information to obtain a first word frequency, and determine the correlation between the first data text information and the preset data type based on the correlation coefficient of the first word frequency and each preset word frequency. The preset word frequency is the product of the word frequency of the words in the preset word set and the corresponding word weight value.

[0095] The correlation calculation module 203 specifically comprises:

[0096] The correlation degree calculation unit is configured to determine a correlation degree coefficient of the first word frequency and each preset word frequency based on a grey correlation degree analysis method; and take an average value of the plurality of correlation degree coefficients as the correlation degree of the first data text information and the preset data type.

[0097] The storage module 204 is configured to compare the correlation degrees of the first data text information and each preset data type, determine the preset data type corresponding to the maximum correlation degree as the data type of the first data text information, and store the first to-be-stored file based on the data type of the first data text information.

[0098] The storage module 204 specifically includes:

[0099] The storage unit is configured to, after parsing the first to-be-stored file to obtain the first data source information and the first storage time information, determine a data type item based on the first data source information and the first data text information; perform mapping processing on the data type item, an identifier of the data type of the first data text information, and a name of the first to-be-stored file to generate a data mapping relationship; and store the first to-be-stored file based on the data mapping relationship and the first storage time information.

[0100] As an optional implementation, the data storage system further includes:

[0101] The processing module is configured to determine whether the preset data type corresponding to the maximum correlation degree exists a sub data type; the sub data type belongs to the preset data type; if the sub data type exists, filter out, from the first data text information, a word in the sub data type based on a sub word set under each sub data type to obtain a second word set; the words in the sub word set at least include the words in the second word set, and the words in the sub word set have weight values in the sub data type; calculate a frequency of the words in the second word set appearing in the first data text information to obtain a second word frequency; determine a correlation degree of the first data text information and the sub data type based on a correlation degree coefficient of the second word frequency and each sub word frequency; compare the correlation degrees of the first data text information and each sub data type, determine the sub data type corresponding to the maximum correlation degree as the sub data type of the first data text information, and store the first to-be-stored file based on the data type and the sub data type of the first data text information.

[0102] The file updating module is configured to parse the second to-be-stored file to obtain second data source information and second storage time information; determine whether a file with the same name is stored; if yes, find a data mapping relationship corresponding to the name of the second to-be-stored file to obtain a target data mapping relationship; find a data type item matching the target data mapping relationship to obtain a target data type item; modify the target data type item based on the second data text information and the second data source information to obtain a modified data type item; update the data mapping relationship based on the modified data type item to obtain an updated data mapping relationship; and store the second to-be-stored file based on the updated data mapping relationship and the second storage time information.

[0103] The deleting module is configured to receive a file deletion operation request, parse the file deletion operation request to obtain a deletion file name, determine whether there is storage request information identical to the deletion file name in the data request set, and if yes, not delete the file identical to the deletion file name.

[0104] The embodiment of the present application provides a computer readable storage medium, which stores a program, and the program is executed by a processor to implement the data storage method.

[0105] The embodiment of the present application provides an electronic device, as shown in the figure, Figure 3 The electronic device 30 includes at least one processor 301 and at least one memory 302 connected with the processor 301, and a bus 303; wherein the processor 301 and the memory 302 complete mutual communication through the bus 303; the processor 301 is used to call program instructions in the memory 302 to execute the data storage method. The electronic device in the present application can be a server, a PC, a PAD, a mobile phone and the like.

[0106] The present application also provides a computer program product, which is suitable for executing the program of the steps included in the data storage method when executed on a data processing device.

[0107] The present application is described with reference to the flowcharts and / or block diagrams of the method, system and computer program product according to the embodiments of the present application. It should be understood that each flow and / or block in the flowcharts and / or block diagrams, and the combination of the flows and / or blocks in the flowcharts and / or block diagrams can be realized by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device produce a device for realizing the functions specified in the flowcharts and / or block diagrams. Figure 1 The device for realizing the functions specified in one flow or multiple flows and / or blocks Figure 1 one flow or multiple flows and / or blocks

[0108] In one typical arrangement, a device includes one or more processors (CPUs), memory, and a bus. The device can also include input / output interfaces, network interfaces, and the like.

[0109] The memory can include non-persistent memory in the form of random access memory (RAM) and / or non-volatile memory, such as read only memory (ROM) or flash memory (flash RAM), including at least one memory chip. The memory is an example of computer readable media.

[0110] Computer readable media includes permanent and non-permanent, removable and non-removable media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read only memory (ROM), electrically erasable programmable read only memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), digital versatile discs (DVDs) or other optical storage, magnetic cassettes, magnetic tapes, magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. According to the definition herein, computer readable media does not include transitory media, such as modulated data signals and carrier waves.

[0111] Those skilled in the art will appreciate that embodiments of the present application can be devised for a method, a system, or a computer program product. Accordingly, the present application can take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application can take the form of a computer program product on one or more computer readable storage media (including, but not limited to, disk storage, CD-ROMs, optical storage devices, etc.) embodying computer readable program code thereon.

[0112] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes the element.

[0113] The various embodiments in this specification are described in a related manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, the system embodiments are basically similar to the method embodiments, so the description is relatively simple; relevant parts can be referred to the descriptions of the method embodiments.

[0114] The above are merely embodiments of this application and are not intended to limit the scope of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of the claims of this application.

Claims

1. A data storage method, characterized by, The method comprises the following steps: parsing a first to-be-stored file to obtain first data text information; based on a preset vocabulary set of each preset data type, filtering out the vocabulary under the preset data type from the first data text information to obtain a first vocabulary set; the vocabulary in the preset vocabulary set at least includes the vocabulary in the first vocabulary set, and the vocabulary in the preset vocabulary set has a weight value under the preset data type; calculating the frequency of the vocabulary in the first vocabulary set appearing in the first data text information to obtain a first word frequency, and determining the association degree of the first data text information and the preset data type based on the association degree coefficient of the first word frequency and each preset word frequency; the preset word frequency is the product of the word frequency of the vocabulary in the preset vocabulary set and the corresponding vocabulary weight value; comparing the association degrees of the first data text information and each preset data type, determining the preset data type corresponding to the maximum association degree as the data type of the first data text information, and storing the first to-be-stored file based on the data type of the first data text information; after determining the preset data type corresponding to the maximum association degree as the data type of the first data text information, the method further comprises: determining whether the preset data type corresponding to the maximum association degree has a sub-data type; the sub-data type belongs to the preset data type; if yes, filtering out the vocabulary under the sub-data type from the first data text information based on a sub-vocabulary set of each sub-data type to obtain a second vocabulary set; the vocabulary in the sub-vocabulary set at least includes the vocabulary in the second vocabulary set, and the vocabulary in the sub-vocabulary set has a weight value under the sub-data type; calculating the frequency of the vocabulary in the second vocabulary set appearing in the first data text information to obtain a second word frequency, and determining the association degree of the first data text information and the sub-data type based on the association degree coefficient of the second word frequency and each sub-word frequency; comparing the association degrees of the first data text information and each sub-data type, determining the sub-data type corresponding to the maximum association degree as the sub-data type of the first data text information, and storing the first to-be-stored file based on the data type and the sub-data type of the first data text information.

2. The data storage method of claim 1, wherein, Further comprising: parsing the first to-be-stored file to obtain first data source information and first storage time information; the method for storing the first to-be-stored file, specifically comprising: determining a data type item based on the first data source information and the first data text information; performing mapping processing on the data type item, the identifier of the data type of the first data text information, and the name of the first to-be-stored file to generate a data mapping relationship; storing the first to-be-stored file based on the data mapping relationship and the first storage time information.

3. The data storage method of claim 2, wherein, Further comprising: parsing a second to-be-stored file to obtain second data source information and second storage time information; determining whether a file with the same name is stored; If yes, a data mapping relationship corresponding to a name of the second to-be-stored file is searched to obtain a target data mapping relationship; A data type item matching the target data mapping relationship is searched to obtain a target data type item; The target data type item is modified based on the second data text information and second data source information to obtain a modified data type item; The data mapping relationship is updated based on the modified data type item to obtain an updated data mapping relationship; The second to-be-stored file is stored based on the updated data mapping relationship and the second storage time information.

4. The data storage method of claim 1, wherein, Further comprising: A file deletion operation request is received, and the file deletion operation request is parsed to obtain a deletion file name; It is judged whether there is storage request information same as the deletion file name in the data request set; If yes, the file same as the deletion file name is not deleted.

5. The data storage method of claim 1, wherein, The association degree of the first data text information and the preset data type is determined based on the association degree coefficients of the first word frequency and each preset word frequency, specifically comprising: The association degree coefficients of the first word frequency and each preset word frequency are determined based on a grey correlation degree analysis method; The average value of the plurality of association degree coefficients is taken as the association degree of the first data text information and the preset data type.

6. The data storage method of claim 1, wherein, The weight value under the preset data type is obtained based on an analytic hierarchy process; and the method for analyzing the first to-be-stored file is an optical character recognition method.

7. A data storage system, characterized by Comprising: An analysis module configured to analyze a first to-be-stored file to obtain first data text information; A screening module configured to screen a word under a preset data type from the first data text information based on a preset word set of each preset data type to obtain a first word set; the words in the preset word set at least include the words in the first word set, and the words in the preset word set have a weight value under the preset data type; An association degree calculation module configured to calculate a frequency of the words in the first word set appearing in the first data text information to obtain a first word frequency, and determine an association degree of the first data text information and the preset data type based on the association degree coefficients of the first word frequency and each preset word frequency; the preset word frequency is a product of a word frequency of the word in the preset word set and a corresponding word weight value; A storage module configured to compare the association degrees of the first data text information and each preset data type, determine a preset data type corresponding to a maximum association degree as a data type of the first data text information, and store the first to-be-stored file based on the data type of the first data text information; A processing module configured to judge whether the preset data type corresponding to the maximum association degree exists a sub-data type; The sub-data type belongs to the preset data type; If the sub-data type exists, based on the sub-vocabulary set under each sub-data type, the vocabulary under the sub-data type is filtered from the first data text information to obtain a second vocabulary set; the vocabulary in the sub-vocabulary set at least includes the vocabulary in the second vocabulary set, and the vocabulary in the sub-vocabulary set has a weight value under the sub-data type; the frequency of the vocabulary in the second vocabulary set appearing in the first data text information is calculated to obtain a second word frequency, the correlation degree of the second word frequency and each sub-word frequency is determined to determine the correlation degree of the first data text information and the sub-data type; the correlation degrees of the first data text information and each sub-data type are compared, the sub-data type corresponding to the maximum correlation degree is determined as the sub-data type of the first data text information, and the first to-be-stored file is stored based on the data type and the sub-data type of the first data text information.

8. A computer-readable storage medium, characterized in that, The computer readable storage medium stores a program, and the program is executed by the processor to implement the data storage method in any one of claims 1-6.

9. An electronic device, comprising: Comprise: At least one processor, and at least one memory connected with the processor, bus; The processor, the memory complete mutual communication through the bus; The processor is used to call the program instruction in the memory, to execute the data storage method in any one of claims 1-6.

Citation Information

Patent Citations

  • Document classification method, document classification device, computer device and computer readable medium

    CN107729520A

  • Text matching method and device, electronic equipment and storage medium

    CN111898380A