Method and device for extracting triple data based on field of Internet of Things, and server
By combining relative position coding and large language model of data text in the field of IoT, the problem of low accuracy of triple data extraction in the prior art is solved, and higher accuracy and accuracy of extraction are achieved.
Patent Information
- Application Number
- CN202411814700.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-10
- Publication Date
- 2025-03-21
AI Technical Summary
The prior art ignores context information in triplet data extraction in the field of IoT, resulting in low accuracy of extraction.
By encoding the data text pairs relative position, combining large language models to obtain text of entity data, relational data or event data from IoT data, and extracting the initial triple data using predefined entity types and prompt word templates, and finally determining the final triple data through similarity calculation.
The accuracy of triple data extraction is improved, and the accuracy of data extraction is enhanced by considering the relative positional relationship and context information between the data.
Smart Images

Figure CN119670871A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of Internet of Things, and in particular to a method, device and server for extracting triplet data based on the Internet of Things field. Background Art
[0002] With the widespread use of IoT cards, their security monitoring and control has become extremely important. In order to effectively deal with these security risks, a technical means is needed that can deeply understand the characteristics and business logic of the IoT industry. The training of IoT industry large models is the key to meeting this demand, and accurate triplet data sets are the basis for training IoT industry large models.
[0003] Currently, existing technologies only focus on sentence-level information and ignore important contextual information, which affects the accuracy of triple data extraction. Summary of the invention
[0004] The embodiments of the present application provide a method, device and server for extracting triplet data based on the field of Internet of Things, so as to achieve the effect of improving the accuracy of extracting triplet data.
[0005] In a first aspect, an embodiment of the present application provides a method for extracting triple data based on the field of Internet of Things, including: collecting Internet of Things data from an Internet of Things data platform; marking multiple data-text pairs based on the Internet of Things data; obtaining multiple data-text pairs with relative position encodings based on the relative position deviation value of each data-text pair; obtaining text containing entity data, relationship data or event data from the Internet of Things data based on a large language model; inputting predefined entity types and text containing entity data, relationship data or event data into a prompt word template, and extracting multiple initial triple data through the prompt word template; wherein the predefined entity types set the entity data to be extracted first; obtaining final triple data based on multiple data-text pairs with relative position encodings and multiple initial triple data.
[0006] In one possible implementation, based on the relative position deviation value of each data text pair, multiple data text pairs with relative position encoding are obtained, including: adding the relative position deviation value of each data text pair to the encoding vector of each data text pair to obtain multiple data text pairs with relative position encoding.
[0007] In a possible implementation, the relative position deviation value of each data text pair is expressed as follows:
[0008]
[0009] In the formula, Relative position deviation value. Represents the text length measurement, Indicates the average text length.
[0010] In one possible implementation, a predefined entity type and text containing entity data, relationship data, or event data are input into a prompt word template, and multiple initial triple data are extracted through the prompt word template, including: the prompt word template determines whether there is a predefined entity type in the text containing entity data, relationship data, or event data; if so, outputting multiple initial triple data based on the existing entity type.
[0011] In a possible implementation, final triple data is obtained based on multiple data text pairs with relative position encodings and multiple initial triple data, including: calculating the similarity value of each initial triple data based on multiple data text pairs with relative position encodings; and determining the initial triple data with a similarity value higher than a preset similarity value as the final triple data.
[0012] In a second aspect, an embodiment of the present application provides a device for extracting triplet data based on the field of Internet of Things, including:
[0013] The collection module is used to collect IoT data from the IoT data platform.
[0014] The annotation module is used to annotate multiple data text pairs based on IoT data.
[0015] The first acquisition module is used to obtain a plurality of data text pairs with relative position codes according to the relative position deviation value of each data text pair.
[0016] The second acquisition module is used to acquire text containing entity data, relationship data or event data from IoT data based on the large language model.
[0017] The extraction module is used to input the predefined entity type and the text containing entity data, relationship data or event data into the prompt word template, and extract multiple initial triplet data through the prompt word template; wherein the predefined entity type sets the entity data to be extracted first.
[0018] The third acquisition module is used to obtain final triple data based on multiple data text pairs with relative position encoding and multiple initial triple data.
[0019] In a possible implementation, the first acquisition module is used to add the relative position deviation value of each data text pair to the encoding vector of each data text pair to obtain multiple data text pairs with relative position encoding.
[0020] In a third aspect, an embodiment of the present application provides a server, including: a memory, a processor;
[0021] The memory stores computer-executable instructions;
[0022] The processor executes the computer-executable instructions stored in the memory, so that the processor executes the above first aspect and / or various possible implementations of the first aspect.
[0023] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, in which computer-executable instructions are stored. When the computer-executable instructions are executed by a processor, they are used to implement the first aspect above and / or various possible implementations of the first aspect.
[0024] In a fifth aspect, an embodiment of the present application provides a computer program product, including a computer program, which, when executed by a processor, implements the above first aspect and / or various possible implementation methods of the first aspect.
[0025] The method, device and server for extracting triple data based on the field of Internet of Things provided by the embodiment of the present application mark multiple data text pairs according to the Internet of Things data; position encode the data text pairs to obtain multiple data text pairs with relative position encoding; based on the large language model, obtain the text of the entity data, relationship data or event data from the Internet of Things data. The predefined entity type and the text of the entity data, relationship data or event data are input into the prompt word template, and the prompt word template extracts multiple initial triple data. Through the data text pairs with relative position encoding, the multiple initial triple data are verified to obtain the final triple data, thereby improving the accuracy of extracting triple data. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0027] Figure 1 A schematic diagram of the structure of a server provided in an embodiment of the present application;
[0028] Figure 2 A flow chart of a method for extracting triplet data based on the Internet of Things provided in an embodiment of the present application;
[0029] Figure 3 A schematic diagram of the structure of a device for extracting triplet data based on the Internet of Things provided in an embodiment of the present application;
[0030] Figure 4 A schematic diagram of the hardware structure of the server provided in an embodiment of the present application.
[0031] The above drawings have shown clear embodiments of the present application, which will be described in more detail later. These drawings and text descriptions are not intended to limit the scope of the present application in any way, but to illustrate the concept of the present application to those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION
[0032] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present application. Instead, they are merely examples of devices and methods consistent with some aspects of the present application as detailed in the appended claims.
[0033] Figure 1 A schematic diagram of the structure of the server provided in the embodiment of the present application, such as Figure 1 As shown, the server provided in this embodiment includes: a receiving device 101, a processor 102 and a display device 103.
[0034] It is to be understood that the structure illustrated in the embodiment of the present application does not constitute a specific limitation on the method. In other feasible implementations of the present application, the above architecture may include more or fewer components than shown in the figure, or combine certain components, or split certain components, or arrange the components differently, which can be determined according to the actual application scenario and is not limited here. Figure 1 The components shown may be implemented in hardware, software, or a combination of software and hardware.
[0035] In the specific implementation process, the receiving device 101 can be an input / output interface or a communication interface, and can collect IoT data from the IoT data platform.
[0036] The processor 102 may process the IoT data collected from the IoT data platform to obtain triplet data from the IoT data.
[0037] The display device 103 can be used to display triple data.
[0038] It should be understood that the above-mentioned processor can be implemented by the processor reading instructions in the memory and executing the instructions, or it can be implemented by a chip circuit.
[0039] In addition, the network architecture and business scenarios described in the embodiments of the present application are intended to more clearly illustrate the technical solutions of the embodiments of the present application, and do not constitute a limitation on the technical solutions provided in the embodiments of the present application. Ordinary technicians in this field can know that with the evolution of network architecture and the emergence of new business scenarios, the technical solutions provided in the embodiments of the present application are also applicable to similar technical problems.
[0040] With the widespread use of IoT cards, their security monitoring and control has become extremely important. In order to effectively deal with these security risks, a technical means is needed that can deeply understand the characteristics and business logic of the IoT industry. The training of large models in the IoT industry is the key to meeting this demand, and accurate triplet datasets are the basis for training large models in the IoT industry. At present, existing technologies only focus on sentence-level information, ignoring important contextual information, which affects the accuracy of triplet data extraction.
[0041] In order to solve the above technical problems, the present application proposes the following technical ideas: relative position encoding is performed on data-text pairs, taking into account the relative position relationship between the data. In the process of triple data extraction, entity data, relationship data and event data are considered at the same time. Based on the large language model, the text containing entity data, relationship data or event data is obtained from the IoT data. The pre-defined entity types and the text containing entity data, relationship data or event data are input into the prompt word template, and the prompt word template extracts multiple initial triple data. Through data-text pairs with relative position encoding, multiple initial triple data are verified to obtain the final triple data, thereby improving the accuracy of extracting triple data.
[0042] The technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems are described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.
[0043] Figure 2 A flow chart of a method for extracting triplet data based on the Internet of Things provided in an embodiment of the present application is shown in FIG. Figure 2 As shown, the method includes:
[0044] S201: Collect IoT data from the IoT data platform.
[0045] In this embodiment, the collection work is carried out under the Spark framework. Spark is a fast general computing engine for large-scale data processing and can process data efficiently.
[0046] In this embodiment, the IoT data includes real-time streaming call bill data, real-time streaming location data, offline attribute data, account data, roaming data, traffic data, SMS data and other billing data.
[0047] S202: Label multiple data-text pairs according to IoT data.
[0048] In this embodiment, the IoT data is sorted and labeled with data text pairs such as <card number XX, account XX, customer XX>, <card number XX, roaming location XX, attribute XX>, etc.
[0049] Optionally, save in the following format:
[0050]
[0051] S203: According to the relative position deviation value of each data text pair, a plurality of data text pairs with relative position coding are obtained.
[0052] Specifically, the relative position deviation value of each data-text pair is added to the encoding vector of each data-text pair to obtain a plurality of data-text pairs with relative position encoding.
[0053] In this embodiment, relative position encoding is performed on each data text pair through jump position encoding, and a relative position deviation is introduced into the encoding vector to obtain a data text pair with relative position encoding.
[0054] Among them, relative position encoding focuses on representing the relative position relationship between data, which is suitable for processing tasks with complex position relationships and ultimately generates diverse data-text pairs. When processing IoT data, due to the complexity and diversity of data sources and formats, the position relationship between data is crucial to understanding data semantics.
[0055] Specifically, the formula for the relative position deviation value of each data text pair is:
[0056]
[0057] In the formula, Relative position deviation value. Represents the text length measurement, Indicates the average text length.
[0058] S204: Based on the large language model, obtain text containing entity data, relationship data, or event data from the IoT data.
[0059] In this embodiment, the IoT data is input into a large language model (LLM), and the text of entity data, relationship data, or event data is obtained from the IoT data based on the LLM. In this way, unnecessary information can be filtered out in advance to reduce the search and calculation complexity.
[0060] S205: Input the predefined entity type and the text containing entity data, relationship data or event data into the prompt word template, and extract a plurality of initial triplet data through the prompt word template; wherein the predefined entity type sets the entity data to be extracted first.
[0061] Specifically, the prompt word template determines whether there is a predefined entity type in the text containing entity data, relationship data or event data; if so, a plurality of initial triplet data are output according to the existing entity type.
[0062] Optionally, if it is determined that there is no predefined entity type in the text of entity data, relationship data or event data, then "None" is output.
[0063] In this embodiment, a question template chain is designed in the predefined entity type, that is, the extraction of a certain entity data depends on the extraction of previous entity data, and the entity data that needs to be extracted first is set.
[0064] S206: Obtain final triple data according to multiple data text pairs with relative position encoding and multiple initial triple data.
[0065] Specifically, based on a plurality of data text pairs with relative position encodings, a similarity value of each initial triple data is calculated; and the initial triple data with a similarity value higher than a preset similarity value is determined as the final triple data.
[0066] In this embodiment, the similarity value of each initial triple data is calculated based on multiple data text pairs with relative position encoding. For example, a similarity calculation method based on a vector space model is used to convert the data text pairs and the initial triple data into vector representations, and then the similarity value of the initial triple data is calculated by calculating the distance between the vectors, such as cosine similarity. It is also possible to use a method based on edit distance to calculate the similarity value.
[0067] Exemplarily, the "card number" identified in the data text pair needs to be accurately matched with the corresponding "card number" entity in the initial triple data to check whether they are consistent and semantically correspond to each other. At the same time, the relationship description between the data in the data text pair is analyzed based on the relative position coding in the data text pair to see whether it is consistent with the relationship reflected in the initial triple data. For example, if the close association between "card number" and "roaming place" is expressed by the jump position coding in the data text pair, then there should also be a reasonable logical relationship in the initial triple data to link these two entity data, otherwise it will affect the judgment of similarity. Based on the data text pair corresponding to each initial triple data, the similarity value of each initial triple data is calculated.
[0068] In summary, based on IoT data, multiple data-text pairs are annotated; the data-text pairs are position-encoded to obtain multiple data-text pairs with relative position encoding; based on the large language model, texts with entity data, relationship data or event data are obtained from IoT data. The pre-defined entity types and texts with entity data, relationship data or event data are input into the prompt word template, and the prompt word template extracts multiple initial triple data. Multiple initial triple data are verified through data-text pairs with relative position encoding to obtain the final triple data, which improves the accuracy of extracting triple data.
[0069] Based on the above embodiment, in this embodiment, the prompt word template is introduced, which is described in detail as follows:
[0070] In this embodiment, the prompt word template includes a description of the input text and entity type, a query statement, and a response format requirement. For example, the template may be "given a sentence: '{...}'; given a list of entity types: {...}; in this sentence, what entity types may be included? If not present, answer: none; if present, reply in the form of a triple. The prompt word template guides the model to extract the initial triple data according to the set logic.
[0071] In this embodiment, the given list of entity types is predefined.
[0072] Exemplarily, the predefined entity type format is as follows:
[0073] df_nert={
[0074] 'chinese':['Card Number', 'Account Name', 'Customer Name']
[0075] 'chinese':{'Account / Risk:['Usage time','Roaming location','Number of cards in the account']}
[0076] }
[0077] In this embodiment, the entity data extracted first are the card number, account name and customer name. On this basis, entity data, relationship data and event data related to the entity data extracted first are further extracted. The above operation is repeated to extract multiple initial triplet data.
[0078] In summary, by designing prompt word templates and pre-defined entity types, and setting the entity data to be extracted first in the pre-defined entity types, the prompt word template can be used to gradually deepen the initial triple data extraction process and accurately extract relevant data in complex relationships, so as to better handle the dependency relationship between IoT data and entity data, thereby improving the accuracy of extracting triple data.
[0079] Figure 3 A schematic diagram of the structure of a device for extracting triplet data based on the Internet of Things provided in an embodiment of the present application is shown in FIG. Figure 3 As shown, the device for extracting triplet data based on the Internet of Things field provided in this embodiment includes: a collection module 301, a labeling module 302, a first acquisition module 303, a second acquisition module 304, an extraction module 305 and a third acquisition module 306.
[0080] The collection module 301 is used to collect IoT data from the IoT data platform;
[0081] A labeling module 302 is used to label multiple data text pairs according to the IoT data;
[0082] A first acquisition module 303 is used to obtain a plurality of data text pairs with relative position codes according to the relative position deviation value of each data text pair;
[0083] A second acquisition module 304 is used to acquire text containing entity data, relationship data or event data from IoT data based on the large language model;
[0084] The extraction module 305 is used to input the predefined entity type and the text containing entity data, relationship data or event data into the prompt word template, and extract a plurality of initial triple data through the prompt word template; wherein the predefined entity type sets the entity data to be extracted first;
[0085] The third acquisition module 306 is used to obtain final triple data according to multiple data text pairs with relative position encoding and multiple initial triple data.
[0086] In a possible implementation, the first acquisition module 303 is specifically used to: add the relative position deviation value of each data text pair to the encoding vector of each data text pair to obtain multiple data text pairs with relative position encoding.
[0087] In a possible implementation, the relative position deviation value of each data text pair is expressed as follows:
[0088]
[0089] In the formula, Relative position deviation value. Represents the text length measurement, Indicates the average text length.
[0090] In a possible implementation, the extraction module 305 is specifically used to: use a prompt word template to determine whether there is a predefined entity type in the text containing entity data, relationship data or event data; if so, output multiple initial triplet data according to the existing entity type.
[0091] In a possible implementation, the third acquisition module 306 is specifically used to: calculate the similarity value of each initial triple data based on multiple data text pairs with relative position encoding; and determine the initial triple data with a similarity value higher than a preset similarity value as the final triple data.
[0092] The device for extracting triplet data in the field of the Internet of Things provided in this embodiment can execute the method provided in the above method embodiment, and its implementation principle and technical effect are similar, so this embodiment will not be described in detail here.
[0093] Figure 4 The hardware structure diagram of the server provided in the embodiment of the present application is shown in FIG. Figure 4 As shown, the server provided in this embodiment includes: at least one processor 401 and a memory 402. Optionally, the server also includes a communication component 403. The processor 401, the memory 402 and the communication component 403 are connected via a bus 404.
[0094] In a specific implementation process, at least one processor 401 executes the computer-executable instructions stored in the memory 402, so that at least one processor 401 executes the above method.
[0095] The specific implementation process of the processor 401 can be found in the above method embodiment, and its implementation principle and technical effect are similar, so this embodiment will not be repeated here.
[0096] In the above embodiments, it should be understood that the processor can be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), etc. A general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in the invention can be directly implemented as a hardware processor, or can be implemented by a combination of hardware and software modules in the processor.
[0097] The memory may include a high-speed memory (Random Access Memory, RAM), and may also include a non-volatile memory (NVM), such as at least one disk storage.
[0098] The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, the bus in the drawings of this application is not limited to only one bus or one type of bus.
[0099] The present application also provides a computer program product, including a computer program, which implements the above method when executed by a processor.
[0100] The present application also provides a computer-readable storage medium, in which computer-executable instructions are stored. When a processor executes the computer-executable instructions, the above method is implemented.
[0101] The above-mentioned readable storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk. The readable storage medium can be any available medium that can be accessed by a general or special-purpose computer.
[0102] An exemplary readable storage medium is coupled to a processor so that the processor can read information from the readable storage medium and write information to the readable storage medium. Of course, the readable storage medium can also be a component of the processor. The processor and the readable storage medium can be located in an application specific integrated circuit (Application Specific Integrated Circuits, referred to as: ASIC). Of course, the processor and the readable storage medium can also exist in the device as discrete components.
[0103] The division of units is only a logical function division, and there may be other divisions in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interface, device or unit, which can be electrical, mechanical or other forms.
[0104] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0105] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0106] If the function is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the methods of each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc. Various media that can store program codes.
[0107] Those skilled in the art can understand that all or part of the steps of implementing the above-mentioned method embodiments can be completed by hardware related to program instructions. The aforementioned program can be stored in a computer-readable storage medium. When the program is executed, the steps of the above-mentioned method embodiments are executed; and the aforementioned storage medium includes: ROM, RAM, disk or optical disk and other media that can store program codes.
[0108] Finally, it should be noted that those skilled in the art will readily conceive of other embodiments of the present invention after considering the specification and practicing the invention disclosed herein. The present invention is intended to cover any variations, uses or adaptations of the present invention, which follow the general principles of the present invention and include common knowledge or customary technical means in the art not disclosed by the present invention, are not limited to the precise structure described above and shown in the drawings, and may be modified and changed in various ways without departing from the scope thereof. The scope of the present invention is limited only by the appended claims.
Claims
1. A method for extracting triplet data based on the field of Internet of Things, characterized in that: Applicable to servers, including: Collect IoT data from the IoT data platform; Annotate multiple data-text pairs according to the IoT data; According to the relative position deviation value of each data text pair, a plurality of data text pairs with relative position encoding are obtained; Based on the large language model, obtaining text containing entity data, relationship data or event data from the IoT data; Inputting a predefined entity type and a text containing entity data, relationship data or event data into a prompt word template, and extracting a plurality of initial triplet data through the prompt word template; wherein the predefined entity type sets entity data to be extracted preferentially; The final triple data is obtained according to the multiple data text pairs with relative position encoding and the multiple initial triple data.
2. The method according to claim 1, characterized in that: The method of obtaining a plurality of data text pairs with relative position codes according to the relative position deviation value of each data text pair includes: The relative position deviation value of each data text pair is added to the encoding vector of each data text pair to obtain multiple data text pairs with relative position encoding.
3. The method according to claim 2, characterized in that The formula for the relative position deviation value of each data text pair is: In the formula, Relative position deviation value. Represents the text length measurement, Indicates the average text length.
4. The method according to claim 1, characterized in that: The predefined entity type and text containing entity data, relationship data or event data are input into a prompt word template, and a plurality of initial triplet data are extracted through the prompt word template, including: The prompt word template determines whether there is a predefined entity type in the text containing the entity data, relationship data or event data; If it exists, multiple initial triplet data are output according to the existing entity type.
5. The method according to any one of claims 1 to 4, characterized in that: The method of obtaining final triple data according to the plurality of data text pairs with relative position encoding and the plurality of initial triple data comprises: Calculate the similarity value of each initial triple data according to the plurality of data text pairs with relative position encodings; The initial triplet data whose similarity value is higher than the preset similarity value is determined as the final triplet data.
6. A device for extracting triplet data based on the field of Internet of Things, characterized in that: Applicable to servers, including: A collection module, used to collect IoT data from the IoT data platform; A labeling module, used for labeling a plurality of data-text pairs according to the IoT data; A first acquisition module is used to obtain a plurality of data text pairs with relative position codes according to the relative position deviation value of each data text pair; A second acquisition module is used to acquire text containing entity data, relationship data or event data from the IoT data based on a large language model; An extraction module is used to input a predefined entity type and a text containing entity data, relationship data or event data into a prompt word template, and extract a plurality of initial triplet data through the prompt word template; wherein the predefined entity type sets entity data to be extracted first; The third acquisition module is used to obtain final triple data according to the multiple data text pairs with relative position encoding and the multiple initial triple data.
7. The device according to claim 6, characterized in that The first acquisition module is used to add the relative position deviation value of each data text pair to the encoding vector of each data text pair to obtain multiple data text pairs with relative position encoding.
8. A server, characterized in that: include: Memory, processor; The memory stores computer-executable instructions; The processor executes the computer-executable instructions stored in the memory, so that the processor performs the method according to any one of claims 1 to 5.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, which are used to implement the method according to any one of claims 1 to 5 when executed by a processor.
10. A computer program product, characterized in that The invention comprises a computer program, which implements the method according to any one of claims 1 to 5 when being executed by a processor.