Semantic processing-based double-sided screen self-adaptive translation generation method and semantic processing-based double-sided screen self-adaptive translation generation system
By identifying and adjusting the visual presentation parameters of abnormal words in dual-screen translation devices, the problem of display confusion caused by the lack of natural breakpoints in ultra-long words has been solved, improving the visual clarity of the translation and the user experience.
Patent Information
- Application Number
- CN202511640379.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-11
- Publication Date
- 2025-12-09
- Estimated Expiration
- 2045-11-11
AI Technical Summary
Existing dual-screen translation devices suffer from display clutter and abnormal layout when processing professional translations due to the lack of natural breakpoints for extremely long words, which affects user experience and communication efficiency.
By identifying anomalous words that are longer than a preset threshold and lack natural separators, and adjusting their visual presentation parameters, such as character spacing, halo parameters, and font style, an adaptive translation is generated.
It significantly improves the visual clarity and reading fluency of the translated text, optimizes the user experience of dual-screen translation devices, and is of great value, especially in professional communication.
Smart Images

Figure CN121093901A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of adaptive translation generation for dual-screen displays based on semantic processing, and particularly to a method and system for adaptive translation generation for dual-screen displays based on semantic processing. Background Technology
[0002] In today's world of increasingly frequent cross-language communication, portable dual-screen translation devices offer convenience for face-to-face communication. These devices typically use speech recognition and semantic processing technologies to translate one party's speech in real time and display it on the other party's screen. However, in practical applications, especially when the conversation involves specialized fields, existing technologies still face significant challenges in terms of accuracy in handling technical terminology, adaptability to displaying extremely long translations, and understanding subtle user interaction intentions. This often leads to inaccuracies in the meaning of the translation, display clutter, and consequently affects communication efficiency and user experience.
[0003] Specifically, when the conversation shifts from general topics to highly specialized, domain-specific issues, translation programs encounter a large number of technical terms, abbreviations, and specific expressions that are uncommon or even never appear in general corpora. Because the meanings of these terms are highly dependent on specific professional contexts and often have multiple meanings, the program's internal semantic certainty decreases significantly during processing. To preserve the complete information of the source language's technical terms as much as possible despite this decreased semantic certainty, the translation program may tend to employ a literal translation or word-by-word combination strategy when generating the translation. Especially when dealing with compound nouns or technical phrases common in certain languages, the program may directly translate a complex concept into an abnormally long string in the target language that lacks any natural breaks (such as spaces or hyphens).
[0004] These extremely long translations, generated by translation programs and lacking natural breakpoints, pose a significant challenge to the device's screen display adjustment logic. This display logic is typically optimized based on statistical analysis of the characteristics of everyday language text. When it receives text strings that are far longer than expected and lack internal breakpoints, its built-in automatic line wrapping algorithm, character spacing adjustment mechanism, and text alignment rules fail. This can lead to severe layout problems on the secondary screen; for example, long words may be forcibly compressed, leaving almost no space between characters and making the text illegible; or the text may overflow the preset display area, causing parts of the content to be truncated and unable to be displayed completely. This chaotic layout not only severely affects the visual clarity of the translation but also makes it difficult for users to read smoothly, thus undermining the good user experience that "adaptive" displays should provide. Summary of the Invention
[0005] This invention provides a semantic processing-based adaptive translation generation method for dual-screen devices, which improves the display clarity and user comprehension efficiency of ultra-long translations in professional field dialogues.
[0006] In a first aspect, in order to solve the above-mentioned technical problems, the present invention provides a dual-screen adaptive translation generation method based on semantic processing, comprising: obtaining the translation generated by a translation program; Identify anomalous words in the translation; anomalous words are those whose length exceeds a preset threshold and lack natural delimiters. Adjust the visual rendering parameters of abnormal words. The visual rendering parameters include any one or more of the following: character spacing, halo parameters, and font style. The translation is generated based on the adjusted visual rendering parameters of the abnormal words.
[0007] Optionally, identify anomalous words in the translation, including: Determine the number of characters for each word in the translation; Words with a character count greater than a preset threshold and lacking natural separators are identified as abnormal words.
[0008] Optional, the natural separator is a space or a hyphen.
[0009] Optionally, adjust the visual rendering parameters for abnormal words, including: If an abnormal word is an important word appearing for the first time in the translation, the visual presentation parameters of the abnormal word will be adjusted. An important word must meet any of the following conditions: it is a word in the preset professional domain vocabulary list, it is the subject of the sentence, or it is the object of the sentence.
[0010] Optionally, when the visual rendering parameter is character spacing, adjust the visual rendering parameters of abnormal words, including: Reduce the character spacing of abnormal words according to the preset compression ratio.
[0011] Optionally, when the visual rendering parameter is the halo parameter, adjust the visual rendering parameters of the abnormal words, including: Render a halo with a radius of 2-3 pixels at the distance from the abnormal word.
[0012] Optionally, when the visual rendering parameter is font style, adjust the visual rendering parameters of abnormal words, including: Bold out unusual words; Change the font color of abnormal words from black to dark gray.
[0013] Optionally, the method also includes: Identify the area of light interference; Adjust the brightness of abnormal words in the area of light interference to meet the following contrast formula. The contrast formula is:
[0014] Where C_target represents the target contrast of the pixel (x, y) where the abnormal word is located; I_adjusted(x, y) represents the adjusted brightness of the pixel (x, y) where the abnormal word is located; and I_background(x, y) represents the background brightness of the pixel (x, y) where the abnormal word is located.
[0015] Optionally, determine the area of light interference, including: For any pixel among multiple pixels, if the angle between the direction vector of the external light source and the normal vector of the pixel is less than a first preset angle, and the light intensity of the pixel is greater than the intensity threshold, the pixel is determined to be a glare area. For any pixel among multiple pixels, if the angle between the external light source direction vector and the normal vector of the pixel is greater than a second preset angle, and the light intensity of the pixel is less than the intensity threshold, the pixel is determined to be a shadow region. Glare areas and shadow areas are identified as light interference areas.
[0016] Secondly, this invention provides a dual-screen adaptive translation generation system based on semantic processing, the system comprising: The acquisition module is used to acquire the translation generated by the translation program; The identification module is used to identify abnormal words in the translation; abnormal words are words whose length exceeds a preset threshold and lack natural separators. The adjustment module is used to adjust the visual presentation parameters of abnormal words. The visual presentation parameters include any one or more of the following: character spacing, halo parameters, and font style. The generation module is used to generate translations based on the adjusted visual rendering parameters of the abnormal words.
[0017] Compared with the prior art, the present invention has the following beneficial effects: This application provides a semantic processing-based adaptive translation generation method for dual-screen displays. The method acquires the translation generated by a translation program and identifies anomalous words whose length exceeds a preset threshold and lacks natural separators. For these anomalous words, this application adjusts their visual presentation parameters, including any one or more of character spacing, halo parameters, and font styles, and generates the final translation based on the adjusted parameters.
[0018] Through the above technical solution, this application effectively solves the technical problem of existing dual-screen translation devices when processing professional translations, where the lack of natural breakpoints for extremely long words due to literal translation or word splicing strategies in the translation program leads to display chaos and abnormal layout. Specifically, this application can accurately identify extremely long strings that are abnormally long in the target language and do not contain natural separators, and perform targeted visual optimization on them. For example, by reducing the character spacing, extremely long words can be presented completely within the limited display space, avoiding text overflow or truncation; by rendering halos or adjusting font styles (such as bolding or changing colors), the visual prominence and readability of abnormal words can be significantly enhanced, making them easier for users to identify and understand in complex backgrounds.
[0019] Therefore, this application overcomes the shortcomings of existing technologies, such as the failure of automatic line wrapping algorithms, character spacing adjustment mechanisms, and text alignment rules when handling such abnormal text, thus avoiding layout problems such as illegible handwriting and truncated content. Accordingly, this application significantly improves the visual clarity and reading fluency of the translated text, thereby optimizing the user experience and communication efficiency of dual-screen translation devices, and has significant practical value, especially in professional field communication. Attached Figure Description
[0020] Figure 1 This is a schematic diagram of a method for generating adaptive translations on a dual-screen screen based on semantic processing, provided in an embodiment of the present invention. Figure 2 This is a schematic diagram of another method for generating adaptive translations on a dual-screen screen based on semantic processing, provided in an embodiment of the present invention. Figure 3 This is a schematic diagram of the structure of a dual-screen adaptive translation generation system based on semantic processing provided in an embodiment of the present invention. Detailed Implementation
[0021] The technical solutions of this application will now be clearly and completely described with reference to the accompanying drawings. Obviously, the described embodiments are merely some embodiments of this application, and not all embodiments. The components of this application described and shown in the accompanying drawings can generally be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of this application provided in the accompanying drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of this application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.
[0022] It should be noted that similar reference numerals and letters in the following figures indicate similar items; therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures. Furthermore, in the description of this application, terms such as "first," "second," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0023] In order to better understand the technical solution proposed in this application, it is necessary to explain some of the key terms involved.
[0024] In this application, "translation" refers to the text content generated by a translation program after translating source language content into the target language, which is usually displayed on a dual-screen device. "Abnormal words" specifically refer to words in the translation that exceed a preset threshold in length and lack natural separators (such as spaces, hyphens, etc.). These words are often technical terms, compound nouns, or specific expressions, and due to their special structure, they are prone to display problems in traditional text rendering.
[0025] "Visual presentation parameters" refer to various attributes that affect how text is displayed on the screen, such as character spacing, halo parameters, and font style. Adjusting these parameters can change the visual presentation of words.
[0026] Traditional dual-screen translation devices often face problems when handling professional dialogues, such as inaccurate translation of technical terms, cluttered display of excessively long translations, and insufficient user interaction and understanding. Specifically, when the translation program encounters highly technical, unusually long words that lack natural separators, the generated translation may have layout issues on the dual-screen display, such as improper character spacing, text overflow, or illegibility, severely impacting the user's reading experience and communication efficiency.
[0027] Therefore, the following specific embodiments will be used to provide a detailed introduction and explanation of the semantic processing-based dual-screen adaptive translation generation method provided in this application.
[0028] Reference Figure 1 This invention provides a dual-screen adaptive translation generation method based on semantic processing, comprising the following steps: S1, retrieve the translation generated by the translation program.
[0029] In practical applications, the translation program can be a translation engine running locally on the dual-screen device, or a cloud-based translation service connected via the network.
[0030] There are various ways to obtain the translation. For example, the translation program can directly pass the generated translation to this method through an internal interface, or this method can listen to a specific data port to receive the translation data.
[0031] As one possible implementation, after the translation program completes the translation, it outputs the translation as a text string. This method receives and caches this translation data by calling the corresponding API interface.
[0032] S2. Identify unusual words in the translation.
[0033] Abnormal words are those whose length exceeds a preset threshold and lack natural separators.
[0034] As one possible approach, the number of characters in each word in the translation can be determined, and words whose number of characters exceeds a preset threshold and which do not contain natural separators can be identified as abnormal words.
[0035] For example, a preset threshold of 10 characters can be set, and any word longer than 10 characters that does not contain spaces or hyphens will be considered an abnormal word.
[0036] It should be noted that the recognition process can employ various technical means. For example, the translated text can be segmented into words, and then the length of each word can be determined, and whether it contains natural separators.
[0037] As another approach, regular expression matching can be used to define a pattern to find strings that meet the condition of "length greater than a preset threshold and lacking natural separators".
[0038] In some embodiments of this application, the natural separator is a space or a hyphen. A natural separator refers to a symbol used in text to distinguish different words or phrases. In many languages, such as English, spaces are the primary natural separator. Hyphens are often used to connect compound words or indicate breaks in words. By explicitly defining the natural separator as a space or a hyphen, a clear criterion can be provided for identifying anomalous words. For example, when the length of a word exceeds a preset threshold and there are no spaces or hyphens effectively separating it internally or around it, the word is considered to lack natural separators, thus meeting the criteria for identifying anomalous words.
[0039] This application's solution, by specifically defining natural separators as spaces or hyphens, provides the recognition module with a clear and consistent standard for determining whether words in the translation lack natural separators. In translations generated by translation programs, especially when dealing with certain languages or specific text formats, some words may not be correctly separated in the conventional way due to layout, encoding, or language characteristics. By using spaces or hyphens as the criterion, these words that may appear visually too compact or difficult to read can be effectively captured, thus laying the foundation for subsequent adjustments to visual presentation parameters.
[0040] S3. Adjust the visual presentation parameters of abnormal words.
[0041] The visual presentation parameters include any one or more of the following: character spacing, halo parameters, and font style.
[0042] As one possible approach, if the anomalous word is an important word appearing for the first time in the translation, the visual presentation parameters of the anomalous word can be adjusted.
[0043] Important vocabulary meets any of the following conditions: it is a word in the preset professional domain vocabulary list, it is the subject of the sentence, or it is the object of the sentence.
[0044] "First appearance" refers to the first time the anomalous word is identified and requires visual adjustment in the current translation or user session. By determining the first appearance of a word, unnecessary visual emphasis on recurring words can be avoided, thus maintaining the overall reading fluency of the translation.
[0045] The preset professional field vocabulary list includes multiple words, and the preset professional field vocabulary list is set in advance by humans.
[0046] For example, in medical conversations, if "Electroencephalography" appears for the first time and is in a pre-defined professional vocabulary list, then "Electroencephalography" is identified as an important term.
[0047] It should be noted that the specific implementation of identifying whether a word is the subject or object of a sentence can be found in existing technologies, and will not be elaborated here.
[0048] It should be noted that specific instructions on adjusting the visual presentation parameters of abnormal words can be found in later sections, and are not limited here.
[0049] This application's solution effectively addresses the potential overemphasis and resource waste issues in basic solutions by introducing a mechanism to determine the "first appearance" and "importance" of anomalous words. After the translation program generates the translation, the system first identifies anomalous words. Subsequently, before adjusting the visual presentation parameters of these anomalous words, they undergo further screening. Only when an anomalous word appears for the first time in the current translation and is determined to be an important word will its visual presentation parameters be adjusted. This selective adjustment method ensures the accuracy of visual emphasis, concentrating limited visual resources on information crucial to the user's understanding of the translation and avoiding interference with non-critical or repetitive information.
[0050] Through the aforementioned technical solutions, this application significantly improves the intelligence level and user experience of the dual-screen adaptive translation generation method. Firstly, by visually adjusting only important, newly appearing anomalous words, it avoids overemphasizing repetitive or non-critical information, thereby reducing user visual fatigue and cognitive burden, making the translation reading smoother and more natural. Secondly, this selective processing method reduces unnecessary computational and rendering overhead, optimizing resource utilization efficiency. Furthermore, by highlighting key, newly appearing professional terms or core semantic terms, it helps users quickly grasp the key information in the translation, especially in professional fields or complex contexts, significantly improving the efficiency and accuracy of information acquisition.
[0051] In some preferred embodiments, it is assumed that a user is translating a medical report using a dual-screen device. After the translation program generates the translation, the system identifies several abnormal words, such as "myocardial infarction," "coronary atherosclerosis," and "hypertension." According to the scheme of this application, the system first determines whether these words are appearing for the first time. If "myocardial infarction" is appearing for the first time and is identified as an important word by querying a preset medical professional terminology list, or is used as the subject or object in the current sentence, then its visual presentation parameters (such as character spacing, halo parameters, or font style) will be adjusted to make it more prominent on the dual-screen. However, if "hypertension" has appeared multiple times in the report, or is determined to be non-critical information, even if it is also an abnormal word, its visual presentation parameters may not be adjusted, thereby avoiding unnecessary visual interference. In this way, users can quickly focus on the core medical terms and key information in the report, improving reading efficiency and comprehension accuracy.
[0052] S4. Generate the translation based on the adjusted visual presentation parameters of the abnormal words.
[0053] For example, the rendering engine draws the text based on the visual rendering parameters of each word (including character spacing, halo effects, font styles, etc.). For unusual words, the rendering engine applies their specific adjustment parameters, while for normal words, it renders according to default or preset parameters. The final translation will be displayed on both screens for the user to read.
[0054] The semantic processing-based adaptive translation generation method for dual-screen displays proposed in this application effectively solves the display challenges faced by existing dual-screen translation devices when processing professional terminology translations. First, after the translation program generates the translation, the system intelligently acquires it. Then, the recognition module accurately identifies "abnormal words" in the translation that are unusually long and lack natural separators. These words are often the root cause of display clutter. Once abnormal words are identified, the adjustment module adaptively adjusts the visual presentation parameters of these words according to preset strategies, such as reducing character spacing, adding halo effects, or changing font styles. Finally, the generation module regenerates and displays the translation based on these adjusted parameters. The entire process forms a closed loop, ensuring that even when faced with complex professional terminology, the translation is presented clearly and legibly on the dual-screen display, significantly improving user experience and communication efficiency.
[0055] Compared to existing technologies, the core innovation of this application lies in introducing the concept of "abnormal words" and adaptively adjusting their visual presentation parameters. Traditional methods often employ uniform text rendering rules, which can easily lead to text overflow, blurred characters, or layout chaos when encountering extremely long professional terms without natural breaks. This application intelligently identifies these "abnormal words" and finely adjusts their character spacing, halo parameters, or font styles, enabling these special words to be presented optimally within the limited display space. For example, by reducing character spacing, words can be displayed in their entirety without truncating them; by adding halos or changing font styles, readability and recognizability against complex backgrounds can be improved. This adaptive adjustment strategy for specific words effectively overcomes the limitations of existing technologies in processing professional translations, significantly improves the display effect and user experience of dual-screen translation devices, and provides a smoother and more efficient solution for cross-language communication.
[0056] In one possible design, such as Figure 2 As shown, in order to identify anomalous words in the translation, this application may also include the following steps: S101. Determine the number of characters for each word in the translation.
[0057] Determining the number of characters for each word in the translation involves segmenting the translated text generated by the translation program into words and then counting the number of characters contained in each segmented word. This segmentation process can be implemented using existing, mature Natural Language Processing (NLP) techniques.
[0058] Natural Language Processing (NLP) techniques can be referenced from existing technologies, and will not be elaborated upon here.
[0059] S102. Words whose number of characters exceeds a preset threshold and do not contain natural separators are identified as abnormal words.
[0060] For example, for Chinese text, the preset threshold can be set to 5 to 8 characters.
[0061] For example, for English text, the preset threshold can be set to 10 to 15 characters.
[0062] Natural separators are symbols used in text to distinguish different words or phrases, such as spaces, hyphens, and punctuation marks. Their presence usually means that word boundaries are clear and less likely to cause reading difficulties.
[0063] Therefore, words with a character count exceeding a preset threshold and lacking natural separators are identified as abnormal words, aiming to filter out those that are both excessively long and lack clear separation. Such words can easily cause visual crowding and reading difficulties when displayed on dual screens, especially when screen size is limited or display area is restricted.
[0064] Through the above technical solution, this application can accurately identify abnormal words in the translation. This identification mechanism not only considers the length of the word, but also takes into account whether there are natural separators inside or around it, thus avoiding misjudgments that may be caused by judging solely by length. As a result, it can be ensured that subsequent adjustments to visual presentation parameters can be applied specifically to words that truly affect the reading experience, improving the adaptability and user-friendliness of the translation displayed on dual-screen displays.
[0065] In one possible design, with the visual presentation parameter set to character spacing, the visual presentation parameters for abnormal words are adjusted, including: S201. Reduce the character spacing of abnormal words according to the preset compression ratio.
[0066] Character spacing refers to the distance between adjacent characters in text. When the visual presentation parameter is determined to be character spacing, the solution in this application aims to optimize the display effect by specifically adjusting the character spacing of abnormal words.
[0067] The preset compression ratio is a pre-defined value used to guide the degree of reduction in character spacing. This ratio can be empirically set or dynamically calculated based on factors such as actual display requirements, screen size, font size, and the length of unusual words. For example, it can be set to 0.8, indicating a 20% reduction in the original character spacing. By reducing the character spacing of unusual words according to this preset compression ratio, longer unusual words can be visually "compacted," occupying less space in a limited display area, thereby improving their overall visual presentation efficiency.
[0068] This application's solution reduces the character spacing of anomalous words by introducing a preset compression ratio, thus solving the problem of the lack of specific strategies for adjusting character spacing in the basic solution. When the translation generated by the translation program contains anomalous words that are longer than a preset threshold and lack natural separators, these words often appear visually lengthy and difficult to read. By purposefully reducing the character spacing of these anomalous words, the originally scattered characters can be visually brought closer together, allowing the entire word to occupy less horizontal space while maintaining readability. This compact processing method is particularly suitable for dual-screen display environments, better adapting to different screen sizes and layout requirements, and avoiding long words overflowing the display area or causing inconsistent layout.
[0069] Through the above technical solution, this application can specifically optimize the visual presentation of abnormal words, especially in terms of character spacing. By reducing the character spacing of abnormal words according to a preset compression ratio, the display efficiency and readability of long abnormal words on dual-screen displays can be significantly improved. This not only helps to better accommodate longer words within a limited display area, reducing line breaks or truncation caused by excessively long words, but also makes these words lacking natural separators appear more compact and cohesive visually, thereby enhancing the user's reading experience and improving the professionalism and aesthetics of the translation.
[0070] In some preferred embodiments, suppose the translation program generates a translation containing the anomalous word "Geschwindigkeitsbegrenzung" (German for "speed limit"). This word is long and lacks natural separators. After identifying the word as anomalous, the system determines that its visual presentation parameters need to be adjusted. When adjusting character spacing is selected, the system reduces the character spacing of "Geschwindigkeitsbegrenzung" according to a preset compression ratio (e.g., set to 0.8). Specifically, if the original character spacing is 1 unit, it will be adjusted to 0.8 units. As a result, when the anomalous word is displayed on a dual-screen display, its overall width will be shortened accordingly, allowing the long word to be presented more compactly on the screen. This avoids incomplete display or the need for additional scrolling due to the word's length, thereby improving the visual effect and readability of the translation.
[0071] In one possible design, when the visual presentation parameter is the halo parameter, the visual presentation parameters of abnormal words are adjusted, including: S301. Render a halo with a radius of 2-3 pixels at the location of the abnormal word.
[0072] Specifically, the halo parameter refers to a glowing effect generated around the edges of text or images, designed to enhance their visual prominence. In this application, when the halo parameter is selected as a method to adjust the visual presentation parameters of abnormal words, the specific implementation involves rendering a halo with a specific radius around the abnormal word. The radius of this halo is limited to a range of 2-3 pixels. Rendering refers to the process of generating and displaying visual effects using computer graphics technology. The 2-3 pixel radius range is selected to ensure that the halo effect effectively attracts the user's attention without being overly exaggerated and affecting the overall aesthetics and readability of the translation.
[0073] In some preferred embodiments, suppose the translation program generates a Japanese translation containing the long compound word "International Union for Education, Science and Culture Organization" (UNESCO). This word lacks natural separators in the translation and exceeds a preset threshold in length, thus being identified as an anomalous word. When it is necessary to adjust its visual presentation using halo parameters, the system renders a soft halo with a radius of 2 or 3 pixels around the word "International Union for Education, Science and Culture Organization." For example, this halo could be a light blue or light yellow, making it stand out slightly against the background text without being too jarring. As the user reads, their gaze is naturally drawn to this word with the halo, making it easier to notice this important anomalous word and to understand or process it more carefully. This approach effectively solves the problem of long words being visually difficult to identify, improving the reading efficiency and accuracy of the translation.
[0074] In one possible design, when the visual presentation parameter is font style, the visual presentation parameters of abnormal words are adjusted, including: S401. Bold out abnormal words.
[0075] Specifically, bolding unusual words involves changing the thickness of the font strokes to make them stand out visually from the surrounding ordinary words. This bolding can quickly attract the user's attention, making it easier for them to notice these identified unusual words.
[0076] S402. Change the font color of abnormal words from black to dark gray.
[0077] The adjustment of the font color for abnormal words from black to dark gray can be understood as further distinguishing abnormal words through subtle color adjustments while maintaining a certain level of contrast. For example, in some display environments, pure black may be too glaring or have too high contrast with the background, while dark gray can provide a softer visual effect and reduce eye strain while maintaining legibility. In practical applications, these adjustments can be automatically executed by the display system according to preset rules, or users can customize the settings according to their personal preferences.
[0078] In some preferred embodiments, suppose the translation program generates a Japanese translation containing a long compound word, "International Joint Security Council" (United Nations Security Council), which is identified as an anomalous word in the translation because its length exceeds a preset threshold and it lacks natural separators. To enhance its readability on both screens, the proposed solution bolds this anomalous word, making it more visually prominent. Simultaneously, its font color is adjusted from the default black to dark gray, such as a color with an RGB value of (50, 50, 50), to provide a softer yet still high-contrast display effect. In this way, when users read the translation on both screens, they can quickly identify the key anomalous word "International Joint Security Council," even in less-than-ideal lighting conditions, thus helping users better understand the translated content.
[0079] Through the aforementioned technical solutions, this application significantly enhances the visual recognizability of unusual words in the translation. Boldness makes these unusual words more visually striking, helping users quickly locate and focus on words that may require additional understanding or confirmation. Simultaneously, changing the font color from black to dark gray provides a softer and more professional visual distinction without sacrificing readability, effectively avoiding visual fatigue that may be caused by overemphasis, especially during prolonged reading or when switching perspectives on dual-screen displays, offering a more comfortable reading experience. This specific font style adjustment strategy enables users to process translated information more efficiently, improving the overall readability of the translated content and user satisfaction.
[0080] In some embodiments described above, this application proposes optimizing the display effect of the translation by adjusting the visual presentation parameters of abnormal words (e.g., character spacing, halo parameters, and font style). However, in practical applications, the ambient lighting conditions of dual-screen devices can be complex and varied, with strong glare or shadow areas. In such cases, simply adjusting character spacing, halo parameters, or font style may not be sufficient to ensure good readability of abnormal words under all lighting conditions, thus affecting the user's efficiency in understanding the translation. If the above problem is not solved, users may experience inconvenience due to unclear translation display when using dual-screen devices in different lighting environments. To address this, this application further proposes a scheme for adaptively adjusting the brightness of abnormal words in areas of light interference to ensure that the translation maintains the best visual presentation effect under various lighting conditions.
[0081] The above methods also include: S501. Determine the area of light interference.
[0082] Specifically, light interference areas refer to regions on the screen that are significantly affected by external light sources, such as glare areas caused by direct sunlight or shadow areas caused by insufficient light. The purpose of identifying these areas is to optimize the display of unusual words in a targeted manner, avoiding readability degradation in these areas.
[0083] For details on this step, please refer to the following sections.
[0084] S502. Adjust the brightness of abnormal words in the light interference area to meet the following contrast formula. The contrast formula is:
[0085] Where C_target represents the target contrast of the pixel (x, y) where the abnormal word is located; I_adjusted(x, y) represents the adjusted brightness of the pixel (x, y) where the abnormal word is located; and I_background(x, y) represents the background brightness of the pixel (x, y) where the abnormal word is located.
[0086] The adjustment of the brightness of the abnormal words aims to establish a suitable target contrast ratio C_target between the displayed brightness of the abnormal words and the background brightness within the illumination interference area. This target contrast ratio C_target is a preset contrast value that ensures good readability. I_adjusted(x,y) represents the adjusted brightness of the abnormal words at pixel (x,y), a value that the system needs to calculate and set. I_background(x,y) represents the background brightness of the abnormal words at pixel (x,y), a value that can be obtained in real time through an ambient light sensor or image analysis technology. Using the above contrast formula, the system can inversely calculate the brightness I_adjusted(x,y) that the abnormal words should be adjusted to within the illumination interference area based on the real-time background brightness I_background(x,y) and the preset target contrast ratio C_target.
[0087] This application's solution effectively addresses the problem of decreased readability in complex lighting environments by introducing the identification of lighting interference areas and adaptive adjustment of the brightness of anomalous words. Specifically, when a dual-screen device is in an environment with uneven lighting, such as some areas being exposed to strong light and causing glare, or some areas being in shadow, traditional visual presentation parameter adjustments may not be effective. By first identifying these lighting interference areas, the system can accurately locate the screen portions requiring special processing. Subsequently, for anomalous words within these areas, the system no longer relies solely on parameters such as character spacing, halo, or font style, but further utilizes a contrast formula to dynamically calculate and adjust the brightness I_adjusted(x,y) of the anomalous words based on the real-time background brightness I_background(x,y) and the preset target contrast C_target. This brightness adjustment mechanism based on the contrast formula ensures that anomalous words maintain sufficient contrast with the background even within lighting interference areas, thereby significantly improving readability under various lighting conditions.
[0088] In one possible design, to determine the area of light interference, this application also includes: S601. For any pixel among multiple pixels, if the angle between the direction vector of the external light source and the normal vector of the pixel is less than a first preset angle, and the light intensity of the pixel is greater than the intensity threshold, the pixel is determined to be a glare area.
[0089] Specifically, the external light source direction vector refers to the direction vector from the external light source to a specific pixel on the screen, which reflects the direction of light incidence.
[0090] The normal vector of a pixel is a unit vector perpendicular to the screen surface and pointing outwards, representing the orientation of the screen at that pixel. By calculating the angle between the direction vector of the external light source and the normal vector of the pixel, the angle at which light enters the screen can be determined. When this angle is less than a first preset angle, it indicates that the light is entering the screen almost perpendicularly, which easily creates reflected glare. Furthermore, if the light intensity at that pixel exceeds an intensity threshold, the area is further confirmed as a glare region.
[0091] The first preset angle can be set according to the actual application scenario and screen material characteristics. For example, it can be set to between 15 and 30 degrees. The intensity threshold can be dynamically adjusted according to the brightness value measured by the ambient light sensor.
[0092] S602. For any pixel among multiple pixels, if the angle between the external light source direction vector and the normal vector of the pixel is greater than a second preset angle, and the light intensity of the pixel is less than the intensity threshold, the pixel is determined to be a shadow region.
[0093] The second preset angle is typically larger than the first preset angle, for example, it can be set between 60 and 80 degrees to distinguish between normal lighting areas and shadow areas. The intensity threshold is used here to determine whether the lighting is significantly lower than normal, thus confirming the presence of shadows. Therefore, by comprehensively considering the angle of light incidence and the actual light intensity, areas on the screen that may be affected by glare or shadows can be accurately identified, and these areas are collectively referred to as lighting interference areas.
[0094] S603. Glare areas and shadow areas are defined as light interference areas.
[0095] Through the above technical solution, this application overcomes the limitations of traditional methods in terms of translation readability under complex lighting conditions. By identifying areas of light interference and adaptively adjusting the brightness of abnormal words, it ensures that key information (i.e., abnormal words) in the translation can still be clearly and accurately presented to the user under adverse lighting conditions such as glare or shadows. This not only significantly improves the user experience of dual-screen devices in different usage scenarios but also enhances the user's efficiency in understanding the translated content, especially in outdoor environments or environments with frequent changes in lighting, where its advantages are even more pronounced.
[0096] like Figure 3 As shown, this embodiment of the invention also provides a dual-screen adaptive translation generation system based on semantic processing. The system includes: The acquisition module is used to acquire the translation generated by the translation program; The identification module is used to identify abnormal words in the translation; abnormal words are words whose length exceeds a preset threshold and lack natural separators. The adjustment module is used to adjust the visual presentation parameters of abnormal words. The visual presentation parameters include any one or more of the following: character spacing, halo parameters, and font style. The generation module is used to generate translations based on the adjusted visual rendering parameters of the abnormal words.
[0097] This application also provides a computer-readable storage medium. All or part of the processes in the above method embodiments can be executed by a computer program instructing related hardware. This program can be stored in the computer-readable storage medium, and when executed, it can include the processes of the above method embodiments. The computer-readable storage medium can be an internal storage unit of the task execution device (including a data sending end and / or a data receiving end) of any of the foregoing embodiments, such as the hard disk or memory of the task execution device. The computer-readable storage medium can also be an external storage device of the terminal device, such as a plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, etc., equipped on the terminal device. Further, the computer-readable storage medium can include both the internal storage unit of the task execution device and an external storage device. The computer-readable storage medium is used to store the computer program and other programs and data required by the task execution device. The computer-readable storage medium can also be used to temporarily store data that has been output or will be output.
[0098] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0099] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solutions of the embodiments of this application, essentially, or the parts that contribute to the prior art, or all or part of the technical solutions, can be embodied in the form of a software product. This software product is stored in a storage medium and includes several instructions to cause a device (which may be a microcontroller, chip, etc.) or processor to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, ROM, RAM, magnetic disks, or optical disks.
[0100] The above are merely specific embodiments of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions within the technical scope disclosed in this application should be covered within the scope of protection of this application.
Claims
1. A method for generating adaptive translations on a dual-screen screen based on semantic processing, characterized in that, include: Obtain the translation generated by the translation program; Identify unusual words in the translation; The abnormal words are those whose length exceeds a preset threshold and lack natural separators; Adjust the visual presentation parameters of the abnormal words, including any one or more of the following: character spacing, halo parameters, and font style; The translation is generated based on the adjusted visual rendering parameters of the abnormal words.
2. The method for generating adaptive translations on a dual-screen screen based on semantic processing according to claim 1, characterized in that, The identification of anomalous words in the translation includes: Determine the number of characters for each word in the translation; Words whose number of characters exceeds the preset threshold and which do not contain natural separators are identified as abnormal words.
3. The method for generating adaptive translations on a dual-screen screen based on semantic processing according to claim 1, characterized in that, The natural separator is a space or a hyphen.
4. The method for generating adaptive translations on a dual-screen screen based on semantic processing according to claim 1, characterized in that, Adjusting the visual presentation parameters of the abnormal words, including: If the abnormal word is the first occurrence in the translation and is an important word, then the visual presentation parameters of the abnormal word are adjusted; the important word meets any of the following conditions: it is a word in a preset professional domain vocabulary list, it is the subject of the sentence, or it is the object of the sentence.
5. The method for generating adaptive translations on a dual-screen screen based on semantic processing according to claim 1, characterized in that, When the visual rendering parameter is the character spacing, adjusting the visual rendering parameter of the abnormal words includes: The character spacing of the abnormal words is reduced according to a preset compression ratio.
6. The method for generating adaptive translations on a dual-screen screen based on semantic processing according to claim 1, characterized in that, When the visual rendering parameter is the halo parameter, adjusting the visual rendering parameter of the abnormal words includes: Render a halo with a radius of 2-3 pixels at a distance from the anomalous word.
7. The method for generating adaptive translations on a dual-screen screen based on semantic processing according to claim 1, characterized in that, When the visual presentation parameters are the font style, adjusting the visual presentation parameters of the abnormal words includes: The abnormal words are bolded; Change the font color of the abnormal words from black to dark gray.
8. The method for generating adaptive translations on a dual-screen screen based on semantic processing according to claim 1, characterized in that, The method further includes: Identify the area of light interference; Adjust the brightness of the abnormal words in the light interference area to satisfy the following contrast formula. The contrast ratio formula is: Wherein, C_target represents the target contrast of the pixel (x, y) where the abnormal word is located; I_adjusted(x, y) represents the adjusted brightness of the pixel (x, y) where the abnormal word is located; and I_background(x, y) represents the background brightness of the pixel (x, y) where the abnormal word is located.
9. The method for generating adaptive translations on a dual-screen screen based on semantic processing according to claim 8, characterized in that, The determination of the light interference area includes: For any pixel among multiple pixels, if the angle between the direction vector of the external light source and the normal vector of the pixel is less than a first preset angle, and the light intensity of the pixel is greater than the intensity threshold, the pixel is determined to be a glare area. For any pixel among multiple pixels, if the angle between the external light source direction vector and the normal vector of the pixel is greater than a second preset angle, and the light intensity of the pixel is less than an intensity threshold, the pixel is determined to be a shadow region. The glare area and the shadow area are defined as the light interference area.
10. A dual-screen adaptive translation generation system based on semantic processing, characterized in that, The system includes: The acquisition module is used to acquire the translation generated by the translation program; The identification module is used to identify abnormal words in the translation; the abnormal words are words whose length is greater than a preset threshold and lack natural separators. The adjustment module is used to adjust the visual presentation parameters of the abnormal words, and the visual presentation parameters include any one or more of the following: character spacing, halo parameters, and font style; The generation module is used to generate the translation based on the adjusted visual presentation parameters of the abnormal words.
Citation Information
Patent Citations
Translation return determination method and device
CN113420528A
Data display method
CN116700864A
Fall prevention apparatus of hoist
KR102174926B1
Method of displaying elements having a width greater than a screen display width
US6147670A