Message processing method, device, electronic device and medium

The method enables users to cancel translation errors in instant messaging by a second operation, improving user experience and communication efficiency in cross-lingual contexts.

JP7772971B2Active Publication Date: 2025-11-18BEIJING ZITIAO NETWORK TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
JP2024565269
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Priority Date
2022-07-05
Filing Date
2023-05-17
Publication Date
2025-11-18
Estimated Expiration
2043-05-17

AI Technical Summary

Technical Problem

Cross-lingual communication in instant messaging is hindered by the need for users to manually edit or re-enter messages after making mistakes with the 'translate-as-you-type' feature, affecting user experience.

Method used

A method and device that allows users to cancel translation in the input box by triggering a second predetermined operation, enabling easy return to the original message without re-entry.

Benefits of technology

Improves user experience by allowing users to quickly correct translation errors directly, enhancing communication efficiency in cross-lingual scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007772971000001
    Figure 0007772971000001
  • Figure 0007772971000002
    Figure 0007772971000002
  • Figure 0007772971000003
    Figure 0007772971000003
Patent Text Reader

Abstract

This application discloses a message processing method, apparatus, device, and medium. Among them, the method includes: when a user uses the "translate while inputting" function via an instant messenger, in response to the input of the message original text in the input box, displaying the message translation corresponding to the message original text in the translation text area; when the user triggers a first predetermined operation to use the translation text, displaying the message translation text in the input box; and when the user triggers a second predetermined operation to cancel the use of the translation text, displaying the message original text in the input box. That is, this application provides a cancellation function, which can be returned to the previous step by the second predetermined operation, avoiding the need for the user to re-enter after misoperation, and improving the user experience.
Need to check novelty before this filing date? Find Prior Art

Description

[Technical Field]

[0001] [CROSS-REFERENCE TO RELATED APPLICATIONS] This application claims priority to a Chinese patent application bearing application number 202210571461.9 and entitled "Method, apparatus, electronic device, and storage medium for realizing conversation translation," filed with the Patent Office of the People's Republic of China on May 24, 2022, and also claims priority to a Chinese patent application bearing application number 202210784607.8 and entitled "Message processing method, apparatus, device, and medium," filed with the Patent Office of the People's Republic of China on July 5, 2022, the contents of which are incorporated herein by reference in their entirety. This application relates to the field of computer technology, and in particular to a message processing method, apparatus, device, and medium. [Background technology]

[0002] Nowadays, to improve communication efficiency, users communicate information through instant messengers. In global collaboration scenarios, cross-lingual communication is a pain point for many users. In light of this, some instant messengers support a "translate-as-you-type" feature. Summary of the Invention

[0003] Therefore, the embodiments of the present application provide a message processing method, device, apparatus, and medium that allows the user to cancel the translation that has been used if the user makes a mistake, thereby improving the user's usage experience.

[0004] To achieve the above objectives, the technical solution of the present application is as follows:

[0005] According to a first aspect of the present application, In response to input of an original message into the input box, displaying a message translation corresponding to the original message in the translation area; displaying the message translation in the input box in response to a first predetermined operation using the translation; and displaying the original message in the input box in response to a second predetermined operation that cancels use of the translation.

[0006] According to a second aspect of the present application, a first display unit for displaying a message translation corresponding to the original message in a translation area in response to the original message being input into the input box; a second display unit for displaying the message translation in the input box in response to a first predetermined operation using the translation; a third display unit for displaying the original message text in the input box in response to a second predetermined operation for canceling use of the translation text.

[0007] According to a third aspect of the present application, a memory for storing instructions or computer programs; a processor for executing the instructions or computer program in the memory to cause the electronic device to perform the method of the first aspect.

[0008] According to a fourth aspect of the present application, there is provided a computer-readable storage medium having stored thereon instructions that, when executed on an apparatus, cause the apparatus to perform the method according to the first aspect.

[0009] According to a fifth aspect of the present application there is provided a computer program product comprising computer programs / instructions which, when executed by a processor, cause the computer program / instructions to perform the method according to the first aspect.

[0010] Therefore, the embodiments of the present application have the following beneficial effects:

[0011] In an embodiment of the present application, when a user uses the "translate as you type" function via an instant messenger, a message translation corresponding to the original message is displayed in the translation area in response to the original message being entered into the input box. When the user triggers a first predetermined operation to use the translation, the message translation is displayed in the input box. When the user triggers a second predetermined operation to cancel the use of the translation, the original message is displayed in the input box. That is, the present application provides a cancel function, allowing the user to return to the previous step by performing the second predetermined operation, avoiding the need for the user to re-enter after making a mistake and improving the user experience.

[0012] According to a sixth aspect of the present application, a method for displaying a corresponding input text in an input area of ​​a conversation interface in response to a user's input operation in the conversation interface, the input text having a first text format; obtaining a translation of the input text, the translation having a second text format, the second text format of the translation matching the first text format of the input text; and displaying the translated text in a translated text display area of ​​the conversation interface.

[0013] According to a seventh aspect of the present application, a first display unit for displaying corresponding input text in an input area of ​​the conversation interface in response to a user's input operation in the conversation interface, the input text having a first text format; a text obtainer for obtaining a translation of the input text, the translation having a second text format, the second text format of the translation matching the first text format of the input text; and a second display unit for displaying the translated text in a translated text display area of ​​the conversation interface.

[0014] According to an eighth aspect of the present application, There is provided an electronic device comprising a processor and a memory configured to store computer-executable instructions that, when executed, cause the processor to perform the steps of the method according to the sixth aspect above.

[0015] According to a ninth aspect of the present application, there is provided a computer-readable storage medium for storing computer-executable instructions which, when executed by a processor, cause the computer to perform the steps of the method according to the sixth aspect above.

[0016] According to a tenth aspect of the present application there is provided a computer program product comprising computer programs / instructions which, when executed by a processor, cause the computer program / instructions to perform the method according to the sixth aspect.

[0017] In an embodiment of the present specification, in response to a user's input operation in the conversation interface, a corresponding input text is displayed in an input area of ​​the conversation interface, the input text having a first text format, a translation text of the input text is obtained, the translation text has a second text format, the second text format of the translation text is consistent with the first text format of the input text, and the translation text is displayed in a translation text display area of ​​the conversation interface. Thus, in this embodiment, the input text in the user's conversation can be translated in real time to obtain the translation text, and the text format of the translation text and the input text can be consistent. The format synchronization ability between the translation text and the input text can better preserve the user's expression intention in the translation text, thereby improving the communication efficiency between users in cross-lingual communication scenarios and improving the efficiency of user collaboration work. [Brief explanation of the drawings]

[0018] In order to more clearly explain the technical solutions in the embodiments of the present application or the prior art, the drawings necessary for the description of the embodiments or the prior art will be briefly described below. Obviously, the drawings in the following description are only some of the embodiments described in the present application, and those skilled in the art can obtain other drawings based on these drawings without paying any creative effort. [Figure 1a] FIG. 1 is a schematic diagram illustrating speech-based input and simultaneous translation according to an embodiment of the present application. [Figure 1b] 1 is a schematic diagram of an input interface according to an embodiment of the present application; [Figure 2] 1 is a flowchart of a message processing method according to an embodiment of the present application; [Figure 3a] 1 is a schematic diagram of a display of a translation region according to an embodiment of the present application; [Figure 3b] 1 is a schematic diagram of a display of a translation region according to an embodiment of the present application; [Figure 3c] 1 is a schematic diagram of a display of a translation region according to an embodiment of the present application; [Figure 3d] 1 is a schematic diagram of a display of a translation region according to an embodiment of the present application; [Figure 4] 1 is a schematic diagram of a message processing device according to an embodiment of the present application; [Figure 5] 1 is a schematic diagram illustrating the configuration of an electronic device according to an embodiment of the present application. [Figure 6] 1 is a schematic diagram illustrating a method flow for implementing conversation translation according to an embodiment of the present disclosure; [Figure 7a] 1 is a schematic diagram of a conversation translation scenario according to one embodiment of the present specification; [Figure 7b] FIG. 2 is a schematic diagram of a conversation translation scenario according to another embodiment of the present disclosure. [Figure 7c] FIG. 2 is a schematic diagram of a conversation translation scenario according to another embodiment of the present disclosure. [Figure 7d] FIG. 2 is a schematic diagram of a conversation translation scenario according to another embodiment of the present disclosure. [Figure 7e] FIG. 2 is a schematic diagram of a conversation translation scenario according to another embodiment of the present disclosure. [Figure 8] FIG. 2 is a schematic diagram illustrating a method flow for implementing conversation translation according to another embodiment of the present disclosure. [Figure 9] 1 is a schematic diagram illustrating the configuration of an apparatus for implementing conversation translation according to an embodiment of the present specification. [Figure 10] 1 is a schematic diagram illustrating the configuration of an electronic device according to an embodiment of the present specification. DETAILED DESCRIPTION OF THE INVENTION

