Data processing method, device and equipment
By converting the text data to be encrypted into semantic target text data and using this data during data transmission, the problem of poor concealment of ciphertext data is solved, and the security and efficiency of data transmission are improved.
Patent Information
- Application Number
- CN202411862427.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-17
- Publication Date
- 2025-04-29
- Estimated Expiration
- 2044-12-17
AI Technical Summary
During data transmission, the ciphertext data is poorly concealed and easily recognized, resulting in a higher risk of privacy leakage.
By obtaining the text data to be encrypted, converting it into an encoding sequence according to the preset encoding rules, and generating semantic target text data based on the preset comparison relationship of the text structure and the coded value, and finally sending the target text data to the data recipient.
Simplify encryption operations, reduce dependence on third-party encryption software, improve encryption efficiency, and improve security and concealment in data transmission by generating semantic target text data.
Smart Images

Figure CN119312374B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a data processing method, device and equipment. Background Art
[0002] As people pay more and more attention to their own privacy data, in order to protect user privacy and ensure data security, it is necessary to encrypt the transmitted data.
[0003] For example, the text data to be transmitted can be converted into ciphertext data through an encryption key, and then the ciphertext data can be sent to the data recipient. However, since ciphertext data is easily identified during the data transmission process, it has poor concealment and a high risk of privacy leakage. Therefore, a technical solution is needed to improve the security of privacy data during data transmission. Summary of the invention
[0004] The purpose of the embodiments of this specification is to provide a technical solution to improve the security of private data during data transmission.
[0005] In order to implement the above technical solution, the embodiments of this specification are implemented as follows:
[0006] A data processing method provided in an embodiment of the present specification includes: obtaining first text data to be encrypted, and converting the first text data into a first coding sequence according to a preset coding rule; determining a target text structure corresponding to each coding value in the first coding sequence according to a preset comparison relationship between text structure and coding value, and generating semantic target text data corresponding to the first text data according to the target text structure corresponding to each coding value; and sending the target text data to a data recipient.
[0007] A data processing device provided in an embodiment of the present specification includes: a first encoding module, used to obtain first text data to be encrypted, and convert the first text data into a first encoding sequence according to a preset encoding rule; a text generation module, used to determine a target text structure corresponding to each encoding value in the first encoding sequence according to a preset comparison relationship between text structure and encoding value, and generate semantic target text data corresponding to the first text data according to the target text structure corresponding to each encoding value; a data sending module, used to send the target text data to a data recipient.
[0008] A data processing device provided in an embodiment of the present specification includes: a processor; and a memory arranged to store computer executable instructions, wherein when the executable instructions are executed, the processor: obtains first text data to be encrypted, and converts the first text data into a first coding sequence according to a preset coding rule; determines a target text structure corresponding to each coding value in the first coding sequence according to a preset comparison relationship between text structure and coding value, and generates semantic target text data corresponding to the first text data according to the target text structure corresponding to each coding value; and sends the target text data to a data recipient.
[0009] The embodiments of this specification also provide a storage medium, which is used to store computer-executable instructions. When the executable instructions are executed by a processor, they implement the following process: obtaining first text data to be encrypted, and converting the first text data into a first coding sequence according to a preset coding rule; determining a target text structure corresponding to each coding value in the first coding sequence according to a preset comparison relationship between text structure and coding value, and generating semantic target text data corresponding to the first text data according to the target text structure corresponding to each coding value; and sending the target text data to a data recipient.
[0010] The embodiments of this specification also provide a computer program product, including a computer program, which implements the following process when executed by a processor: obtaining first text data to be encrypted, and converting the first text data into a first coding sequence according to a preset coding rule; determining a target text structure corresponding to each coding value in the first coding sequence according to a preset comparison relationship between text structure and coding value, and generating semantic target text data corresponding to the first text data according to the target text structure corresponding to each coding value; and sending the target text data to a data recipient.
[0011] A data processing method provided in an embodiment of the present specification includes: receiving target text data, and based on the text structure of each sentence in the target text data, determining the encoding value corresponding to each sentence in the target text data from a preset comparison relationship between the text structure and the encoding value; constructing a second encoding sequence corresponding to the target text data according to the encoding value corresponding to each sentence in the target text data; and decoding the second encoding sequence to obtain second text data.
[0012] A data processing device provided in an embodiment of the present specification includes: a data receiving module, used to receive target text data, and based on the text structure of each sentence in the target text data, determine the encoding value corresponding to each sentence in the target text data from a preset comparison relationship between the text structure and the encoding value; a second encoding module, used to construct a second encoding sequence corresponding to the target text data according to the encoding value corresponding to each sentence in the target text data; and a text conversion module, used to decode the second encoding sequence to obtain second text data.
[0013] A data processing device provided in an embodiment of the present specification includes: a processor; and a memory arranged to store computer executable instructions, wherein when the executable instructions are executed, the processor: receives target text data, and based on the text structure of each sentence in the target text data, determines the encoding value corresponding to each sentence in the target text data from a preset comparison relationship between the text structure and the encoding value; constructs a second encoding sequence corresponding to the target text data according to the encoding value corresponding to each sentence in the target text data; and decodes the second encoding sequence to obtain second text data.
[0014] The embodiments of this specification also provide a storage medium, which is used to store computer-executable instructions. When the executable instructions are executed by a processor, they implement the following process: receiving target text data, and based on the text structure of each sentence in the target text data, determining the encoding value corresponding to each sentence in the target text data from a preset comparison relationship between the text structure and the encoding value; constructing a second encoding sequence corresponding to the target text data according to the encoding value corresponding to each sentence in the target text data; and decoding the second encoding sequence to obtain second text data.
[0015] The embodiments of this specification also provide a computer program product, including a computer program, which implements the following process when executed by a processor: receiving target text data, and based on the text structure of each sentence in the target text data, determining the encoding value corresponding to each sentence in the target text data from a preset comparison relationship between the text structure and the encoding value; constructing a second encoding sequence corresponding to the target text data according to the encoding value corresponding to each sentence in the target text data; and decoding the second encoding sequence to obtain second text data. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] In order to more clearly illustrate the technical solutions in the embodiments of this specification or the prior art, the drawings required for use in the embodiments or the prior art description will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this specification. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative labor.
[0017] Figure 1 This is an embodiment of a data processing method of this specification;
[0018] Figure 2 Another data processing method embodiment of this specification;
[0019] Figure 3 This is a schematic diagram of a data encryption process in this manual;
[0020] Figure 4 A schematic diagram of a data encryption program processing process of this specification;
[0021] Figure 5 Another data processing method embodiment of this specification;
[0022] Figure 6 Another data processing method embodiment of this specification;
[0023] Figure 7 This is a schematic diagram of a data decryption process in this manual;
[0024] Figure 8 A schematic diagram of a data decryption program processing process of this specification;
[0025] Fig. 9 This is an embodiment of a data processing device of the present specification;
[0026] Fig.10 This is another data processing device embodiment of the present specification;
[0027] Fig.11 This is an embodiment of a data processing device in this specification. DETAILED DESCRIPTION
[0028] The embodiments of this specification provide data processing methods, devices and equipment.
[0029] In order to enable those skilled in the art to better understand the technical solutions in this specification, the technical solutions in the embodiments of this specification will be clearly and completely described below in conjunction with the drawings in the embodiments of this specification. Obviously, the described embodiments are only part of the embodiments of this specification, not all of the embodiments. Based on the embodiments in this specification, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of this specification.
[0030] The embodiments of this specification provide data processing methods, devices and equipment. As people pay more and more attention to their private data, in order to protect user privacy and ensure the security of data, it is necessary to encrypt the data to be transmitted. For example, the text data to be transmitted can be converted into ciphertext data through an encryption key, and then the ciphertext data is sent to the data recipient. However, since the ciphertext data is easy to be identified during the data transmission process, the concealment is poor, and the risk of privacy leakage is high, therefore, a technical solution to improve the security of private data during the data transmission process is needed. In this solution, the first text data to be encrypted can be obtained, and according to the preset encoding rules, the first text data can be converted into a first encoding sequence, and according to the preset comparison relationship between the text structure and the encoding value, the target text structure corresponding to each encoding value in the first encoding sequence is determined, and according to the target text structure corresponding to each encoding value, the semantic target text data corresponding to the first text data is generated, and the target text data is sent to the data recipient. In this way, by using the preset comparison relationship between the text structure and the encoding value, the target text data with semantics is generated, which can simplify the encryption operation, reduce the dependence on third-party encryption software, and improve the encryption efficiency. On the other hand, since the generated target text data has semantics, it has high concealment during the data transmission process and is not easily detected by malicious third parties, thereby improving the security of the data transmission process. For specific processing, please refer to the specific content in the following embodiment.
[0031] like Figure 1 As shown, the embodiment of this specification provides a data processing method, the execution subject of the method can be a terminal device or a server, wherein the server can be an independent server, or a server cluster composed of multiple servers, etc. The terminal device can be a device such as a personal computer, or a mobile terminal device such as a mobile phone or a tablet computer. The method can specifically include the following steps:
[0032] In step S102, first text data to be encrypted is obtained, and the first text data is converted into a first coding sequence according to a preset coding rule.
[0033] Among them, the first text data can be any privacy data that needs to be sent to the data recipient and needs to be encrypted. For example, the first text data can be the business data corresponding to the target business triggered by the user. The target business can be a resource transfer business, a user information change business, a user authority change business, and the like. Taking the resource transfer business as an example, the first text data can be the business data required to execute the resource transfer business. Specifically, the first text data can be data such as resource transfer time, resource transfer quantity, resource transfer object, and resource transfer platform. The preset encoding rule can be any rule for converting text data into a coding sequence.
[0034] In implementation, taking the case where the first text data is the business data corresponding to the resource transfer service triggered by the user and the execution subject is a terminal device as an example, when the terminal device detects that the user has triggered the execution of the resource transfer service, it can obtain the business data corresponding to the triggered execution of the resource transfer service (such as resource transfer page data, interaction data between the user and customer service, etc.), and convert the obtained business data into text data to obtain the first text data.
[0035] Then, the terminal device can convert the first text data into a first coding sequence according to the preset coding rule. For example, the server can determine the preset coding rule according to the historical text data corresponding to the target business and the corresponding historical coding sequence, and then encode the first text data according to the preset coding rule to obtain the first coding sequence. In addition, there can be many preset coding rules, and different preset coding rules can be selected according to different actual application scenarios. This embodiment of the specification does not specifically limit this.
[0036] In step S104, the target text structure corresponding to each code value in the first code sequence is determined according to the preset comparison relationship between the text structure and the code value, and according to the target text structure corresponding to each code value, semantic target text data corresponding to the first text data is generated.
[0037] In implementation, taking the encoding values including 0, 1, 2, and 3 as an example, assuming that the first encoding sequence is 1320, the target text structure corresponding to each encoding value in the first encoding sequence can be determined according to the preset comparison relationship between the text structure and the encoding value shown in Table 1 below.
[0038] Table 1
[0039]
[0040] According to the preset comparison relationship between the text structure and the coding value in Table 1 above, it can be determined that the target text structure corresponding to the first coding sequence "1320" is: "subject + adverb + verb", "object + subject + verb", "adverb + verb + object", "subject + verb + object".
[0041] The preset correspondence between the text structure and the code value can be expanded and modified according to actual needs, and is not limited to the four modes in Table 1 above. For example, more complex sentence patterns can be added, or the text structure can be adjusted according to specific language habits. This flexibility can make the encryption method more diverse and difficult to crack, and because of the simple design structure and convenient encryption, the information capacity of the encrypted content can be increased, thereby increasing its useful information transmission capacity (that is, accommodating more information under the same data size).
[0042] The terminal device can generate semantic target text data corresponding to the first text data according to the target text structure. For example, the terminal device can determine the target text data corresponding to the target text structure according to the preset correspondence between the text structure and the text data. Specifically, it is assumed that the preset correspondence between the text structure and the text data is the correspondence shown in Table 2 below.
[0043] Table 2
[0044]
[0045] Then, the terminal device can determine, based on the preset correspondence between the text structure and the text data, that the target text data corresponding to the target text structure is: the cat runs quickly, the cat eats the fish, eats the fish quickly, and the cat eats the fish.
[0046] In addition, the same text structure may correspond to multiple text data, and text data with the target text structure may be randomly selected to construct the target text data.
[0047] The above-mentioned method for generating target text data is an optional and feasible generation method. There may be a variety of different generation methods in actual application scenarios. Different generation methods can be selected according to different actual application scenarios. The embodiments of this specification do not make specific limitations on this.
[0048] In step S106, the target text data is sent to the data recipient.
[0049] In implementation, when there are multiple preset encoding rules, the terminal device or server can send the rule identifier of the preset encoding rule corresponding to the target text data and the target text data to the data recipient. In order to improve data confidentiality, the terminal device or server can also convert the rule identifier of the preset encoding rule into text data with semantic meaning, and insert the converted text data into the preset insertion position of the target text data, and then send the inserted target text data to the data recipient.
[0050] In this way, the data receiver can extract the inserted target text data, obtain the rule identifier corresponding to the preset encoding rule corresponding to the target text data, and then determine the preset decoding rule corresponding to the target text data according to the rule identifier. The target text data is decrypted through the preset decoding rule, text structure and preset comparison relationship of the encoding value to obtain the decrypted text data.
[0051] In addition, when there are multiple preset correspondences between text structures and coding values, the terminal device or server may also insert the relationship identifier of the preset correspondence corresponding to the target text data into the target text data. The specific processing process may refer to the processing process of the above-mentioned rule identifier, which will not be repeated here.
[0052] The embodiment of this specification provides a data processing method, which can obtain the first text data to be encrypted, and convert the first text data into a first coding sequence according to a preset coding rule, determine the target text structure corresponding to each coding value in the first coding sequence according to the preset comparison relationship between the text structure and the coding value, and generate semantic target text data corresponding to the first text data according to the target text structure corresponding to each coding value, and send the target text data to the data recipient. In this way, by generating semantic target text data through the preset comparison relationship between the text structure and the coding value, on the one hand, the encryption operation can be simplified, the dependence on third-party encryption software can be reduced, and the encryption efficiency can be improved. On the other hand, because the generated target text data is semantic, it has a high degree of concealment during the data transmission process and is not easily detected by malicious third parties, thereby improving the security of the data transmission process.
[0053] In practical applications, in the above step S102, according to the preset encoding rule, there are various processing methods for converting the first text data into the first encoding sequence. An optional processing method is provided below, such as Figure 2 , specifically, it may include the processing of the following steps S1022 to S1026.
[0054] In step S1022, the ASCII code corresponding to each character in the first text data is obtained.
[0055] In step S1024, a first encoding result corresponding to the first text data is determined according to the ASCII code corresponding to each character, and the first encoding result is converted into a binary code to obtain a binary encoding result corresponding to the first encoding result.
[0056] In step S1026, a first coding sequence is determined according to the binary coding result.
[0057] In practical applications, there may be various processing methods for determining the first coding sequence according to the binary coding result in the above step S1026. An optional processing method is provided below, which may specifically include the processing of the following step A1.
[0058] In step A1, the binary encoding result is compressed according to a preset compression algorithm to obtain a first encoding sequence.
[0059] In implementation, taking the first text data "Secret Success" as an example, the ASCII code corresponding to each character in the first text data is: Secret: 31192, Secret: 23494, Success: 25104, Success: 21151.
[0060] According to the ASCII code corresponding to each of the above characters, the first encoding result can be obtained as: 31192234942510421151.
[0061] After performing binary conversion processing on the first coding result, a binary coding result corresponding to the first coding result is obtained. The binary code corresponding to each character in the first coding result can be: secret: 0111100111011000, secret: 0101110111010110, success: 0110001000010000, success: 0101001010011111.
[0062] That is, the binary encoding result is: 0111100111011000010111011101011001100010000100000101001010011111.
[0063] The server may compress the binary result according to a preset compression algorithm to obtain a first encoding sequence.
[0064] For example, the server may compress the binary result according to the Huffman coding algorithm, and the obtained first coding sequence may be 0110.
[0065] In addition, there may be a variety of preset compression algorithms, and different compression algorithms may be selected according to different actual application scenarios, which is not specifically limited in the embodiments of this specification.
[0066] In this way, through compression processing, the binary encoding result can be compressed into a first encoding sequence of a preset length.
[0067] In practical applications, in the above step S104, there are various processing methods for generating semantic target text data corresponding to the first text data according to the target text structure corresponding to each code value. An optional processing method is provided below, such as Figure 2 , specifically, the processing of the following steps S1042 may include:
[0068] In step S1042, a pre-trained generation model is used to generate semantic target text data corresponding to the first text data according to the target text structure corresponding to each encoding value.
[0069] The generation model may be a model constructed based on a preset text generation algorithm and used to randomly generate text data with semantics according to the text structure.
[0070] During implementation, the server can determine the target text structure corresponding to each coding value in the first coding sequence based on the preset comparison relationship between the text structure and the coding value, and then use the pre-trained generation model to generate semantic target text data corresponding to the first text data based on the target text structure corresponding to each coding value.
[0071] For example, taking the first coding sequence as 0110, the preset comparison relationship between the text structure and the coding value is as shown in Table 3 below.
[0072] Table 3
[0073]
[0074] The server can determine the target text structure corresponding to each code value in the first coding sequence according to the comparison relationship shown in Table 3, wherein, since the same code value can correspond to different text structures, the server can randomly select the text structure corresponding to the code value. For example, the first coding sequence is 0110, and the text structure corresponding to the code value 0 can be "subject + verb + object" or "subject + adverb + verb". Then, the server can randomly select any of these two text structures as the text structure corresponding to the code value 0, and the obtained target text structure can be: "subject + verb + object", "adverb + verb + object", "adverb + verb + object", "subject + verb + object".
[0075] The server can use a pre-trained generation model to generate semantic target text data corresponding to the first text data according to the target text structure corresponding to each encoding value. For example, the target text data generated for the above target text structure can be: "The cat eats fish, eats fish quickly, eats fish slowly, and the dog bites bones."
[0076] In practical applications, the generation model may also include a first processing layer and a second processing layer. The first processing layer may be used to determine the target text structure corresponding to each coding value in the first coding sequence according to each coding value in the input first coding sequence by a preset comparison relationship between the text structure and the coding value. The second processing layer may be used to generate semantic target text data corresponding to the first text data according to the target text structure corresponding to each coding value of the input.
[0077] In practical applications, in the above step S104, according to the preset comparison relationship between the text structure and the code value, the target text structure corresponding to each code value in the first code sequence is determined, and according to the target text structure corresponding to each code value, a processing method for generating semantic target text data corresponding to the first text data can be various. The following is an optional processing method, such as Figure 2 , specifically, the processing of the following steps S1044 may include:
[0078] In step S1044, a pre-trained generation model is used to determine the target text structure corresponding to each coding value in the first coding sequence according to the preset comparison relationship between the text structure and the coding value, and based on the target text structure corresponding to each coding value, semantic target text data corresponding to the first text data is generated.
[0079] Among them, the pre-trained generation model can be obtained by training a model constructed based on a preset text generation algorithm according to a preset comparison relationship between text structure and coding value, historical coding sequence and corresponding historical text data.
[0080] In implementation, the server can use a pre-trained generation model to determine the target text structure corresponding to each coding value in the first coding sequence according to the preset comparison relationship between the text structure and the coding value as shown in Table 4 below, and generate semantic target text data corresponding to the first text data based on the target text structure corresponding to each coding value.
[0081] Table 4
[0082]
[0083] The same code value can correspond to multiple different text structures. In this way, the unique number of each entry can be identified by a serial number. This number can be used as the first layer of encryption information to identify the code value and text structure corresponding to the text structure. The code value can represent 0 or 1 in the binary encoding result, where the code values 0 and 1 correspond to different text structures. This is the second layer of encryption. The text structure can be used to describe specific grammatical structures or sentence structures in the text. These text structures can correspond to binary encoding results. This is the third layer of encryption. By choosing a simple structure and combining fragmented information, sentence semantic encryption and main state actions can be efficiently obtained. The specific corresponding definitions of text structure and code value can be as follows:
[0084] Among them, subject + verb + object - 0: for example, "the cat eats fish". This text structure is a declarative sentence, which can be used to indicate that the subject performs an action and acts on the object.
[0085] Subject + adverb + verb - 0: For example, "the cat ran quickly", inserting an adverb between the subject and the verb can modify the way the verb proceeds.
[0086] Adverb + Verb + Object-1: For example, "Eat fish quickly", this structure can be used to emphasize the way of action, and the adverb is at the beginning of the sentence.
[0087] Object + Subject + Verb-1: For example, "fish cat eats", which can be a non-standard sentence pattern used to increase concealment, with the positions of subject and object reversed.
[0088] In summary, if Figure 3 As shown, the text encryption process may include the following steps:
[0089] S1. Generate a text structure comparison table (i.e., the preset comparison relationship between text structure and encoding value): The encryption party (i.e., the data sender) and the decryption party (i.e., the data receiver) need to jointly generate a text structure comparison table to define the encoding values corresponding to different text structures.
[0090] S2. The encryption party determines a first encoding result corresponding to the first text data according to the ASCII code corresponding to each character in the first text data to be encrypted, and performs binary conversion on the first encoding result to obtain a binary encoding result corresponding to the first encoding result.
[0091] S3. Generate a code sequence of a preset length: compress the binary code result corresponding to the first text data to be sent using a preset compression algorithm to obtain a compressed binary sequence (ie, the first code sequence).
[0092] S4. Apply the text structure comparison table for encryption: According to the text structure comparison table, the specific text structure pattern in the plaintext is mapped to the binary coding table, that is, according to the text structure comparison table, the target text structure corresponding to each coding value in the first coding sequence is determined, and according to the target text structure corresponding to each coding value, the target text data with semantics corresponding to the first text data is generated.
[0093] S5. Generate encrypted text, that is, target text data.
[0094] In addition, for the convenience of users, an automatic encryption program can be encapsulated.
[0095] Among them, Figure 4 As shown, the encryption process can be divided into four steps:
[0096] S1. Input the original ciphertext, that is, the user inputs the first text data to be encrypted.
[0097] S2. Compress and generate a binary sequence. Use Huffman coding to compress the text and generate a binary sequence, that is, the binary coding result.
[0098] S3. Generate plain text and encrypt it. Generate logical plain text (i.e., the first coding sequence) according to the binary sequence, and encrypt it using the text structure comparison table.
[0099] S4. Output the encrypted text (i.e., target text data), and output the generated encrypted text to the user.
[0100] The method of encrypting text through text structure can use a pre-defined text structure comparison table to map the binary sequence generated by ciphertext compression to a specific text structure, so that the encrypted text still has semantics.
[0101] By generating and applying a text structure comparison table, three layers of encryption can be used without being redundant. Each entry in the text structure comparison table defines the correspondence between binary code (0 or 1) and specific grammatical structure and sentence structure, expanding the capacity of encrypted text information and enhancing the concealment of encrypted information. The encryption party and the decryption party jointly generate and use the comparison table, and use the automatic encryption and decryption program to encrypt and decrypt the content, which is more convenient and quick to use.
[0102] In this way, through the specially designed text structure comparison table, the encrypted content structure can be made simple and clear, the encrypted transmission capacity can be increased, and the three-layer encryption of serial number, code value, and text structure can make the content more concealed. The binary sequence generated by compressing the ciphertext can be mapped to a specific text structure through a specific relationship, so that the encrypted text still has semantics and is difficult to detect. In addition, in order to facilitate user use and enhance user experience, the encapsulated automatic encryption program can make the entire encoding process efficient, so that the encryption process can be completed without the user manually looking up the table, and the operation is simple and convenient.
[0103] The embodiment of this specification provides a data processing method, which can obtain the first text data to be encrypted, and convert the first text data into a first coding sequence according to a preset coding rule, determine the target text structure corresponding to each coding value in the first coding sequence according to the preset comparison relationship between the text structure and the coding value, and generate semantic target text data corresponding to the first text data according to the target text structure corresponding to each coding value, and send the target text data to the data recipient. In this way, by generating semantic target text data through the preset comparison relationship between the text structure and the coding value, on the one hand, the encryption operation can be simplified, the dependence on third-party encryption software can be reduced, and the encryption efficiency can be improved. On the other hand, because the generated target text data is semantic, it has a high degree of concealment during the data transmission process and is not easily detected by malicious third parties, thereby improving the security of the data transmission process.
[0104] like Figure 5 As shown, the embodiment of this specification provides a data processing method, the execution subject of the method can be a terminal device or a server, wherein the server can be an independent server, or a server cluster composed of multiple servers, etc. The terminal device can be a device such as a personal computer, or a mobile terminal device such as a mobile phone or a tablet computer. The method can specifically include the following steps:
[0105] In step S502, target text data is received, and based on the text structure of each sentence in the target text data, the code value corresponding to each sentence in the target text data is determined from a preset comparison relationship between the text structure and the code value.
[0106] In implementation, taking the target text data of "the cat runs fast, the cat eats fish, eats fish quickly, the cat eats fish" as an example, the text structure in the target text data can be: "subject + adverb + verb", "object + subject + verb", "adverb + verb + object", "subject + verb + object".
[0107] Assuming that the preset comparison relationship between the text structure and the coding value is the comparison relationship shown in Table 1 above, then, according to the preset comparison relationship, it can be determined that the coding values corresponding to each sentence in the target text data are 1, 3, 2, and 0 respectively.
[0108] In step S504, a second encoding sequence corresponding to the target text data is constructed according to the encoding value corresponding to each sentence in the target text data.
[0109] In implementation, according to the encoding value corresponding to each sentence in the above target text data, the second encoding sequence corresponding to the target text data is constructed as "1320".
[0110] In step S506, the second coding sequence is decoded to obtain second text data.
[0111] In implementation, the terminal device or server may convert the second encoding sequence "1320" into second text data according to a preset decoding rule.
[0112] Among them, the terminal device or server can also receive a rule identifier of a preset encoding rule corresponding to the target text data sent by the data sender. The terminal device or server can determine the preset decoding rule for decoding the second encoding sequence based on the rule identifier, and decode the second encoding sequence according to the preset decoding rule to obtain the second text data.
[0113] The embodiment of this specification provides a data processing method, which can receive target text data, determine the code value corresponding to each sentence in the target text data from the preset comparison relationship between the text structure and the code value based on the text structure of each sentence in the target text data, construct a second code sequence corresponding to the target text data according to the code value corresponding to each sentence in the target text data, and decode the second code sequence to obtain the second text data. In this way, since the target text data with semantics is generated through the preset comparison relationship between the text structure and the code value, on the one hand, the encryption operation can be simplified, the dependence on third-party encryption software can be reduced, and the encryption efficiency can be improved. On the other hand, since the generated target text data has semantics, it has a high degree of concealment during the data transmission process and is not easily detected by malicious third parties, thereby improving the security of the data transmission process.
[0114] In practical applications, the second code sequence may be a compressed code sequence. In the above step S506, the second code sequence is decoded to obtain the second text data in various ways. An optional processing method is provided below, such as: Figure 6 , specifically, it may include the processing of the following steps S5062~S5066.
[0115] In step S5062, the second coded sequence is decompressed according to a preset decompression algorithm to obtain a third coded sequence.
[0116] In implementation, taking the target text data of "cat eats fish, eats fish quickly, eats fish slowly, and dog bites bones" as an example, assuming that the preset comparison relationship between the text structure and the encoding value is the comparison relationship shown in Table 3 above, then, according to the comparison relationship shown in Table 3 above, it can be determined that the encoding value corresponding to each sentence in the target text data is: "cat eats fish" corresponds to "subject + verb + object", mapped to "0", "eat fish quickly" corresponds to "adverb + verb + object", mapped to "1", "eat fish slowly" corresponds to "adverb + verb + object", mapped to "1", and "dog bites bones" corresponds to "subject + verb + object", mapped to "0".
[0117] According to the preset decompression algorithm, the second code sequence is decompressed, and the obtained third code sequence may be:
[0118] 01111001001101010010111011101011001100010000100000101001000111011.
[0119] In step S5064, the third coding sequence is segmented according to the number of coding bits corresponding to the ASCII code to obtain multiple subsequences.
[0120] In step S5066, the character corresponding to each subsequence is determined according to the ASCII code corresponding to each subsequence, and the second text data is determined according to the character corresponding to each subsequence.
[0121] In implementation, the server or terminal device may segment the third coding sequence according to the number of coding bits corresponding to the ASCII code (eg, 16 bits) to obtain multiple subsequences, and then determine the character corresponding to each subsequence according to the ASCII code corresponding to each subsequence.
[0122] For example, the ASCII codes corresponding to the multiple subsequences obtained by dividing the third encoding sequence may be:
[0123] 01111001001101010 ->31192
[0124] 0101110111010110 -> 23494
[0125] 0110001000010000 ->25104
[0126] 0101001000111011 ->21151
[0127] According to the ASCII code corresponding to each subsequence, the character corresponding to each subsequence is determined, and according to the character corresponding to each subsequence, the determined second text data may be: "Secret Success".
[0128] In this way, Figure 7 As shown, the data receiver can reverse parse the binary code of the ciphertext according to the text structure in the received text file, and decompress and restore the original text.
[0129] In addition, if Figure 8 As shown, for the convenience of users, an automatic decryption program can be encapsulated.
[0130] S1. Read encrypted text. The program reads the encrypted text entered by the user.
[0131] S2. Parse the binary code and parse the binary code according to the text structure comparison table.
[0132] S3, decompress and restore the ciphertext, and restore the original ciphertext through the decompression algorithm.
[0133] S4. Output the decrypted plaintext: output the decrypted plaintext to the user.
[0134] In this way, by using the text structure for encryption, an efficient, secure and highly concealed text encryption and decryption method is realized. It can not only significantly improve the confidentiality of electronic texts and prevent the leakage of sensitive information, but also realize convenient encryption and decryption operations without complex algorithms and high cost investment. It is suitable for occasions such as enterprises and government agencies that require high confidentiality, such as local encryption and decryption operations of confidential files. For enterprises, it can effectively protect business secrets and internal files, prevent competitors from stealing information, and thus enhance competitive advantages. For government departments and security agencies, it can ensure the security of sensitive data during transmission and storage, and prevent the leakage of confidential information. In summary, this application has broad commercial application prospects and significant commercial value potential, can meet the confidentiality needs in a variety of occasions, and is suitable for multiple industries and fields.
[0135] In practical applications, the second text data may be business data corresponding to the target business that is triggered by the user, and business processing may be performed according to the second text data. There are many ways to process the business. An optional processing method is provided below, such as Figure 6 As shown, the process may specifically include the following step S602.
[0136] In step S602, the target service is processed according to the second text data, and the service processing result is returned to the data sender.
[0137] The target business may be any business that may have a risk of privacy data leakage, for example, the target business may be a resource transfer business, a user information change business, a user authority change business, a database access business, etc.
[0138] The embodiment of this specification provides a data processing method, which can receive target text data, determine the code value corresponding to each sentence in the target text data from the preset comparison relationship between the text structure and the code value based on the text structure of each sentence in the target text data, construct a second code sequence corresponding to the target text data according to the code value corresponding to each sentence in the target text data, and decode the second code sequence to obtain the second text data. In this way, since the target text data with semantics is generated through the preset comparison relationship between the text structure and the code value, on the one hand, the encryption operation can be simplified, the dependence on third-party encryption software can be reduced, and the encryption efficiency can be improved. On the other hand, since the generated target text data has semantics, it has a high degree of concealment during the data transmission process and is not easily detected by malicious third parties, thereby improving the security of the data transmission process.
[0139] The above is a data processing method provided in the embodiment of this specification. Based on the same idea, the embodiment of this specification also provides a data processing device, such as Fig. 9 shown.
[0140] The data processing device comprises: a first encoding module 901, a text generating module 902 and a data sending module 903, wherein:
[0141] The first encoding module 901 is used to obtain first text data to be encrypted and convert the first text data into a first encoding sequence according to a preset encoding rule;
[0142] A text generation module 902 is used to determine the target text structure corresponding to each code value in the first code sequence according to a preset comparison relationship between the text structure and the code value, and generate semantic target text data corresponding to the first text data according to the target text structure corresponding to each code value;
[0143] The data sending module 903 is used to send the target text data to a data receiver.
[0144] In the embodiment of this specification, the first encoding module 901 is used to:
[0145] Obtaining the ASCII code corresponding to each character in the first text data;
[0146] Determine a first encoding result corresponding to the first text data according to the ASCII code corresponding to each of the characters, and perform binary conversion processing on the first encoding result to obtain a binary encoding result corresponding to the first encoding result;
[0147] The first coding sequence is determined according to the binary coding result.
[0148] In the embodiment of this specification, the first encoding module 901 is used to:
[0149] According to a preset compression algorithm, the binary encoding result is compressed to obtain the first encoding sequence. In the embodiment of this specification, the text generation module 902 is used to:
[0150] Using a pre-trained generation model, target text data with semantics corresponding to the first text data is generated according to the target text structure corresponding to each of the encoding values. The generation model is a model constructed based on a preset text generation algorithm and is used to randomly generate semantic text data according to the text structure.
[0151] In the embodiment of this specification, the text generation module 902 is used to:
[0152] Using a pre-trained generation model, according to the preset contrast relationship between the text structure and the code value, the target text structure corresponding to each code value in the first code sequence is determined, and according to the target text structure corresponding to each code value, semantic target text data corresponding to the first text data is generated. The pre-trained generation model is obtained by training a model constructed based on a preset text generation algorithm according to the preset contrast relationship between the text structure and the code value, the historical code sequence and the corresponding historical text data.
[0153] The embodiment of this specification provides a data processing device, which can obtain first text data to be encrypted, and convert the first text data into a first coding sequence according to a preset coding rule, determine the target text structure corresponding to each coding value in the first coding sequence according to the preset comparison relationship between the text structure and the coding value, and generate semantic target text data corresponding to the first text data according to the target text structure corresponding to each coding value, and send the target text data to the data recipient. In this way, by generating semantic target text data through the preset comparison relationship between the text structure and the coding value, on the one hand, the encryption operation can be simplified, the dependence on third-party encryption software can be reduced, and the encryption efficiency can be improved. On the other hand, because the generated target text data is semantic, it has a high degree of concealment during the data transmission process and is not easily detected by malicious third parties, thereby improving the security of the data transmission process.
[0154] The above is a data processing method provided in the embodiment of this specification. Based on the same idea, the embodiment of this specification also provides a data processing device, such as Fig.10 shown.
[0155] The data processing device comprises: a data receiving module 1001, a second encoding module 1002 and a text conversion module 1003, wherein:
[0156] The data receiving module 1001 is used to receive target text data, and determine the code value corresponding to each sentence in the target text data from a preset comparison relationship between the text structure and the code value based on the text structure of each sentence in the target text data;
[0157] A second encoding module 1002, configured to construct a second encoding sequence corresponding to the target text data according to the encoding value corresponding to each sentence in the target text data;
[0158] The text conversion module 1003 is used to decode the second coding sequence to obtain second text data.
[0159] In the embodiment of this specification, the second coding sequence is a compressed coding sequence, and the text conversion module 1003 is used to:
[0160] Decompressing the second coded sequence according to a preset decompression algorithm to obtain a third coded sequence;
[0161] Segmenting the third coding sequence according to the number of coding bits corresponding to the ASCII code to obtain a plurality of subsequences;
[0162] According to the ASCII code corresponding to each of the subsequences, the character corresponding to each of the subsequences is determined, and according to the character corresponding to each of the subsequences, the second text data is determined.
[0163] In the embodiment of this specification, the second text data is service data corresponding to the target service triggered by the user, and the device further includes:
[0164] The service processing module is used to process the target service according to the second text data and return the service processing result to the data sender.
[0165] The embodiments of this specification provide a data processing device, which generates semantic target text data through a preset comparison relationship between text structure and coding value. On the one hand, it can simplify encryption operations, reduce dependence on third-party encryption software, and improve encryption efficiency. On the other hand, since the generated target text data is semantic, it has a high degree of concealment during data transmission and is not easily detected by malicious third parties, thereby improving the security of the data transmission process.
[0166] The above is a data processing device provided in the embodiment of this specification. Based on the same idea, the embodiment of this specification also provides a data processing device, such as Fig.11 shown.
[0167] The data processing device may provide a terminal device or a server, etc. for the above-mentioned embodiments.
[0168] The data processing device may have relatively large differences due to different configurations or performances, and may include one or more processors 1101 and memory 1102, and the memory 1102 may store one or more storage applications or data. Among them, the memory 1102 may be a short-term storage or a persistent storage. The application stored in the memory 1102 may include one or more modules (not shown in the figure), and each module may include a series of computer executable instructions in the data processing device. Furthermore, the processor 1101 may be configured to communicate with the memory 1102 and execute a series of computer executable instructions in the memory 1102 on the data processing device. The data processing device may also include one or more power supplies 1103, one or more wired or wireless network interfaces 1104, one or more input and output interfaces 1105, and one or more keyboards 1106.
[0169] Specifically in this embodiment, the data processing device includes a memory and one or more programs, wherein the one or more programs are stored in the memory, and the one or more programs may include one or more modules, and each module may include a series of computer executable instructions in the data processing device, and the one or more programs are configured to be executed by one or more processors, including computer executable instructions for performing the following:
[0170] Acquire first text data to be encrypted, and convert the first text data into a first coding sequence according to a preset coding rule;
[0171] Determine the target text structure corresponding to each code value in the first code sequence according to a preset comparison relationship between the text structure and the code value, and generate semantically-significant target text data corresponding to the first text data according to the target text structure corresponding to each code value;
[0172] The target text data is sent to a data receiver.
[0173] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the data processing device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0174] Specifically in this embodiment, the data processing device includes a memory and one or more programs, wherein the one or more programs are stored in the memory, and the one or more programs may include one or more modules, and each module may include a series of computer executable instructions in the data processing device, and the one or more programs are configured to be executed by one or more processors, including computer executable instructions for performing the following:
[0175] Receive target text data, and determine, based on the text structure of each sentence in the target text data, a code value corresponding to each sentence in the target text data from a preset comparison relationship between the text structure and the code value;
[0176] Constructing a second encoding sequence corresponding to the target text data according to the encoding value corresponding to each sentence in the target text data;
[0177] The second coding sequence is decoded to obtain second text data.
[0178] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the data processing device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0179] The embodiments of this specification provide a data processing device, which generates semantic target text data through a preset comparison relationship between text structure and coding value. On the one hand, it can simplify encryption operations, reduce dependence on third-party encryption software, and improve encryption efficiency. On the other hand, since the generated target text data is semantic, it has a high degree of concealment during data transmission and is not easily detected by malicious third parties, thereby improving the security of the data transmission process.
[0180] Furthermore, based on the above Figures 1 to 8In one embodiment, the present specification further provides a storage medium for storing computer executable instruction information. In a specific embodiment, the storage medium may be a USB flash drive, an optical disk, a hard disk, etc. When the computer executable instruction information stored in the storage medium is executed by the processor, the following process can be implemented:
[0181] Acquire first text data to be encrypted, and convert the first text data into a first coding sequence according to a preset coding rule;
[0182] Determine the target text structure corresponding to each code value in the first code sequence according to a preset comparison relationship between the text structure and the code value, and generate semantically-significant target text data corresponding to the first text data according to the target text structure corresponding to each code value;
[0183] The target text data is sent to a data receiver.
[0184] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the above-mentioned storage medium embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0185] Furthermore, based on the above Figures 1 to 8 In one embodiment, the present specification further provides a storage medium for storing computer executable instruction information. In a specific embodiment, the storage medium may be a USB flash drive, an optical disk, a hard disk, etc. When the computer executable instruction information stored in the storage medium is executed by the processor, the following process can be implemented:
[0186] Receive target text data, and determine, based on the text structure of each sentence in the target text data, a code value corresponding to each sentence in the target text data from a preset comparison relationship between the text structure and the code value;
[0187] Constructing a second encoding sequence corresponding to the target text data according to the encoding value corresponding to each sentence in the target text data;
[0188] The second coding sequence is decoded to obtain second text data.
[0189] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the above-mentioned storage medium embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0190] The embodiments of this specification provide a storage medium, which generates semantic target text data through a preset comparison relationship between text structure and coding value. On the one hand, it can simplify encryption operations, reduce dependence on third-party encryption software, and improve encryption efficiency. On the other hand, since the generated target text data is semantic, it has a high degree of concealment during data transmission and is not easily detected by malicious third parties, thereby improving the security of the data transmission process.
[0191] Furthermore, based on the above Figures 1 to 8 In one or more embodiments of the present specification, a computer program product is provided, including a computer program. When the computer program in the computer program product is executed by a processor, the following process can be implemented:
[0192] Acquire first text data to be encrypted, and convert the first text data into a first coding sequence according to a preset coding rule;
[0193] Determine the target text structure corresponding to each code value in the first code sequence according to a preset comparison relationship between the text structure and the code value, and generate semantically-significant target text data corresponding to the first text data according to the target text structure corresponding to each code value;
[0194] The target text data is sent to a data receiver.
[0195] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the above-mentioned computer program product embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0196] Furthermore, based on the above Figures 1 to 8 In one or more embodiments of the present specification, a computer program product is provided, including a computer program. When the computer program in the computer program product is executed by a processor, the following process can be implemented:
[0197] Receive target text data, and determine, based on the text structure of each sentence in the target text data, a code value corresponding to each sentence in the target text data from a preset comparison relationship between the text structure and the code value;
[0198] Constructing a second encoding sequence corresponding to the target text data according to the encoding value corresponding to each sentence in the target text data;
[0199] The second coding sequence is decoded to obtain second text data.
[0200] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the above-mentioned computer program product embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0201] The embodiments of this specification provide a computer program product that generates semantic target text data through a preset comparison relationship between text structure and coding value. On the one hand, it can simplify encryption operations, reduce dependence on third-party encryption software, and improve encryption efficiency. On the other hand, since the generated target text data is semantic, it has a high degree of concealment during data transmission and is not easily detected by malicious third parties, thereby improving the security of the data transmission process.
[0202] The above is a description of a specific embodiment of the specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the embodiments and still achieve the desired results. In addition, the processes depicted in the drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0203] In the 1990s, it was very clear whether the improvement of a technology was hardware improvement (for example, improvement of the circuit structure of diodes, transistors, switches, etc.) or software improvement (improvement of the method flow). However, with the development of technology, many improvements of the method flow today can be regarded as direct improvements of the hardware circuit structure. Designers almost always obtain the corresponding hardware circuit structure by programming the improved method flow into the hardware circuit. Therefore, it cannot be said that the improvement of a method flow cannot be implemented with a hardware entity module. For example, a programmable logic device (PLD) (such as a field programmable gate array (FPGA)) is such an integrated circuit whose logical function is determined by the user's programming of the device. Designers can "integrate" a digital system on a PLD by programming themselves, without having to ask chip manufacturers to design and make dedicated integrated circuit chips. Moreover, nowadays, instead of manually making integrated circuit chips, this kind of programming is mostly implemented by "logic compiler" software, which is similar to the software compiler used when developing and writing programs, and the original code before compilation must also be written in a specific programming language, which is called hardware description language (HDL). There is not only one kind of HDL, but many kinds, such as ABEL (Advanced Boolean Expression Language), AHDL (Altera Hardware Description Language), Confluence, CUPL (Cornell University Programming Language), HDCal, JHDL (Java Hardware Description Language), Lava, Lola, MyHDL, PALASM, RHDL (Ruby Hardware Description Language), etc. The most commonly used ones are VHDL (Very-High-Speed Integrated Circuit Hardware Description Language) and Verilog. Those skilled in the art should also know that it is only necessary to program the method flow slightly in the above-mentioned hardware description languages and program it into the integrated circuit, and then it is easy to obtain the hardware circuit that implements the logic method flow.
[0204] The controller may be implemented in any suitable manner, for example, the controller may take the form of a microprocessor or processor and a computer-readable medium storing a computer-readable program code (e.g., software or firmware) executable by the (micro)processor, a logic gate, a switch, an application-specific integrated circuit (ASIC), a programmable logic controller, and an embedded microcontroller, examples of which include but are not limited to the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicone Labs C8051F320, and the memory controller may also be implemented as part of the control logic of the memory. It is also known to those skilled in the art that, in addition to implementing the controller in a purely computer-readable program code manner, the controller may be implemented in the form of a logic gate, a switch, an application-specific integrated circuit, a programmable logic controller, and an embedded microcontroller by logically programming the method steps. Therefore, such a controller may be considered as a hardware component, and the devices for implementing various functions included therein may also be considered as structures within the hardware component. Or even, the devices for implementing various functions may be considered as both software modules for implementing the method and structures within the hardware component.
[0205] The systems, devices, modules or units described in the above embodiments may be implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer. Specifically, the computer may be, for example, a personal computer, a laptop computer, a cellular phone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.
[0206] For the convenience of description, the above devices are described in terms of functions and are divided into various units. Of course, when implementing one or more embodiments of this specification, the functions of each unit can be implemented in the same or multiple software and / or hardware.
[0207] Those skilled in the art will appreciate that the embodiments of this specification may be provided as methods, systems, or computer program products. Therefore, one or more embodiments of this specification may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, one or more embodiments of this specification may take 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.) containing computer-usable program codes.
[0208] The embodiments of this specification are described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to the embodiments of this specification. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of processes and / or boxes in the flowchart and / or 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 fraud case serial and parallel device to produce a machine, so that the instructions executed by the processor of the computer or other programmable fraud case serial and parallel device generate instructions for implementing the processes in the process. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0209] These computer program instructions may also be stored in a computer readable memory capable of directing a computer or other programmable fraud case serial and parallel device to operate in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0210] These computer program instructions may also be loaded onto a computer or other programmable device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, whereby the instructions executed on the computer or other programmable device provide for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0211] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0212] Memory may include non-permanent storage in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. Memory is an example of a computer-readable medium.
[0213] Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be 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 disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined in this article, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.
[0214] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.
[0215] Those skilled in the art will appreciate that the embodiments of this specification may be provided as methods, systems or computer program products. Therefore, one or more embodiments of this specification may be in the form of a complete hardware embodiment, a complete software embodiment or an embodiment combining software and hardware. Furthermore, one or more embodiments of this specification may be in 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.) containing computer-usable program code.
[0216] One or more embodiments of the present specification may be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform specific tasks or implement specific abstract data types. One or more embodiments of the present specification may also be practiced in distributed computing environments where tasks are performed by remote processing devices connected through a communication network. In a distributed computing environment, program modules may be located in local and remote computer storage media, including storage devices.
[0217] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0218] The above description is only an embodiment of this specification and is not intended to limit this document. For those skilled in the art, this specification may have various changes and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of this specification should be included in the scope of the claims of this specification.
Claims
1. A data processing method, characterized in that: The method comprises: Acquire first text data to be encrypted, and convert the first text data into a first coding sequence according to a preset coding rule; Determine the target text structure corresponding to each code value in the first code sequence according to a preset comparison relationship between the text structure and the code value, and generate semantically-significant target text data corresponding to the first text data according to the target text structure corresponding to each code value; The target text data is sent to a data receiver.
2. The method according to claim 1, characterized in that The step of converting the first text data into a first coding sequence according to a preset coding rule includes: Obtaining the ASCII code corresponding to each character in the first text data; Determine a first encoding result corresponding to the first text data according to the ASCII code corresponding to each of the characters, and perform binary conversion processing on the first encoding result to obtain a binary encoding result corresponding to the first encoding result; The first coding sequence is determined according to the binary coding result.
3. The method according to claim 2, characterized in that The determining the first coding sequence according to the binary coding result includes: The binary encoding result is compressed according to a preset compression algorithm to obtain the first encoding sequence.
4. The method according to claim 3, characterized in that The step of determining the target text structure corresponding to each code value in the first code sequence according to a preset comparison relationship between the text structure and the code value, and generating semantically-sound target text data corresponding to the first text data according to the target text structure corresponding to each code value, comprises: Using a pre-trained generation model, according to the preset contrast relationship between the text structure and the code value, the target text structure corresponding to each code value in the first code sequence is determined, and according to the target text structure corresponding to each code value, semantic target text data corresponding to the first text data is generated. The pre-trained generation model is obtained by training a model constructed based on a preset text generation algorithm according to the preset contrast relationship between the text structure and the code value, the historical code sequence and the corresponding historical text data.
5. The method according to claim 4, characterized in that The generation model includes a first processing layer and a second processing layer. The first processing layer is used to determine the target text structure corresponding to each code value in the first coding sequence according to each code value in the first coding sequence input by a preset comparison relationship between the text structure and the code value. The second processing layer is used to generate semantic target text data corresponding to the first text data according to the target text structure corresponding to each code value input.
6. A data processing method, characterized in that: The method comprises: Receive target text data, and determine, based on the text structure of each sentence in the target text data, a code value corresponding to each sentence in the target text data from a preset comparison relationship between the text structure and the code value; Constructing a second encoding sequence corresponding to the target text data according to the encoding value corresponding to each sentence in the target text data; The second coding sequence is decoded to obtain second text data.
7. The method according to claim 6, characterized in that The second coding sequence is a compressed coding sequence, and the decoding process of the second coding sequence to obtain the second text data includes: Decompressing the second coded sequence according to a preset decompression algorithm to obtain a third coded sequence; Segmenting the third coding sequence according to the number of coding bits corresponding to the ASCII code to obtain multiple subsequences; According to the ASCII code corresponding to each of the subsequences, the character corresponding to each of the subsequences is determined, and according to the character corresponding to each of the subsequences, the second text data is determined.
8. The method according to claim 6, characterized in that The second text data is business data corresponding to the target business triggered by the user, and the method further includes: The target service is processed according to the second text data, and the service processing result is returned to the data sender.
9. A data processing device, characterized in that: The device comprises: A first encoding module, used for acquiring first text data to be encrypted, and converting the first text data into a first encoding sequence according to a preset encoding rule; A text generation module, used to determine the target text structure corresponding to each code value in the first code sequence according to a preset comparison relationship between the text structure and the code value, and generate semantic target text data corresponding to the first text data according to the target text structure corresponding to each code value; The data sending module is used to send the target text data to a data receiver.
10. A data processing device, characterized in that: The device comprises: A data receiving module, used for receiving target text data, and determining, based on the text structure of each sentence in the target text data, the code value corresponding to each sentence in the target text data from a preset comparison relationship between the text structure and the code value; A second encoding module, used to construct a second encoding sequence corresponding to the target text data according to the encoding value corresponding to each sentence in the target text data; The text conversion module is used to decode the second coding sequence to obtain second text data.
11. A data processing device, characterized in that: The method comprises a processor, a memory and a computer program stored in the memory and executable on the processor, wherein the computer program implements the steps of the data processing method according to any one of claims 1 to 8 when executed by the processor.
12. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the data processing method according to any one of claims 1 to 8 are implemented.
13. A computer program product, characterized in that The invention comprises a computer program, which implements the steps of the data processing method according to any one of claims 1 to 8 when being executed by a processor.
Citation Information
Patent Citations
Language model pre-training method and device, medium and electronic equipment
CN118690848A
Risk control model training method and device and readable storage medium
CN118691072A