A data processing method, device, apparatus, and storage medium
By performing frequency modulation processing on the candidate text returned by the server on the client side and combining it with local input feature information, the problem of insufficient candidate sorting accuracy in traditional input methods is solved, and more accurate sorting results are achieved.
Patent Information
- Application Number
- CN202210390669.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-04-14
- Publication Date
- 2026-11-27
- Estimated Expiration
- 2042-04-14
AI Technical Summary
In traditional input methods, the word library capabilities of the client and server are inconsistent, resulting in poor accuracy of candidate sorting results in certain scenarios.
The client obtains the first character input string and historical text data, generates a business request, and after the server returns candidate data, the client adjusts the frequency of the candidate text based on the matching mapping relationship and sorts it in combination with local input feature information.
It improves the accuracy of candidate ranking results by fully considering both local input features from the client and server model data.
Smart Images

Figure CN116956875B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, and in particular to a data processing method, apparatus, device, and storage medium. Background Technology
[0002] Traditional input methods employ a client-cloud collaborative approach, where the client uploads the target input string and historical text data to the server. The server then leverages its powerful dictionary to determine the real-time results corresponding to candidate texts for that input string. Upon receiving the real-time results from the server, the client directly sorts the candidate texts based on their word frequencies, thus obtaining the candidate ranking results. Here, word frequency refers to the calculated score used for ranking comparisons among the candidate texts. Because the client's local frequency modulation algorithm differs from the server's, and the server selects candidate texts solely based on its powerful dictionary, the final candidate ranking results may be suboptimal in certain scenarios, thus reducing the accuracy of the ranking. Summary of the Invention
[0003] This application provides a data processing method, apparatus, device, and storage medium that can improve the accuracy of candidate ranking results.
[0004] One embodiment of this application provides a data processing method, which is executed by a client and includes:
[0005] The system acquires the first character input string with text word formation function and the target historical text data in the text input area, and generates a business request to be sent to the server. The business request is used to instruct the server to acquire target model candidate data that matches the target historical text data and the first character input string based on the text word formation function. The target model candidate data includes the first candidate text and the first word frequency evaluation value corresponding to the first candidate text.
[0006] When the target model candidate data is received from the server, the target object input string is obtained after updating the first character input string. When the target model candidate data meets the model frequency tuning condition, the first word frequency evaluation value corresponding to the first candidate text is adjusted based on the matching mapping relationship between the target object input string and the target model candidate data to obtain the second word frequency evaluation value corresponding to the first candidate text.
[0007] Obtain the client-side word frequency evaluation value of the second candidate text that matches the target historical text data and the target object input string. Based on the second word frequency evaluation value of the first candidate text and the client-side word frequency evaluation value of the second candidate text, sort the first candidate text and the second candidate text to obtain the candidate sorting result.
[0008] One embodiment of this application provides a data processing method, which is executed by a server and includes:
[0009] Obtain the business request sent by the client; the business request is determined by the client based on the first character input string with text word formation function and the target historical text data in the text input area;
[0010] Based on the text word formation function, target model candidate data that matches the target historical text data and the first character input string is obtained; the target model candidate data includes the first candidate text and the first word frequency evaluation value corresponding to the first candidate text.
[0011] The target model candidate data is returned to the client so that when the client determines that the target model candidate data meets the model frequency tuning conditions, it determines the second word frequency evaluation value corresponding to the first candidate text. Based on the second word frequency evaluation value corresponding to the first candidate text and the client's word frequency evaluation value corresponding to the second candidate text, the first candidate text and the second candidate text are sorted to obtain the candidate ranking result. The second word frequency evaluation value is obtained by the client after adjusting the first word frequency evaluation value corresponding to the first candidate text based on the matching mapping relationship between the target object input string and the target candidate model data. The target object input string is updated based on the first character input string. The second candidate text is the candidate text obtained by the client that matches the target historical text data and the target object input string.
[0012] One embodiment of this application provides a data processing apparatus, including:
[0013] The request generation module is used to obtain the first character input string with text word formation function and the target historical text data in the text input area, and generate a business request to be sent to the server. The business request is used to instruct the server to obtain target model candidate data that matches the target historical text data and the first character input string based on the text word formation function. The target model candidate data includes the first candidate text and the first word frequency evaluation value corresponding to the first candidate text.
[0014] The word frequency adjustment module is used to obtain the target object input string after updating the first character input string when the target model candidate data is received from the server. When the target model candidate data meets the model frequency adjustment conditions, the first word frequency evaluation value corresponding to the first candidate text is adjusted based on the matching mapping relationship between the target object input string and the target model candidate data to obtain the second word frequency evaluation value corresponding to the first candidate text.
[0015] The candidate sorting module is used to obtain the client-side word frequency evaluation value of the second candidate text that matches the target historical text data and the target object input string. Based on the second word frequency evaluation value of the first candidate text and the client-side word frequency evaluation value of the second candidate text, the first candidate text and the second candidate text are sorted to obtain the candidate sorting result.
[0016] The request generation module includes:
[0017] The first character input string determination unit is used to display a text input area including initial historical text data, respond to input operations on the text input area, and take the object input string corresponding to the input operation as the first character input string with text word formation function;
[0018] The text element count unit is used to obtain the input feature information of the target object in response to the initial historical text data, and to count the number of text elements corresponding to the text elements in the initial historical text data; a text element is used to indicate the text data entered by the target object in one text input cycle; the text input cycle is used to indicate the conversion time of the client to convert the historical input string into text data to be displayed in the text input area;
[0019] The first historical text determination unit is used to determine the initial historical text data as the target historical text data if the number of text elements is less than or equal to the text element number threshold K; K is a positive integer.
[0020] The request generation unit is used to generate a business request to be sent to the server based on the first character input string and the target historical text data.
[0021] The request generation module also includes:
[0022] The timestamp sorting unit is used to sort the input timestamps corresponding to each text element in the input feature information if the number of text elements is greater than the threshold K, and obtain the time sorting result.
[0023] The second historical text determination unit is used to obtain the last K input timestamps from the time sorting results and to obtain the text data corresponding to the last K input timestamps from the initial historical text data, and to use the obtained text data as the target historical text data.
[0024] The word frequency adjustment module includes:
[0025] The data stream parsing unit is used to receive the compressed data stream generated by the server for the target model candidate data, and to parse and process the compressed data stream to obtain the target model candidate data.
[0026] The target input string acquisition unit is used to acquire the target object input string after updating the first character input string;
[0027] The matching mapping relationship determination unit is used to determine the matching mapping relationship between the target object input string and the target model candidate data based on the model matching rules for the target model candidate data;
[0028] The frequency modulation parameter determination unit is used to determine the frequency modulation evaluation parameters corresponding to the matching mapping relationship and the text word type corresponding to the first candidate text when the matching mapping relationship indicates that the target model candidate data meets the model frequency modulation conditions;
[0029] The word frequency adjustment unit is used to adjust the first word frequency evaluation value of the first candidate text based on the frequency modulation evaluation parameters and the text word type corresponding to the first candidate text, so as to obtain the second word frequency evaluation value of the first candidate text.
[0030] The word frequency adjustment unit includes:
[0031] The text word type adjustment subunit is used to adjust the text word type of the text to be adjusted from the first text word type to the second text word type if there is a text to be adjusted in the first candidate text that belongs to the target text meta type and whose text word type is the first text word type.
[0032] The word frequency adjustment subunit is used to adjust the first word frequency evaluation value of the text to be adjusted based on the number of times the second text word type is used and the frequency adjustment evaluation parameters, so as to obtain the second word frequency evaluation value of the text to be adjusted.
[0033] The term frequency determination subunit is used to determine the second term frequency evaluation value corresponding to the first candidate text based on the second term frequency evaluation value corresponding to the text to be adjusted.
[0034] The candidate sorting module includes:
[0035] The client-side word frequency acquisition unit is used to acquire the client-side word frequency evaluation value corresponding to the second candidate text that matches the target historical text data and the target object input string;
[0036] The unsorted text determination unit is used to determine the first candidate text and the second candidate text as unsorted candidate texts, and to determine the text word type of the unsorted candidate texts; the unsorted candidate texts include the first unsorted text belonging to the first text word type and the second unsorted text belonging to the second text word type;
[0037] The first sorting processing unit is used to sort the first text to be sorted based on the word frequency evaluation value of the first text to be sorted, and obtain the first sorting result;
[0038] The second sorting processing unit is used to sort the second text based on the word frequency evaluation value of the second text to be sorted, and obtain the second sorting result;
[0039] The sorting result determination unit is used to arrange the first sorting result after the second sorting result to obtain the candidate sorting result.
[0040] One embodiment of this application provides a data processing apparatus, including:
[0041] The request acquisition module is used to acquire business requests sent by the client; the business request is determined by the client based on the first character input string with text word formation function and the target historical text data in the text input area;
[0042] The target model data acquisition module is used to acquire target model candidate data that matches the target historical text data and the first character input string based on the text word formation function; the target model candidate data includes the first candidate text and the first word frequency evaluation value corresponding to the first candidate text.
[0043] The target model data sending module is used to return target model candidate data to the client. This allows the client to determine the second word frequency evaluation value corresponding to the first candidate text when it determines that the target model candidate data meets the model frequency tuning conditions. Based on the second word frequency evaluation value corresponding to the first candidate text and the client's word frequency evaluation value corresponding to the second candidate text, the first and second candidate texts are sorted to obtain a candidate ranking result. The second word frequency evaluation value is obtained by adjusting the first word frequency evaluation value corresponding to the first candidate text based on the matching mapping relationship between the target object input string and the target candidate model data. The target object input string is updated based on the first character of the input string. The second candidate text is the candidate text obtained by the client that matches the target historical text data and the target object input string.
[0044] Wherein, the number of text elements corresponding to text elements in the target historical text data is N; N is a positive integer less than or equal to the threshold K for the number of text elements;
[0045] The target model data acquisition module includes:
[0046] The request identifier mapping unit is used to map the target historical text data and the first character input string to N text meta-types respectively through a tree structure; the N text meta-types include text meta-type M. i ; i is a positive integer less than or equal to N; text metatype M i The number of text elements indicated is a positive integer greater than 1 and less than or equal to (N+1);
[0047] The initial model data acquisition unit is used for data acquisition based on text metatype M. i The corresponding request identifier is used to obtain the text metatype M. i Corresponding initial model candidate data;
[0048] The filtering unit is used to filter the initial model candidate data corresponding to the N text meta-types obtained based on the model resource filtering strategy, so as to obtain the target model candidate data.
[0049] The initial model data acquisition unit includes:
[0050] Request to generate sub-units for use based on text metatype M i The corresponding request identifier generates a text meta-type M. i The corresponding resource acquisition request i;
[0051] The candidate combination string acquisition subunit is used to obtain a data compression list for compressing and storing model resources. Based on the resource acquisition request i and the data compression list, the input candidate combination string associated with the first character input string is obtained.
[0052] The initial word frequency acquisition subunit is used to determine the initial candidate text corresponding to the input candidate combination string based on the text word formation function, and to obtain the initial word frequency evaluation value corresponding to the initial candidate text;
[0053] The initial model data determines the sub-units, which are used to transform the text meta-type M... i The determined input candidate combination string, the corresponding initial candidate text, and the initial word frequency evaluation value of the initial candidate text are used as the text metatype M. i The corresponding initial model candidate data; the first word frequency evaluation value includes the initial word frequency evaluation value after filtering the initial candidate text.
[0054] The filtering unit includes:
[0055] The filtering strategy acquisition subunit is used to acquire model resource filtering strategies. The model resource filtering strategies include input string filtering strategies, word frequency evaluation value filtering strategies for target text metatypes, and common word filtering strategies for target text metatypes.
[0056] The first filtering subunit is used to determine the initial model candidate data corresponding to the N obtained text meta types as the first model candidate data to be filtered, and to filter the first model candidate data to be filtered based on the input string filtering strategy to obtain the second model candidate data to be filtered.
[0057] The second filtering subunit is used to filter the second model data based on the word frequency evaluation value filtering strategy if there are initial model candidate data belonging to the target text meta type in the second model candidate data to be filtered, so as to obtain the third model candidate data to be filtered.
[0058] The third filtering subunit is used to perform text matching on the initial candidate text belonging to the target text metatype in the third candidate data of the model to be filtered based on the common words in the common word filtering strategy. If a common word is matched in the third candidate data of the model to be filtered, the model candidate sub-data corresponding to the matched common word is filtered in the third candidate data of the model to be filtered to obtain the target model candidate data. The model candidate sub-data corresponding to a common word includes the input candidate combination string corresponding to the common word and the initial word frequency evaluation value corresponding to the common word.
[0059] The input string filtering strategy includes a first input string filtering strategy; the first input string filtering strategy includes a first type attribute and a second type attribute; the text meta level of the first type attribute is lower than the text meta level of the second type attribute;
[0060] The first filtering subunit includes:
[0061] The first data to be filtered determination subunit is used to determine the initial model candidate data corresponding to the N obtained text meta types as the first model candidate data to be filtered.
[0062] The type data determination subunit is used to, in the first candidate model data to be filtered, take the initial candidate model data associated with the first type attribute as the first type data and take the initial candidate model data associated with the second type attribute as the second type data.
[0063] The duplicate data filtering subunit is used to filter the model candidate sub-data associated with the duplicate input candidate combination string in the first type of data if there is a duplicate input candidate combination string between the first type of data and the second type of data, so as to obtain the filtered first type of data.
[0064] The second data to be filtered determination subunit is used to determine the second candidate data for the filter model based on the filtered first type of data and the second type of data.
[0065] The input string filtering strategy includes a second input string filtering strategy; the second input string filtering strategy includes a distribution ratio threshold.
[0066] The second data to be filtered subunit is also used for:
[0067] The data to be processed is obtained from the filtered first type of data and second type of data, and the input candidate combination strings in the data to be processed are determined as the input string set; the input string set includes the first input candidate combination string with an empty input string and the second input candidate combination string including the first character input string;
[0068] Based on the initial word frequency evaluation value corresponding to the first input candidate combination string and the initial word frequency evaluation value corresponding to the second input candidate combination string, the distribution ratio of word frequency evaluation values corresponding to the data type to be processed is determined.
[0069] If the distribution ratio of word frequency evaluation values is greater than the distribution ratio threshold, then in the data to be processed, the model candidate sub-data associated with the second input candidate combination string is filtered to obtain the second model candidate data to be filtered.
[0070] The second filtering subunit includes:
[0071] The target data determination subunit is used to determine the initial model candidate data of the target text metatype as target type data if the second model candidate data to be filtered has initial model candidate data of the target text metatype. The target type data includes a first initial text and a second initial text associated with the target input candidate combination string. The initial word frequency evaluation value corresponding to the second initial text is lower than the initial word frequency evaluation value corresponding to the first initial text, and the first initial text is the initial candidate text with the highest initial word frequency evaluation value corresponding to the target input candidate combination string.
[0072] The third data to be filtered subunit is used to filter target type data based on the initial word frequency evaluation value corresponding to the first initial text, the initial word frequency evaluation value corresponding to the second initial text, and the word frequency evaluation value filtering strategy, so as to obtain the third candidate data of the model to be filtered.
[0073] The target model data transmission module includes:
[0074] The metaword matching unit is used to match the first candidate text in the candidate data of the target model based on the metawords in the metaword identifier mapping table;
[0075] The metaword identifier acquisition unit is used to obtain the metaword identifier corresponding to the matched metaword from the metaword identifier mapping table if the first candidate text matched in the target model candidate data contains a metaword;
[0076] The data compression unit is used to compress the candidate data of the target model based on metaword identifiers to obtain a compressed data stream;
[0077] The data stream return unit is used to return a compressed data stream to the client.
[0078] One embodiment of this application provides a computer device, including: a processor and a memory;
[0079] The processor is connected to a memory, which stores a computer program. When the computer program is executed by the processor, it causes the computer device to perform the method provided in the embodiments of this application.
[0080] One aspect of this application provides a computer-readable storage medium storing a computer program adapted to be loaded and executed by a processor, so that a computer device having the processor performs the method provided in this application.
[0081] One aspect of this application provides a computer program product, which includes a computer program stored in a computer-readable storage medium; a processor of a computer device reads the computer program from the computer-readable storage medium and executes the computer program, causing the computer device to perform the method described in this application.
[0082] In this embodiment, through the interaction between a client with frequency tuning and sorting capabilities and a server with cloud-based model data delivery capabilities, when the client initiates a business request based on the first character input string and target historical text data, it can obtain not only the cloud-based model data determined by the server (i.e., target model candidate data including the first candidate text) but also the second candidate text determined by the client itself. It is worth noting that when the target model candidate data sent by the server meets the model frequency tuning conditions, the client does not directly perform sorting based on the first word frequency evaluation value corresponding to the first candidate text determined by the server. Instead, it needs to further tune the frequency of the first candidate text sent by the server to obtain the second word frequency evaluation value corresponding to the first candidate text. This ensures that the candidate sorting result fully considers the client's local input feature information and the cloud-based model data sent by the server, thereby effectively improving the accuracy of the candidate sorting result. Attached Figure Description
[0083] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0084] Figure 1This is a schematic diagram of a network architecture provided in an embodiment of this application;
[0085] Figure 2 This is a schematic diagram of a data interaction scenario provided in an embodiment of this application;
[0086] Figure 3 This is a flowchart illustrating a data processing method provided in an embodiment of this application;
[0087] Figure 4 This is a schematic diagram illustrating a process for a server to distribute cloud-based model data, as provided in an embodiment of this application.
[0088] Figure 5 This is a schematic diagram illustrating a client's use of model data according to an embodiment of this application;
[0089] Figure 6 This is a flowchart illustrating a data processing method provided in an embodiment of this application;
[0090] Figure 7 This is a flowchart illustrating the overall interactive process of cloud frequency modulation as provided in an embodiment of this application;
[0091] Figure 8 This is a schematic diagram of the structure of a data processing device provided in an embodiment of this application;
[0092] Figure 9 This is a schematic diagram of the structure of a data processing device provided in an embodiment of this application;
[0093] Figure 10 This is a schematic diagram of a computer device provided in an embodiment of this application;
[0094] Figure 11 This is a schematic diagram of the structure of a data processing system provided in an embodiment of this application. Detailed Implementation
[0095] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0096] Please see Figure 1 , Figure 1 This is a schematic diagram of a network architecture provided in an embodiment of this application. Figure 1 As shown, this network architecture may include a server 10F and a cluster of terminal devices. The terminal device cluster may include one or more terminal devices; the number of terminal devices is not limited here. Figure 1 As shown, it may specifically include terminal device 100a, terminal device 100b, terminal device 100c, ..., terminal device 100n. For example... Figure 1 As shown, terminal devices 100a, 100b, 100c, ..., 100n can each connect to the server 10F via a network, so that each terminal device can interact with the server 10F through the network connection.
[0097] Each terminal device in this terminal device cluster can include: smartphones, tablets, laptops, desktop computers, smart speakers, smartwatches, in-vehicle terminals, smart TVs, and other smart terminals with data display capabilities. It should be understood that, for example... Figure 1 Each terminal device in the terminal device cluster shown can have the target application (i.e., client) installed. When the client runs on each terminal device, it can interact with the aforementioned applications. Figure 1 Data interaction occurs between the servers 10F shown. This client can include social clients, multimedia clients (e.g., video clients), entertainment clients (e.g., game clients), educational clients, live streaming clients, and other clients with frequency tuning and sorting capabilities. This client can be a standalone client or an embedded sub-client integrated into another client (e.g., social clients, educational clients, and multimedia clients); this is not limited here.
[0098] like Figure 1 As shown, in this embodiment, server 10F can be the server corresponding to the client. Server 10F can be an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud computing services.
[0099] For ease of understanding, the embodiments of this application may be described in detail below. Figure 1 From the multiple terminal devices shown, one terminal device is selected as the target terminal device. For example, in the embodiments of this application, a terminal device can be selected as the target terminal device. Figure 1 The terminal device 100a shown serves as the target terminal device, which may integrate a client with the frequency modulation and sorting function. In this case, the target terminal device can interact with the server 10F through the business data platform corresponding to the client.
[0100] It should be understood that the target terminal device can display a text input area in the service display interface provided by the client. This text input area can be used to display historically determined text data of the target object (i.e., historical text data). When the target object corresponding to the target terminal device (i.e., the target user accessing the client) performs an input operation (e.g., a click on the virtual keyboard) in this text input area, the client can generate a service request to be sent to server 10F based on the first character input string with text word formation function entered by the target object, and the target historical text data in the text input area. Here, the first character input string refers to the object input string containing one character entered by the target object at the first timestamp of the current text input period. This object input string can be a numeric string or an alphanumeric string. For example, the first character input string can be "s". At this time, server 10F can obtain target model candidate data matching the first character input string and the target historical text data based on this text word formation function. This target model candidate data can include the candidate text determined by server 10F (i.e., the first candidate text) and the first word frequency evaluation value corresponding to the first candidate text.
[0101] Furthermore, when the client in the target terminal device receives the target model candidate data returned by the server 10F, it can obtain the target object input string after updating the first character input string. Here, the target object input string refers to the object input string updated based on the first character input string at the second timestamp of the current text input period (e.g., adding a new string to the first character input string, or directly replacing the first character input string). For example, the target object input string could be "sh". The second timestamp can be the next timestamp after the first timestamp, where the first timestamp refers to the timestamp when the client generates the business request, and the second timestamp refers to the timestamp when the client receives the target model candidate data.
[0102] At this point, the client needs to determine whether the target model candidate data meets the model frequency tuning conditions. If the target model candidate data meets the model frequency tuning conditions, the client can adjust the first word frequency evaluation value corresponding to the first candidate text returned by the server 10F based on the matching mapping relationship between the target object input string and the target model candidate data to obtain the second word frequency evaluation value corresponding to the first candidate text. At the same time, the client can also obtain the client word frequency evaluation value corresponding to the candidate text (i.e., the second candidate text) that matches the target historical text data and the target object input string locally. Then, by using the second word frequency evaluation value after frequency tuning of the first candidate text and the client word frequency evaluation value of the second candidate text evaluated by the client itself, the first candidate text and the second candidate text can be sorted to obtain a more accurate candidate ranking result.
[0103] Therefore, the embodiments of this application can provide a novel end-to-cloud collaborative mode. Through interaction between the client and server 10F, the client can obtain not only the cloud-based model data determined by server 10F (i.e., target model candidate data including the first candidate text), but also the second candidate text determined by the client itself. It is worth noting that when the target model candidate data sent by server 10F meets the model frequency tuning conditions, the client does not directly perform sorting based on the first word frequency evaluation value corresponding to the first candidate text determined by server 10F. Instead, it needs to further tune the frequency of the first candidate text sent by server 10F to obtain the second word frequency evaluation value corresponding to the first candidate text (i.e., the tuned first word frequency evaluation value). This ensures that subsequent sorting based on the second word frequency evaluation value corresponding to the first candidate text and the client-side word frequency evaluation value corresponding to the second candidate text determined by the client itself fully considers the input feature information of the target object on the client's local machine and the cloud-based model data sent by server 10F, thereby effectively improving the accuracy of the candidate sorting results.
[0104] For better understanding, please refer to [link / reference]. Figure 2 , Figure 2 This is a schematic diagram illustrating a data interaction scenario provided in an embodiment of this application. For example... Figure 2 As shown, in this embodiment, interface 200J1 and interface 200J2 are both service display interfaces provided by the client in the target terminal device. The target terminal device can be the aforementioned Figure 1 Any terminal device in the terminal device cluster in the corresponding embodiment, for example, terminal device 100a. Figure 2 The server 20F shown can be a server used to distribute cloud model data, and this server 20F can be the aforementioned Figure 1 The corresponding embodiment is server 10F.
[0105] like Figure 2 As shown, area 2Q1 of interface 200J1 can be a text input area for displaying historical text data 2w, which can be "I don't want to go". Here, the historical text data 2w can be the text data historically input by the target object corresponding to the target terminal device in response to the business data information displayed on interface 200J1.
[0106] It should be understood that when the target object performs an input operation on region 2Q1, the client can respond to the input operation and display the object input string 21d (i.e., the first character input string, for example) corresponding to the input operation on interface 200J1. Figure 2 (as shown by "s"). The input string 21d has text word formation capabilities. It is understood that when responding to an input operation, the client can also obtain the input string 21d and the target historical text data determined based on historical text data 2w, and then generate a business request 20q to be sent to server 20F.
[0107] When server 20F receives the business request 20q, it can use the text word formation function to obtain target model candidate data that matches the target historical text data and the object input string 21d (e.g., Figure 2 The model candidate data 20m shown here may include x candidate texts (i.e., the first candidate texts) determined by the server 20F and the corresponding word frequency evaluation values (i.e., the first word frequency evaluation values) for each of these x candidate texts, where x is a positive integer. Figure 2 As shown, the word frequency evaluation value corresponding to candidate text 20W1 can be word frequency evaluation value 20C1; the word frequency evaluation value corresponding to candidate text 20W2 can be word frequency evaluation value 20C2; and so on, the word frequency evaluation value corresponding to candidate text 20W1 can be word frequency evaluation value 20C2; and so on, the word frequency evaluation value corresponding to candidate text 20W2 can be word frequency evaluation value 20C2; and so on, the word frequency evaluation value corresponding to candidate x The corresponding word frequency evaluation value can be word frequency evaluation value 20C. x Furthermore, the server 20F can return the model candidate data 20m to the client, so that the client can obtain the updated object input string 22d (i.e., the target object input string, for example, after updating the object input string 21d) Figure 2 The interface shown in Figure 200J2 displays "sh".
[0108] At this point, the client needs to determine whether the model candidate data 20m returned by the server 20F meets the model frequency tuning conditions. If the target model candidate data meets the model frequency tuning conditions, the client needs to further tune the first candidate text based on the matching mapping relationship between the object input string 22d and the model candidate data 20m, that is, adjust the first word frequency evaluation value corresponding to the first candidate text to obtain the second word frequency evaluation value corresponding to the first candidate text.
[0109] Simultaneously, the client can also consider the historical input features of the target object, namely, obtaining a second candidate text that matches the object input string 22d and historical text data 2w locally from the client, as well as the client-side word frequency evaluation value corresponding to the second candidate text. For example... Figure 2 As shown, the second candidate text obtained by the client can include y candidate texts, specifically candidate text 21W1, candidate text 21W2, ..., candidate text 21W... y Here, y is a positive integer. The word frequency evaluation value corresponding to candidate text 21W1 can be word frequency evaluation value 21C1; the word frequency evaluation value corresponding to candidate text 21W2 can be word frequency evaluation value 21C2; and so on, for candidate text 21W... y The corresponding word frequency evaluation value can be word frequency evaluation value 21C. y .
[0110] Furthermore, the client can sort the locally acquired second candidate text and the frequency-tuned first candidate text based on the second word frequency evaluation value and the client's word frequency evaluation value, thereby obtaining a more accurate candidate ranking result. For example... Figure 2 As shown, this candidate ranking result can be used to display Figure 2 The interface 220J shown includes region 2Q2 (i.e., the candidate display area). For example, the candidate ranking result may include candidate text 1 (e.g., "harm"), candidate text 2 (e.g., "audit"), candidate text 3 (e.g., "life"), candidate text 4 (e.g., "is"), candidate text 5 (e.g., "speak"), and candidate text 6 (e.g., "command"). All six candidate texts belong to either the first or second candidate text mentioned above.
[0111] Therefore, Figure 2When the client performs an input operation on the text input area (i.e., area 2Q1) as shown, it can not only obtain the model candidate data 20m that matches the historical text data 2w and the object input string 21d as determined by the server 20F, but also obtain the second candidate text including y candidate texts locally on the client. Then, when the model candidate data 20m meets the model frequency tuning condition, the first candidate text in the model candidate data 20m can be tuned, and the tuned first candidate text and the locally obtained second candidate text can be comprehensively sorted. This fully considers the input feature information of the target object (input behavior, i.e. the target object's screen display habits for candidate texts in area 2Q2) and the cloud model data of the server, so as to improve the accuracy of the final candidate sorting result.
[0112] In this embodiment of the application, the client-side, based on an end-to-cloud collaborative mode, performs frequency tuning and sorting on the first candidate text returned by the server and the second candidate text obtained locally by the client. The specific implementation method can be found below. Figures 3-7 The corresponding implementation examples.
[0113] Further, please see Figure 3 , Figure 3 This is a flowchart illustrating a data processing method provided in an embodiment of this application. Figure 3 As shown, this method can be executed by a client with frequency modulation sorting functionality, which can be the aforementioned... Figure 1 The method refers to any terminal device in the terminal device cluster in the corresponding embodiment, for example, terminal device 100a. The method can also be implemented by a server with frequency modulation and sorting capabilities (e.g., the one described above). Figure 1 The method is executed by the server 10F shown, but is not limited here. For ease of understanding, this application embodiment describes the method as being executed by a target terminal device running a client, and the method may include at least the following steps S101-S103:
[0114] Step S101: Obtain the first character input string with text word formation function and the target historical text data in the text input area, and generate a business request to be sent to the server.
[0115] Here, the business request can instruct the server to obtain target model candidate data that matches the target historical text data and the first character input string based on the text word formation function. This target model candidate data can include a first candidate text and the first word frequency evaluation value corresponding to the first candidate text. Specifically, the client displays a text input area including the initial historical text data (e.g., the one described above). Figure 2When the target object is in region 2Q1 (as shown), it can perform an input operation on this text input region. This input operation can be performed by the target object on the virtual keyboard in the business display interface or on the physical keyboard; this is not limited here. Furthermore, the client can respond to this input operation by using the object input string corresponding to the input operation as the first character input string with text word formation functionality. Simultaneously, the client can obtain the input feature information of the target object on the initial historical text data to count the number of text elements corresponding to the text elements in the initial historical text data. Further, based on the number of text elements corresponding to the initial historical text data and the text element number threshold K, the client can determine the target historical text data that meets the text element number threshold K from the initial historical text data, and then generate a business request to be sent to the server based on the first character input string and the target historical text data.
[0116] The input feature information here may include the input timestamp corresponding to each text element in the initial historical text data. A text element can be used to indicate the text data input by the target object in one text input cycle. The text input cycle here is used to indicate the conversion time for the client to convert the historical input string into text data for display in the text input area. That is, the text input cycle refers to the time from when the target object performs the input operation to when it is finally displayed on the screen (i.e., the candidate text is selected). It should be understood that the text element number threshold K here is a positive integer, which is set by the client to effectively ensure the efficiency of the client's input string conversion. It can be dynamically adjusted according to the actual situation, and will not be limited here. For ease of explanation, K in this embodiment can be taken as 4.
[0117] It should be understood that if the number of text elements in the initial historical text data is less than or equal to the text element count threshold K, then the client can directly determine the initial historical text data as the target historical text data. For example... Figure 2 As shown, the historical text data 2w (i.e., the initial historical text data) displayed in region 2Q1 is "I don't want to go". The client can determine that the historical text data 2w includes four text elements: text 1 (e.g., "I"), text 2 (e.g., "no"), text 3 (e.g., "willing"), and text 4 (e.g., "go"). Therefore, the client can determine that the number of text elements in the historical text data 2w is equal to the text element number threshold K. At this time, the client can directly determine the initial historical text data as the target historical text data. Then, based on the target historical text data "I don't want to go" and the object input string 21d (i.e., the first character input string, e.g., "s"), the client can generate a business request 20q to be sent to the server.
[0118] Optionally, if the number of text elements in the initial historical text data is greater than the text element number threshold K, the client can sort the input timestamps corresponding to each text element in the input feature information to obtain a time-sorted result. Then, the client can obtain the last K input timestamps from the time-sorted result. At this time, the client can obtain the text data corresponding to the last K input timestamps from the initial historical text data and use the obtained text data as the target historical text data. For example, if the initial historical text data is "I like going outdoors in spring", the client can determine that the initial historical text data includes five text elements: text 1 (e.g., "I"), text 2 (e.g., "like"), text 3 (e.g., "spring"), text 4 (e.g., "go"), and text 5 (e.g., "outdoors"). Therefore, the client can determine that the number of text elements in the initial historical text data is greater than the text element number threshold. At this time, the client can obtain the input timestamp of each of these five text elements from the input feature information corresponding to the initial historical text data, and then sort these five text elements based on the obtained input timestamps to obtain a time-sorted result. Furthermore, the client can obtain the four last four input timestamps from the time sorting results, and obtain the four text data corresponding to these four input timestamps (e.g., "I like going outdoors in spring") from the initial historical text data as target historical text data. Then, based on the target historical text data and the first character input string, a business request to be sent to the server can be generated.
[0119] Understandably, when the server receives a business request from a client, it can use text word formation functionality to retrieve candidate target model data that matches the target historical text data and the first character input string, and then return this candidate target model data to the client. Here, the number of text elements corresponding to the text elements in the target historical text data is N, where N is a positive integer less than or equal to the threshold K for the number of text elements. For example, the server can use a tree structure (e.g., a multi-way search tree with ID as the node) to map the target historical text data and the first character input string to request identifiers corresponding to N text element types. These N text element types can include text element type M. i ; i is a positive integer less than or equal to N; text metatype M i The indicated number of text elements is a positive integer greater than 1 and less than or equal to (N+1). Furthermore, the server can base it on text element type M. i The corresponding request identifier is used to obtain the text metatype M. i The corresponding initial model candidate data is obtained, and based on the model resource filtering strategy, the initial model candidate data corresponding to the N text meta types are filtered to obtain the target model candidate data.
[0120] For better understanding, please refer to [link / reference]. Figure 4 , Figure 4 This is a schematic diagram illustrating a process for a server to distribute cloud-based model data, as provided in an embodiment of this application. Figure 4 As shown, the server in this embodiment can be a server used to distribute cloud model data, and the server 20F can be the one described above. Figure 1 The corresponding embodiment is server 10F. The client in this embodiment can run on the above-described... Figure 1 Any terminal device in the terminal device cluster in the corresponding embodiment, for example, terminal device 100a.
[0121] It should be understood that when the server receives a business request from a client, it can obtain... Figure 4 The example shown is a first-character input string with text word formation functionality and target historical text data. It can be understood that the server can use a tree structure to map the target historical text data and the first-character input string into request identifiers corresponding to N text meta-types. Furthermore, the server can obtain... Figure 4 The data compression list 400B shown is used for compressing and storing model resources. This data compression list 400B can then be used to obtain model resources, yielding initial model candidate data for each text metatype. Here, the data compression list 400B is a linear data structure designed by a remote dictionary service (e.g., Redis) to save memory. It can contain any number of elements, each of which can be a byte array or an integer. This embodiment of the application stores cloud frequency modulation data offline in the form of a compressed list, which significantly reduces memory usage and improves query efficiency, achieving highly efficient data compression.
[0122] It is understandable that the server can be based on text metatype M from N text metatypes. i The corresponding request identifier generates a text meta-type M. i The corresponding resource acquisition request i, and based on resource acquisition request i and data compression list 400B, can obtain the input candidate combination string associated with the first character input string. Then, the server can determine the initial candidate text corresponding to the input candidate combination string based on the text word formation function, and obtain the initial word frequency evaluation value corresponding to the initial candidate text. Further, the server can use text metatype M as a basis for... i The determined input candidate combination string, the corresponding initial candidate text, and the initial word frequency evaluation value of the initial candidate text are used as the text metatype M. iThe corresponding initial model candidate data. In this embodiment, the first word frequency evaluation value may include the initial word frequency evaluation value after filtering the initial candidate text.
[0123] For example, the target historical text data here can be the above. Figure 2 The historical text data 2w shown is text data containing four text elements: text 1 (e.g., "I"), text 2 (e.g., "No"), text 3 (e.g., "Willing"), and text 4 (e.g., "Go"). The first character input string is... Figure 2 The input string 21d is shown. The server maps the target historical text data and the first character input string to obtain four request identifiers. These four request identifiers can specifically include the request identifier corresponding to text metatype 1 (e.g., quinary type), the request identifier corresponding to text metatype 2 (e.g., quaternary type), the request identifier corresponding to text metatype 3 (e.g., ternary type), and the request identifier corresponding to text metatype 4 (e.g., binary type).
[0124] The server can initiate up to four resource acquisition requests based on the number of text elements corresponding to the target historical text data. For example, the server can generate a resource acquisition request (e.g., resource acquisition request 1) corresponding to the five-element type based on the request identifier corresponding to text element type 1 (e.g., five-element type). Furthermore, the server can quickly acquire the input candidate combination string associated with the first character input string based on resource acquisition request 1 and data compression list 400B. Further, the server can determine the initial candidate text corresponding to the input candidate combination string under the five-element type based on text word formation functionality, and acquire the initial word frequency evaluation value corresponding to the initial candidate text under the five-element type. At this point, the server can use the input candidate combination string determined based on the five-element type, the initial candidate text determined under the five-element type, and the initial word frequency evaluation value as the initial model candidate data corresponding to the five-element type.
[0125] Similarly, the server can refer to the specific implementation of the initial model candidate data corresponding to the five-element type to obtain the initial model candidate data corresponding to the four-element type, the initial model candidate data corresponding to the three-element type, and the initial model candidate data corresponding to the two-element type in parallel.
[0126] For ease of understanding, please further refer to Table 1, which is a schematic table of model candidate data provided in an embodiment of this application. The business request received by the server can carry target historical text data and a first character input string. Here, the target historical text data can be "I don't want to go," which includes four text elements, and the first character input string can be "s." Table 1 can be used to characterize the server's response based on the business request and... Figure 4The data compression list 400B shown shows the obtained text metadata type M. i The corresponding initial model candidate data are shown in Table 1:
[0127] Table 1
[0128]
[0129] The initial model candidate data corresponding to a text metatype can include model candidate sub-data corresponding to multiple candidate texts. The model candidate sub-data corresponding to a candidate text can include the text metatype corresponding to the candidate text, the input candidate combination string corresponding to the candidate text, and the word frequency evaluation value corresponding to the candidate text. As shown in Table 1, the model candidate sub-data corresponding to the candidate text "Explanation" can include the text metatype corresponding to the candidate text "Explanation" (text metatype M). i For example, a five-element type), the input candidate combination string corresponding to the candidate text "description" (e.g., "sm"), and the word frequency evaluation value corresponding to the candidate text "description" (e.g., "253"). The word frequency evaluation value for each candidate text can range from [0, 256], and this value can be determined by the server based on the conditional probability of each initial candidate text. It is understood that the input candidate combination string corresponding to a text metatype can include two types: one is an input candidate combination string with an empty input string (i.e., the first input candidate combination string); the other is an input candidate combination string with the first character of the input string (i.e., the second input candidate combination string). For example, text metatype M... i The corresponding second input candidate combination string can include “s”, “sh”, “sn”, and “sm”.
[0130] Furthermore, when the server obtains the initial model candidate data corresponding to each of the N text meta-types, it can acquire a model resource filtering strategy and perform model resource filtering and compression processing on these N initial model candidate data to obtain the final compressed data stream used to send to the client. For example... Figure 4 As shown, the model resource filtering strategies obtained by the server may include an input string filtering strategy 41L, a word frequency evaluation value filtering strategy 42L for the target text metatype, and a common word filtering strategy 43L for the target text metatype. The target text metatype can include binary and ternary types. The filtering order of the server when filtering the obtained initial model candidate data according to the three filtering strategies in the model resource filtering strategy is not specified here.
[0131] like Figure 4As shown, the server can determine the initial model candidate data corresponding to the N obtained text meta-types as the first model candidate data to be filtered, and then based on... Figure 4 The input string filtering strategy 41L shown filters the first candidate model data to be filtered, resulting in the second candidate model data to be filtered. The input string filtering strategy 41L can include a first input string filtering strategy and a second input string filtering strategy. The first input string filtering strategy can be used to filter out model candidate sub-data that overlaps with the second type of data (i.e., high-data) from the first type of data (i.e., low-metadata). The second input string filtering strategy can be used to filter model candidate sub-data that meets a distribution ratio threshold (e.g., 20) based on the distribution ratio of word frequency evaluation values between data without input strings (i.e., initial model candidate data associated with the first input candidate combination string) and data with input strings (i.e., initial model candidate data associated with the second input candidate combination string). This distribution ratio threshold can be dynamically adjusted according to actual needs and will not be limited here.
[0132] The first input string filtering strategy can include a first type attribute and a second type attribute, where the text meta-level of the first type attribute is lower than that of the second type attribute. For example, the server can use initial model candidate data associated with the first type attribute as first type data and initial model candidate data associated with the second type attribute as second type data from the first type of model candidate data to be filtered. If there are duplicate input candidate combination strings between the first type data and the second type data, the model candidate sub-data associated with the duplicate input candidate combination strings are filtered from the first type data to obtain filtered first type data. Then, based on the filtered first type data and the second type data, the second type of model candidate data to be filtered can be determined. For example, regarding the initial model candidate data corresponding to the pentagonal type (i.e., pentagonal type data) and the initial model candidate data corresponding to the quaternary type (i.e., quaternary type data), the pentagonal type data belongs to high-level metadata, while the quaternary type data belongs to low-level metadata. When there is an input string candidate combination string (e.g., "sm") that is repeated in the quaternary type data, the server can filter out the model candidate sub-data associated with the input string "sm" in the quaternary type data.
[0133] The second input string filtering strategy may include a distribution ratio threshold (e.g., 20). After the server uses the first input string filtering strategy, it can obtain the data to be processed from the filtered first and second type data, and determine the input candidate combinations in the data to be processed as an input string set. This input string set may include a first input candidate combination string with an empty input string and a second input candidate combination string including the first character of the input string. Further, the server can determine the distribution ratio of the word frequency evaluation values corresponding to the data to be processed based on the initial word frequency evaluation values corresponding to the first and second input candidate combination strings. If the distribution ratio of the word frequency evaluation values is less than or equal to the distribution ratio threshold, the server does not need to filter the second input candidate combination string obtained from the data to be processed. Optionally, if the distribution ratio of the word frequency evaluation values is greater than the distribution ratio threshold, the server can filter the model candidate sub-data associated with the second input candidate combination string from the data to be processed to obtain the second model candidate data to be filtered.
[0134] For example, if the data to be processed obtained by the server is the text meta-type M shown in Table 1 above. i If the initial model candidate data corresponds to a quintuple type (e.g., a five-element type), the server can determine that the distribution ratio (i.e., the word frequency evaluation value distribution ratio) between the initial word frequency evaluation value (e.g., 130) corresponding to the first input candidate combination string of the quintuple type data and the initial word frequency evaluation value (e.g., 861) corresponding to the second input candidate combination string is approximately 0.151. In this case, the server can determine that the word frequency evaluation value distribution ratio is less than the distribution ratio threshold (e.g., 20), and therefore the server does not need to filter out the model candidate sub-data corresponding to the second input candidate combination string from the quintuple type data.
[0135] Furthermore, when determining the second candidate model data to be filtered, the server can detect whether there is initial candidate model data belonging to the target text metatype among the second candidate model data to be filtered. In this embodiment, the initial candidate model data belonging to the target text metatype can be referred to as target type data. Here, target type data can include initial candidate model data corresponding to binary types (i.e., binary type data) and initial candidate model data corresponding to ternary types (i.e., ternary type data). If the server detects that there is no target type data among the second candidate model data to be filtered, the server can directly determine the second candidate model data to be filtered as the third candidate model data to be filtered. Optionally, if the server detects that there is target type data among the second candidate model data to be filtered, the server can filter the second candidate model data based on the word frequency evaluation value filtering strategy 42L to obtain the third candidate model data to be filtered.
[0136] The target type data here may include a first initial text and a second initial text associated with the target input candidate combination string. The initial word frequency evaluation value of the second initial text is lower than that of the first initial text, and the first initial text is the initial candidate text with the highest initial word frequency evaluation value corresponding to the target input candidate combination string. This means that the first initial text is the best candidate text under the target input candidate combination string, while the second initial text is the second best candidate text under the same target input candidate combination string. Furthermore, the server can filter the target type data based on the initial word frequency evaluation values of the first and second initial texts, and the word frequency evaluation value filtering strategy 42L, to obtain the third model candidate data to be filtered.
[0137] The word frequency evaluation value filtering strategy 42L here can include four filtering sub-strategies, specifically a first filtering sub-strategy, a second filtering sub-strategy, a third filtering sub-strategy, and a fourth filtering sub-strategy. The first filtering sub-strategy instructs the server to filter out model candidate sub-data corresponding to other candidate texts besides the first initial text when the initial word frequency evaluation value of the first initial text is less than or equal to a first word frequency threshold (e.g., 10). The second filtering sub-strategy instructs the server to filter out model candidate sub-data corresponding to other candidate texts besides the first initial text when the word frequency difference between the initial word frequency evaluation values of the first and second initial texts is greater than a second word frequency threshold (e.g., 100). The third filtering sub-strategy instructs the server to filter out model candidate sub-data under the target input candidate combination string when both the initial word frequency evaluation values of the first and second initial texts are less than a third word frequency threshold (e.g., 6). The fourth filtering sub-policy here is used to instruct the server to filter out model candidate sub-data corresponding to other candidate texts besides the first and second initial texts when the difference between the initial word frequency evaluation value of the first initial text and the initial word frequency evaluation value of the second initial text is greater than the fourth word frequency threshold (e.g., 10) and the initial word frequency evaluation value of the second initial text is less than the fifth word frequency threshold (e.g., 60).
[0138] For example, if the target type data obtained by the server is the text meta-type M shown in Table 1 above. iFor the initial model candidate data corresponding to (e.g., ternary type), for the target input candidate combination string 1 shown in Table 1 above (e.g., the input string is "empty"), the server, based on the word frequency evaluation value corresponding to each candidate text under the target input candidate combination string 1, can determine that the first initial text is the candidate text "love" and the second initial text is the candidate text "think". The server can determine that neither the first initial text nor the second initial text corresponding to the target input candidate combination string 1 conforms to the above four filtering sub-strategies. At this time, the server can retain the model candidate sub-data under the target input candidate combination string 1.
[0139] For example, if the target type data obtained by the server is the text meta-type M shown in Table 1 above... i For the initial model candidate data corresponding to the ternary type (e.g., the target input candidate combination string 2 shown in Table 1 above, e.g., the input string is "sh"), the server, based on the word frequency evaluation value corresponding to each candidate text under the target input candidate combination string 2, can determine that the first initial text is the candidate text "life" and the second initial text is the candidate text "harm". The server can determine that the first initial text and the second initial text corresponding to the target input candidate combination string 2 conform to the second filtering sub-strategy among the above four filtering sub-strategies. At this time, the server can filter the model candidate sub-data corresponding to other candidate texts under the target input candidate combination string 2 except for the first initial text, that is, filter the model candidate sub-data corresponding to the candidate text "harm" and the model candidate sub-data corresponding to the candidate text "review".
[0140] Furthermore, since commonly used words exist locally on the client side, in order to reduce redundancy caused by data transmission between the server and the client, the server can determine the candidate data for the third filter model based on the above. Figure 4 The commonly used words filtering strategy 43L shown here filters the commonly used words. Here, "commonly used words" can refer to the N-gram model data derived from combining and splitting the top Z (e.g., 20,000) two- and three-character words that belong to the system's word type and rank in terms of word frequency evaluation value under big data statistics. This N-gram model data refers to the matching relationship between words obtained from big data statistics based on the target object (i.e., user) input. N-gram refers to the semantic matching relationship between the last language segment and the preceding N-1 language segments in the corresponding input string. For example, in five-gram type data, it refers to the candidate text and its corresponding word frequency evaluation value, given the text data corresponding to the four text elements (e.g., "I don't want to go") and the input candidate combination strings associated with the first character input string (e.g., "empty", "s", "sh", etc.).
[0141] It should be understood that the server can be based on Figure 4The common word filtering strategy 43L shown uses common words to perform text matching on the initial candidate text belonging to the target text metatype in the third candidate data to be filtered. If there are no common words in the third candidate data to be filtered, the server can determine the third candidate data to be filtered as the target model candidate data. Optionally, if there are common words matched in the third candidate data to be filtered, the server can filter the model candidate sub-data corresponding to the matched common words in the third candidate data to obtain the target model candidate data. Here, the model candidate sub-data corresponding to a common word includes an input candidate combination string corresponding to a common word and an initial word frequency evaluation value corresponding to a common word. In this embodiment, the initial candidate text in the target model candidate data can be referred to as the first candidate text determined by the server based on the first character input string and the target historical text data, and the initial word frequency evaluation value corresponding to the initial candidate text in the target model candidate data can be determined as the first word frequency evaluation value corresponding to the first candidate text.
[0142] Furthermore, to reduce resource consumption during data transmission, the server can also obtain a metaword identifier mapping table to store the mapping relationship between metawords and metaword identifiers (e.g., metaword IDs). Here, metawords can be candidate texts belonging to the system word type and having a high word frequency. For example, the metaword identifier corresponding to metaword 1 (e.g., "hello") can be metaword identifier 1. For instance, the server can match the first candidate text in the target model candidate data based on the metawords in the metaword identifier mapping table. If the matched first candidate text in the target model candidate data contains a metaword, the server can obtain the metaword identifier corresponding to the matched metaword from the metaword identifier mapping table, and then perform data compression processing on the target model candidate data based on the metaword identifier to obtain a compressed data stream for sending to the client. For example, the server can transmit metawords according to their metaword identifiers, convert the input string from a byte stream to a bit stream, and transmit it using a flexible and efficient language platform-independent structured data representation method (e.g., Protobuf).
[0143] Step S102: When receiving the target model candidate data returned by the server, obtain the target object input string after updating the first character input string. When the target model candidate data meets the model frequency tuning condition, adjust the first word frequency evaluation value corresponding to the first candidate text based on the matching mapping relationship between the target object input string and the target model candidate data to obtain the second word frequency evaluation value corresponding to the first candidate text.
[0144] Specifically, the client can receive a compressed data stream generated by the server for the target model candidate data, and then parse the compressed data stream to obtain the target model candidate data. Furthermore, the client can obtain the input string based on its first character (e.g., ...). Figure 2 The target object input string (e.g., the object input string 21d shown) is updated by the object input string 21d shown. Figure 2 Given the object input string 22d shown, the client can determine the matching mapping relationship between the target object input string and the target model candidate data based on the model matching rules for the target model candidate data. When the matching mapping relationship indicates that the target model candidate data meets the model frequency modulation condition, the client can determine the frequency modulation evaluation parameters corresponding to the matching mapping relationship and the text word type corresponding to the first candidate text. Then, based on the frequency modulation evaluation parameters and the text word type corresponding to the first candidate text, the client can adjust the first word frequency evaluation value corresponding to the first candidate text to obtain the second word frequency evaluation value corresponding to the first candidate text.
[0145] For better understanding, please refer to [link / reference]. Figure 5 , Figure 5 This is a schematic diagram illustrating a client's use of model data according to an embodiment of this application. For example... Figure 5 As shown, the client in this application embodiment can run on the above-described... Figure 1 Any terminal device in the terminal device cluster in the corresponding embodiment, for example, terminal device 100a.
[0146] It should be understood that when the client receives the target model candidate data sent by the server, it can store the target model candidate data and simultaneously obtain the target object input string updated based on the first character input string. Furthermore, the client can obtain the model matching rules for the target model candidate data to determine the model matching result corresponding to each first candidate text in the target model candidate data. These model matching rules can include matching rule 51G (i.e., the first matching rule) and matching rule 52G (i.e., the second matching rule). The model data matching priority of matching rule 51G can be: pentagonal data with input string > pentagonal data without input string > quaternary data with input string > quaternary data without input string > ternary data with input string > ternary data without input string > binary data with input string > binary data without input string. Matching rule 52G is used for precise searching, that is, finding model candidate sub-data in the target model candidate data whose input candidate combination string is completely consistent with the target object input string. The matching rule 52G is used for fuzzy search, that is, to find model candidate sub-data in the target model candidate data whose prefix matches the input candidate combination string of the target object input string.
[0147] The client can precisely search for model candidate sub-data that matches the target object input string in the target model candidate data sent by the server, according to the model data matching priority in matching rule 51G. If the client finds model candidate sub-data that matches the target object input string in the target model candidate data, the client can determine the found model candidate sub-data as the first model candidate sub-data, and determine the matching mapping relationship corresponding to the first model candidate sub-data as the first matching mapping relationship (i.e., the exact matching mapping relationship). Then, the client can determine the model matching result of the first model candidate sub-data based on the first matching mapping relationship.
[0148] For example, when the target input string is "sh" and the target historical text data is "I don't want to go", the target model candidate data received by the client can include the text meta-type M shown in Table 1 above. i (For example, 5-gram type) The candidate model sub-data corresponding to the candidate text "life". At this time, the client can determine the matching mapping relationship corresponding to the candidate model sub-data of the candidate text "life" as the first matching mapping relationship based on matching rule 51G, and the model matching result corresponding to the candidate text "life" can include the hit text meta-type (for example, 5-gram with input string), whether the input string is hit (for example, yes), whether the input string is completely matched (for example, yes), and the hit word frequency evaluation value (for example, 290).
[0149] Optionally, if the client fails to find a model candidate sub-data that precisely matches the target object input string according to the model data matching priority in matching rule 51G, the client can continue the search based on matching rule 52G. When the client finds a model candidate sub-data in the target model candidate sub-data that matches the prefix of the target object input string, the client can determine the found model candidate sub-data as the second model candidate sub-data, and determine the matching mapping relationship corresponding to the second model candidate sub-data as the second matching mapping relationship (i.e., the fuzzy matching mapping relationship). Then, the client can determine the model matching result of the second model candidate sub-data based on the second matching mapping relationship.
[0150] For example, when the target input string is "sh" and the target historical text data is "I don't want to go", the target model candidate data received by the client can include the text meta-type M shown in Table 1 above. i(For example, a quintuple type) The candidate text "is" corresponds to the model candidate sub-data. At this time, the client can determine the matching mapping relationship corresponding to the model candidate sub-data corresponding to the candidate text "is" as the second matching mapping relationship based on matching rule 52G, and the model matching result corresponding to the candidate text "is" can include the hit text meta-type (for example, a quintuple type), whether the input string is hit (for example, yes), whether the input string is completely matched (for example, no), and the hit word frequency evaluation value (for example, 70).
[0151] Furthermore, the client can obtain Figure 5 The model frequency tuning conditions are shown below. Specifically, if the hit text metatype indicated by the model matching result corresponding to the first candidate text is less than a pre-set text metatype (e.g., a four-gram type), the hit word frequency evaluation value is greater than or equal to the client's word frequency threshold (e.g., 15), and the first candidate text belongs to a client-set word, then the client determines that the model matching result corresponding to the first candidate text does not meet the model frequency tuning conditions. Conversely, if the model matching result corresponding to the first candidate text does not meet the model frequency tuning conditions, then the client determines that the model matching result corresponding to the first candidate text does meet the model frequency tuning conditions.
[0152] Here, the client-side setting words can include a first setting word (i.e., a user-created word), a second setting word (i.e., a word from the user's history), a third setting word (i.e., a hot word in the user's input), and a fourth setting word (i.e., a candidate word for error correction). The first setting word refers to user-created candidate text that is not stored locally on the client. The second setting word refers to candidate text whose text metatype in the client's history is binary and whose screen appearance count is greater than or equal to a first screen appearance count threshold (e.g., 2). The third setting word can be a first object word that fully matches the input string (i.e., a candidate text belonging to the second text word type), whose screen appearance count is greater than or equal to a second screen appearance count threshold (e.g., 1) and whose last screen appearance timestamp belongs to the first count region (e.g., the most recent 15 times). Optionally, the third setting word can also be a second object word that fully matches the input string, whose screen appearance count is greater than or equal to a third screen appearance count threshold (e.g., 2) and whose last screen appearance timestamp belongs to the second count region (e.g., the most recent 20 times).
[0153] Furthermore, when the client determines that the model matching result corresponding to each first candidate text satisfies the model frequency tuning condition, that is, when the matching mapping relationship between the target object input string and the target model candidate data satisfies the model frequency tuning condition, the client can obtain the model frequency tuning rule 53G and perform frequency tuning on the first candidate text. For example, the client can determine the frequency tuning evaluation parameters corresponding to the matching mapping relationship and the text word type corresponding to the first candidate text, and then adjust the first word frequency evaluation value corresponding to the first candidate text based on the frequency tuning evaluation parameters and the text word type corresponding to the first candidate text to obtain the second word frequency evaluation value corresponding to the first candidate text. Among them, the text word type in this application embodiment may include a first text word type (i.e., system word type) and a second text word type (i.e., object word type). Among them, candidate text belonging to the system word type refers to candidate text that the target object has not been displayed on the client; candidate text belonging to the object word type is candidate text that the target object has been displayed on the client.
[0154] Specifically, when the matching mapping relationship is the first matching mapping relationship, the frequency modulation evaluation parameter determined by the client can be the first parameter (e.g., 0 points). When the matching mapping relationship is the second matching mapping relationship, the frequency modulation evaluation parameter determined by the client can be the second parameter (e.g., -20 points). That is, the client can adaptively penalize it.
[0155] If the client identifies a first candidate text containing a text of the target text metatype and a text word type of the first type (i.e., the first text to be adjusted), then the client can adjust the text word type of the first text to be adjusted from the first text word type to the second text word type. Then, based on the word frequency of the second text word type and the frequency modulation evaluation parameter of the first text to be adjusted, the client can adjust the first word frequency evaluation value of the first text to be adjusted to obtain the second word frequency evaluation value. For example, the client can sum the first word frequency evaluation value (e.g., 100 points), the word frequency adjustment parameter determined based on the word frequency (e.g., 10 points), and the frequency modulation evaluation parameter (e.g., -20) of the first text to be adjusted to obtain the second word frequency evaluation value (e.g., 90 points).
[0156] If the client identifies a first candidate text containing a target text metatype and a second-type word type (i.e., a second text to be adjusted), the client can directly adjust the first word frequency evaluation value of the second text to be adjusted based on the frequency modulation evaluation parameter corresponding to that second text to obtain a second word frequency evaluation value. For example, the client can sum the first word frequency evaluation value (e.g., 50 points) and the frequency modulation evaluation parameter (e.g., 0 points) corresponding to the second text to be adjusted to obtain the second word frequency evaluation value (e.g., 50 points).
[0157] If the client identifies a third text to be adjusted (i.e., a text that does not belong to the target text metatype (e.g., a quadratic or quinary type) among the first candidate texts, the client can directly adjust the first term frequency evaluation value corresponding to the third text to obtain a second term frequency evaluation value based on the frequency modulation evaluation parameters corresponding to the third text. For example, the second term frequency evaluation value corresponding to the third text can be obtained by performing a non-linear operation (e.g., squaring) on the term frequency evaluation value obtained by summing the first term frequency evaluation value and the frequency modulation evaluation parameters corresponding to the third text.
[0158] Furthermore, the client can determine the second word frequency evaluation value corresponding to the first candidate text based on the second word frequency evaluation values corresponding to the texts to be adjusted, so that subsequent sorting processing can be performed based on the second word frequency evaluation value corresponding to the first candidate text and the client word frequency evaluation value corresponding to the second candidate text, thereby obtaining... Figure 5 The candidate ranking results are shown.
[0159] Therefore, it can be seen that the model frequency modulation rule of this application embodiment can be scaled and adjusted based on the local binary and ternary system word frequency modulation strategy and the local binary and ternary user word frequency modulation strategy, supplementing the frequency modulation strategy of quaternary type data and quinary type data, and the reward order for frequency modulation of the first candidate text is consistent with the model matching rule.
[0160] Step S103: Obtain the client-side word frequency evaluation value corresponding to the second candidate text that matches the target historical text data and the target object input string. Based on the second word frequency evaluation value corresponding to the first candidate text and the client-side word frequency evaluation value corresponding to the second candidate text, sort the first candidate text and the second candidate text to obtain the candidate sorting result.
[0161] Specifically, the client can retrieve a second candidate text that matches the target historical text data and the target object input string locally, and then determine the client-side word frequency evaluation value corresponding to the second candidate text. Further, the client can identify the first and second candidate texts as candidate texts to be sorted, and determine the text word type of the candidate texts to be sorted; wherein, the candidate texts to be sorted here include a first text to be sorted belonging to the first text word type and a second text to be sorted belonging to the second text word type. It is understood that the client can sort the first text to be sorted (e.g., in descending order) based on the word frequency evaluation value of the first text to be sorted to obtain a first sorting result; similarly, it can sort the second text to be sorted (e.g., in descending order) based on the word frequency evaluation value of the second text to be sorted to obtain a second sorting result. The first sorting result can then be arranged after the second sorting result to obtain the candidate sorting result.
[0162] The first sorting result obtained by the client can be Figure 2 The candidate text shown is “life” with a word frequency evaluation value of 3 (e.g., 243 points), “is” with a word frequency evaluation value of 4 (e.g., 182 points), “speak” with a word frequency evaluation value of 5 (e.g., 170 points), and “command” with a word frequency evaluation value of 6 (e.g., 60 points). The second ranking result can be… Figure 2 The candidate text shown is "harm" with a word frequency evaluation value of 1 (e.g., 230 points), and the candidate text is "audit" with a word frequency evaluation value of 2 (e.g., 150 points). In this case, the final candidate ranking result obtained by the client after arranging the first ranking result after the second ranking result can be... Figure 2 The candidate texts shown in region 2Q2 are: “harm”, “audit”, “life”, “is”, “speak”, and “command”.
[0163] Among these innovations, a new edge-cloud collaboration model was constructed by pre-fetching model data (i.e., candidate data for the target model) during the text input cycle. This avoids the link-sensitive requirements of real-time cloud deployment and also reduces a lot of invalid cloud deployments, greatly improving cloud utilization. At the same time, the pre-fetched model data can be better combined with the overall input behavior for frequency tuning and ranking to obtain more accurate candidate ranking results, thereby improving the input method's first choice rate.
[0164] Further, please see Figure 6 , Figure 6 This is a flowchart illustrating a data processing method provided in an embodiment of this application. Figure 6As shown, this method can be executed interactively by a client with frequency modulation and sorting capabilities and a server with cloud-based model data distribution capabilities. The client can run on the aforementioned... Figure 1 Any terminal device in the terminal device cluster shown, for example, terminal device 100a. The server can be any of the aforementioned terminal devices. Figure 1 The server 10F is shown. This method may include at least the following steps S201-S206:
[0165] Step S201: The client obtains the first character input string with text word formation function and the target historical text data in the text input area, and generates a business request.
[0166] In step S202, the client sends a service request to the server.
[0167] In step S203, the server uses the text word formation function to obtain target model candidate data that matches the target historical text data and the first character input string.
[0168] In step S204, the server returns the target model candidate data to the client.
[0169] In step S205, the client obtains the target object input string after updating the first character input string. When the target model candidate data meets the model frequency tuning condition, the first word frequency evaluation value corresponding to the first candidate text is adjusted based on the matching mapping relationship between the target object input string and the target model candidate data to obtain the second word frequency evaluation value corresponding to the first candidate text.
[0170] Step S206: The client obtains the client word frequency evaluation value corresponding to the second candidate text that matches the target historical text data and the target object input string. Based on the second word frequency evaluation value corresponding to the first candidate text and the client word frequency evaluation value corresponding to the second candidate text, the first candidate text and the second candidate text are sorted to obtain the candidate sorting result.
[0171] For specific implementation methods of steps S201-S206, please refer to the above. Figure 3 The descriptions of steps S101-S103 in the corresponding embodiments will not be repeated here.
[0172] For better understanding, please refer to [link / reference]. Figure 7 , Figure 7 This is a flowchart illustrating the overall interactive process of cloud frequency modulation as provided in an embodiment of this application. Figure 7 As shown, the client here can be a client with frequency modulation and sorting capabilities, and this client can run on the above-mentioned... Figure 1 Any terminal device in the terminal device cluster shown, for example, terminal device 100a. The server can be any of the aforementioned terminal devices. Figure 1 The server shown is 10F.
[0173] like Figure 7 As shown, a text input cycle refers to the time it takes for the client to convert an object input string into text data for display in the text input area. It should be understood that when the target object corresponding to the client performs an input operation on the text input area, the client can be considered to have started a new text input cycle. At this time, the client can obtain the first character input string with text word formation function indicated by the target object's input operation, as well as the target's historical text data, and then generate a business request. At this point, the client can execute step S71 to send a business request to the server.
[0174] When the server receives the service request, it can use the text word formation function to obtain target model candidate data that matches the target historical text data and the first character input string. Then, it can execute step S72 to send the target model candidate data to the client. The target model candidate data may include the first candidate text determined by the server and the first word frequency evaluation value corresponding to the first candidate text.
[0175] Furthermore, when the client executes step S73 to receive target model candidate data, it can obtain the target object input string after updating the first character input string. Then, when the target model candidate data meets the model frequency tuning condition, the client can execute step S74, using the model data. That is, the client can adjust the first word frequency evaluation value corresponding to the first candidate text based on the matching mapping relationship between the target object input string and the target model candidate data to obtain the second word frequency evaluation value corresponding to the first candidate text. Simultaneously, the client can also obtain the second candidate text that matches the target historical text data and the target object input string, as well as the client word frequency evaluation value corresponding to the second candidate text. Then, based on the second word frequency evaluation value corresponding to the first candidate text and the client word frequency evaluation value corresponding to the second candidate text, the first candidate text and the second candidate text can be sorted to obtain the candidate sorting result.
[0176] Furthermore, the target object can be the target candidate text in the candidate ranking results (e.g., Figure 2 The candidate text "harm" is shown. The trigger operation is executed to make the client put the candidate text "harm" on the screen to the text input area, that is, to display the text data such as "I do not want to cause harm" in the text input area.
[0177] This application provides a novel end-to-cloud collaborative model to address the issue of sorting accuracy in target object typing input, thereby improving the typing input experience. Specifically, the server in this application can compress and store N-ary model data from big data statistics into a data compression list (i.e., a Redis database). Simultaneously, a frequency modulation server internally acquires target model candidate data and externally provides cloud-based model data delivery, thus constructing a novel end-to-cloud prefetching channel. This allows the client to obtain the cloud-based model data (including the first candidate text) determined by the server based on the frequency modulation service when initiating a business request based on the first character input string and target historical text data. Furthermore, the client can receive, cache, and use model data within the current input cycle, thus incorporating a cloud model data frequency modulation algorithm into the original frequency modulation algorithm, resulting in better overall frequency modulation and sorting performance. Additionally, the server in this solution can compress the target model candidate data, providing an optimized solution for data storage compression and data stream delivery bandwidth compression. This effectively solves the problems of high data storage resource consumption and high data delivery bandwidth caused by prefetching model data, reducing the dependence of business requests on link latency.
[0178] Further, please see Figure 8 , Figure 8 This is a schematic diagram of the structure of a data processing apparatus provided in an embodiment of this application. The data processing apparatus 1 can be a computer program (including program code) running on a computer device; for example, the data processing apparatus 1 is an application software. The data processing apparatus 1 can be used to execute corresponding steps in the method provided in the embodiments of this application. Figure 8 As shown, the data processing device 1 can run on a client with frequency modulation sorting function, and the client can run on the aforementioned... Figure 1 Any terminal device in the terminal device cluster in the corresponding embodiment, for example, terminal device 100a. The data processing device 1 may include: a request generation module 10, a word frequency adjustment module 20, and a candidate sorting module 30.
[0179] The request generation module 10 is used to obtain the first character input string with text word formation function and the target historical text data in the text input area, and generate a business request to be sent to the server; the business request is used to instruct the server to obtain target model candidate data that matches the target historical text data and the first character input string based on the text word formation function; the target model candidate data includes the first candidate text and the first word frequency evaluation value corresponding to the first candidate text.
[0180] The request generation module 10 includes: a first character input string determination unit 101, a text element quantity statistics unit 102, a first historical text determination unit 103, a request generation unit 104, a timestamp sorting unit 105, and a second historical text determination unit 106.
[0181] The first character input string determination unit 101 is used to display a text input area including initial historical text data, respond to input operations on the text input area, and use the object input string corresponding to the input operation as the first character input string with text word formation function.
[0182] The text element counting unit 102 is used to obtain the input feature information of the target object for the initial historical text data and count the number of text elements corresponding to the text elements in the initial historical text data; a text element is used to indicate the text data entered by the target object in a text input cycle; the text input cycle is used to indicate the conversion time of the client to convert the historical input object string into text data to be displayed in the text input area;
[0183] The first historical text determination unit 103 is used to determine the initial historical text data as the target historical text data if the number of text elements is less than or equal to the text element number threshold K; K is a positive integer.
[0184] The request generation unit 104 is used to generate a business request to be sent to the server based on the first character input string and the target historical text data.
[0185] The timestamp sorting unit 105 is used to sort the input timestamps corresponding to each text element in the input feature information if the number of text elements is greater than the text element number threshold K, so as to obtain the time sorting result.
[0186] The second historical text determination unit 106 is used to obtain the last K input timestamps from the time sorting result, and to obtain the text data corresponding to the last K input timestamps from the initial historical text data, and to use the obtained text data as the target historical text data.
[0187] The specific implementation methods of the first character input string determination unit 101, the text element quantity counting unit 102, the first historical text determination unit 103, the request generation unit 104, the timestamp sorting unit 105, and the second historical text determination unit 106 can be found above. Figure 3 The description of step S101 in the corresponding embodiments will not be repeated here.
[0188] The word frequency adjustment module 20 is used to obtain the target object input string after updating the first character input string when receiving the target model candidate data returned by the server. When the target model candidate data meets the model frequency adjustment conditions, the first word frequency evaluation value corresponding to the first candidate text is adjusted based on the matching mapping relationship between the target object input string and the target model candidate data to obtain the second word frequency evaluation value corresponding to the first candidate text.
[0189] The word frequency adjustment module 20 includes: a data stream parsing unit 201, a target input string acquisition unit 202, a matching mapping relationship determination unit 203, a frequency modulation parameter determination unit 204, and a word frequency adjustment unit 205.
[0190] The data stream parsing unit 201 is used to receive the data compressed stream generated by the server for the target model candidate data, and to parse the data compressed stream to obtain the target model candidate data.
[0191] The target input string acquisition unit 202 is used to acquire the target object input string after updating the first character input string;
[0192] The matching mapping relationship determination unit 203 is used to determine the matching mapping relationship between the target object input string and the target model candidate data based on the model matching rules for the target model candidate data;
[0193] The frequency modulation parameter determination unit 204 is used to determine the frequency modulation evaluation parameters corresponding to the matching mapping relationship and the text word type corresponding to the first candidate text when the matching mapping relationship indicates that the target model candidate data meets the model frequency modulation conditions;
[0194] The word frequency adjustment unit 205 is used to adjust the first word frequency evaluation value corresponding to the first candidate text based on the frequency adjustment evaluation parameters and the text word type corresponding to the first candidate text, so as to obtain the second word frequency evaluation value corresponding to the first candidate text.
[0195] The word frequency adjustment unit 205 includes: a text word type adjustment subunit 2051, a word frequency adjustment subunit 2052, and a word frequency determination subunit 2053.
[0196] The text word type adjustment subunit 2051 is used to adjust the text word type of the text to be adjusted from the first text word type to the second text word type if there is a text to be adjusted in the first candidate text that belongs to the target text meta type and whose text word type is the first text word type.
[0197] The word frequency adjustment subunit 2052 is used to adjust the first word frequency evaluation value of the text to be adjusted based on the number of times the second text word type is used and the frequency adjustment evaluation parameters, so as to obtain the second word frequency evaluation value of the text to be adjusted.
[0198] The word frequency determination subunit 2053 is used to determine the second word frequency evaluation value corresponding to the first candidate text based on the second word frequency evaluation value corresponding to the text to be adjusted.
[0199] The specific implementation methods of the text word type adjustment subunit 2051, word frequency adjustment subunit 2052, and word frequency determination subunit 2053 can be found in the above description. Figure 3 The description of frequency modulation of the first candidate text in the corresponding embodiment will not be repeated here.
[0200] The specific implementation methods of the data stream parsing unit 201, the target input string acquisition unit 202, the matching mapping relationship determination unit 203, the frequency modulation parameter determination unit 204, and the word frequency adjustment unit 205 can be found above. Figure 3 The description of step S102 in the corresponding embodiment will not be repeated here.
[0201] The candidate sorting module 30 is used to obtain the client word frequency evaluation value corresponding to the second candidate text that matches the target historical text data and the target object input string, and to sort the first candidate text and the second candidate text based on the second word frequency evaluation value corresponding to the first candidate text and the client word frequency evaluation value corresponding to the second candidate text to obtain the candidate sorting result.
[0202] The candidate sorting module 30 includes: a client word frequency acquisition unit 301, a text to be sorted determination unit 302, a first sorting processing unit 303, a second sorting processing unit 304, and a sorting result determination unit 305.
[0203] The client-side word frequency acquisition unit 301 is used to acquire the client-side word frequency evaluation value corresponding to the second candidate text that matches the target historical text data and the target object input string;
[0204] The text to be sorted determination unit 302 is used to determine the first candidate text and the second candidate text as candidate texts to be sorted, and to determine the text word type of the candidate texts to be sorted; the candidate texts to be sorted include the first text to be sorted belonging to the first text word type and the second text to be sorted belonging to the second text word type;
[0205] The first sorting processing unit 303 is used to sort the first text to be sorted based on the word frequency evaluation value of the first text to be sorted, and obtain a first sorting result;
[0206] The second sorting processing unit 304 is used to sort the second text to be sorted based on the word frequency evaluation value of the second text to be sorted, and obtain a second sorting result;
[0207] The sorting result determination unit 305 is used to arrange the first sorting result after the second sorting result to obtain the candidate sorting result.
[0208] The specific implementation methods of the client-side word frequency acquisition unit 301, the text to be sorted determination unit 302, the first sorting processing unit 303, the second sorting processing unit 304, and the sorting result determination unit 305 can be found above. Figure 3 The description of step S103 in the corresponding embodiment will not be repeated here.
[0209] The specific implementation methods of the request generation module 10, the word frequency adjustment module 20, and the candidate sorting module 30 can be found in the above description. Figure 3 The descriptions of steps S101-S103 in the corresponding embodiments will not be repeated here. Furthermore, the beneficial effects of using the same method will also not be repeated.
[0210] Further, please see Figure 9 , Figure 9 This is a schematic diagram of the structure of a data processing apparatus provided in an embodiment of this application. The data processing apparatus 2 can be a computer program (including program code) running on a computer device; for example, the data processing apparatus 2 is application software. The data processing apparatus 2 can be used to execute corresponding steps in the method provided in the embodiments of this application. Figure 9 As shown, the data processing device 2 can run on a server with cloud-based model data distribution capabilities, and this server can be used for the aforementioned... Figure 1 The corresponding embodiment is server 10F. The data processing device 2 may include: a request acquisition module 40, a target model data acquisition module 50, and a target model data sending module 60.
[0211] The request acquisition module 40 is used to acquire the business request sent by the client; the business request is determined by the client based on the first character input string with text word formation function and the target historical text data in the text input area;
[0212] The target model data acquisition module 50 is used to acquire target model candidate data that matches the target historical text data and the first character input string based on the text word formation function; the target model candidate data includes the first candidate text and the first word frequency evaluation value corresponding to the first candidate text.
[0213] Wherein, the number of text elements corresponding to text elements in the target historical text data is N; N is a positive integer less than or equal to the threshold K for the number of text elements;
[0214] The target model data acquisition module 50 includes: a request identifier mapping unit 501, an initial model data acquisition unit 502, and a filtering unit 503.
[0215] The request identifier mapping unit 501 is used to map the target historical text data and the first character input string into request identifiers corresponding to N text metatypes through a tree structure; the N text metatypes include text metatype M. i ; i is a positive integer less than or equal to N; text metatype M i The number of text elements indicated is a positive integer greater than 1 and less than or equal to (N+1);
[0216] The initial model data acquisition unit 502 is used for data acquisition based on text metatype M. i The corresponding request identifier is used to obtain the text metatype M. i The corresponding initial model candidate data.
[0217] The initial model data acquisition unit 502 includes: a request generation subunit 5021, a candidate combination string acquisition subunit 5022, an initial word frequency acquisition subunit 5023, and an initial model data determination subunit 5024.
[0218] This request generates subunit 5021, used for text metatype M. i The corresponding request identifier generates a text meta-type M. i The corresponding resource acquisition request i;
[0219] The candidate combination string acquisition subunit 5022 is used to acquire a data compression list for compressing and storing model resources. Based on the resource acquisition request i and the data compression list, it acquires the input candidate combination string associated with the first character input string.
[0220] The initial word frequency acquisition subunit 5023 is used to determine the initial candidate text corresponding to the input candidate combination string based on the text word formation function, and to obtain the initial word frequency evaluation value corresponding to the initial candidate text.
[0221] The initial model data identifies subunit 5024, which is used to perform text meta-type M-based modeling. i The determined input candidate combination string, the corresponding initial candidate text, and the initial word frequency evaluation value of the initial candidate text are used as the text metatype M. i The corresponding initial model candidate data; the first word frequency evaluation value includes the initial word frequency evaluation value after filtering the initial candidate text.
[0222] The specific implementation methods of the request generation subunit 5021, the candidate combination string acquisition subunit 5022, the initial word frequency acquisition subunit 5023, and the initial model data determination subunit 5024 can be found above. Figure 4 The description of obtaining the initial model candidate data in the corresponding embodiments will not be repeated here.
[0223] The filtering unit 503 is used to filter the initial model candidate data corresponding to the N text meta-types obtained based on the model resource filtering strategy to obtain the target model candidate data.
[0224] The filtering unit 503 includes: a filtering strategy acquisition subunit 5031, a first filtering subunit 5032, a second filtering subunit 5033, and a third filtering subunit 5034.
[0225] The filtering strategy acquisition subunit 5031 is used to acquire model resource filtering strategies; the model resource filtering strategies include input string filtering strategies, word frequency evaluation value filtering strategies for target text metatypes, and common word filtering strategies for target text metatypes.
[0226] The first filtering subunit 5032 is used to determine the initial model candidate data corresponding to the N obtained text meta types as the first model candidate data to be filtered, and to filter the first model candidate data to be filtered based on the input string filtering strategy to obtain the second model candidate data to be filtered.
[0227] The input string filtering strategy includes a first input string filtering strategy; the first input string filtering strategy includes a first type attribute and a second type attribute; the text meta level of the first type attribute is lower than the text meta level of the second type attribute;
[0228] The first filtering subunit 5032 includes: a first data to be filtered determination subunit 50321, a type data determination subunit 50322, a duplicate data filtering subunit 50323, and a second data to be filtered determination subunit 50324.
[0229] The first data to be filtered subunit 50321 is used to determine the initial model candidate data corresponding to the N obtained text meta types as the first model candidate data to be filtered.
[0230] The data type determination subunit 50322 is used to, in the first filterable model candidate data, take the initial model candidate data associated with the first type attribute as the first type data, and take the initial model candidate data associated with the second type attribute as the second type data.
[0231] The duplicate data filtering subunit 50323 is used to filter model candidate sub-data associated with duplicate input candidate combination strings in the first type of data if there are duplicate input candidate combination strings between the first type of data and the second type of data, so as to obtain filtered first type of data.
[0232] The second data to be filtered determination subunit 50324 is used to determine the second candidate data for the filter model based on the filtered first type of data and the second type of data.
[0233] The input string filtering strategy includes a second input string filtering strategy; the second input string filtering strategy includes a distribution ratio threshold.
[0234] The second data to be filtered subunit 50324 is also used for:
[0235] The data to be processed is obtained from the filtered first type of data and second type of data, and the input candidate combination strings in the data to be processed are determined as the input string set; the input string set includes the first input candidate combination string with an empty input string and the second input candidate combination string including the first character input string;
[0236] Based on the initial word frequency evaluation value corresponding to the first input candidate combination string and the initial word frequency evaluation value corresponding to the second input candidate combination string, the distribution ratio of word frequency evaluation values corresponding to the data type to be processed is determined.
[0237] If the distribution ratio of word frequency evaluation values is greater than the distribution ratio threshold, then in the data to be processed, the model candidate sub-data associated with the second input candidate combination string is filtered to obtain the second model candidate data to be filtered.
[0238] The specific implementation methods of the first data to be filtered determination subunit 50321, the type data determination subunit 50322, the duplicate data filtering subunit 50323, and the second data to be filtered determination subunit 50324 can be found above. Figure 4 The description of filtering the candidate data of the first model to be filtered in the corresponding embodiment will not be repeated here.
[0239] The second filtering subunit 5033 is used to filter the second model data to be filtered based on the word frequency evaluation value filtering strategy if there are initial model candidate data belonging to the target text meta type in the second model candidate data to be filtered, so as to obtain the third model candidate data to be filtered.
[0240] The second filtering subunit 5033 includes a target data determination subunit 50331 and a third data to be filtered determination subunit 50332.
[0241] The target data determination subunit 50331 is used to determine the initial model candidate data of the target text metatype as target type data if the second model candidate data to be filtered has initial model candidate data belonging to the target text metatype. The target type data includes a first initial text and a second initial text associated with the target input candidate combination string. The initial word frequency evaluation value corresponding to the second initial text is lower than the initial word frequency evaluation value corresponding to the first initial text, and the first initial text is the initial candidate text with the highest initial word frequency evaluation value corresponding to the target input candidate combination string.
[0242] The third data to be filtered subunit 50332 is used to filter target type data based on the initial word frequency evaluation value corresponding to the first initial text, the initial word frequency evaluation value corresponding to the second initial text, and the word frequency evaluation value filtering strategy, so as to obtain the third model candidate data to be filtered.
[0243] The specific implementation methods of the target data determination subunit 50331 and the third data to be filtered determination subunit 50332 can be found above. Figure 4 The description of filtering the candidate data of the second filter model in the corresponding embodiment will not be repeated here.
[0244] The third filtering subunit 5034 is used to perform text matching on the initial candidate text belonging to the target text metatype in the third candidate data of the model to be filtered based on the common words in the common word filtering strategy. If a common word is matched in the third candidate data of the model to be filtered, the model candidate sub-data corresponding to the matched common word is filtered in the third candidate data of the model to be filtered to obtain the target model candidate data. The model candidate sub-data corresponding to a common word includes the input candidate combination string corresponding to a common word and the initial word frequency evaluation value corresponding to a common word.
[0245] The specific implementation methods of the filtering strategy acquisition subunit 5031, the first filtering subunit 5032, the second filtering subunit 5033, and the third filtering subunit 5034 can be found above. Figure 6 The description of filtering the initial model candidate data in the corresponding embodiments will not be repeated here.
[0246] The specific implementation methods of the request identifier mapping unit 501, the initial model data acquisition unit 502, and the filtering unit 503 can be found in the above description. Figure 6 The description of step S203 in the corresponding embodiments will not be repeated here.
[0247] The target model data sending module 60 is used to return target model candidate data to the client, so that when the client determines that the target model candidate data meets the model frequency tuning conditions, it determines the second word frequency evaluation value corresponding to the first candidate text, and sorts the first candidate text and the second candidate text based on the second word frequency evaluation value corresponding to the first candidate text and the client word frequency evaluation value corresponding to the second candidate text, to obtain the candidate ranking result; the second word frequency evaluation value is obtained by the client after adjusting the first word frequency evaluation value corresponding to the first candidate text based on the matching mapping relationship between the target object input string and the target candidate model data; the target object input string is updated based on the first character input string; the second candidate text is the candidate text obtained by the client that matches the target historical text data and the target object input string.
[0248] The target model data sending module 60 includes: a metaword matching unit 601, a metaword identifier acquisition unit 602, a data compression unit 603, and a data stream return unit 604.
[0249] The metaword matching unit 601 is used to match the first candidate text in the target model candidate data based on the metawords in the metaword identifier mapping table;
[0250] The metaword identifier acquisition unit 602 is used to obtain the metaword identifier corresponding to the matched metaword from the metaword identifier mapping table if the first candidate text matched in the target model candidate data contains a metaword.
[0251] The data compression unit 603 is used to perform data compression processing on the candidate data of the target model based on metaword identifiers to obtain a compressed data stream;
[0252] The data stream return unit 604 is used to return the compressed data stream to the client.
[0253] The specific implementation methods of the metaword matching unit 601, the metaword identifier acquisition unit 602, the data compression unit 603, and the data stream return unit 604 can be found above. Figure 4 The description of data compression processing of candidate data for the target model in the corresponding embodiments will not be repeated here.
[0254] The specific implementation methods of the request acquisition module 40, the target model data acquisition module 50, and the target model data sending module 60 can be found in the above description. Figure 6 The descriptions of steps S201-S206 in the corresponding embodiments will not be repeated here. Furthermore, the beneficial effects of using the same method will also not be repeated.
[0255] Further, please see Figure 10 , Figure 10 This is a schematic diagram of a computer device provided in an embodiment of this application. Figure 10 As shown, the computer device 3000 can be a client with frequency modulation and sorting functions. The computer device 3000 may include: at least one processor 3001, such as a CPU; at least one network interface 3004; a user interface 3003; a memory 3005; and at least one communication bus 3002. The communication bus 3002 is used to implement communication between these components. The user interface 3003 may include a display screen and a keyboard. The network interface 3004 may optionally include a standard wired interface or a wireless interface (such as a Wi-Fi interface). The memory 3005 may be high-speed RAM or non-volatile memory, such as at least one disk storage device. Optionally, the memory 3005 may also be at least one storage device located remotely from the aforementioned processor 3001. Figure 10 As shown, the memory 3005, which serves as a computer storage medium, may include an operating system, a network communication module, a user interface module, and a device control application program.
[0256] exist Figure 10 In the computer device 3000 shown, the network interface 3004 is mainly used for network communication with a server that has cloud model data download function; while the user interface 3003 is mainly used to provide an input interface for users; and the processor 3001 can be used to call the device control application stored in the memory 3005.
[0257] It should be understood that the computer device 3000 described in the embodiments of this application can execute the foregoing text. Figure 3 or Figure 6 The description of the data processing method in the corresponding embodiment can also be performed as described above. Figure 8 The corresponding embodiment relates to the data processing device 1 or Figure 9 The description of the data processing device 2 in the corresponding embodiments will not be repeated here. Furthermore, the beneficial effects of using the same method will also not be repeated here.
[0258] This application also provides a computer-readable storage medium storing a computer program, the computer program including program instructions, which are implemented when executed by a processor. Figure 3 and Figure 6 For details on the data processing methods provided in each step, please refer to [link / reference]. Figure 3 as well as Figure 6 The implementation methods provided for each step will not be elaborated here.
[0259] The computer-readable storage medium can be an internal storage unit of the data transmission apparatus or computer device provided in any of the foregoing embodiments, such as a hard disk or memory of the computer device. The computer-readable storage medium can also be an external storage device of the computer device, such as a plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, etc., provided on the computer device. Furthermore, the computer-readable storage medium may include both internal and external storage units of the computer device. The computer-readable storage medium is used to store the computer program and other programs and data required by the computer device. The computer-readable storage medium can also be used to temporarily store data that has been output or will be output.
[0260] This application also provides a computer program product, which includes a computer program stored in a computer-readable storage medium. A processor of a computer device reads the computer program from the computer-readable storage medium and executes the computer program, enabling the computer device to perform the data processing methods or apparatus described in the preceding embodiments, which will not be repeated here. Furthermore, the beneficial effects of using the same method will also not be repeated here.
[0261] For further details, please see Figure 11 , Figure 11 This is a schematic diagram of the structure of a data processing system provided in an embodiment of this application. The data processing system 3 may include a data processing device 1a and a data processing device 2a. The data processing device 1a may be the one described above. Figure 8 Regarding the data processing device 1 in the corresponding embodiment, it is understood that the data processing device 1a can be integrated into a client with frequency modulation and sorting functions, and the client can run on the aforementioned... Figure 1 The terminal device in the terminal device cluster in the corresponding embodiment is any one of the terminal devices, for example, terminal device 100a. Therefore, it will not be described in detail here. The data processing device 2a can be the one described above. Figure 9 Regarding the data processing device 2 in the corresponding embodiment, it is understood that the data processing device 2a can be integrated into a server with cloud model data distribution capabilities, and this server can be the aforementioned Figure 1 The server 10F in the corresponding embodiment will not be described again here. Furthermore, the beneficial effects of using the same method will also not be described again. For technical details not disclosed in the data processing system embodiments of this application, please refer to the description of the method embodiments of this application.
[0262] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The program can be stored in a computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. The storage medium can be a magnetic disk, optical disk, read-only memory (ROM), or random access memory (RAM), etc.
[0263] The above-disclosed embodiments are merely preferred embodiments of this application and should not be construed as limiting the scope of this application. Therefore, any equivalent variations made in accordance with the claims of this application shall still fall within the scope of this application.
Claims
1. A data processing method, characterized in that, The method is executed by the client and includes: The system acquires the first character input string with text word formation function and the target historical text data in the text input area, and generates a business request to be sent to the server. The business request instructs the server to acquire target model candidate data that matches the target historical text data and the first character input string based on the text word formation function. The target model candidate data includes a first candidate text and a first word frequency evaluation value corresponding to the first candidate text. Upon receiving the target model candidate data returned by the server, the target object input string is obtained after updating the first character input string. When the target model candidate data meets the model frequency tuning condition, the first word frequency evaluation value corresponding to the first candidate text is adjusted based on the matching mapping relationship between the target object input string and the target model candidate data to obtain the second word frequency evaluation value corresponding to the first candidate text. The model frequency tuning condition refers to the condition that the hit text meta-type indicated by the model matching result corresponding to the first candidate text is greater than or equal to the preset text meta-type, or the hit word frequency evaluation value in the model matching result is less than the client word frequency threshold, or the first candidate text does not belong to the client-set word condition. The matching mapping relationship between the target object input string and the target model candidate data is used to indicate whether the target model candidate data meets the model frequency tuning condition. The client-set words include object-created words, object history words, object input hot words, and error correction candidate words. Obtain the client-side word frequency evaluation value corresponding to the second candidate text that matches the target historical text data and the target object input string. Based on the second word frequency evaluation value corresponding to the first candidate text and the client-side word frequency evaluation value corresponding to the second candidate text, sort the first candidate text and the second candidate text to obtain the candidate sorting result.
2. The method according to claim 1, characterized in that, The process of obtaining the first character input string with text word formation function and the target historical text data in the text input area, and generating a business request to be sent to the server, includes: Display a text input area including initial historical text data, and respond to input operations on the text input area by using the object input string corresponding to the input operation as the first character input string with text word formation function; The input feature information of the target object in relation to the initial historical text data is obtained, and the number of text elements corresponding to text elements in the initial historical text data is counted. A text element is used to indicate the text data input by the target object in one text input cycle. The text input cycle is used to indicate the conversion time for the client to convert the historically input object input string into text data for display in the text input area. The input feature information includes the input timestamp corresponding to each text element in the initial historical text data. If the number of text elements is less than or equal to the text element number threshold K, then the initial historical text data is determined as the target historical text data; K is a positive integer; Based on the first character input string and the target historical text data, a business request is generated to be sent to the server.
3. The method according to claim 2, characterized in that, The method further includes: If the number of text elements is greater than the threshold K, then the input timestamp corresponding to each text element in the input feature information is sorted to obtain a time sorting result. Obtain the last K input timestamps from the time sorting results, and obtain the text data corresponding to the last K input timestamps from the initial historical text data, and use the obtained text data as the target historical text data.
4. The method according to claim 1, characterized in that, When receiving the target model candidate data returned by the server, the step involves obtaining the target object input string after updating the first character input string. When the model matching result corresponding to the target model candidate data satisfies the model frequency tuning condition, the step adjusts the first word frequency evaluation value corresponding to the first candidate text based on the matching mapping relationship between the target object input string and the target model candidate data to obtain a second word frequency evaluation value corresponding to the first candidate text, including: Receive the compressed data stream generated by the server for the target model candidate data, and parse the compressed data stream to obtain the target model candidate data; Obtain the target object input string after updating the first character input string; Based on the model matching rules for the target model candidate data, a matching mapping relationship between the target object input string and the target model candidate data is determined. The model matching rules include a first matching rule and a second matching rule. The first matching rule is used to find model candidate sub-data in the target model candidate data whose input candidate combination string is completely consistent with the target object input string. The second matching rule is used to find model candidate sub-data in the target model candidate data whose input candidate combination string has a prefix match with the target object input string. If a completely consistent first model candidate sub-data is found through the first matching rule, the matching mapping relationship is the first matching mapping relationship, which is used to determine the model matching result of the first model candidate sub-data. If a second model candidate sub-data with a consistent prefix is found through the second matching rule, the matching mapping relationship is the second matching mapping relationship, which is used to determine the model matching result of the second model candidate sub-data. When the matching mapping relationship indicates that the target model candidate data meets the model frequency modulation condition, the frequency modulation evaluation parameter corresponding to the matching mapping relationship and the text word type corresponding to the first candidate text are determined; Based on the frequency modulation evaluation parameters and the text word type corresponding to the first candidate text, the first word frequency evaluation value corresponding to the first candidate text is adjusted to obtain the second word frequency evaluation value corresponding to the first candidate text.
5. The method according to claim 4, characterized in that, The step of adjusting the first word frequency evaluation value corresponding to the first candidate text based on the frequency modulation evaluation parameters and the text word type corresponding to the first candidate text to obtain the second word frequency evaluation value corresponding to the first candidate text includes: If there is a text to be adjusted in the first candidate text that belongs to the target text meta type and whose text word type is the first text word type, then the text word type corresponding to the text to be adjusted will be changed from the first text word type to the second text word type; the candidate text corresponding to the first text word type refers to the candidate text that the target object has not been displayed on the client; the candidate text corresponding to the second text word type is the candidate text that the target object has been displayed on the client. Based on the word frequency corresponding to the second text word type and the frequency modulation evaluation parameters, the first word frequency evaluation value corresponding to the text to be adjusted is adjusted to obtain the second word frequency evaluation value corresponding to the text to be adjusted. Based on the second word frequency evaluation value corresponding to the text to be adjusted, the second word frequency evaluation value corresponding to the first candidate text is determined.
6. The method according to claim 1, characterized in that, The process of obtaining the client-side word frequency evaluation value corresponding to the second candidate text that matches the target historical text data and the target object input string, and sorting the first candidate text and the second candidate text based on the second word frequency evaluation value corresponding to the first candidate text and the client-side word frequency evaluation value corresponding to the second candidate text to obtain the candidate sorting result includes: Obtain the client-side word frequency evaluation value corresponding to the second candidate text that matches the target historical text data and the target object input string; The first candidate text and the second candidate text are determined as candidate texts to be sorted, and the text word type of the candidate texts to be sorted is determined; the candidate texts to be sorted include a first candidate text belonging to a first text word type and a second candidate text belonging to a second text word type; Based on the word frequency evaluation value of the first text to be sorted, the first text to be sorted is sorted to obtain a first sorting result; Based on the word frequency evaluation value of the second text to be sorted, the second text to be sorted is sorted to obtain a second sorting result; The first sorting result is arranged after the second sorting result to obtain the candidate sorting result.
7. A data processing method, characterized in that, The method is executed by the server and includes: Obtain the business request sent by the client; the business request is determined by the client based on the first character input string with text word formation function and the target historical text data in the text input area; Based on the text word formation function, target model candidate data that matches the target historical text data and the first character input string is obtained; the target model candidate data includes a first candidate text and a first word frequency evaluation value corresponding to the first candidate text. The target model candidate data is returned to the client, so that when the client determines that the target model candidate data meets the model frequency tuning condition, it determines the second word frequency evaluation value corresponding to the first candidate text, and sorts the first candidate text and the second candidate text based on the second word frequency evaluation value corresponding to the first candidate text and the client word frequency evaluation value corresponding to the second candidate text, to obtain a candidate ranking result; the second word frequency evaluation value is obtained by the client after adjusting the first word frequency evaluation value corresponding to the first candidate text based on the matching mapping relationship between the target object input string and the target candidate model data; the target object input string is updated based on the first character input string. The second candidate text is the candidate text obtained by the client that matches the target historical text data and the target object input string; the model frequency tuning condition refers to the hit text meta-type indicated by the model matching result corresponding to the first candidate text being greater than or equal to the preset text meta-type, or the hit word frequency evaluation value in the model matching result being less than the client word frequency threshold, or the first candidate text not belonging to the client-set word condition; the matching mapping relationship between the target object input string and the target model candidate data is used to indicate whether the target model candidate data meets the model frequency tuning condition; the client-set words include object-created words, object historical text words, object input hot words, and error correction candidate words.
8. The method according to claim 7, characterized in that, The number of text elements corresponding to the text elements in the target historical text data is N; N is a positive integer less than or equal to the threshold K for the number of text elements; The step of obtaining target model candidate data that matches the target historical text data and the first character input string based on the text word formation function includes: Using a tree structure, the target historical text data and the first character input string are mapped to request identifiers corresponding to N text metatypes; the N text metatypes include text metatype M. i ; i is a positive integer less than or equal to N; the text metatype M i The number of text elements indicated is a positive integer greater than 1 and less than or equal to (N+1); Based on the text metatype M i The corresponding request identifier is used to obtain the text metatype M. i Corresponding initial model candidate data; Based on the model resource filtering strategy, the initial model candidate data corresponding to the N text meta-types are filtered to obtain the target model candidate data.
9. The method according to claim 8, characterized in that, The text metatype M i The corresponding request identifier is used to obtain the text metatype M. i The corresponding initial model candidate data includes: Based on the text metatype M i The corresponding request identifier generates a text meta-type M. i The corresponding resource acquisition request i; Obtain a data compression list for compressing and storing model resources; based on the resource acquisition request i and the data compression list, obtain the input candidate combination string associated with the first character input string. Based on the text word formation function, the initial candidate text corresponding to the input candidate combination string is determined, and the initial word frequency evaluation value corresponding to the initial candidate text is obtained. Based on the text metatype M i The determined input candidate combination string, the initial candidate text corresponding to the input candidate combination string, and the initial word frequency evaluation value corresponding to the initial candidate text are used as the text metatype M. i The corresponding initial model candidate data; the first word frequency evaluation value includes the initial word frequency evaluation value after filtering the initial candidate text.
10. The method according to claim 9, characterized in that, The model resource filtering strategy filters the initial model candidate data corresponding to the N text meta-types to obtain target model candidate data, including: Obtain model resource filtering strategies; the model resource filtering strategies include input string filtering strategies, word frequency evaluation value filtering strategies for target text metatypes, and common word filtering strategies for the target text metatypes; The initial model candidate data corresponding to the N text meta types obtained are determined as the first model candidate data to be filtered. Based on the input string filtering strategy, the first model candidate data to be filtered is filtered to obtain the second model candidate data to be filtered. If the second candidate model data to be filtered has initial candidate model data belonging to the target text meta type, then the second candidate model data to be filtered is filtered based on the word frequency evaluation value filtering strategy to obtain the third candidate model data to be filtered. Based on the common words in the common word filtering strategy, text matching is performed on the initial candidate texts belonging to the target text metatype in the third candidate data to be filtered. If the common words are found in the third candidate data to be filtered, the model candidate sub-data corresponding to the matched common words are filtered in the third candidate data to be filtered to obtain the target model candidate data. The model candidate sub-data corresponding to a common word includes the input candidate combination string corresponding to the common word and the initial word frequency evaluation value corresponding to the common word.
11. The method according to claim 10, characterized in that, The input string filtering strategy includes a first input string filtering strategy; the first input string filtering strategy includes a first type attribute and a second type attribute; the text meta level of the first type attribute is lower than the text meta level of the second type attribute; The step of determining the initial model candidate data corresponding to the N text meta-types as the first model candidate data to be filtered, and filtering the first model candidate data to be filtered based on the input string filtering strategy to obtain the second model candidate data to be filtered includes: The initial model candidate data corresponding to the N text meta types obtained are determined as the first model candidate data to be filtered; In the first candidate model data to be filtered, the initial candidate model data associated with the first type attribute is used as the first type data, and the initial candidate model data associated with the second type attribute is used as the second type data. If there is a duplicate input candidate combination string between the first type of data and the second type of data, then filter the model candidate sub-data associated with the duplicate input candidate combination string in the first type of data to obtain the filtered first type of data. Based on the filtered first type of data and the second type of data, candidate data for the second model to be filtered are determined.
12. The method according to claim 11, characterized in that, The input string filtering strategy includes a second input string filtering strategy; the second input string filtering strategy includes a distribution ratio threshold. The process of determining candidate data for the second model to be filtered based on the filtered first type of data and the second type of data includes: The data to be processed is obtained from the filtered first type of data and the second type of data, and the input candidate combination strings in the data to be processed are determined as the input string set; the input string set includes a first input candidate combination string with an empty input string and a second input candidate combination string including the first character input string; Based on the initial word frequency evaluation value corresponding to the first input candidate combination string and the initial word frequency evaluation value corresponding to the second input candidate combination string, the distribution ratio of word frequency evaluation values corresponding to the data type to be processed is determined; If the distribution ratio of the word frequency evaluation value is greater than the distribution ratio threshold, then in the data to be processed, filter the model candidate sub-data associated with the second input candidate combination string to obtain the second model candidate data to be filtered.
13. The method according to claim 10, characterized in that, If the second candidate model data to be filtered contains initial candidate model data belonging to the target text meta-type, then based on the word frequency evaluation value filtering strategy, the second candidate model data to be filtered is screened to obtain the third candidate model data to be filtered, including: If the second candidate model data to be filtered contains initial candidate model data belonging to the target text metatype, then the initial candidate model data of the target text metatype is determined as target type data; the target type data includes a first initial text and a second initial text associated with the target input candidate combination string; the initial word frequency evaluation value corresponding to the second initial text is lower than the initial word frequency evaluation value corresponding to the first initial text, and the first initial text is the initial candidate text with the highest initial word frequency evaluation value corresponding to the target input candidate combination string; Based on the initial word frequency evaluation value corresponding to the first initial text, the initial word frequency evaluation value corresponding to the second initial text, and the word frequency evaluation value filtering strategy, the target type data is filtered to obtain the third candidate model data to be filtered.
14. The method according to claim 7, characterized in that, Returning the target model candidate data to the client includes: Based on the metawords in the metaword identifier mapping table, the first candidate text in the target model candidate data is matched; the metaword is a candidate text that belongs to the first text word type and has a word frequency greater than the word frequency threshold; the candidate text corresponding to the first text word type refers to the candidate text that the target object has not been displayed on the client. If the first candidate text in the target model candidate data contains the metaword, then the metaword identifier corresponding to the matched metaword is obtained from the metaword identifier mapping table; Based on the metaword identifiers, the candidate data of the target model is compressed to obtain a compressed data stream; The compressed data stream is returned to the client.
15. A data processing apparatus, characterized in that, include: A request generation module is used to obtain the first character input string with text word formation function and the target historical text data in the text input area, and generate a business request to be sent to the server; the business request is used to instruct the server to obtain target model candidate data that matches the target historical text data and the first character input string based on the text word formation function; the target model candidate data includes a first candidate text and a first word frequency evaluation value corresponding to the first candidate text; The word frequency adjustment module is used to, upon receiving the target model candidate data returned by the server, obtain the target object input string after updating the first character input string, and when the target model candidate data meets the model frequency adjustment conditions, adjust the first word frequency evaluation value corresponding to the first candidate text based on the matching mapping relationship between the target object input string and the target model candidate data to obtain the second word frequency evaluation value corresponding to the first candidate text. The model frequency adjustment conditions refer to the following: the hit text meta-type indicated by the model matching result corresponding to the first candidate text is greater than or equal to a preset text meta-type, or the hit word frequency evaluation value in the model matching result is less than the client word frequency threshold, or the first candidate text does not belong to the conditions of the client-set words. The matching mapping relationship between the target object input string and the target model candidate data is used to indicate whether the target model candidate data meets the model frequency adjustment conditions. The client-set words include object-created words, object history words, object input hot words, and error correction candidate words. The candidate sorting module is used to obtain the client-side word frequency evaluation value corresponding to the second candidate text that matches the target historical text data and the target object input string, and to sort the first candidate text and the second candidate text based on the second word frequency evaluation value corresponding to the first candidate text and the client-side word frequency evaluation value corresponding to the second candidate text to obtain the candidate sorting result.
16. A data processing apparatus, characterized in that, include: The request acquisition module is used to acquire the business request sent by the client; the business request is determined by the client based on the first character input string with text word formation function and the target historical text data in the text input area; The target model data acquisition module is used to acquire target model candidate data that matches the target historical text data and the first character input string based on the text word formation function; the target model candidate data includes a first candidate text and a first word frequency evaluation value corresponding to the first candidate text; The target model data sending module is used to return the target model candidate data to the client, so that when the client determines that the target model candidate data meets the model frequency tuning condition, it determines the second word frequency evaluation value corresponding to the first candidate text, and sorts the first candidate text and the second candidate text based on the second word frequency evaluation value corresponding to the first candidate text and the client word frequency evaluation value corresponding to the second candidate text, to obtain the candidate sorting result; The second word frequency evaluation value is obtained by the client adjusting the first word frequency evaluation value corresponding to the first candidate text based on the matching mapping relationship between the target object input string and the target candidate model data; The target object input string is updated based on the first character input string; the second candidate text is the candidate text obtained by the client that matches the target historical text data and the target object input string; the model frequency tuning condition refers to the condition that the hit text metatype indicated by the model matching result corresponding to the first candidate text is greater than or equal to the preset text metatype, or the hit word frequency evaluation value in the model matching result is less than the client word frequency threshold, or the first candidate text does not belong to the conditions set by the client; the matching mapping relationship between the target object input string and the target model candidate data is used to indicate whether the target model candidate data meets the model frequency tuning condition; the client-set words include object-created words, object historical words, object input hot words, and error correction candidate words.
17. A computer device, characterized in that, include: Processor and memory; The processor is connected to a memory, wherein the memory is used to store a computer program, and the processor is used to invoke the computer program to cause the computer device to perform the method according to any one of claims 1 to 14.
18. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program adapted to be loaded and executed by a processor to cause a computer device having the processor to perform the method of any one of claims 1 to 14.
19. A computer program product, characterized in that, The computer program product includes a computer program stored in a computer-readable storage medium, the computer program being adapted to be read and executed by a processor to cause a computer device having the processor to perform the method of any one of claims 1-14.
Citation Information
Patent Citations
Pinyin-input cloud result prediction methods, system and device
CN102508829A
Method and device for showing candidate items
CN103886043A