[0019] In order to help those skilled in the art to better understand the aspects of the present application, the following clearly and completely describes the technical solutions in the embodiments of the present application in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, not all of the embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of the present application without any creative efforts fall within the scope of protection of the present application.

[0020] In some application scenarios, to meet users' cross-lingual communication needs, instant messengers support a "translate-as-you-type" function. That is, when a user inputs a message into the input box, a translation area is displayed above the input box, and a message translation is displayed in the translation area based on the message input by the user. For example, as shown in FIG. 1a, a client automatically enables the "translate-as-you-type" function of an instant messenger for a user. The conversation input interface includes an input box 101 and a translation area 102. When a user inputs a message into the input box 101, a corresponding translation is displayed in the translation area 102. When a user inputs a message into the input box 101, a usage control 103 may be displayed in the translation area, as shown in the upper diagram of FIG. 1b. A shortcut key corresponding to the usage control 103 may also be displayed. When a user triggers the usage control 103 in the translation area, the translation is displayed in the input box, as shown in the lower diagram of FIG. 1b. The translation is sent in response to a send operation triggered by the user.

[0021] If a user finds that a message needs to be revised before sending the translation, they must manually edit the translation or delete the entire content and re-enter the original message to translate, which affects the user's operation. Here, "translate as you type" refers to the display of the corresponding translation in the translation field while the user is entering the original text in the input box. Here, the language corresponding to the translation is set by the user according to their own needs.

[0022] Based on this, in the message processing method of the present application, when a user inputs a message text in an input box, a message translation corresponding to the message text is displayed in the translation text area. The message translation is displayed in the input box in response to a first predetermined operation using the translation. If the user needs to go back, the original message text is displayed in the input box in response to a second predetermined operation canceling the use of the translation. That is, if the user makes an input error, the second predetermined operation can be used to go back, eliminating the need for the user to manually edit or re-enter, improving the user experience.

[0023] To facilitate understanding of the technical solutions according to the embodiments of the present application, the following description will be made in conjunction with the drawings.

[0024] Referring to Figure 2, this figure shows a message processing method according to an embodiment of the present application, which may be executed by a message processing client, which may be installed in an electronic device. Here, the electronic device may include a device with a communication function, such as a mobile phone, a tablet, a laptop, a desktop computer, an in-vehicle terminal, a wearable electronic device, a multifunction peripheral, or a smart home device, or may be a device simulated by a virtual machine or a simulator. As shown in Figure 2, the method may include the following steps:

[0025] S201: In response to an original message being input into the input box, a translated message corresponding to the original message is displayed in the translation area.

[0026] In this embodiment, when a user turns on the "translate as you type" function and enters a message text in the input box, the translation text corresponding to the message text is displayed in the translation text area. For ease of user browsing, the translation text area may be located above and adjacent to the input box, as shown in FIG. 1a.

[0027] In one embodiment of the present disclosure, when a message translation corresponding to the original message is displayed in the translation area, a first control may be further displayed in the input interface. Here, the first control is for triggering the use of the message translation. The input interface may include a translation area and an input box area. The first control may be displayed in the translation area, the input box area, or in a position other than the translation area and the input box area in the input interface. For example, the first control is the use control 103 located in the translation area shown in FIG. 1b. This allows the user to intuitively understand the function of the first control.

[0028] Specifically, when the "translate as you type" function is activated, a translation area may be displayed above the input frame, as shown in the schematic diagram of FIG. 1a. Alternatively, when the user activates the "translate as you type" function but has not yet entered a message into the input frame, a translation area may be displayed above the input frame, and a third control may be displayed in the translation area. The third control is for closing the translation area. As shown in the schematic diagram of the translation area display in FIG. 3a, a third control 104 may be displayed in the translation area. When the user enters a message into the input frame, for example, the translation area may not display the third control, but may instead display the message translation and the first control 103, as shown in the schematic diagram of FIG. 1b.

[0029] Here, the "translate as you type" feature can be activated manually by a user or automatically by a client. For example, if the primary languages ​​of both conversations do not match and the primary language of the current user is not English, entering the conversation automatically turns on translation for the current user. Here, the "translate as you type" feature can support translating different types of messages, such as text, rich text, and messages containing the @ symbol.

[0030] S202: In response to a first predetermined operation using a translation, the message translation is displayed in the input box.

[0031] In this embodiment, when a user triggers a first predetermined operation to use a translation, the message translation is displayed in the input box to indicate that the message translation in the translation area is to be used, thereby realizing the use of the message translation. Here, the first predetermined operation may be a trigger operation on a first control, a trigger operation on a shortcut key to use the translation, or an operation of right-clicking to call up a menu item and clicking an item in the menu item that uses the translation.

[0032] In one embodiment of the present disclosure, when the message translation is displayed in the input box, a second control may be further displayed in the input interface. Here, the second control is for canceling the use of the message translation, and the location where the second control is displayed may be the translation area, the input box area, or another location in the input interface other than the translation area and the input box area. For example, in the application scenario shown in FIG. 3b, when a user triggers the use control 103, the message translation appears in the input box, the translation area displays the cancel control 105, and the use control 103 disappears.

[0033] S203: In response to a second predetermined operation for canceling the use of the translation, the original message is displayed in the input box.

[0034] If the user wishes to cancel the current use, the user may trigger a second predetermined operation to cancel the use of the translation. In response to receiving the second predetermined operation triggered by the user, the system controls the original message to reappear in the input box. That is, the second predetermined operation can cancel the use of the message translation, making it easy for the user to quickly return to the previous step and re-edit the original message, thereby improving the user experience. For example, in the scenario application shown in FIG. 3c, when the user triggers the cancel control 105, the message translation appears in the translation area, the original message appears in the input box, and the use control 103 appears in the translation area, after which the cancel control 105 disappears.

[0035] After the original message is displayed in the input box, the translation of the message may be displayed in the translation area, allowing the user to easily view the translation corresponding to the original message.

[0036] Here, when a first control is displayed on the input interface, a shortcut key corresponding to the first control may be further displayed. This allows the user to easily trigger the use of the shortcut key for the translation. Furthermore, when a second control or a third control is displayed on the input interface, a shortcut key corresponding to each of the second control or the third control may be displayed. This embodiment is not limited thereto.

[0037] When the second control is displayed on the input interface, the second predetermined operation for canceling the use of the translation is a trigger operation for the second control, or the second predetermined operation may be a trigger operation for a shortcut key for canceling the use of the translation, or an operation of right-clicking to call up a menu item and clicking an item in the menu item for canceling the use of the translation.

[0038] In one embodiment of the present disclosure, after canceling the use of the translation, when the original message is displayed in the input box, the first control may be re-displayed in the input interface, so that the user can reuse the translation by triggering the first control, facilitating the user operation.

[0039] In one embodiment of the present disclosure, a display time length of the second control may be set. Within the display time length, the user can return to the previous step using the second control. If the display time length is exceeded, a third control is displayed in the input interface and the second control is no longer displayed. Specifically, if a message translation is displayed in the input box, the second control is displayed in the input interface, and no input is made within a predetermined time length, the third control is displayed in the input interface and the second control is no longer displayed. For example, if the display time length is 30 seconds, and the message translation appears in the input box, and the user does not make any input in the input box even after 30 seconds, the second control is no longer displayed and the third control is displayed. Here, the third control may be displayed in the translation area, the input box area, or in a position other than the translation area and the input box area in the input interface. For example, as shown in FIG. 3d, when the display time length of the cancel control 105 is equal to a predetermined time length and there is no input operation in the input box, the translation area is changed from the cancel control 105 to the close control 104 (third control).

