Method and apparatus for evaluating legibility of text
By acquiring the target text of foreign language texts translated into Chinese by machine and historical search records, and utilizing search term popularity and sentence vector scoring standards, the accuracy problem of foreign language text readability evaluation was solved, resulting in a more objective evaluation outcome.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-04-06
- Publication Date
- 2026-03-24
AI Technical Summary
In existing technologies, there is a lack of unified standards for evaluating the readability of foreign language documents after machine translation into Chinese. This makes the evaluation results susceptible to the influence of personal subjective feelings, resulting in poor accuracy.
By acquiring the target text and historical text database, utilizing the historical search records of the search engine, and establishing first and second scoring criteria based on the popularity of search terms and sentence vectors, the readability of the target text is determined by combining the word segmentation processing model.
It improves the accuracy of text readability assessment, ensures that the assessment results are closer to conventional expression habits, and reduces subjective bias.
Smart Images

Figure CN114706952B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of text readability evaluation, and in particular to a text readability evaluation method and device. BACKGROUND
[0002] Readability refers to the degree of understanding of the text of a book, magazine or article. For foreign language literature translated by a machine, the readability of the Chinese version cannot be ensured due to the influence of the translation process. The current evaluation method is mainly subjective evaluation by experts or scholars in the corresponding field, and there is no unified evaluation standard. The evaluation result is easily affected by personal subjective feelings, resulting in poor accuracy of the evaluation.
[0003] Therefore, how to improve the accuracy of text readability evaluation is a technical problem to be solved at present. SUMMARY
[0004] The text readability evaluation method and device provided by the present application improve the accuracy of text readability evaluation.
[0005] The embodiments of the present application provide the following solutions.
[0006] In a first aspect, the embodiments of the present application provide a text readability evaluation method, which comprises the following steps:
[0007] obtaining a target text and a historical text library, wherein the target text is a text translated from a foreign language to Chinese by a machine, and the historical text library is a text collection of historical search records of a search engine;
[0008] obtaining a first scoring standard according to the heat of search words in the historical text library;
[0009] obtaining a second scoring standard according to the sentence vector of search sentences in the historical text library;
[0010] determining the readability of the target text according to the first scoring standard and the second scoring standard.
[0011] In an optional embodiment, the historical text library is obtained by the following steps:
[0012] obtaining historical search information of the search engine in a first time period;
[0013] obtaining the historical text library according to all search words and search sentences of a target field in the historical search information, wherein the target field is a field with the same classification as the target text.
[0014] In an optional embodiment, the first score standard is obtained according to the popularity of the search word in the historical text library, and the method comprises the following steps:
[0015] A word popularity sequence is determined according to the search frequency of the search word.
[0016] The search words with the same meaning in the word popularity sequence are arranged according to a preset rule to obtain the first score standard.
[0017] In an optional embodiment, the second score standard is obtained according to the sentence vector of the search sentence in the historical text library, and the method comprises the following steps:
[0018] All the search sentences are input into a preset Word2vec model to obtain all the sentence vectors.
[0019] The second score standard is obtained according to the sentence vector greater than a preset search frequency.
[0020] In an optional embodiment, the search engine is a semantic search engine, and before all the search sentences are input into a preset Word2vec model to obtain all the sentence vectors, the method further comprises the following steps:
[0021] The search sentences are updated according to the historical search information of the search user of the semantic search engine in a second time period.
[0022] In an optional embodiment, the readability of the target text is determined according to the first score standard and the second score standard, and the method comprises the following steps:
[0023] The target text is input into a word segmentation processing model to obtain a target word group.
[0024] A first score of the target word group is determined according to the first score standard.
[0025] A second score of the target word group is determined according to the second score standard.
[0026] The readability of the target text is determined according to the first score, the second score and a preset weight coefficient.
[0027] In an optional embodiment, the readability of the target text is determined according to the first score, the second score and a preset weight coefficient, and the method comprises the following steps:
[0028] The readability K of the target text is determined according to the formula K=AS1+BS2, wherein A is the first score, S1 is a first weight coefficient, B is the second score, and S2 is a second weight coefficient.
[0029] In a second aspect, the embodiments of the present application further provide a device for evaluating text readability, the device comprising:
[0030] an acquisition module configured to acquire a target text and a historical text library, wherein the target text is a text translated from a foreign language into Chinese by a machine, and the historical text library is a text collection of historical search records of a search engine;
[0031] a first obtaining module configured to obtain a first scoring standard according to a search word heat in the historical text library;
[0032] a second obtaining module configured to obtain a second scoring standard according to a search sentence vector in the historical text library;
[0033] a determination module configured to determine the readability of the target text according to the first scoring standard and the second scoring standard.
[0034] In a third aspect, the embodiments of the present application further provide an electronic device comprising a processor and a memory, the memory being coupled to the processor, and the memory storing instructions which, when executed by the processor, cause the electronic device to perform the steps of the method of any one of the first aspect.
[0035] In a fourth aspect, the embodiments of the present application further provide a computer readable storage medium having a computer program stored thereon, the program, when executed by a processor, implementing the steps of the method of any one of the first aspect.
[0036] The method and device for evaluating text readability provided by the present application have the following advantages compared with the prior art:
[0037] The present application acquires a target text and a historical text library, and since the historical text library is a text collection of historical search records of a search engine, records the expression habits of regular words and sentence orders, obtains a first scoring standard according to a search word heat in the historical text library to determine whether the target text is expressed according to regular words, obtains a second scoring standard according to a search sentence vector in the historical text library to determine whether the target text is expressed according to regular sentence orders, accurately determines the readability of the target text, and further improves the accuracy of the evaluation of text readability. BRIEF DESCRIPTION OF DRAWINGS
[0038] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the drawings needed in the embodiments will be briefly introduced as follows. Obviously, the drawings in the following description are only some embodiments of the present application, and for those skilled in the art, other drawings can also be obtained without creative labor on the basis of these drawings.
[0039] Figure 1 A flow chart of a text readability evaluation method provided by an embodiment of the present application;
[0040] Figure 2 A structural schematic diagram of a text readability evaluation device provided by an embodiment of the present application. DETAILED DESCRIPTION
[0041] The technical solutions in the embodiments of the present application will be clearly and completely described with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all the embodiments of the present application. Based on the embodiments of the present application, all other embodiments obtained by a person of ordinary skill in the art belong to the scope of protection of the embodiments of the present application.
[0042] Please refer to Figure 1 , Figure 1 A flow chart of a text readability evaluation method provided by an embodiment of the present application, the method comprising:
[0043] S11, obtaining a target text and a historical text library, wherein the target text is a text translated from a foreign language to Chinese by a machine, and the historical text library is a text collection of historical search records of a search engine;
[0044] Specifically, the target text is a text translated from a foreign language to Chinese by a machine. Since there is a big difference between the expression habits of foreign languages and Chinese, the machine translation cannot accurately translate the expression words and sentences suitable for the habits of Chinese people. Especially for the translation of technical documents, most of them involve special terms. One word in a foreign language may be translated into multiple Chinese expressions, resulting in a target text that is difficult to understand. The target text can be an electronic text directly obtained through the network, or an electronic text extracted by scanning a paper text through machine vision. The historical text library can be obtained according to the historical search records of the search engine, for example, by processing a specified search engine through a python tool.
[0045] In a specific embodiment, the historical text library is obtained, comprising:
[0046] Obtaining historical search information of the search engine in a first time period; obtaining the historical text library according to all search words and search sentences of a target field in the historical search information, wherein the target field is a same field as the classification of the target text.
[0047] Specifically, the specific time of the first time period can be determined according to the working experience of the technical personnel, for example, the last 6 months or 12 months, or can be determined according to the volume of accumulated search information, which can represent the latest Chinese expression habits. The historical search information includes searched words, sentences and corresponding time points. Different words and sentences may be proper nouns related to a specific field, and in this field, the proper nouns and sentences are in line with the conventional expression habits. Further classification of them can improve the matching of the historical text library and the target text. It should be noted that the classification of historical search information can be classified into computer field, biological field, optical field and daily life field by using existing classification tools. A word may involve multiple fields, and the classification tool is allocated accordingly to ensure the integrity of the information. After obtaining the target text and the historical text library, step S12 is entered.
[0048] S12, obtaining a first scoring standard according to the heat of the search word in the historical text library.
[0049] Specifically, the heat of the search word represents the search frequency of the word. The higher the search frequency, the higher the heat, which means that the conventional expression is more likely to use this search word. In the first scoring standard, the corresponding score is higher; on the contrary, the lower the search frequency, the lower the heat, which means that the conventional expression is less likely to use this search word. In the first scoring standard, the corresponding score is lower. The first scoring standard can be represented in the form of an interpolation table, in which a search word corresponds to a score value according to its heat. Of course, the first scoring standard can also be indexed to quickly locate the search word and the corresponding score value. The index can be established according to the first letter of the search word.
[0050] In a specific implementation, since the first scoring standard includes search words and corresponding score values, it has a large amount of data and a large amount of calculation when executed, which is not conducive to efficient execution.
[0051] In a specific embodiment, the first scoring standard is obtained according to the heat of the search word in the historical text library, comprising:
[0052] According to the search frequency of the search word, a word heat sequence is determined, and search words with the same meaning in the word heat sequence are arranged according to a preset rule to obtain the first scoring standard.
[0053] Specifically, the keyword popularity sequence is a sequence of search terms arranged according to popularity rules. A higher search frequency indicates higher popularity for the search term, and a higher ranking in the keyword popularity sequence. By arranging search terms with the same meaning in the keyword popularity sequence according to preset rules, the popularity distribution of different search terms with the same meaning can be determined. The same meaning may have different search terms; arranging them according to preset rules yields search terms that are more commonly used for expression and application. The first scoring criterion is obtained through this arrangement. It can be understood that the preset rule arrangement can be in descending or ascending order of popularity. After obtaining the first scoring criterion, proceed to step S13.
[0054] S13. Obtain the second scoring criterion based on the statement vector of the search statement in the historical text database;
[0055] Specifically, when searching for information through a search engine, the statement vector of the search query represents the Chinese way of expressing text. The search query is composed of words and phrases, and the order of their combination can be represented by the corresponding statement vector. The second scoring criterion is obtained through the statement vector of the search query.
[0056] In one specific implementation, a second scoring criterion is obtained based on the statement vector of the search statement in the historical text database, including:
[0057] Input all search terms into the preset Word2vec model to obtain all corresponding statement vectors; obtain the second scoring criterion based on statement vectors with a frequency greater than the preset search frequency.
[0058] Specifically, the Word2vec model is a neural network with one-hot encoding. After inputting all search statements into the Word2vec model, it can accurately represent the statement vectors of each search statement. It's understandable that statements with the same meaning expressed in different word orders will yield different statement vectors. However, there are usually common word orders. In the second scoring criterion, if every expression has a corresponding score, less frequently used expressions might also receive scores. Therefore, it's necessary to include statement vectors with a search frequency greater than the preset limit in the second scoring criterion to accurately obtain the second scoring standard.
[0059] In one specific implementation, the search engine is a semantic search engine. Before inputting all search statements into a preset Word2vec model and obtaining all statement vectors, the following steps are also included:
[0060] The search query is updated based on the historical search information of users in the second time period from the semantic search engine.
[0061] Specifically, the semantic search engine directly retrieves corresponding results based on the given statement. It automatically extracts keywords from the statement and then performs the corresponding search. The search statements obtained from the semantic search engine are more consistent with the textual expressions of the relevant field, making the second scoring criterion more accurate. The second time period can be freely defined or determined by the volume of historical search information, such as the most recent 6 months or 12 months. After obtaining the second scoring criterion, proceed to step S14.
[0062] S14. Determine the readability of the target text based on the first scoring standard and the second scoring standard.
[0063] Specifically, the readability of a target text represents the degree of comprehensibility of the translated text. When determining readability using the first and second scoring criteria, the words and sentences in the target text can be assigned scores according to the first and second scoring criteria. By summing all the scores, the readability of the target text can be determined.
[0064] In practice, due to differences in word order expression habits across different fields, there are certain discrepancies between the first and second scoring criteria when determining the readability of texts in different fields.
[0065] To address the aforementioned issues, in one specific implementation, the readability of the target text is determined based on a first scoring criterion and a second scoring criterion, including:
[0066] The target text is input into the word segmentation model to obtain the target word group; the first score of the target word group is determined according to the first scoring criterion; the second score of the target word group is determined according to the second scoring criterion; and the readability of the target text is determined based on the first score, the second score and the preset weight coefficient.
[0067] Specifically, the word segmentation model can be an existing word segmentation tool, such as PyTorch. This model can extract target word groups from the target text and remove irrelevant words. A first scoring criterion determines the first score of the target word group, and a second scoring criterion determines the second score. Weighting coefficients can be determined based on the domain of the target text, thereby determining the readability of the target text. Those skilled in the art will understand that the weighting coefficients are determined based on the corresponding domain and can be obtained through experimental calibration tests, which will not be elaborated upon here. The weighting coefficients can be correlated with both the first and second scores, or only one of them.
[0068] In one specific implementation, the readability of the target text is determined based on a first score, a second score, and a preset weighting coefficient, including:
[0069] The readability K of the target text is determined according to the formula K = AS1 + BS2, where A is the first score, S1 is the first weight coefficient, B is the second score, and S2 is the second weight coefficient.
[0070] Similarly, the first and second weighting coefficients can be determined based on the experience of technical personnel, for example, both can be set to 0.5, or they can be determined through calibration tests in the corresponding field.
[0071] Based on the same inventive concept as the evaluation method, embodiments of the present invention also provide a text readability evaluation device. Please refer to [link to relevant documentation]. Figure 2 The device includes:
[0072] The acquisition module 201 is used to acquire target text and historical text library, wherein the target text is foreign language text translated into Chinese by machine, and the historical text library is a collection of text records from the search engine's history.
[0073] The first obtaining module 202 is used to obtain a first scoring standard based on the popularity of search terms in the historical text database;
[0074] The second obtaining module 203 is used to obtain a second scoring standard based on the statement vector of the search statement in the historical text library;
[0075] The determination module 204 is used to determine the readability of the target text based on the first scoring criterion and the second scoring criterion.
[0076] Based on the same inventive concept as the evaluation method, embodiments of the present invention also provide an electronic device, including a processor and a memory, wherein the memory is coupled to the processor and stores instructions that, when executed by the processor, cause the electronic device to perform the steps of any of the methods in the evaluation method.
[0077] Based on the same inventive concept as the evaluation method, embodiments of the present invention also provide a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of any of the evaluation methods.
[0078] The technical solutions provided in the embodiments of the present invention have at least the following technical effects or advantages:
[0079] By acquiring the target text and the historical text database, which contains a collection of historical search records from the search engine, recording the expression habits of conventional words and sentence order, the first scoring criterion is obtained through the popularity of search terms in the historical text database to determine whether the target text is expressed according to conventional words. The second scoring criterion is obtained through the sentence vectors of search statements in the historical text database to determine whether the target text is expressed according to conventional sentence order. This accurately determines the readability of the target text, thereby improving the accuracy of the text readability evaluation.
[0080] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (modules, systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded computer, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0081] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0082] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0083] Although preferred embodiments of the invention have been described, those skilled in the art, upon learning the basic inventive concept, can make other changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including both the preferred embodiments and all changes and modifications falling within the scope of the invention.
[0084] Obviously, those skilled in the art can make various modifications and variations to this invention without departing from its spirit and scope. Therefore, if these modifications and variations fall within the scope of the claims of this invention and their equivalents, this invention also intends to include these modifications and variations.
Claims
1. A method for evaluating text readability, characterized in that, The method includes: Obtain the target text and the historical text library, wherein the target text is foreign language text translated into Chinese by machine, and the historical text library is a collection of text records from the search engine's historical search history; The first scoring criterion is obtained based on the popularity of search terms in the historical text database; The second scoring criterion is obtained based on the statement vector of the search statements in the historical text database; The readability of the target text is determined based on the first and second scoring criteria. The acquisition of the historical text library includes: Obtain the historical search information of the search engine in the first time period; The historical text library is obtained based on all the search terms and search statements in the target domain in the historical search information, wherein the target domain is the same domain as the target text classification; The first scoring criterion, obtained based on the popularity of search terms in the historical text database, includes: Determine the word popularity sequence based on the search frequency of the search terms; The search terms with the same meaning in the word popularity sequence are arranged according to a preset rule to obtain the first scoring standard, wherein the preset rule is based on the definition of search terms used in habitual expressions.
2. The method for evaluating text readability according to claim 1, characterized in that, The step of obtaining the second scoring criterion based on the statement vector of the search statements in the historical text database includes: Input all the search statements into the preset Word2vec model to obtain all the statement vectors; The second scoring criterion is obtained based on the statement vectors that have a higher search frequency than the preset search frequency.
3. The method for evaluating text readability according to claim 2, characterized in that, The search engine is a semantic search engine. Before inputting all the search statements into a preset Word2vec model and obtaining all the statement vectors, the process further includes: The search query is updated based on the historical search information of the users of the semantic search engine in the second time period.
4. The method for evaluating text readability according to claim 1, characterized in that, Determining the readability of the target text based on the first and second scoring criteria includes: The target text is input into the word segmentation model to obtain the target word group; The first score of the target phrase is determined according to the first scoring criterion; The second score for the target phrase is determined according to the second scoring criteria. The readability of the target text is determined based on the first score, the second score, and a preset weighting coefficient.
5. The method for evaluating text readability according to claim 4, characterized in that, The step of determining the readability of the target text based on the first score, the second score, and a preset weighting coefficient includes: The readability K of the target text is determined according to the formula K=AS1+BS2, where A is the first score, S1 is the first weight coefficient, B is the second score, and S2 is the second weight coefficient.
6. A device for evaluating text readability, characterized in that, The device includes: The acquisition module is used to acquire target text and historical text library, wherein the target text is foreign language text translated into Chinese by machine, and the historical text library is a collection of text records from the search engine's historical search history; The first obtaining module is used to obtain a first scoring standard based on the popularity of search terms in the historical text database; The second obtaining module is used to obtain a second scoring criterion based on the statement vector of the search statement in the historical text database; The determination module is used to determine the readability of the target text based on the first scoring criterion and the second scoring criterion.
7. An electronic device, characterized in that, The device includes a processor and a memory, the memory being coupled to the processor, the memory storing instructions that, when executed by the processor, cause the electronic device to perform the steps of the method according to any one of claims 1-5.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the program implements the steps of the method described in any one of claims 1-5.
Citation Information
Patent Citations
Translation quality evaluation method and device, electronic equipment and storage medium
CN113609875A