[0040] In one embodiment of the present disclosure, when a message translation is displayed in the input frame and a second control is displayed in the input interface, a third control is displayed in the input interface in response to triggering sending of the message translation, and the second control is not displayed. That is, when a user triggers sending of a message translation to be used, the control displayed in the input interface changes from the second control to a third control. The third control is for closing the translation area. For example, as shown in the display configuration diagram of the translation area in FIG. 3a, a close control 104 is displayed in the translation area.

[0041] In one embodiment of the present disclosure, a first control is displayed in the input interface in response to a user subsequently triggering an input operation in the input box. When the user subsequently inputs into the input box, if the input box contains an existing message translation, the translation area displays the existing message translation and the message translation corresponding to the original message subsequently input by the user. Here, the control displayed in the input interface before the user subsequently triggers an input operation in the input box may be a second control or a third control. That is, when the user subsequently triggers an input operation in the input box, the control in the input interface may change from a cancel control to a use control, or from a close control to a use control. This allows the user to subsequently input the original message in the input box at any time, eliminating the need for manual switching and improving the user experience.

[0042] Specifically, when a translated message is displayed in the input box and a second control is displayed in the input interface, the first control is displayed in the input interface and the second control is not displayed in response to the user's subsequent input in the input box. That is, based on the original message that the user subsequently inputs in the input box, a trigger is triggered to automatically change the control displayed in the input interface from the second control to the first control.

[0043] Here, the message translation may include multimedia resources, including one or more of images, videos, or links (non-naked links), where a naked link is a form of external link that a user cannot directly click to enter the target page.

[0044] In one embodiment of the present disclosure, the method further includes sending the message translation to the conversation in response to an operation to send the message translation, and displaying all content of the message translation in the input box in response to a re-edit triggered for the sent message translation. That is, when the user re-edits, all content formats in the message translation, such as text, images, or links, can reappear in the input box, facilitating user editing and improving the user experience compared to when only the text in the existing message translation reappears in the input box. Here, the re-edit operation triggered by the user for the sent message translation may include first triggering a retraction operation for the sent message translation and then triggering a re-edit operation for the retracted message translation.

[0045] Thus, when a user uses the "translate as you type" function via an instant messenger, a message translation corresponding to the original message is displayed in the translation area in response to the original message being entered into the input box. When the user triggers a first predetermined operation to use the translation, the message translation is displayed in the input box. When the user triggers a second predetermined operation to cancel the use of the translation, the original message is displayed in the input box. That is, the second predetermined operation allows the user to return to the previous step, avoiding the need to re-enter after making a mistake and improving the user experience.

[0046] Based on the above method embodiment, the embodiment of the present application provides a message processing device and device, which will be described below in conjunction with the drawings.

[0047] 4, which is a structural schematic diagram of a message processing device according to an embodiment of the present application. As shown in FIG. 4, the device 400 may include a first display unit 401, a second display unit 402 and a third display unit 403.

[0048] The first display unit 401 is used to display a message translation corresponding to the message in the translation area in response to an input of the message in the input box, a second display unit (402) for displaying the message translation in the input box in response to a first predetermined operation using the translation; The third display unit 403 is used to display the original message text in the input box in response to a second predetermined operation for canceling the use of the translation text.

[0049] In one embodiment of the present disclosure, the third display unit 403 is further used to display the message translation in the translation area.

[0050] In one embodiment of the present disclosure, the first display unit 401 is further configured to display a first control on the input interface when a message translation corresponding to the original message is displayed in the translation area, and the first predetermined operation using the translation is a trigger operation for the first control; the second display unit 402 is further used to display a second control on the input interface when the message translation is displayed in the input box, and the second predetermined operation for canceling the use of the translation is a trigger operation on the second control; The third display unit 403 is further used to further display the first control on the input interface when the original message text is displayed in the input box in response to a second predetermined operation to cancel the use of the translation text.

[0051] In one embodiment of the present disclosure, the device further comprises a controller: The control unit is used to, when the message translation is displayed in the input box and a second control is displayed in the input interface, display the first control in the input interface and not display the second control in response to subsequent input into the input box.

[0052] In one embodiment of the present disclosure, the device further comprises a fourth display unit; The fourth display unit is used to, when the message translation is displayed in the input frame and a second control is displayed in the input interface, display a third control for closing the translation area in the input interface and not display the second control in response to a trigger to send the message translation.

[0053] In one embodiment of the present disclosure, the device further comprises a fourth display unit; The message translation is displayed in the input box, a second control is displayed in the input interface, and if no input is made within a predetermined period of time, a third control for closing the translation area is displayed in the input interface, and the second control is not displayed.

[0054] In one embodiment of the present disclosure, the fourth display unit is further used to display the first control on the input interface when an input operation is subsequently triggered in the input frame.

[0055] In one embodiment of the present disclosure, the method includes one or more of: displaying the first control in the translation text area; displaying the second control in the translation text area; and displaying the second control in the translation text area.

[0056] In one embodiment of the present disclosure, the message translation includes a multimedia resource, the multimedia resource including one or more of an image, a video, or a link.

[0057] In one embodiment of the present disclosure, the device further includes a transmitter and a fifth display unit; the sending unit is used to send the message translation to the conversation in response to an operation to send the message translation; A fifth display unit is used to display all the contents of the message translation in the input box in response to a re-edit triggered on the sent message translation.

[0058] For specific implementation of each means in this embodiment, please refer to the relevant descriptions in the above method embodiments.

[0059] In the embodiments of the present application, the division into means is merely an example and is a logical function division, and other division methods may be used in actual implementation. Each functional means in the embodiments of the present application may be integrated into one processing means, or each means may exist physically separately, or two or more means may be integrated into one means. For example, in the above embodiment, the processing unit and the transmitting unit may be the same means or different means. The integrated means may be implemented in the form of hardware or software functional means.

[0060] Referring to Figure 5, a schematic diagram of an electronic device 500 suitable for implementing an embodiment of the present disclosure is shown. Terminal devices in the embodiment of the present disclosure may include, but are not limited to, mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablets), PMPs (portable multimedia players), and in-car terminals (e.g., in-car navigation terminals), as well as fixed terminals such as digital TVs and desktop computers. The electronic device shown in Figure 5 is merely an example and does not impose any limitations on the functionality and scope of use of the embodiment of the present disclosure.

[0061] 5, electronic device 500 may include a processing unit (e.g., a central processing unit, a graphics processor, etc.) 501, which can perform various appropriate operations and processes according to programs stored in read-only memory (ROM) 502 or programs loaded from storage device 508 into random access memory (RAM) 503. RAM 503 further stores various programs and data necessary for the operation of electronic device 500. Processing unit 501, ROM 502, and RAM 503 are interconnected via bus 504. Input / output (I / O) interface 505 is also connected to bus 504.

[0062] Typically, input devices 506, including, for example, a touch screen, touch panel, keyboard, mouse, camera head, microphone, accelerometer, gyroscope, etc.; output devices 507, including, for example, a liquid crystal display (LCD), speaker, oscillator, etc.; storage devices 508, including, for example, a magnetic tape, hard disk, etc.; and communication devices 509 may be connected to the I / O interface 505. The communication devices 509 enable the electronic device 500 to communicate wirelessly or via wires with other devices to exchange data. While FIG. 5 illustrates the electronic device 500 with various devices, it should be understood that it is not intended to require the electronic device 500 to implement or include all of the devices shown. Alternatively, more or fewer devices may be implemented or included.

[0063] In particular, according to embodiments of the present disclosure, the processes described above with reference to the flowcharts may be implemented as a computer software program. For example, embodiments of the present disclosure include a computer program product, which includes a computer program embodied in a non-transitory computer-readable medium, including program code for performing the methods illustrated in the flowcharts. In such embodiments, the computer program may be downloaded and installed from a network via the communication device 509, or installed from the storage device 508, or installed from the ROM 502. When executed by the processing device 501, the computer program performs the functions defined above in the methods of the embodiments of the present disclosure.

[0064] The electronic device according to the embodiment of the present disclosure belongs to the same inventive concept as the method according to the above embodiment, and the technical details not described in detail in this embodiment can be referred to the above embodiment, and this embodiment has the same beneficial effects as the above embodiment.

[0065] According to an embodiment of the present disclosure, a computer storage medium is provided, having a computer program stored thereon, the program being executed by a processor to perform a method according to the above embodiment.

[0066] It should be noted that the computer-readable medium in this disclosure may be a computer-readable signal medium, a computer-readable storage medium, or any combination thereof. The computer-readable storage medium may be, for example, but is not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of the computer-readable storage medium include, but are not limited to, an electrical connection having one or more conductors, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In this disclosure, the computer-readable storage medium may be any tangible medium that contains or stores a program, and the program can be used in or in combination with an instruction execution system, apparatus, or device. In this disclosure, the computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code therein. Such propagated data signals may take many forms, including, but not limited to, electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium, which may transmit, propagate, or transmit a program for use in or in connection with an instruction execution system, apparatus, or device. The program code contained in the computer-readable medium may be transmitted over any suitable medium, including, but not limited to, electrical wire, optical cable, RF (radio frequency), or the like, or any suitable combination thereof.

[0067] In some embodiments, clients and servers may communicate using any now known or later developed network protocol, such as HTTP (HyperText Transfer Protocol), and may interconnect with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include local area networks ("LANs"), wide area networks ("WANs"), the World Wide Web (e.g., the Internet), and end-to-end networks (e.g., ad hoc end-to-end networks), as well as any now known or later developed network.

[0068] The computer-readable medium may be included in the electronic device, or may be a standalone medium not mounted in the electronic device.

[0069] The computer-readable medium has one or more programs stored therein, which, when executed by the electronic device, cause the electronic device to perform the method described above.

[0070] Computer program code for carrying out the operations of the present disclosure can be written using one or more programming languages, or a combination thereof, including, but not limited to, object-oriented programming languages ​​such as Java, Smalltalk, and C++, as well as general procedural programming languages ​​such as "C" or similar programming languages. The program code can execute entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer can be connected to the user's computer by any network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computer (e.g., via the Internet using an Internet Service Provider).

[0071] The flowcharts and block diagrams in the figures illustrate possible architectural architectures, functions, and operations of systems, methods, and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowcharts or block diagrams may represent a module, program segment, or portion of code, which includes one or more executable instructions for implementing a specified logical function. Note that in some alternative implementations, the functions depicted in the blocks may be implemented in a different order than depicted in the figures. For example, two successively shown blocks may be executed substantially simultaneously, or, depending on the functionality, they may be executed in the reverse order. Note that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, may be implemented by a dedicated hardware-based system that performs the specified function or operation, or by a combination of dedicated hardware and computer instructions.

[0072] The means according to the embodiments of the present disclosure may be realized by software or hardware, and the names of the means / modules may not limit the means themselves.

[0073] The functions described herein above may be performed, at least in part, by one or more hardware logic units, For example, exemplary hardware logic units that may be used include, but are not limited to, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), etc.

[0074] In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain or store a program used by or in connection with an instruction execution system, device, or apparatus. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or apparatus, or any suitable combination of the above. More specific examples of machine-readable storage media include an electrical connection based on one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), optical fiber, a compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof.

[0075] In addition, each embodiment in this specification will be described progressively, and the differences between each embodiment will be described mainly, and the same or similar parts between each embodiment may be referred to. Regarding the systems or devices disclosed in the embodiments, the descriptions are relatively simplified to correspond to the methods disclosed in the embodiments, and the relevant parts may be referred to the description of the methods.

[0076] In this application, "at least one" means one or more, and "multiple" means two or more. "And / or" is used to describe a relationship between related objects and indicates that three relationships may exist. For example, "A and / or B" may represent three cases: A alone exists, B alone exists, and both A and B exist simultaneously. A and B may be one or more. The character " / " generally indicates an "or" relationship between the related objects before and after. "At least one of" or similar expressions refers to any combination of these items, including any combination of single or multiple items. For example, "at least one of a, b, or c" may represent a, b, c, "a and b," "a and c," "b and c," or "a, b, and c," where a, b, and c may be single or multiple.

[0077] It should be noted that, in this specification, relational terms such as "first" and "second" are used solely to distinguish one entity or operation from another, and do not require or imply the existence of any actual relationship or order between those entities or operations. Furthermore, the terms "comprise," "include," or any other variant thereof, indicate a non-exclusive inclusion, such that a process, method, article, or device that includes a series of elements includes not only those elements but also other elements not expressly specified or elements inherent in such process, method, article, or device. Absent further limitations, an element defined by "comprises a..." does not exclude the inclusion of other identical elements in a process, method, article, or device that includes said element.

[0078] The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. A software module may be located in Random Access Memory (RAM), memory, Read Only Memory (ROM), Electrically Programmable ROM, Electrically Erasable Programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.

[0079] The above description of the disclosed embodiments will enable those skilled in the art to make or use the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Thus, the present application is not intended to be limited to these embodiments but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

[0080] In addition, with the rapid development of global collaborative work scenarios, employees within many large multinational corporations now collaborate through collaborative work software. These employees are typically distributed across different countries and regions and speak different languages. Most collaborative work software integrates many work applications, such as instant messaging, cloud documents, and audio / video conferencing, greatly improving the efficiency of collaborative work between employees across different countries and regions of multinational corporations.

[0081] In cross-lingual collaborative work scenarios, employees from different countries or regions may be limited by language barriers when collaborating through collaborative work software, which can reduce communication and work efficiency. For example, when employee A, who speaks language X, communicates with employee B, who speaks language Y, through collaborative work software, because neither employee is familiar with the other's language, employee A must first translate the content from language X to language Y using translation software and then send it to employee B. This additional translation process reduces the efficiency of communication between employees A and B, further reducing work efficiency.

[0082] Based on this, it is necessary to provide a technical solution to improve the communication efficiency between users in cross-lingual communication scenarios and improve the efficiency of users' collaborative work.

[0083] 6 is a schematic diagram illustrating a method flow for realizing conversation translation according to an embodiment of the present disclosure. As shown in FIG. 6, the flow includes the following steps:

[0084] Step S102: According to the user's input operation in the conversation interface, display a corresponding input text in an input area of ​​the conversation interface, where the input text has a first text format.

[0085] Step S104: Obtain a translation text of the input text, where the translation text has a second text format, and the second text format of the translation text is consistent with the first text format of the input text.

[0086] Step S106: The translated text is displayed in the translated text display area of ​​the conversation interface.

[0087] In an embodiment of the present specification, according to a user's input operation in the conversation interface, a corresponding input text is displayed in an input area of ​​the conversation interface, the input text has a first text format, a translation text of the input text is obtained, the translation text has a second text format, the second text format of the translation text is consistent with the first text format of the input text, and the translation text is displayed in a translation text display area of ​​the conversation interface.

[0088] Therefore, in this embodiment, the input text in the user's conversation is translated in real time to obtain the translated text, and the text format of the translated text and the input text is kept consistent. The format synchronization capability between the translated text and the input text allows the user's intention of expression to be better preserved in the translated text, which can improve the communication efficiency between users in cross-lingual communication scenarios and enhance the efficiency of user collaboration work.

[0089] In one embodiment of the present disclosure, the conversation is a conversation in an instant messaging application integrated into the collaborative work software, and in the above step S102, corresponding input text is displayed in the input area of ​​the conversation interface in response to the user's input operation in the conversation interface in the instant messaging application integrated into the collaborative work software.

[0090] In other embodiments, the conversation may be a conversation in another scenario, such as a conversation in an independent instant messaging application, a conversation in a video or audio conference, or a conversation for communication between different users of various platform applications (e.g., an e-commerce platform, a video platform, a social platform). Here, in the case of an e-commerce platform, communication may occur between different sellers, between different buyers, between a seller and a buyer, between a buyer and platform customer support, or between a seller and platform customer support. In the case of a video platform, communication may occur between video bloggers, or between a video blogger and platform customer support. In the case of a social platform, communication may occur between platform users, or between a platform user and platform customer support. Furthermore, the conversation may be a conversation initiated when a user sends a short message or a multimedia message via a mobile phone base station. Accordingly, in step S102, in response to a user's input operation in the conversation interface of any one of the conversations, corresponding input text may be displayed in the input area of ​​the conversation interface. Here, the input text has a first text format.

[0091] In one embodiment, in step S102, displaying the corresponding input text in the input area of ​​the conversation interface in response to the user's input operation in the conversation interface can be specifically performed by: (a1) acquiring a user's input text in response to a user's text input operation in the conversation interface and displaying the text in an input area of ​​the conversation interface; Or, (a2) in response to the user's audio input operation in the conversation interface, obtain audio data input by the user, convert the audio data into text to obtain input text, and display the input text in the input area of ​​the conversation interface.

[0092] In one case, a user may input text into the conversation interface, and the text input by the user is obtained according to the user's text input operation in the conversation interface, and the input text is displayed in the input area of ​​the conversation interface. In this case, the first text format is the text format customized and arranged for the input text when the user edits the input text. The user can input text by performing input operations in the rich text input box or plain text input box provided by the conversation.

[0093] In another case, the user may input audio data into the conversation interface, and the conversation interface acquires the audio data input by the user, converts the audio data into text, and displays the input text in the input area of ​​the conversation interface. In such a case, the user may input the audio data by performing an input operation using the voice input control provided by the conversation.

[0094] When a user inputs audio data, considering that the audio data does not have a text format, in one embodiment, after converting the audio data to text to obtain input text, the first text format of the input text obtained by conversion is set to the default format of the conversation, or set to the format previously set by the user in the conversation; or after converting to obtain input text, the user adjusts the format of the input text through a formatting tool in the conversation interface.

[0095] Here, if the first text format is a format that the user has previously arranged in the conversation, an interface may be provided for the user to customize the format, and the format customized by the user may be obtained through the interface, and the format customized by the user may be set as the first text format corresponding to the case of voice input.

[0096] Therefore, in this embodiment, considering that the audio data does not have a text format, after converting the audio data input by the user into text to obtain input text, the first text format of the converted input text may be set to the default format provided by the dialogue or the format previously set by the user in the dialogue, so that when the user inputs audio data, a corresponding first text format is set for the input text corresponding to the audio data.

[0097] FIG. 7A is a schematic diagram of a conversation translation scenario according to one embodiment of the present disclosure. As shown in FIG. 7A, in one scenario, taking collaboration software on a mobile phone as an example, a user may input a text conversation message through a plain text input box in an instant messaging application integrated with the collaboration software. When the user inputs a text conversation message, the instant messaging application may translate the text conversation message entered by the user into the language spoken by the conversation partner in real time to obtain a translated text, set the second text format of the translated text to be the same as the first text format of the user's input text, and display the translated text in the translated text display area. In the figure, the case where the language spoken by the conversation partner is English is taken as an example.

[0098] FIG. 7b is a schematic diagram of a conversation translation scenario according to another embodiment of the present disclosure. As shown in FIG. 7b, in one scenario, using collaboration software on a mobile phone as an example, a user may input a text conversation message using a rich text input field in an instant messaging application integrated with the collaboration software. When the user inputs a text conversation message, the instant messaging application may translate the text conversation message entered by the user into the language spoken by the conversation partner in real time to obtain a translated text, set the second text format of the translated text to be the same as the first text format of the user's input text, and display the translated text in the translated text display area. In the figure, the case where the language spoken by the conversation partner is English is taken as an example.

[0099] FIG. 7c is a schematic diagram of a conversation translation scenario according to another embodiment of the present disclosure. As shown in FIG. 7c, in one scenario, using collaboration software on a personal computer as an example, a user may input a text conversation message using a plain text input box in an instant messaging application integrated with the collaboration software. When the user inputs a text conversation message, the instant messaging application may translate the text conversation message entered by the user into the language spoken by the conversation partner in real time to obtain a translated text, set the second text format of the translated text to be the same as the first text format of the user's input text, and display the translated text in the translated text display area. In the figure, the case where the language spoken by the conversation partner is English is taken as an example.

[0100] FIG. 7d is a schematic diagram of a conversation translation scenario according to another embodiment of the present disclosure. As shown in FIG. 7d, in one scenario, using collaboration software on a personal computer as an example, a user may input a text conversation message using a rich text input field in an instant messaging application integrated with the collaboration software. When the user inputs a text conversation message, the instant messaging application may translate the text conversation message entered by the user into the language spoken by the conversation partner in real time to obtain a translated text, set the second text format of the translated text to be the same as the first text format of the user's input text, and display the translated text in the translated text display area. In the figure, the case where the language spoken by the conversation partner is English is taken as an example.

[0101] The simple distinction between plain text and rich text data frames is that plain text frames do not allow images to be added and do not allow for more complex text formatting, such as numbering. Rich text frames allow images to be added and allow for more complex text formatting, such as numbering, line breaks, etc. Rich text frames are comparable to a miniature WordPad program.

[0102] Of course, the user can perform simple formatting on the conversation message input in the plain text input box and the rich text input box, for example, set bold, italic, font, size, etc.

[0103] FIG. 7e is a schematic diagram of a conversation translation scenario according to another embodiment of the present disclosure. As shown in FIG. 7e, in one scenario, using collaboration software on a mobile phone as an example, a user may input a voice-based conversation message using a voice input control in an instant messaging application integrated with the collaboration software. When the user inputs a voice-based conversation message, the instant messaging application may translate the voice-based conversation message entered by the user into the language spoken by the conversation partner in real time and display the translated text in the translation text display area. The figure illustrates an example in which the language spoken by the conversation partner is English. In FIG. 7e, if the conversation message entered by the user is a voice message, the voice message may first be converted into the corresponding input text and displayed, and the translated text obtained by translating the input text may be displayed synchronously. As described above, in FIG. 7e, the text format corresponding to the translation text and the input text is the same, which may be the default format for the conversation or a format previously configured by the user for the conversation.

[0104] In this embodiment, when a user inputs a conversation message through a route such as a plain text frame, a rich text frame, or a voice input control, the conversation message is translated in real time, which can meet the conversation translation needs in different scenarios.

[0105] In one embodiment, the text format of the text content of each section in the input text is the same. As shown in FIG. 7a, the text format of the text content of each section in the input text is the same, and all are in No. 4 Song typeface. In another embodiment, the text format of the text content of each section in the input text may be different. As shown in FIG. 7c, the text format of the first line of the input text is No. 4 Song typeface, the text format of the second line of the input text is No. 4 Song typeface in bold, the text format of the third line of the input text is No. 4 Song typeface in italic, and the text format of the fourth line of the input text is No. 4 Song typeface with underline. In both of these cases, as shown in FIGS. 7a and 7c, the method of this embodiment can ensure that the second text format of the translated text is the same as the first text format of the input text.

[0106] In one embodiment, the conversation interface has an input area and a translation text display area, the input area has a text display sub-area for displaying input text, and the translation text display area is for displaying translated text, and the input area and the translation text display area are arranged vertically side by side.

[0107] Taking Figure 7a as an example, Figure 7a schematically shows a translation text display area and an input area. The translation text display area and the input area are arranged side by side vertically, and the input area further has a text display sub-area. In a scenario where a user inputs text, the text display sub-area is for displaying the text input by the user in real time, and the translation text display area is for displaying the translated text in real time.

[0108] Taking Fig. 7e as an example, Fig. 7e schematically shows a translation text display area and an input area, which are arranged vertically side by side, and the input area further has a text display sub-area, in a scenario where a user inputs audio data, the text display sub-area is for displaying input text corresponding to the audio data input by the user in real time, and the translation text display area is for displaying translation text in real time.

[0109] In one embodiment, after the translated text is displayed in the translated text display area of ​​the conversation interface, the translated text or audio data corresponding to the translated text may be sent to the conversation in response to a user's confirmation operation for the translated text. As shown in Figures 7a to 7e, the user may click a confirmation key to confirm the translated text, and the translated text confirmed by the user or audio data corresponding to the confirmed translated text may be sent to the conversation.

[0110] In another embodiment, after the translated text is displayed in the translated text display area of ​​the conversation interface, the translated text may be synchronously processed in response to a processing operation on the input text by a user, where the processing operation includes at least one of a scrolling operation, a text editing operation, a formatting operation, a text selection operation, and a cursor movement operation.

[0111] Specifically, the user may perform a scrolling operation on the input text to synchronously scroll through the translation text. The user may perform a text editing operation on the input text to synchronously edit the translation text, so that the translation of the input text edited by the user is reflected in the edited translation text. The user may perform a formatting operation on the input text to synchronously modify the format of the translation text, so that the text format of the input text remains the same as that of the translation text. The user may perform a text selection operation on the input text to synchronously select the corresponding translation text. The user may perform a cursor movement operation on the input text to synchronously move the cursor in the translation text.

[0112] According to this embodiment, when a user processes an input text, the translated text can be processed synchronously, so that the user can achieve the effect of correcting the translated text by correcting the original text.

[0113] In this embodiment, in response to a user's confirmation operation on the synchronized translated text, the synchronized translated text or audio data corresponding to the synchronized translated text may be sent to the conversation. Based on this, Figure 8 is a schematic diagram showing the flow of a method for realizing conversation translation according to another embodiment of the present disclosure. As shown in Figure 8, the flow includes the following steps:

[0114] Step S302: According to the user's input operation in the conversation interface, display a corresponding input text in an input area of ​​the conversation interface, where the input text has a first text format.

[0115] Step S304: Obtain a translation text of the input text, where the translation text has a second text format, and the second text format of the translation text is consistent with the first text format of the input text.

[0116] Step S306: The translated text is displayed in the translated text display area of ​​the conversation interface.

[0117] Step S308: In response to a user's confirmation operation on the translated text, the translated text or voice data corresponding to the translated text is transmitted to the conversation.

[0118] Step S310: In response to a processing operation on the input text by the user, the translated text is processed synchronously.

[0119] Step S312: In response to a user's confirmation operation on the processed translated text, the processed translated text or voice data corresponding to the processed translated text is transmitted to the conversation.

[0120] Specifically, after the translated text is displayed, in one case, if the user does not want to modify the input text, step S308 is executed to accept the user's confirmation operation on the translated text, and the translated text or the voice data corresponding to the translated text is sent to the conversation; in another case, if the user wants to modify the input text, steps S310 and S312 are executed to accept the user's processing operation on the input text, perform appropriate processing on the translated text, and further accept the user's confirmation operation on the processed translated text, and the translated text confirmed by the user or the voice data corresponding to the confirmed translated text is sent to the conversation.

[0121] In one embodiment, obtaining the translation text of the input text in step S104 specifically includes: (b1) determining a conversation target of a user; (b2) acquiring language type information of the conversation target; (b3) Acquire a translated text by translating and formatting the input text in accordance with the language type information of the conversation target.

[0122] In one embodiment, in operation (b1), determining the conversational subject of the user's conversation specifically includes: (b11) if the conversation is a private chat conversation, the conversation target of the user in the private chat conversation is the conversation target of the user; (b12) If the conversation is a group chat conversation, a target message for which a user has performed a predetermined message reply operation in the group chat conversation is determined, and the sender of the target message is made the conversation target of the user.

[0123] In operation (b11), for an individual chat conversation, the conversation target in the user's individual chat conversation is set as the user's conversation target. In operation (b12), for a group chat conversation, a target message for which the user performed a predetermined message reply operation in the group chat conversation is determined, and the sender of the target message is set as the user's conversation target.

[0124] In one embodiment, the predetermined message response operation includes a message read operation and a message marking operation for marking the message as a message waiting for a reply, and determining the target message for which the user performed the predetermined message response operation in the group chat conversation can be specifically: When a message waiting for a reply from a user written by a message writing operation exists in the group chat conversation, the message waiting for a reply is determined as a target message, and when a message waiting for a reply from a user written by a message writing operation does not exist in the group chat conversation, a message that has already been read by the user in the group chat conversation is determined as a target message by a message reading operation.

[0125] Specifically, after a user performs a predetermined message response operation on a group chat message in a group chat conversation, it is determined whether there is a message awaiting a reply from the user in the group chat conversation that has been written by a message writing operation, and if there is, the message awaiting a reply is determined as the target message; if there is no message awaiting a reply, the message that the user has already read in the conversation is determined as the target message by a message reading operation.

[0126] In one embodiment, the predetermined message response operation includes a message read operation, and determining the target message for which the user has performed the predetermined message response operation in the group chat conversation specifically involves determining the user's read message in the group chat conversation as the target message through the message read operation. That is, if the predetermined message response operation includes a message read operation, determining the user's read message in the group chat conversation as the target message.

[0127] In one embodiment, the predetermined message response operation includes a message writing operation to mark the message as a message waiting for a reply, and determining the target message for which the user has performed the predetermined message response operation in the group chat conversation specifically means determining the user's message waiting for a reply written in the group chat conversation by the message writing operation as the target message. That is, when the predetermined message response operation includes a message writing operation, determining the message waiting for a reply written by the user in the group chat conversation as the target message.

[0128] Considering that a user may have read multiple messages in a group chat conversation, in the above flow, when a user's read message in the group chat conversation is determined as a target message by a message read operation, if there are multiple read messages, the message last read by the user determined by the message read operation may be determined as the target message.Therefore, if the user does not indicate a message waiting for a reply and has read multiple messages, the last read message may be determined as the target message, and the sender of the target message may be the conversation target in the user's group chat conversation.

[0129] In this embodiment, it can be seen that in the case of an individual chat conversation, the user's conversation target can be determined. In the case of a group chat conversation, the conversation target is determined by a user operation, and the sender corresponding to the message waiting for a reply written by the user is most likely to be the conversation target to which the user will reply. If the user does not write a message waiting for a reply, the sender corresponding to the message read by the user is most likely to be the conversation target to which the user will reply. Therefore, it can be seen that the conversation target to which the user is most likely to reply is the conversation target in the user's group chat conversation, and the user's conversation target can be accurately determined in the group chat scenario.

[0130] In the above operation (b2), information on the language type of the conversation target is acquired. In one embodiment, the operation specifically includes: (b21) if the conversation is an individual chat conversation, obtain the main language type information of the conversation target as the language type information of the conversation target, or obtain the language type information of a message that satisfies a predetermined condition and that is sent by the conversation target in the individual chat conversation as the language type information corresponding to the conversation; (b22) When the conversation is a group chat conversation, the operation is to obtain the main language type information of the conversation target as the language type information of the conversation target, or to determine a target message that the conversation target sent in the group chat conversation and for which a predetermined message response operation was performed by the user, and to set the language type information of the target message as the language type information of the conversation target.

[0131] In one case, in an individual chat conversation, after determining a user's conversation target, the main language type information of the conversation target may be acquired as the conversation target's language type information. A machine learning model may be used to identify the language type of messages sent by the conversation target. For example, conversation messages sent by the conversation target in a conversation using an instant messaging application may be input into a pre-trained machine learning model, which then outputs the language type information of the conversation messages. The language type information output by the machine learning model is used as the language type label of the conversation messages. In this way, the language type labels of conversation messages sent by the conversation target within a recent period (e.g., three months) may be collected to determine the main language type information of the conversation target. Of course, if the conversation target has set a label for the main language type information themselves, the label may be acquired directly to determine the main language type information of the conversation target. Furthermore, the main language type information of the conversation target is used as the conversation target's language type information.

[0132] In the case of an individual chat conversation, in another case, the language type information of a message that is sent by the conversation target in the individual chat conversation and that satisfies a predetermined condition is used as the language type information of the conversation target. Here, the message that satisfies the predetermined condition includes one or more of the message last read by the user and a message written by the user that is waiting for a reply. Specifically, in an individual chat conversation between the user and the conversation target, the conversation target sends a conversation message, and the language type information of the message last read by the user among the sent conversation messages is used as the language type information of the conversation target, or the language type information of the message written by the user that is waiting for a reply among the sent conversation messages is used as the language type information of the conversation target. If the sent conversation messages include both a message read by the user and a message written by the user that is waiting for a reply, the language type information of the message last read by the user and the language type information of the message written by the user may be obtained, and if the two language type information are the same, the same language type information may be used as the language type information of the conversation target. If the two language type information are different, the language type information of the message written by the user that is waiting for a reply may be used as the language type information of the conversation target.

[0133] In the case of a group chat conversation, the main language type information of the conversation target may be obtained as the language type information of the conversation target using the same method as described above. Alternatively, a target message sent by the conversation target in the group chat conversation and for which a predetermined message reply operation has been performed by the user is determined. The process of determining the target message is the same as the process of determining the target message in the above-described operation (b12). As can be seen from the above-described process of determining the target message, the target message is sent by the conversation target. The language type information of the target message is used as the language type information of the conversation target. The language type information of the target message may be identified using a machine learning model.

[0134] It can be seen that operations (b21) and (b22) enable acquisition of language type information of a conversation target in different conversation scenarios. In one embodiment, operation (b3) translates and formats the input text according to the language type information of the conversation target to obtain a translated text, which may be accomplished by a pre-trained machine learning model. When training the machine learning model, text data having a format and a translation having the same format as the text data may be used as training data, and parameters in the model may be trained using the training data. The trained model has the ability to translate text and the ability to maintain the same format between the original text and the translated text. In another embodiment, operation (b3) translates and formats the input text according to the language type information of the conversation target to obtain a translated text. Specifically, the input text may be translated by a pre-trained machine learning model, and the translated text may be formatted based on format information of a first text format of the input text to obtain the translated text. The second text format of the translation text is the same as the first text format of the input text, because the text output by the machine learning model is formatted according to the format information of the first text format to obtain the translation text.

[0135] As described above, the above method for realizing conversation translation can translate the input text in a user's conversation in real time to obtain a translated text, and maintain the consistency of the text format between the translated text and the input text. The format synchronization ability between the translated text and the input text can better preserve the user's expressed intention in the translated text, improve the communication efficiency between users in cross-lingual communication scenarios, and increase the efficiency of user collaboration work.

[0136] FIG. 9 is a schematic diagram of the configuration of an apparatus for realizing conversation translation according to one embodiment of the present specification. As shown in FIG. 9, the apparatus includes: a first display unit (41) for displaying a corresponding input text in an input area of ​​the conversation interface in response to a user's input operation in the conversation interface, the input text having a first text format; a text obtainer 42 for obtaining a translation of the input text, the translation having a second text format, the second text format of the translation matching the first text format of the input text; and a second display unit 43 for displaying the translated text in a translated text display area of ​​the conversation interface.

[0137] Optionally, the text acquisition unit 42 specifically: determining a conversation target of the user in the conversation; acquiring language type information of the conversation target; and obtaining a translated text by performing translation and formatting processing on the input text in accordance with the language type information of the conversation target.

[0138] Selectively, The system further includes a processing unit for synchronously processing the translated text in response to a processing operation on the input text by the user after the translated text is displayed in a translated text display area of ​​the conversation interface.

[0139] Selectively, The conversation interface further includes a transmitting unit for transmitting the translated text or audio data corresponding to the translated text to the conversation in response to a confirmation operation of the user on the translated text after the translated text is displayed in the translated text display area of ​​the conversation interface.

[0140] Optionally, the first display unit 41 specifically displays: acquiring a text input by the user in response to a text input operation by the user in the conversation interface, and displaying the text in an input area of ​​the conversation interface; Or, It is used to obtain audio data input by the user in response to the user's audio input operation in the conversation interface, convert the audio data into text to obtain input text, and display the input text in the input area of ​​the conversation interface.

[0141] Selectively, The method further includes a format setting unit for, after converting the audio data into text to obtain input text, setting the first text format of the input text to a default format of the conversation or a format previously arranged by the user in the conversation.

[0142] Optionally, the text acquisition unit 42 further specifically: If the conversation is an individual chat conversation, setting the conversation target of the user in the individual chat conversation as the conversation target of the user; If the conversation is a group chat conversation, it is used to determine a target message for which the user performed a predetermined message reply operation in the group chat conversation, and to make the sender of the target message the conversation subject of the user.

[0143] Optionally, the predetermined message response operation includes a message reading operation and a message writing operation for writing a message as a message waiting for a reply, and the text acquisition unit 42 is further specifically used to determine, when a message waiting for a reply from the user written by the message writing operation exists in the group chat conversation, the message waiting for a reply as a target message, and when a message waiting for a reply from the user written by the message writing operation does not exist in the group chat conversation, to determine, by the message reading operation, a message that the user has already read in the group chat conversation as a target message; Or, The predetermined message response operation includes a message read operation, and the text acquisition unit 42 further specifically: The message reading operation is used to determine the user's read message in the group chat conversation as a target message; Or, the predetermined message response operation includes a message display operation for displaying the message as a message waiting for a reply; The text acquisition unit 42 is further specifically used to determine, as a target message, a message awaiting a reply from the user written in the group chat conversation by the message writing operation.

[0144] Optionally, the text acquisition unit 42 further specifically: If the number of read messages is plural, the message that the user has read last, determined by the message reading operation, is used to determine the target message.

[0145] Optionally, the text acquisition unit 42 further specifically: If the conversation is an individual chat conversation, acquiring main language type information of the conversation target as language type information of the conversation target, or acquiring language type information of a message that satisfies a predetermined condition and that is sent by the conversation target in the individual chat conversation as language type information of the conversation target; If the conversation is a group chat conversation, the main language type information of the conversation target is obtained as the language type information of the conversation target, or a target message that the conversation target sent in the group chat conversation and for which a predetermined message response operation was performed by the user is determined, and the language type information of the target message is used as the language type information of the conversation target.

[0146] Optionally, the message satisfying the predetermined condition is the last message read by said user; and a message waiting for a reply written by the user.

[0147] It should be noted that the device for realizing conversation translation in this embodiment can implement each process of the embodiment of the method for realizing conversation translation described above, and achieve the same effects and functions, so the description will not be repeated here.

[0148] An embodiment of the present specification further provides an electronic device. FIG. 5 is a schematic diagram of an electronic device according to an embodiment of the present specification. As shown in FIG. 10, the electronic device may vary considerably in configuration or performance and may include one or more processors 801 and memory 802. The memory 802 may store one or more application programs or data. Here, the memory 802 may be a temporary or permanent storage. The application program stored in the memory 802 may include one or more modules (not shown), each of which may include a sequence of computer-executable instructions for the electronic device. Furthermore, the processor 801 may be configured to communicate with the memory 802 and execute the sequence of computer-executable instructions in the memory 802 for the electronic device. The electronic device may further include one or more power sources 803, one or more wired or wireless network interfaces 804, one or more input or output interfaces 805, one or more keyboards 806, etc.

[0149] In one specific embodiment, the electronic device comprises a processor; When executed, the processor: In response to a user's input operation in the conversation interface, displaying corresponding input text in an input area of ​​the conversation interface, the input text having a first text format; obtaining a translation of the input text, the translation having a second text format, the second text format of the translation matching the first text format of the input text; and displaying the translated text in a translated text display area of ​​the conversation interface.

[0150] It should be noted that the electronic device in this embodiment can implement each process of the embodiment of the method for implementing conversation translation described above, and achieve the same effects and functions, so the description will not be repeated here.

[0151] Another embodiment of the present disclosure, when executed by a processor, In response to a user's input operation in the conversation interface, displaying corresponding input text in an input area of ​​the conversation interface, the input text having a first text format; obtaining a translation of the input text, the translation having a second text format, the second text format of the translation matching the first text format of the input text; and displaying the translated text in a translated text display area of ​​the conversation interface.

[0152] It should be noted that the storage medium in this embodiment can implement each process of the embodiment of the method for implementing conversation translation described above, and achieve the same effects and functions, so the description will not be repeated here.

[0153] The computer-readable storage medium includes a read-only memory (ROM), a random access memory (RAM), a magnetic disk, an optical disk, and the like.

[0154] In the 1990s, improvements to a technology could be clearly distinguished between hardware improvements (e.g., improvements to circuit structures such as diodes, transistors, and switches) and software improvements (improvements to method flow). However, with the development of technology, many current method flow improvements can be considered as direct improvements to hardware circuit configurations. Designers generally obtain the corresponding hardware circuit structure by programming the improved method flow into a hardware circuit. Therefore, it cannot be said that a method flow improvement cannot be realized by a hardware entity module. For example, a programmable logic device (PLD) (e.g., a field programmable gate array (FPGA)) is such an integrated circuit, whose logic function is determined by user programming of the device. A digital system can be "integrated" into a PLD by programming it by the designer himself, without requiring a chip manufacturer to design and fabricate a dedicated integrated circuit chip.In addition, instead of creating integrated circuit chips by hand, this programming is now often achieved using "logic compiler" software, similar to the software compilers used in program development and creation. Furthermore, the original code before compilation must also be written in a specific programming language called a Hardware Description Language (HDL). There is not just one type of HDL, but many, including ABEL (Advanced Boolean Expression Language), AHDL (Altera Hardware Description Language), Confluence, CUPL (Cornell University Programming Language), HDCal, JHDL (Java Hardware Description Language), Lava, Lola, MyHDL, PALASM, and RHDL (Ruby Hardware Description Language). The most commonly used HDLs today are VHDL (Very-High-Speed ​​Integrated Circuit Hardware Description Language) and Verilog. It will be apparent to those skilled in the art that a hardware circuit that implements the logic method flow can be easily obtained by programming an integrated circuit using some of the hardware description languages ​​mentioned above for the method flow with a little logic programming.

[0155] The controller may be implemented in any suitable manner. For example, the controller may take the form of a microprocessor or a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro)processor, logic gates, switches, an application-specific integrated circuit (ASIC), a programmable logic controller, and an embedded microcontroller. Examples of controllers include, but are not limited to, microcontrollers such as the ARC625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicone Labs C8051F320. A memory controller may also be implemented as part of the control logic of the memory. As will be appreciated by those skilled in the art, in addition to implementing a controller purely in the form of computer-readable program code, the controller may also be implemented in the form of logic gates, switches, an application-specific integrated circuit, a programmable logic controller, an embedded microcontroller, etc. by logic programming method steps. Therefore, such a controller may be considered a type of hardware component, and the devices included therein for implementing various functions may also be considered structures within the hardware component. Or, in turn, the apparatus for realizing the various functions may be viewed as software modules that implement the methods, or as structures within the hardware components.

[0156] The systems, devices, modules, or means described in the above embodiments may be specifically implemented by computer chips or entities, or may be implemented by products having certain functions. A typical implementation device is a computer. Specifically, the computer may be, for example, a personal computer, a laptop computer, a mobile phone, a camera phone, a smartphone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or any combination of these devices.

[0157] For ease of description, the above-described device is described by dividing it into its respective means based on its function. Of course, in implementing the embodiments of this specification, the functions of the respective means may be realized by the same or multiple pieces of software and / or hardware.

[0158] As will be appreciated by those skilled in the art, one or more embodiments herein may be provided as a method, a system, or a computer program product. Accordingly, one or more embodiments herein may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware. Also, one or more embodiments herein may take the form of a computer program product embodied in one or more computer-usable storage media (including, but not limited to, magnetic disk memory, CD-ROM, optical memory, etc.) containing computer-usable program code.

[0159] This specification has been described with reference to flowcharts and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this specification. It should be understood that each flow and / or block in the flowcharts and / or block diagrams, and combinations of flows and / or blocks in the flowcharts and / or block diagrams, may be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate an apparatus, whereby the instructions, executed by the processor of the computer or other programmable data processing device, cause the apparatus to implement the functions specified in one or more flows in the flowcharts and / or one or more blocks in the block diagrams.

[0160] These computer program instructions may be stored in a computer-readable memory that can direct a computer or other programmable data processing device to operate in a particular manner, thereby causing the instructions stored in the computer-readable memory to generate an article of manufacture that includes an instruction apparatus that implements the functions specified in one or more flows of the flowcharts and / or one or more blocks of the block diagrams.

[0161] These computer program instructions may be loaded into a computer or other programmable data processing device, thereby causing the computer or other programmable device to perform a sequence of operational steps to generate a computer-implemented process, whereby the instructions executed on the computer or other programmable device provide steps for implementing the functions specified in one or more flows of the flowcharts and / or one or more blocks of the block diagrams.

[0162] It should be noted that the terms "comprise," "include," or any other variation thereof, indicate a non-exclusive inclusion, and that a process, method, article, or device that includes a series of elements includes not only those elements but also other elements not expressly specified or inherent in such process, method, article, or device. Absent more limitations, an element qualified by "comprises a..." does not exclude the inclusion of other identical elements in a process, method, article, or device that includes said element.

[0163] One or more embodiments herein may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform particular tasks or implement particular abstract data types. One or more embodiments herein may also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media, including memory storage devices.

[0164] Each embodiment in this specification will be described in a step-by-step manner, and the same or similar parts between the embodiments may be referred to, and the differences between each embodiment will be described in detail. In particular, since the system embodiments are basically similar to the method embodiments, the description will be relatively simplified, and the relevant parts may be referred to the description of the method embodiments.

[0165] The above are merely examples of the present specification and are not intended to limit the present specification. Those skilled in the art may find various modifications and changes to the present specification. Any modifications, equivalents, improvements, etc. made within the spirit and principles of the present specification should be included in the scope of the claims of the present specification.

Claims

1. In response to input of an original message into the input box, displaying a message translation corresponding to the original message in the translation area; In response to a first predetermined operation using the message translation, the message translation is displayed in the input box, and the original message is not displayed, wherein the first predetermined operation includes at least one of a trigger operation on a first control, a trigger operation on a shortcut key using the translation, and an operation of right-clicking to call a menu item and clicking an item in the menu item that uses the translation; a second predetermined operation for canceling the use of the message translation after the first predetermined operation, the original message is displayed in the input box, and the message translation is displayed in the translation area, wherein the second predetermined operation is at least one of a trigger operation on a second control, a trigger operation on a shortcut key for canceling the use of the translation, and an operation of right-clicking to call up a menu item and clicking an item in the menu item for canceling the use of the translation.

2. When a message translation corresponding to the original message is displayed in the translation area, the first control is further displayed on the input interface, and the first predetermined operation using the message translation is a trigger operation for the first control; When the message translation is displayed in the input box, the second control is further displayed in the input interface, and the second predetermined operation for canceling the use of the message translation is a trigger operation for the second control; and further displaying the first control in the input interface when the original message is displayed in the input frame and the message translation is displayed in the translation area in response to a second predetermined operation that cancels use of the message translation.

3. 3. The method of claim 2, further comprising, when the message translation is displayed in the input box and the second control is displayed in the input interface, displaying the first control in the input interface and not displaying the second control in response to subsequent input into the input box.

4. 3. The method of claim 2, further comprising, when the message translation is displayed in the input frame and the second control is displayed in the input interface, displaying a third control in the input interface for closing the translation area and not displaying the second control in response to triggering sending the message translation.

5. 3. The method of claim 2, further comprising: displaying a third control in the input interface for closing the translation area and not displaying the second control when the message translation is displayed in the input frame and the second control is displayed in the input interface and no input is made within a predetermined length of time.

6. The method of claim 4 , further comprising: displaying the first control in the input interface when a subsequent input operation is triggered in the input pane.

7. Displaying the first control in the translation text area; Displaying the second control in the translation area; and displaying a third control in the translation text area for closing the translation text area.

8. 10. The method of claim 1, wherein the message translation includes a multimedia resource, the multimedia resource including one or more of an image, a video, or a link.

9. sending the message translation to the conversation in response to an operation to send the message translation; 9. The method of claim 8, further comprising: in response to a triggered re-edit of the submitted message translation, displaying all content in the message translation in the input box.

10. a first display unit for displaying a message translation corresponding to the original message in a translation area in response to the original message being input into the input frame; a second display unit for displaying the message translation in the input box without displaying the original message in response to a first predetermined operation using the message translation, wherein the first predetermined operation includes at least one of a trigger operation on a first control, a trigger operation on a shortcut key using the translation, and an operation of right-clicking to call a menu item and clicking an item in the menu item that uses the translation; a third display unit for displaying the original message in the input box and the message translation in the translation area in response to a second predetermined operation for canceling the use of the message translation after the first predetermined operation, wherein the second predetermined operation includes at least one of a trigger operation on a second control, a trigger operation on a shortcut key for canceling the use of the translation, and an operation of right-clicking to call up a menu item and clicking an item in the menu item for canceling the use of the translation.

11. a memory for storing instructions or computer programs; a processor for executing the instructions or computer program in the memory to cause the electronic device to perform the method of any one of claims 1 to 9.

12. A computer-readable storage medium having stored thereon instructions which, when executed on a device, cause said device to carry out the method of any one of claims 1 to 9.

Citation Information

Patent Citations

  • Method and system for translation tool for conference assistance

    JP2021190052A

  • Viewer device, viewing system, viewer program, and recording medium

    WO2012086359A1