WO2020062640A1 - 终端应用动态文案的语言切换方法、服务器及存储介质 - Google Patents

终端应用动态文案的语言切换方法、服务器及存储介质 Download PDF

Info

Publication number
WO2020062640A1
WO2020062640A1 PCT/CN2018/122722 CN2018122722W WO2020062640A1 WO 2020062640 A1 WO2020062640 A1 WO 2020062640A1 CN 2018122722 W CN2018122722 W CN 2018122722W WO 2020062640 A1 WO2020062640 A1 WO 2020062640A1
Authority
WO
WIPO (PCT)
Prior art keywords
language
terminal
dynamic
server
switched
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Ceased
Application number
PCT/CN2018/122722
Other languages
English (en)
French (fr)
Inventor
黄超
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
OneConnect Smart Technology Co Ltd
Original Assignee
OneConnect Smart Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by OneConnect Smart Technology Co Ltd filed Critical OneConnect Smart Technology Co Ltd
Publication of WO2020062640A1 publication Critical patent/WO2020062640A1/zh
Anticipated expiration legal-status Critical
Ceased legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces
    • G06F9/454Multi-language systems; Localisation; Internationalisation

Definitions

  • the present application relates to the field of communications, and in particular, to a language switching method for dynamic copywriting of a terminal application, a server, and a computer-readable storage medium.
  • the language corresponding to the dynamic prompt copy displayed by the terminal application is often determined according to the version of the terminal application currently downloaded by the user. For example, if the user downloads a Chinese version of the terminal application, the dynamic of the terminal application The copy is the Chinese version; if the user downloads the English version of the terminal application, the dynamic copy of the terminal application is the English version. If the user version is downloaded incorrectly, it cannot adapt to the display of dynamic copy, so the display of dynamic copy on the terminal application is not intelligent enough.
  • the main purpose of this application is to provide a language switching method, server, and computer-readable storage medium for dynamic copy of terminal application, which aims to solve the problem that the display of dynamic copy of terminal application is not intelligent enough.
  • the present application provides a language switching method for terminal application dynamic copywriting, including steps:
  • the server returns the language pack to the terminal application for the terminal application to switch the language of the dynamic copy by loading the language pack.
  • this application further provides a server, including:
  • An obtaining module configured to receive a dynamic copy language switching instruction sent by the terminal application, and obtain the language to be switched in the dynamic copy according to the dynamic copy language switching instruction;
  • the obtaining module is further configured to obtain a language pack corresponding to the language to be switched from a preset memory according to the language to be switched;
  • a return module is configured to return the language pack to the terminal application, so that the terminal application switches the language of the dynamic copy by loading the language pack.
  • the present application further provides a server.
  • the server includes: a communication module, a memory, a processor, and a computer program stored in the memory and executable on the processor.
  • the computer program is When the processor executes, the steps of the language switching method of the terminal application dynamic copywriting as described above are implemented.
  • the present application also provides a computer-readable storage medium, where the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, implements a language of the terminal application dynamic copywriting as described above. Steps to switch methods.
  • a dynamic copy language switching instruction sent by the terminal application is received by a server, and the language to be switched of the dynamic copy is obtained according to the dynamic copy language language switching instruction.
  • the server selects a language from the preset according to the language to be switched.
  • a language pack corresponding to the language to be switched is obtained in the memory; the server returns the language pack to the terminal application for the terminal application to switch the language of the dynamic copy by loading the language pack. Therefore, the language of the terminal application dynamic copywriting can be freely switched according to the language pack returned by the server, and the terminal application does not need to be downloaded again.
  • the language switching of the dynamic copywriting is very intelligent and flexible.
  • FIG. 1 is a schematic structural diagram of a server involved in a solution according to an embodiment of the present application
  • FIG. 2 is a schematic flowchart of a first embodiment of a language switching method for dynamic copywriting applied by a terminal of this application;
  • FIG. 3 is a detailed flowchart of step S10 in the second embodiment of a language switching method for dynamic copywriting applied by a terminal of this application;
  • FIG. 4 is a detailed flowchart of step S10 in the third embodiment of a language switching method for dynamic copywriting applied by a terminal of this application;
  • FIG. 5 is a detailed flowchart of step S20 in a fourth embodiment of a language switching method for dynamic copywriting applied by a terminal of this application;
  • FIG. 6 is a schematic diagram of a functional module of a server of the present application.
  • FIG. 1 is a schematic diagram of a hardware structure of a server provided by the present application.
  • the server includes components such as a communication module 10, a memory 20, and a processor 30.
  • the processor 30 is respectively connected to the memory 20 and the communication module 10.
  • a computer program is stored in the memory 20, and the computer program is simultaneously executed by the processor 30.
  • the communication module 10 can be connected to an external communication device through a network.
  • the communication module 10 can receive requests from external communication devices, and can also send requests, instructions, and information to the external communication devices.
  • the external communication device may be a terminal used by other servers and / or users.
  • the terminal may be a computer, a tablet computer, a mobile phone, or the like.
  • An application is installed on the terminal, and dynamic copy is displayed on the application display interface.
  • the memory 20 may be used to store software programs and various data.
  • the memory 20 may mainly include a storage program area and a storage data area, where the storage program area may store an operating system, at least one application required by a function (such as determining a language to be switched by a terminal application), etc .; the storage data area may include a database, The storage data area can store data or information created according to the use of the server.
  • the memory 20 may include a high-speed random access memory, and may further include a non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, or other volatile solid-state storage device.
  • the processor 30 is a control center of the server, and uses various interfaces and lines to connect various parts of the entire server. By running or executing software programs and / or modules stored in the memory 20 and calling data stored in the memory 20, Perform various functions of the server and process data to monitor the server as a whole.
  • the processor 30 may include one or more processing units; optionally, the processor 30 may integrate an application processor and a modem processor, wherein the application processor mainly processes an operating system, a user interface, and an application program, etc.
  • the tuning processor mainly handles wireless communication. It can be understood that the foregoing modem processor may not be integrated into the processor 30.
  • the server may further include a circuit control module for connecting to a power source to ensure the normal operation of other components.
  • a circuit control module for connecting to a power source to ensure the normal operation of other components.
  • the method includes:
  • Step S10 The server receives a dynamic copy language switching instruction sent by the terminal application, and obtains the language to be switched in the dynamic copy according to the dynamic copy language switching instruction;
  • dynamic copy refers to the prompt language displayed by the terminal application during the use of the terminal application, for example, prompting the user to enter a user name and password on the display interface, or prompting for a password that only supports a mixture of uppercase and lowercase letters and numbers.
  • the dynamic copy of the terminal application is fed back to the terminal by the server.
  • the terminal application can receive the trigger operation performed by the user on the application display interface to generate a dynamic copy language language switching instruction based on the trigger operation and the information required to switch the language of the dynamic copy language, or the terminal application can periodically and independently generate a dynamic copy language language switch instruction.
  • the server can analyze the dynamic copy language switching instruction and obtain the information required to switch the language of the dynamic copy, which may include the language to be switched by the dynamic copy.
  • the language to be switched may be determined according to the official language of the region where the terminal is located, or may be determined according to the usage habits of the user corresponding to the terminal.
  • the server may obtain the language used by the terminal system according to the dynamic copy language language switching instruction, and then use the language used by the terminal system as the language to be switched by the terminal application dynamic copy.
  • the language of the current dynamic copywriting of the terminal application may also be obtained.
  • the dynamic copywriting language switching instruction may further include the version information of the terminal application. The version information determines the language of the current dynamic copy of the terminal application.
  • Step S20 The server acquires a language pack corresponding to the language to be switched from a preset memory according to the language to be switched;
  • the preset storage of the server may be a local storage, the server may also be composed of a distributed system, and the preset storage is set on another system server.
  • Language packs for multiple languages can be stored in the preset memory in advance. When the language to be switched is determined, the server can find the language pack corresponding to the language to be switched from the preset memory according to the language to be switched.
  • the language to be switched may be identified by a language abbreviation when running at the bottom layer.
  • zh_CN may represent simplified Chinese
  • en_US may represent American English
  • en_GB may represent British English.
  • a mapping relationship table can be set in the preset memory, which is composed of the mapping relationship between the language abbreviation and the storage path of the corresponding language package.
  • the server can use the language to be switched as a keyword to find the storage of the corresponding language package from the mapping relationship table. Path to perform the extraction operation of the corresponding language pack.
  • Step S30 The server returns the language pack to the terminal application for the terminal application to switch the language of the dynamic copywriting by loading the language pack.
  • the server returns the language pack corresponding to the language to be switched to the terminal application, and the terminal application loads the language pack.
  • the actual effect achieved on the terminal application display interface is: the language of the displayed dynamic copy is switched to the language corresponding to the language pack. .
  • the server determines the language of the dynamic copy to be switched according to the dynamic copy language language switching instruction, it returns the corresponding language package to the terminal application, so that the terminal application switches the language of the dynamic copy.
  • This solution does not need to store multiple dynamic copy language packs in the terminal application, which reduces the terminal's memory occupied by the terminal application. Compared with the current dynamic copy display method, it can switch the language of the dynamic copy more intelligently and conveniently. User use.
  • step S30 the method further includes:
  • dynamic copy error reporting information sent by the terminal application, where the dynamic copy error reporting information includes a dynamic copy error message selected by a user on a terminal application display interface and a corresponding character to be replaced;
  • the character string displayed by the language of dynamic copywriting may not be completely correct, and word formation errors and / or grammatical errors may occur.
  • the terminal application can select a dynamic copy that is incorrect in grammar or word formation through the display interface of the terminal.
  • the terminal application can pop up a text box to request the user to enter the character to be replaced.
  • the terminal application sends the dynamic copy error characters and the corresponding characters to be replaced to the server.
  • the server establishes a mapping relationship between the dynamic copy error characters and the corresponding characters to be replaced, and after a preset manual detection terminal detects the mapping relationship, the dynamic copy error characters stored in the language package are reported. Replace with the mapped corresponding character to be replaced.
  • the server After receiving the dynamic copy error message, the server will establish a mapping relationship table between the two, and send the mapping relationship table to the preset manual detection terminal.
  • the detection verification will be performed by the artificial detection agent. If the detection verification is passed, the server will In the language pack of the preset memory, the dynamic copy error character is replaced with a mapped corresponding character to be replaced. Feedback from users for error correction helps the server improve the accuracy of language packs and also gives users more opportunities to participate and optimize terminal applications.
  • the dynamic copywriting The language switching instruction includes the historical position of the terminal when the terminal application last switched the language of the dynamic copy; the step S10 includes:
  • Step S11 The server obtains the current location of the terminal through at least one of base station positioning information, GPS positioning information, and IP address positioning information of the terminal;
  • the positioning information of the terminal can be obtained by the server through the terminal application to obtain the corresponding authority of the terminal.
  • the base station positioning information uses base station positioning technology, also known as mobile location service (LBS-Location Based Service) technology, which obtains the location information of the terminal through the network of the telecommunications operator.
  • GPS Global Positioning System (Global Positioning System) positioning information is generally obtained through the GPS module built into the terminal and software to autonomously measure it. Taking an Android terminal as an example, the GPS positioning information can be obtained through the LocationManager class.
  • IP Internet Protocol (Network Protocol) address positioning information is the country, province, and city where the terminal is located after the IP address is resolved.
  • the current location of the obtained terminal does not need to be very accurate, as long as the official language of the location of the terminal can be determined, so only one of the above three positioning information can be used. Just fine. However, when the combination of at least two positioning information is adopted, it can help improve the accuracy of the positioning information and prevent the user from modifying the positioning information to cause the positioning information to be inaccurate.
  • step S12 the server determines whether the historical position of the terminal in the dynamic copy language language switching instruction is consistent with the current location of the terminal; if not, step S13 is performed;
  • the historical location of the terminal when the terminal application switched the language of the dynamic copy last time refers to the location of the terminal when the terminal application last switched the language of the dynamic copy through the mechanism. By comparing the historical location with the current location of the terminal, it can be determined whether the location of the terminal has been switched. It should be noted that during the comparison between the historical location and the current location, the accuracy of the location can be accurate to the region (such as Hong Kong) or country where it is located, as long as the official language can be determined.
  • the operation may be stopped, and the dynamic copy language is not switched according to the current dynamic copy language switching instruction.
  • step S13 the server determines an official language corresponding to the current location of the terminal according to the current location of the terminal, and uses the official language as the language to be switched in the dynamic copy.
  • the official language is the language or languages that are most widely used or used by each country or region. For example, the official language of the United Kingdom is English, and the official language of France is French. If the current location of the terminal is in the United Kingdom, English is used as the language for dynamic copywriting. When the historical location is inconsistent with the current location, the solution determines the language to be switched by the terminal application based on the geographic location of the terminal, which does not require the user to manually set and use, and also makes the switching of dynamic copy more intelligent and convenient.
  • the dynamic copywriting The language switching instruction includes language configuration information of other applications of the terminal; the step S10 includes:
  • Step S14 the server acquires language configuration information of other applications of the terminal from the dynamic copy language language switching instruction
  • the terminal application dynamic copy language switching setting can be performed.
  • the method for obtaining the language habits set by the user when using other applications may be to obtain the language configuration information of other applications from the dynamic copy language language switching instruction.
  • the language configuration information is used to record the locale set by the user in other applications. It can be stored in In other application's configuration files.
  • each application can be classified according to functions. After classification, each application has its own functional attributes, including living and entertainment attributes, office learning attributes, image processing attributes, and software maintenance attributes.
  • the application attributes of the terminal application can be obtained.
  • the application attributes of other applications of the terminal are acquired through the dynamic copy language language switching instruction, and the appropriate language configuration information of other applications is selected by matching the application attributes of the terminal application and other applications.
  • the application attributes corresponding to each other application can be obtained through a dynamic copy language language switching instruction, and the terminal application can be found from each other application according to the application attributes of the terminal application.
  • This solution matches other applications with consistent application attributes for the terminal application and obtains the language configuration information of the other consistent applications to help users enjoy services that are closer to the user ’s own habits when using the terminal application in work, study, or life. , Enhanced the intelligent and humanized display of terminal application dynamic copy language display.
  • the application includes two attributes of office study and living entertainment for example.
  • the step S14 may include:
  • the server acquires the language configuration information of the application attribute in a plurality of other applications as the office learning attribute;
  • the server obtains the language configuration information of the application attribute in a plurality of other applications as a life entertainment attribute.
  • step S15 the server determines a language used by the other application according to the language configuration information of the other application, and uses the language used by the other application as a language to be switched by the terminal application dynamic copywriting.
  • the server After the server obtains the language configuration information of the other application, it can determine the language used by the other application.
  • the language used by the other application can be the language displayed by the other application as a whole or the language of the dynamic copy of the other application.
  • the language used by other applications is the language to be switched by the terminal application's dynamic copywriting. This solution is conducive to flexibly switching the language of dynamic copywriting according to the usage habits of end users, and is intelligent and user-friendly.
  • the technical solution of determining the languages to be switched by positioning information and application attributes of other applications may be executed simultaneously, or a user may set a priority, and determine the languages to be switched according to the priority order.
  • another corresponding solution may be selected to determine the language to be switched.
  • a fourth embodiment of the language switching method of the dynamic copywriting applied by the terminal of the present application is proposed.
  • Step S21 the server obtains a service node where the terminal application is currently located
  • a service node is a stage in which a user performs operations through a terminal application, for example, to handle a service through a terminal application, which may include an account application phase, a face recognition phase, a business application phase, and a business review phase. After dividing the interval, each business node has its own dynamic copy.
  • step S22 the server finds the language to be switched from the preset memory according to the language to be switched and the service node, and the terminal applies a language pack corresponding to the service node where the terminal is currently located. .
  • the preset memory can also store the language pack of each business node corresponding to each language.
  • the language to be switched and the business node can be directly used as keywords to obtain the corresponding language from the preset memory. package.
  • the language to be switched is Traditional Chinese
  • the business node is the account application node.
  • the method may further include steps:
  • the terminal application corresponds to a language pack corresponding to a service node where the current application is located;
  • the server selects a language of a dynamic copy, and obtains a dynamic copy of the language of the dynamic copy corresponding to a service node where the terminal application is currently located; the server copies the dynamic copy according to the type The preset word-forming rules of the language of the dynamic copywriting process word segmentation to obtain a plurality of reference language blocks; the server uses the plurality of reference language blocks as keywords and searches the preset memory for each reference language block corresponding to Language block to be switched; the server stitches all language blocks according to the preset word formation rules of the language to be switched to obtain the language to be switched, corresponding to the service node where the terminal application is currently located Language pack
  • the server executes searching for the language to be switched from the preset memory according to the language to be switched and the service node, and the language corresponding to the service node where the terminal application is currently located Package steps.
  • this solution uses a randomly selected language as a reference language, and when the terminal application is in a certain service node, all dynamic copy of the basic language of the service node can be obtained , And then processed by NLP with the default word formation rules of the base language (Natural Language Processing (Natural Language Processing) word segmentation of all dynamic copywriting to obtain the base language block. Then, according to the reference language block, the language block to be switched corresponding to the language to be switched is found in the preset memory, the semantics are understood through NLP processing, and all the language blocks to be switched are combined in combination with the preset word formation rules to form the current business node corresponding Required language pack.
  • NLP Natural Language Processing
  • this solution mainly emphasizes the formation of language packs through word segmentation. How NLP processing technology performs word segmentation understanding semantics and joint preset word formation rules for word segmentation can be set by those skilled in the art with reference to the existing technology I won't go into details here.
  • a language pack is generated by finding a corresponding language block to be switched by randomly selecting a reference language, which solves the problem that the corresponding language pack cannot be found and the language switching of dynamic copywriting cannot be performed. problem.
  • this application further provides a server, including:
  • An obtaining module 10 configured to receive a dynamic copy language language switching instruction issued by the terminal application, and obtain the language to be switched by the dynamic copy language according to the dynamic copy language language switching instruction;
  • the obtaining module 10 is further configured to obtain a language pack corresponding to the language to be switched from a preset memory according to the language to be switched;
  • a return module 20 is configured to return the language pack to the terminal application, so that the terminal application switches the language of the dynamic copy by loading the language pack.
  • the dynamic copywriting language switching instruction includes a historical position of the terminal when the terminal application previously switched the language of the dynamic copywriting;
  • the acquisition module includes:
  • An obtaining unit configured to obtain the current location of the terminal through at least one of base station positioning information, global positioning system GPS positioning information, and network protocol IP address positioning information of the terminal;
  • a judging unit configured to judge whether the historical position of the terminal in the dynamic copy language language switching instruction is consistent with the current position of the terminal
  • a determining unit configured to determine an official language corresponding to the current position of the terminal according to the current position of the terminal when the historical position of the terminal is inconsistent with the current position of the terminal, and Language is the language to be switched in the dynamic copywriting.
  • the dynamic copywriting language switching instruction includes language configuration information of other applications of the terminal;
  • the acquisition module includes:
  • An obtaining unit configured to obtain language configuration information of other applications of the terminal from the dynamic copy language language switching instruction
  • a determining unit configured to determine a language used by the other application according to the language configuration information of the other application, and use the language used by the other application as a language to be switched by the terminal application dynamic copywriting.
  • the dynamic copy language language switching instruction further includes a plurality of application attributes of the other applications; the acquiring unit is further configured to acquire the application attributes of the terminal application and retrieve the application attributes from the dynamic The copy language switching instruction obtains the application attributes of multiple other applications of the terminal, wherein the application attributes of the multiple other applications include office learning attributes and living entertainment attributes; and when the application attributes of the terminal application are office learning attributes When acquiring the language configuration information of the application attribute in a plurality of other applications as an office learning attribute; when the application attribute of the terminal application is a living and entertainment attribute, acquiring the language configuration information in which the application attribute is a living and entertainment attribute in a plurality of other applications.
  • the acquisition module further includes a search unit; wherein,
  • the obtaining unit is further configured to obtain a service node where the terminal application is currently located;
  • the searching unit is configured to find the language to be switched from the preset memory according to the language to be switched and the service node, and the language corresponding to the service node where the terminal application is currently located package.
  • the obtaining module includes:
  • the determining unit is further configured to determine whether the language to be switched is included in the preset memory, and the terminal application corresponds to a language pack corresponding to a service node where the terminal is currently located; if so, triggering the searching unit to perform the determination Whether the language to be switched is included in the preset memory, the language pack corresponding to the service node where the terminal application is currently located;
  • a selecting unit configured to select a language for dynamic copywriting when the preset memory does not include the language to be switched, and the terminal applies a language pack corresponding to a service node where the terminal is currently located, and obtain the terminal Apply the dynamic copy of the language of this dynamic copy corresponding to the current business node;
  • the word segmentation unit is configured to perform word segmentation processing on the dynamic copywriting according to a preset word formation rule of the language of the dynamic copywriting to obtain multiple reference language blocks;
  • the searching unit is further configured to use the plurality of reference language blocks as keywords to find a language block to be switched corresponding to each reference language block from the preset memory;
  • a splicing unit is configured to splice all language blocks according to a preset word-forming rule of the language to be switched, to obtain the language to be switched, and the terminal applies a language pack corresponding to a service node where the terminal is currently located.
  • the server further includes a establishing module and a replacing module, wherein:
  • the obtaining module is further configured to obtain dynamic copy error reporting information sent by the terminal application, where the dynamic copy error reporting information includes a dynamic copy error reporting character selected by a user on a terminal application display interface and a corresponding character to be replaced that is input;
  • the establishing module is configured to establish a mapping relationship between the dynamic copywriting error character and the corresponding character to be replaced, and after a preset manual detection terminal passes the mapping relationship detection, trigger the replacing module to replace the
  • the dynamic copywriting error characters stored in the language pack are replaced with the mapped corresponding characters to be replaced.
  • the present application also proposes a computer-readable storage medium on which a computer program is stored.
  • the computer-readable storage medium may be the memory 20 in the server in FIG. 1, or may be a ROM (Read-Only Memory (Read Only Memory) / RAM (Random Access Memory (Random Access Memory), magnetic disks, and optical disks.
  • the computer-readable storage medium includes several instructions to enable a terminal device (such as a mobile phone, a computer, a server, and a server) with a processor. Or a network device, etc.) perform the methods described in the embodiments of the present application.

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

本申请公开了一种终端应用动态文案的语言切换方法、服务器及存储介质,方法包括:服务器接收所述终端应用发出的动态文案语言切换指令,并根据所述动态文案语言切换指令获取所述动态文案待切换的语言;所述服务器根据所述待切换的语言,从预设存储器中获取所述待切换的语言对应的语言包;所述服务器返回所述语言包至所述终端应用,以供所述终端应用通过加载所述语言包切换所述动态文案的语言。

Description

终端应用动态文案的语言切换方法、服务器及存储介质
本申请要求于2018年09月26日提交中国专利局、申请号为201811122739.4、发明名称为“终端应用动态文案的语言切换方法、服务器及存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及通信领域,尤其涉及一种终端应用动态文案的语言切换方法、服务器及计算机可读存储介质。
背景技术
随着终端应用程序的普及,越来越多的终端应用走出国门开始了国际化进程。但目前在终端应用的使用过程中,终端应用显示的动态提示文案对应的语言,往往是根据用户当前下载的终端应用版本决定的,例如用户下载的是中文版的终端应用,则终端应用的动态文案即是中文版;如果用户下载的是英文版的终端应用,则终端应用的动态文案即是英文版。如果用户版本下载错误,则无法适应动态文案的显示,因此终端应用动态文案的显示不够智能。
申请内容
本申请的主要目的在于提供一种终端应用动态文案的语言切换方法、服务器及计算机可读存储介质,旨在解决终端应用动态文案的显示不够智能的问题。
为实现上述目的,本申请提供一种终端应用动态文案的语言切换方法,包括步骤:
服务器接收所述终端应用发出的动态文案语言切换指令,并根据所述动态文案语言切换指令获取所述动态文案待切换的语言;
所述服务器根据所述待切换的语言,从预设存储器中获取所述待切换的语言对应的语言包;
所述服务器返回所述语言包至所述终端应用,以供所述终端应用通过加载所述语言包切换所述动态文案的语言。
为实现上述目的,本申请还提供一种服务器,包括:
获取模块,用于接收所述终端应用发出的动态文案语言切换指令,并根据所述动态文案语言切换指令获取所述动态文案待切换的语言;
所述获取模块,还用于根据所述待切换的语言,从预设存储器中获取所述待切换的语言对应的语言包;
返回模块,用于返回所述语言包至所述终端应用,以供所述终端应用通过加载所述语言包切换所述动态文案的语言。
为实现上述目的,本申请还提供一种服务器,所述服务器包括:通信模块、存储器、处理器及存储在所述存储器上并可在所述处理器上运行的计算机程序,所述计算机程序被所述处理器执行时实现如上所述的终端应用动态文案的语言切换方法的步骤。
为实现上述目的,本申请还提供一种计算机可读存储介质,所述计算机可读存储介质上存储有计算机程序,所述计算机程序被处理器执行时实现如上所述的终端应用动态文案的语言切换方法的步骤。
本申请通过服务器接收所述终端应用发出的动态文案语言切换指令,并根据所述动态文案语言切换指令获取所述动态文案待切换的语言;所述服务器根据所述待切换的语言,从预设存储器中获取所述待切换的语言对应的语言包;所述服务器返回所述语言包至所述终端应用,以供所述终端应用通过加载所述语言包切换所述动态文案的语言。从而根据服务器返回的语言包自由切换终端应用动态文案的语言,不需要重新下载终端应用,动态文案的语言切换十分智能灵活。
附图说明
图1是本申请实施例方案涉及的服务器的结构示意图;
图2为本申请终端应用动态文案的语言切换方法第一实施例的流程示意图;
图3为本申请终端应用动态文案的语言切换方法第二实施例中步骤S10的细化流程示意图;
图4为本申请终端应用动态文案的语言切换方法第三实施例中步骤S10的细化流程示意图;
图5为本申请终端应用动态文案的语言切换方法第四实施例中步骤S20的细化流程示意图;
图6为本申请服务器一功能模块示意图。
本申请目的的实现、功能特点及优点将结合实施例,参照附图做进一步说明。
具体实施方式
应当理解,此处所描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。
请参看图1,图1为本申请所提供的服务器的硬件结构示意图。所述服务器包括通信模块10、存储器20以及处理器30等部件。在所述服务器中,所述处理器30分别与所述存储器20以及所述通信模块10连接,所述存储器20上存储有计算机程序,所述计算机程序同时被处理器30执行。
通信模块10,可通过网络与外部通讯设备连接。通信模块10可以接收外部通讯设备发出的请求,还可以发送请求、指令及信息至所述外部通讯设备。所述外部通讯设备可以是其他服务器和/或用户使用的终端,所述终端可以是计算机、平板电脑以及手机等,所述终端上安装应用程序,该应用程序显示界面上显示有动态文案。
存储器20,可用于存储软件程序以及各种数据。存储器20可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序(比如确定终端应用待切换的语言)等;存储数据区可包括数据库,存储数据区可存储根据服务器的使用所创建的数据或信息等。此外,存储器20可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。
处理器30,是服务器的控制中心,利用各种接口和线路连接整个服务器的各个部分,通过运行或执行存储在存储器20内的软件程序和/或模块,以及调用存储在存储器20内的数据,执行服务器的各种功能和处理数据,从而对服务器进行整体监控。处理器30可包括一个或多个处理单元;可选地,处理器30可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作系统、用户界面和应用程序等,调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器30中。
尽管图1未示出,但上述服务器还可以包括电路控制模块,用于与电源连接,保证其他部件的正常工作。本领域技术人员可以理解,图1中示出的服务器结构并不构成对服务器的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。
基于上述硬件结构,提出本申请方法各个实施例。
参见图2,在本申请终端应用动态文案的语言切换方法的第一实施例中,包括:
步骤S10,服务器接收所述终端应用发出的动态文案语言切换指令,并根据所述动态文案语言切换指令获取所述动态文案待切换的语言;
其中,动态文案是指终端应用在使用过程中终端应用显示的提示性语言,例如提示用户在显示界面上输入用户名和密码,或者提示输入的密码仅支持字母大小写和数字混合。在本实施例中,终端应用的动态文案均由服务器反馈给终端。
终端应用可以接收用户在应用显示界面执行的触发操作,以根据触发操作以及切换动态文案的语言所需要的信息,生成动态文案语言切换指令,或者,也可以由终端应用定期自主生成动态文案语言切换指令。服务器接收终端应用发出的动态文案语言切换指令后,可以对动态文案语言切换指令进行解析,获取切换动态文案的语言所需要的信息,其中可以包括动态文案待切换的语言。
待切换的语言可以根据终端所处区域的官方语言确定,也可以根据终端对应用户的使用习惯进行确定。例如,服务器可以根据动态文案语言切换指令获取终端系统所使用的语言,然后将终端系统所使用的语言作为终端应用动态文案待切换的语言。
在通过动态文案语言切换指令获取动态文案待切换的语言时,还可以获取所述终端应用当前动态文案的语言,例如,动态文案语言切换指令中还可以包括终端应用的版本信息,根据终端应用的版本信息确定终端应用的当前动态文案的语言。
步骤S20,所述服务器根据所述待切换的语言,从预设存储器中获取所述待切换的语言对应的语言包;
服务器的预设存储器可以为本地存储器,所述服务器也可以由分布式系统组成,预设存储器设置在其他系统服务器上。预设存储器中可以预先存储有多种语言的语言包,当确定好待切换的语言后,服务器可以根据待切换的语言从预设存储器中查找出待切换语言对应的语言包。
可选地,待切换的语言在底层运行时可以以语言缩写进行标识,例如zh_CN可以表示简体中文,en_US可以表示美式英语,en_GB可以表示英式英语。相对应地,预设存储器中可以设置映射关系表,由语言缩写与对应语言包的存储路径的映射关系构成,服务器可以以待切换语言为关键词,从映射关系表查找出对应语言包的存储路径,进而执行对应语言包的提取操作。
步骤S30,所述服务器返回所述语言包至所述终端应用,以供所述终端应用通过加载所述语言包切换所述动态文案的语言。
服务器将查找到的待切换的语言对应的语言包返回给终端应用,由终端应用加载该语言包,在终端应用显示界面实际达到的效果是:显示的动态文案的语言切换为语言包对应的语言。
本方案由服务器根据动态文案语言切换指令确定动态文案待切换的语言后,返回对应的语言包给终端应用,使终端应用切换动态文案的语言。本方案无需在终端应用中存储多种动态文案的语言包,减轻了终端应用所占终端的内存;且相较于目前的动态文案显示方法,能够更为智能灵活地切换动态文案的语言,方便用户使用。
进一步地,在其他实施例中,所述步骤S30之后,还包括:
所述服务器获取所述终端应用发送的动态文案报错信息,其中所述动态文案报错信息包括用户在终端应用显示界面选择的动态文案报错字符以及输入的对应待替换字符;
需要说明的是,动态文案的语言显示出的字符串不一定完全正确,可能出现构词错误和/或语法错误。当用户在使用过程中查看到了显示错误的动态文案,可以通过终端应用的显示界面选择语法或构词错误的动态文案报错字符,此时终端应用可以弹出文本框请求用户输入待替换的字符。当输入完成且提交给终端应用后,终端应用会将动态文案报错字符以及对应待替换字符发送给服务器。
所述服务器建立所述动态文案报错字符与所述对应待替换字符间的映射关系,并在预设人工检测终端对所述映射关系检测通过后,将所述语言包中存储的动态文案报错字符替换为映射的对应待替换字符。
服务器收到动态文案报错字符后,会建立两者之间的映射关系表,并将映射关系表发送给预设人工检测终端,通过人工检测坐席进行检测验证,如果检测验证通过,再由服务器将预设存储器的语言包中该动态文案报错字符替换成映射的对应待替换字符。通过用户进行纠错反馈,帮助服务器提高了语言包的准确度,也给用户更多参与和优化终端应用的机会。
进一步地,参见图3,基于本申请终端应用动态文案的语言切换方法的第一实施例提出本申请终端应用动态文案的语言切换方法的第二实施例,在本实施例中,所述动态文案语言切换指令包括所述终端应用前次切换所述动态文案的语言时所述终端的历史位置;所述步骤S10包括:
步骤S11,所述服务器通过所述终端的基站定位信息、GPS定位信息以及IP地址定位信息中的至少一个获取所述终端当前所处位置;
终端的定位信息可以由服务器通过终端应用获取终端的相应权限取得。其中基站定位信息使用的是基站定位技术,又称为移动位置服务(LBS-Location Based Service)技术,其是通过电信运营商的网络获取终端的位置信息。GPS(Global Positioning System,全球定位系统)定位信息一般是通过终端内置的GPS模块结合软件自主测量得到的,以安卓终端为例,GPS定位信息的获取可以通过LocationManager类进行获取。IP(Internet Protocol,网络协议)地址定位信息是将IP地址解析后得到的终端所在国家、省份以及城市。
需要说明的是,在本实施例中,获得的终端当前所处位置不需要十分准确,只要能够确定终端所处位置的官方语言即可,因此可以仅通过上述三个定位信息中任一定位信息即可。但当采用了至少两个定位信息相结合时,能够帮助提高定位信息的准确度,防止用户因个人需要修改了某个定位信息导致定位信息不准确的情况。
步骤S12,所述服务器判断所述动态文案语言切换指令中的所述终端的历史位置是否与所述终端当前所处位置一致;若否,则执行步骤S13;
所述终端应用前次切换所述动态文案的语言时所述终端的历史位置是指终端应用最新一次通过该机制切换动态文案的语言时,所述终端所处的位置。通过将历史位置与终端当前所处的位置进行比较,能确定终端的位置是否有切换。需要说明的是,在该历史位置与当前所处位置的比较过程中,位置的精确度均可以精确到所处的地区(例如香港)或国家,只要能确定官方语言即可。当所述终端的历史位置与终端当前所处的位置一致时,可以停止操作,不根据此次动态文案语言切换指令实现动态文案语言的切换。
步骤S13,所述服务器根据所述终端当前所处位置,确定所述终端当前所处位置对应的官方语言,并将所述官方语言作为所述动态文案待切换的语言。
官方语言是每个国家或地区使用范围最广或使用人数最多的一种或几种语言。例如,英国的官方语言为英语,法国的官方语言为法语。如果当前终端所处的位置是在英国,则将英语作为动态文案待切换的语言。本方案在历史位置与当前所处的位置不一致时,通过终端的地理位置确定终端应用待切换的语言,不需要用户手动设置使用方便,也使得动态文案的切换更为智能便捷。
进一步地,参见图4,基于本申请终端应用动态文案的语言切换方法的第一实施例提出本申请终端应用动态文案的语言切换方法的第三实施例,在本实施例中,所述动态文案语言切换指令包括所述终端其他应用的语言配置信息;所述步骤S10包括:
步骤S14,所述服务器从所述动态文案语言切换指令中获取所述终端其他应用的语言配置信息;
终端除了安装有需要切换动态文案语言的该应用,还会安装有其他应用。因此可以根据用户使用其他应用时设置的语言习惯,进行该终端应用动态文案语言的切换设置。其中,获取用户使用其他应用时设置的语言习惯的方法可以是从动态文案语言切换指令中获取其他应用的语言配置信息,该语言配置信息用于记录其他应用中用户设置的语言环境,可以存储在其他应用的配置文件中。
可以理解的是,应用程序可以按照功能进行分类,分类后每个应用程序都具有各自的功能属性,包括生活娱乐属性、办公学习属性、图像处理属性以及软件维护属性等等。可以在获取终端其他应用的语言配置信息之前,获取终端应用的应用属性。在执行步骤S14的过程中,通过动态文案语言切换指令获取终端其他应用的应用属性,通过匹配终端应用和其他应用的应用属性,选择合适的其他应用的语言配置信息。
可选地,当终端存在多个其他应用时,则可以通过动态文案语言切换指令获取每个其他应用分别对应的应用属性,可以按照终端应用的应用属性,从各其他应用中查找到与终端应用的应用属性一致的其他应用,并获取该应用属性一致的其他应用的语言配置信息。进一步地,如果应用属性一致的其他应用存在多个,可以按照应用属性的使用频率进行选择,选择使用频率最高的其他应用,然后获取其语言配置信息。本方案通过为终端应用匹配到应用属性一致的其他应用,并获取该一致的其他应用的语言配置信息,帮助用户在工作学习或者生活中使用该终端应用时,更为享受贴近用户本身习惯的服务,增强了终端应用动态文案语言显示的智能型和人性化。
在此,以应用程序包括办公学习和生活娱乐两种属性进行举例说明。当在所述步骤S14之前执行了所述服务器获取所述终端应用的应用属性的步骤时,所述步骤S14可以包括:
所述服务器从所述动态文案语言切换指令中获取所述终端多个其他应用的应用属性,其中,所述多个其他应用的应用属性包括办公学习属性以及生活娱乐属性;
当所述终端应用的应用属性为办公学习属性时,所述服务器获取多个其他应用中应用属性为办公学习属性的语言配置信息;
当所述终端应用的应用属性为生活娱乐属性时,所述服务器获取多个其他应用中应用属性为生活娱乐属性的语言配置信息。
步骤S15,所述服务器根据所述其他应用的语言配置信息,确定所述其他应用所使用的语言,并将所述其他应用所使用的语言作为所述终端应用动态文案待切换的语言。
在服务器获取了其他应用的语言配置信息后,可以确定其他应用使用的语言,该其他应用所使用的语言可以是其他应用整体显示的语言,也可以仅是其他应用的动态文案的语言,然后将其他应用使用的语言作为终端应用动态文案待切换的语言。本方案有利于根据终端用户的使用习惯灵活切换动态文案的语言,智能且人性化。
需要说明的是,通过定位信息和其他应用的应用属性确定待切换语言的技术方案可以同时执行,也可以由用户设置优先级,根据优先级的先后进行待切换语言的确定。此外,在定位信息或其他应用的应用属性无法获取到时,也可以选择相对应的另外一种方案进确定待切换的语言。
进一步地,参见图5,基于本申请终端应用动态文案的语言切换方法的第一实施例提出本申请终端应用动态文案的语言切换方法的第四实施例,在本实施例中,所述步骤S20包括:
步骤S21,所述服务器获取所述终端应用当前所处的业务节点;
本实施例相比第一实施例的技术方案,其区别在于:将终端应用所需的动态文案按照业务节点划分了区间。业务节点是用户通过终端应用执行操作过程中所处的阶段,例如通过终端应用办理业务,可以包括账号申请阶段,人脸识别阶段,业务申请阶段以及业务审核阶段等等。划分区间后,每个业务节点都对应有各自的动态文案。
步骤S22,所述服务器根据所述待切换的语言以及所述业务节点,从所述预设存储器中查找出所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包。
预设存储器中也可以存储有每种语言对应的各业务节点的语言包,在执行查找语言包操作时可以直接以待切换的语言以及业务节点为关键词,从预设存储器中获取对应的语言包。例如待切换的语言为繁体中文,业务节点为账户申请节点,此时账户申请节点中语言为繁体中文的动态文案一共有两个,分别为“請輸入帳號和密碼”以及“帳號和密碼僅支持字母大小寫混合”,可以将这两个动态文案打包成语言包,在服务器的处理器通过待切换的语言为“繁体中文”,以及业务节点为“账号申请节点”查询预设存储器时,由预设存储器返回打包后的语言包给处理器,以使处理器将存储器返回给终端应用。本方案通过将每种语言的动态文案分成每个业务节点对应的动态文案,然后在到达该业务节点时再推送给终端应用,减少了对终端内存的占用。
进一步地,所述步骤S22之前还可以包括步骤:
所述服务器判断所述预设存储器中是否包括所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
若否,则所述服务器选择一种动态文案的语言,并获取所述终端应用当前所处的业务节点对应的,该种动态文案的语言的动态文案;所述服务器将该动态文案按照该种动态文案的语言的预设构词规则进行分词处理,得到多个基准语言块;所述服务器以所述多个基准语言块为关键词,从所述预设存储器中查找每个基准语言块对应的待切换的语言块;所述服务器根据所述待切换的语言的预设构词规则对所有语言块进行拼接,得到所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
若是,则所述服务器执行根据所述待切换的语言以及所述业务节点,从所述预设存储器中查找出所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包的步骤。
本方案是当预设存储器中不包括需要的语言包时,通过将随机选择的某种语言作为基准语言,当终端应用处于某个业务节点时,可以获取该业务节点的基础语言的所有动态文案,然后以基准语言的预设构词规则通过NLP处理(Natural Language Processing,自然语言处理)对所有动态文案进行分词,得到基准语言块。然后再根据基准语言块找到预设存储器中对应待切换语言的待切换语言块,通过NLP处理理解语义,再联合预设构词规则将找到的所有待切换语言块组合,形成当前业务节点对应所需的语言包。需要说明的是,本方案主要强调的是通过分词组合形成语言包,对于NLP处理技术如何进行分词理解语义以及联合预设构词规则进行分词均是本领域技术人员参考现有技术可以进行设置的,在此不做赘述。本方案在预设存储器中不包括该种语言包时,通过随机选取的基准语言找到对应的待切换语言块组合生成语言包,解决了找不到对应语言包,无法进行动态文案的语言切换的问题。
参见图6,本申请还提出一种服务器,包括:
获取模块10,用于接收所述终端应用发出的动态文案语言切换指令,并根据所述动态文案语言切换指令获取所述动态文案待切换的语言;
所述获取模块10,还用于根据所述待切换的语言,从预设存储器中获取所述待切换的语言对应的语言包;
返回模块20,用于返回所述语言包至所述终端应用,以供所述终端应用通过加载所述语言包切换所述动态文案的语言。
进一步地,在另一实施例中,所述动态文案语言切换指令包括所述终端应用前次切换所述动态文案的语言时所述终端的历史位置;
所述获取模块包括:
获取单元,用于通过所述终端的基站定位信息、全球定位系统GPS定位信息以及网络协议IP地址定位信息中的至少一个获取所述终端当前所处位置;
判断单元,用于判断所述动态文案语言切换指令中的所述终端的历史位置是否与所述终端当前所处位置一致;
确定单元,用于当所述终端的历史位置与所述终端当前所处位置不一致时,根据所述终端当前所处位置,确定所述终端当前所处位置对应的官方语言,并将所述官方语言作为所述动态文案待切换的语言。
进一步地,在又一实施例中,所述动态文案语言切换指令包括所述终端其他应用的语言配置信息;所述获取模块包括:
获取单元,用于从所述动态文案语言切换指令中获取所述终端其他应用的语言配置信息;
确定单元,用于根据所述其他应用的语言配置信息,确定所述其他应用所使用的语言,并将所述其他应用所使用的语言作为所述终端应用动态文案待切换的语言。
进一步地,在又一实施例中,所述动态文案语言切换指令还包括多个所述其他应用的应用属性;所述获取单元,还用于获取所述终端应用的应用属性以及从所述动态文案语言切换指令中获取所述终端多个其他应用的应用属性,其中,所述多个其他应用的应用属性包括办公学习属性以及生活娱乐属性;并当所述终端应用的应用属性为办公学习属性时,获取多个其他应用中应用属性为办公学习属性的语言配置信息;当所述终端应用的应用属性为生活娱乐属性时,获取多个其他应用中应用属性为生活娱乐属性的语言配置信息。
进一步地,在又一实施例中,所述获取模块还包括查找单元;其中,
所述获取单元,还用于获取所述终端应用当前所处的业务节点;
所述查找单元,用于根据所述待切换的语言以及所述业务节点,从所述预设存储器中查找出所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包。
进一步地,在又一实施例中,所述获取模块包括:
所述判断单元,还用于判断所述预设存储器中是否包括所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;若是,则触发所述查找单元执行判断所述预设存储器中是否包括所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
选择单元,用于当所述预设存储器不包括所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包时,选择一种动态文案的语言,并获取所述终端应用当前所处的业务节点对应的,该种动态文案的语言的动态文案;
分词单元,用于将该动态文案按照该种动态文案的语言的预设构词规则进行分词处理,得到多个基准语言块;
所述查找单元,还用于以所述多个基准语言块为关键词,从所述预设存储器中查找每个基准语言块对应的待切换的语言块;
拼接单元,用于根据所述待切换的语言的预设构词规则对所有语言块进行拼接,得到所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包。
进一步地,在又一实施例中,所述服务器还包括建立模块以及替换模块,其中,
所述获取模块,还用于获取所述终端应用发送的动态文案报错信息,其中所述动态文案报错信息包括用户在终端应用显示界面选择的动态文案报错字符以及输入的对应待替换字符;
所述建立模块,用于建立所述动态文案报错字符与所述对应待替换字符间的映射关系,并在预设人工检测终端对所述映射关系检测通过后,触发所述替换模块将所述语言包中存储的动态文案报错字符替换为映射的对应待替换字符。
本申请还提出一种计算机可读存储介质,其上存储有计算机程序。所述计算机可读存储介质可以是图1的服务器中的存储器20,也可以是如ROM(Read-Only Memory,只读存储器)/RAM(Random Access Memory,随机存取存储器)、磁碟、光盘中的至少一种,所述计算机可读存储介质包括若干指令用以使得一台具有处理器的终端设备(可以是手机,计算机,服务器,服务器,或者网络设备等)执行本申请各个实施例所述的方法。
需要说明的是,在本文中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者服务端不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者服务端所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、方法、物品或者服务端中还存在另外的相同要素。
上述本申请实施例序号仅仅为了描述,不代表实施例的优劣。
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。
以上仅为本申请的可选实施例,并非因此限制本申请的专利范围,凡是利用本申请说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本申请的专利保护范围内。

Claims (20)

  1. 一种终端应用动态文案的语言切换方法,其中,包括步骤:
    服务器接收所述终端应用发出的动态文案语言切换指令,并根据所述动态文案语言切换指令获取所述动态文案待切换的语言;
    所述服务器根据所述待切换的语言,从预设存储器中获取所述待切换的语言对应的语言包;
    所述服务器返回所述语言包至所述终端应用,以供所述终端应用通过加载所述语言包切换所述动态文案的语言。
  2. 根据权利要求1所述的终端应用动态文案的语言切换方法,其中,所述动态文案语言切换指令包括所述终端应用前次切换所述动态文案的语言时所述终端的历史位置;所述根据所述动态文案语言切换指令获取所述动态文案待切换的语言的步骤包括:
    所述服务器通过所述终端的基站定位信息、全球定位系统GPS定位信息以及网络协议IP地址定位信息中的至少一个获取所述终端当前所处位置;
    所述服务器判断所述动态文案语言切换指令中的所述终端的历史位置是否与所述终端当前所处位置一致;
    当所述终端的历史位置与所述终端当前所处位置不一致时,所述服务器根据所述终端当前所处位置,确定所述终端当前所处位置对应的官方语言,并将所述官方语言作为所述动态文案待切换的语言。
  3. 根据权利要求2所述的终端应用动态文案的语言切换方法,其中,所述服务器根据所述待切换的语言,从预设存储器中获取所述待切换的语言对应的语言包的步骤包括:
    所述服务器获取所述终端应用当前所处的业务节点;
    所述服务器判断所述预设存储器中是否包括所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
    若否,则所述服务器选择一种动态文案的语言,并获取所述终端应用当前所处的业务节点对应的,该种动态文案的语言的动态文案;
    所述服务器将该动态文案按照该种动态文案的语言的预设构词规则进行分词处理,得到多个基准语言块;
    所述服务器以所述多个基准语言块为关键词,从所述预设存储器中查找每个基准语言块对应的待切换的语言块;
    所述服务器根据所述待切换的语言的预设构词规则对所有语言块进行拼接,得到所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
    若是,则所述服务器根据所述待切换的语言以及所述业务节点,从所述预设存储器中查找出所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包。
  4. 根据权利要求1所述的终端应用动态文案的语言切换方法,其中,所述动态文案语言切换指令包括所述终端其他应用的语言配置信息;
    所述根据所述动态文案语言切换指令获取所述动态文案待切换的语言的步骤包括:
    所述服务器从所述动态文案语言切换指令中获取所述终端其他应用的语言配置信息;
    所述服务器根据所述其他应用的语言配置信息,确定所述其他应用所使用的语言,并将所述其他应用所使用的语言作为所述终端应用动态文案待切换的语言。
  5. 根据权利要求4所述的终端应用动态文案的语言切换方法,其中,所述动态文案语言切换指令还包括多个所述其他应用的应用属性;
    所述服务器从所述动态文案语言切换指令中获取所述终端其他应用的语言配置信息的步骤之前,还包括:
    所述服务器获取所述终端应用的应用属性;
    所述服务器从所述动态文案语言切换指令中获取所述终端其他应用的语言配置信息的步骤包括:
    所述服务器从所述动态文案语言切换指令中获取所述终端多个其他应用的应用属性,其中,所述多个其他应用的应用属性包括办公学习属性以及生活娱乐属性;
    当所述终端应用的应用属性为办公学习属性时,所述服务器获取多个其他应用中应用属性为办公学习属性的语言配置信息;
    当所述终端应用的应用属性为生活娱乐属性时,所述服务器获取多个其他应用中应用属性为生活娱乐属性的语言配置信息。
  6. 根据权利要求4所述的终端应用动态文案的语言切换方法,其中,所述服务器根据所述待切换的语言,从预设存储器中获取所述待切换的语言对应的语言包的步骤包括:
    所述服务器获取所述终端应用当前所处的业务节点;
    所述服务器判断所述预设存储器中是否包括所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
    若否,则所述服务器选择一种动态文案的语言,并获取所述终端应用当前所处的业务节点对应的,该种动态文案的语言的动态文案;
    所述服务器将该动态文案按照该种动态文案的语言的预设构词规则进行分词处理,得到多个基准语言块;
    所述服务器以所述多个基准语言块为关键词,从所述预设存储器中查找每个基准语言块对应的待切换的语言块;
    所述服务器根据所述待切换的语言的预设构词规则对所有语言块进行拼接,得到所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
    若是,则所述服务器根据所述待切换的语言以及所述业务节点,从所述预设存储器中查找出所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包。
  7. 根据权利要求1所述的终端应用动态文案的语言切换方法,其中,所述服务器根据所述待切换的语言,从预设存储器中获取所述待切换的语言对应的语言包的步骤包括:
    所述服务器获取所述终端应用当前所处的业务节点;
    所述服务器根据所述待切换的语言以及所述业务节点,从所述预设存储器中查找出所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包。
  8. 根据权利要求7所述的终端应用动态文案的语言切换方法,其中,所述服务器根据所述待切换的语言以及所述业务节点,从所述预设存储器中查找出所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包的步骤之前,还包括:
    所述服务器判断所述预设存储器中是否包括所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
    若否,则所述服务器选择一种动态文案的语言,并获取所述终端应用当前所处的业务节点对应的,该种动态文案的语言的动态文案;
    所述服务器将该动态文案按照该种动态文案的语言的预设构词规则进行分词处理,得到多个基准语言块;
    所述服务器以所述多个基准语言块为关键词,从所述预设存储器中查找每个基准语言块对应的待切换的语言块;
    所述服务器根据所述待切换的语言的预设构词规则对所有语言块进行拼接,得到所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
    若是,则所述服务器执行根据所述待切换的语言以及所述业务节点,从所述预设存储器中查找出所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包的步骤。
  9. 根据权利要求1所述的终端应用动态文案的语言切换方法,其中,所述服务器返回所述语言包至所述终端应用,以供所述终端应用通过加载所述语言包切换所述动态文案的语言的步骤之后,还包括:
    所述服务器获取所述终端应用发送的动态文案报错信息,其中所述动态文案报错信息包括用户在终端应用显示界面选择的动态文案报错字符以及输入的对应待替换字符;
    所述服务器建立所述动态文案报错字符与所述对应待替换字符间的映射关系,并在预设人工检测终端对所述映射关系检测通过后,将所述语言包中存储的动态文案报错字符替换为映射的对应待替换字符。
  10. 一种服务器,其中,包括:
    获取模块,用于接收所述终端应用发出的动态文案语言切换指令,并根据所述动态文案语言切换指令获取所述动态文案待切换的语言;
    所述获取模块,还用于根据所述待切换的语言,从预设存储器中获取所述待切换的语言对应的语言包;
    返回模块,用于返回所述语言包至所述终端应用,以供所述终端应用通过加载所述语言包切换所述动态文案的语言。
  11. 一种服务器,其中,所述服务器包括:通信模块、存储器、处理器及存储在所述存储器上并可在所述处理器上运行的计算机程序,所述计算机程序被所述处理器执行时实现以下步骤:
    服务器接收所述终端应用发出的动态文案语言切换指令,并根据所述动态文案语言切换指令获取所述动态文案待切换的语言;
    所述服务器根据所述待切换的语言,从预设存储器中获取所述待切换的语言对应的语言包;
    所述服务器返回所述语言包至所述终端应用,以供所述终端应用通过加载所述语言包切换所述动态文案的语言。
  12. 根据权利要求11所述的服务器,其中,所述动态文案语言切换指令包括所述终端应用前次切换所述动态文案的语言时所述终端的历史位置;所述计算机程序被所述处理器执行时还实现以下步骤:
    所述服务器通过所述终端的基站定位信息、全球定位系统GPS定位信息以及网络协议IP地址定位信息中的至少一个获取所述终端当前所处位置;
    所述服务器判断所述动态文案语言切换指令中的所述终端的历史位置是否与所述终端当前所处位置一致;
    当所述终端的历史位置与所述终端当前所处位置不一致时,所述服务器根据所述终端当前所处位置,确定所述终端当前所处位置对应的官方语言,并将所述官方语言作为所述动态文案待切换的语言;
    或者,所述动态文案语言切换指令包括所述终端其他应用的语言配置信息;所述计算机程序被所述处理器执行时还实现以下步骤:
    所述服务器从所述动态文案语言切换指令中获取所述终端其他应用的语言配置信息;
    所述服务器根据所述其他应用的语言配置信息,确定所述其他应用所使用的语言,并将所述其他应用所使用的语言作为所述终端应用动态文案待切换的语言。
  13. 根据权利要求12所述的服务器,其中,所述计算机程序被所述处理器执行时还实现以下步骤:
    所述服务器获取所述终端应用当前所处的业务节点;
    所述服务器判断所述预设存储器中是否包括所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
    若否,则所述服务器选择一种动态文案的语言,并获取所述终端应用当前所处的业务节点对应的,该种动态文案的语言的动态文案;
    所述服务器将该动态文案按照该种动态文案的语言的预设构词规则进行分词处理,得到多个基准语言块;
    所述服务器以所述多个基准语言块为关键词,从所述预设存储器中查找每个基准语言块对应的待切换的语言块;
    所述服务器根据所述待切换的语言的预设构词规则对所有语言块进行拼接,得到所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
    若是,则所述服务器根据所述待切换的语言以及所述业务节点,从所述预设存储器中查找出所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包。
  14. 根据权利要求11所述的服务器,其中,所述计算机程序被所述处理器执行时还实现以下步骤:
    所述服务器获取所述终端应用当前所处的业务节点;
    所述服务器判断所述预设存储器中是否包括所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
    若否,则所述服务器选择一种动态文案的语言,并获取所述终端应用当前所处的业务节点对应的,该种动态文案的语言的动态文案;
    所述服务器将该动态文案按照该种动态文案的语言的预设构词规则进行分词处理,得到多个基准语言块;
    所述服务器以所述多个基准语言块为关键词,从所述预设存储器中查找每个基准语言块对应的待切换的语言块;
    所述服务器根据所述待切换的语言的预设构词规则对所有语言块进行拼接,得到所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
    若是,则所述服务器根据所述待切换的语言以及所述业务节点,从所述预设存储器中查找出所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包。
  15. 根据权利要求11所述的服务器,其中,所述计算机程序被所述处理器执行时还实现以下步骤:
    所述服务器获取所述终端应用发送的动态文案报错信息,其中所述动态文案报错信息包括用户在终端应用显示界面选择的动态文案报错字符以及输入的对应待替换字符;
    所述服务器建立所述动态文案报错字符与所述对应待替换字符间的映射关系,并在预设人工检测终端对所述映射关系检测通过后,将所述语言包中存储的动态文案报错字符替换为映射的对应待替换字符。
  16. 一种计算机可读存储介质,其中,所述计算机可读存储介质上存储有计算机程序,所述计算机程序被处理器执行时实现以下步骤:
    服务器接收所述终端应用发出的动态文案语言切换指令,并根据所述动态文案语言切换指令获取所述动态文案待切换的语言;
    所述服务器根据所述待切换的语言,从预设存储器中获取所述待切换的语言对应的语言包;
    所述服务器返回所述语言包至所述终端应用,以供所述终端应用通过加载所述语言包切换所述动态文案的语言。
  17. 根据权利要求16所述的计算机可读存储介质,其中,所述动态文案语言切换指令包括所述终端应用前次切换所述动态文案的语言时所述终端的历史位置;所述计算机程序被处理器执行时还实现以下步骤:
    所述服务器通过所述终端的基站定位信息、全球定位系统GPS定位信息以及网络协议IP地址定位信息中的至少一个获取所述终端当前所处位置;
    所述服务器判断所述动态文案语言切换指令中的所述终端的历史位置是否与所述终端当前所处位置一致;
    当所述终端的历史位置与所述终端当前所处位置不一致时,所述服务器根据所述终端当前所处位置,确定所述终端当前所处位置对应的官方语言,并将所述官方语言作为所述动态文案待切换的语言;
    或者,所述动态文案语言切换指令包括所述终端其他应用的语言配置信息;所述计算机程序被处理器执行时还实现以下步骤:
    所述服务器从所述动态文案语言切换指令中获取所述终端其他应用的语言配置信息;
    所述服务器根据所述其他应用的语言配置信息,确定所述其他应用所使用的语言,并将所述其他应用所使用的语言作为所述终端应用动态文案待切换的语言。
  18. 根据权利要求17所述的计算机可读存储介质,其中,所述计算机程序被处理器执行时还实现以下步骤:
    所述服务器获取所述终端应用当前所处的业务节点;
    所述服务器判断所述预设存储器中是否包括所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
    若否,则所述服务器选择一种动态文案的语言,并获取所述终端应用当前所处的业务节点对应的,该种动态文案的语言的动态文案;
    所述服务器将该动态文案按照该种动态文案的语言的预设构词规则进行分词处理,得到多个基准语言块;
    所述服务器以所述多个基准语言块为关键词,从所述预设存储器中查找每个基准语言块对应的待切换的语言块;
    所述服务器根据所述待切换的语言的预设构词规则对所有语言块进行拼接,得到所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
    若是,则所述服务器根据所述待切换的语言以及所述业务节点,从所述预设存储器中查找出所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包。
  19. 根据权利要求16所述的计算机可读存储介质,其中,所述计算机程序被处理器执行时还实现以下步骤:
    所述服务器获取所述终端应用当前所处的业务节点;
    所述服务器判断所述预设存储器中是否包括所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
    若否,则所述服务器选择一种动态文案的语言,并获取所述终端应用当前所处的业务节点对应的,该种动态文案的语言的动态文案;
    所述服务器将该动态文案按照该种动态文案的语言的预设构词规则进行分词处理,得到多个基准语言块;
    所述服务器以所述多个基准语言块为关键词,从所述预设存储器中查找每个基准语言块对应的待切换的语言块;
    所述服务器根据所述待切换的语言的预设构词规则对所有语言块进行拼接,得到所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包;
    若是,则所述服务器根据所述待切换的语言以及所述业务节点,从所述预设存储器中查找出所述待切换的语言的,所述终端应用当前所处的业务节点对应的语言包。
  20. 根据权利要求16所述的计算机可读存储介质,其中,所述计算机程序被处理器执行时还实现以下步骤:
    所述服务器获取所述终端应用发送的动态文案报错信息,其中所述动态文案报错信息包括用户在终端应用显示界面选择的动态文案报错字符以及输入的对应待替换字符;
    所述服务器建立所述动态文案报错字符与所述对应待替换字符间的映射关系,并在预设人工检测终端对所述映射关系检测通过后,将所述语言包中存储的动态文案报错字符替换为映射的对应待替换字符。
PCT/CN2018/122722 2018-09-26 2018-12-21 终端应用动态文案的语言切换方法、服务器及存储介质 Ceased WO2020062640A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201811122739.4 2018-09-26
CN201811122739.4A CN109669741B (zh) 2018-09-26 2018-09-26 终端应用动态文案的语言切换方法、服务器及存储介质

Publications (1)

Publication Number Publication Date
WO2020062640A1 true WO2020062640A1 (zh) 2020-04-02

Family

ID=66141636

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/122722 Ceased WO2020062640A1 (zh) 2018-09-26 2018-12-21 终端应用动态文案的语言切换方法、服务器及存储介质

Country Status (2)

Country Link
CN (1) CN109669741B (zh)
WO (1) WO2020062640A1 (zh)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111767104A (zh) * 2020-05-07 2020-10-13 北京奇艺世纪科技有限公司 一种语言种类切换方法、装置、计算机设备及存储介质
CN118427199A (zh) * 2024-07-04 2024-08-02 杭州乒乓智能技术有限公司 多语言文案自适应适配方法及装置

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110362370B (zh) * 2019-06-14 2022-10-18 平安科技(深圳)有限公司 一种网页语言的切换方法、装置及终端设备
CN110716777A (zh) * 2019-08-30 2020-01-21 平安普惠企业管理有限公司 应用程序语言动态切换方法、装置、存储介质及电子设备
CN110536149A (zh) * 2019-09-02 2019-12-03 北京字节跳动网络技术有限公司 消息显示方法、装置、可读介质及电子设备
CN114924804A (zh) * 2021-02-02 2022-08-19 腾讯科技(深圳)有限公司 一种启动应用程序的方法、装置、计算机设备及存储介质
CN113590242A (zh) * 2021-06-25 2021-11-02 影石创新科技股份有限公司 应用程序的文案语言切换方法、装置、终端及存储介质
CN113407288B (zh) * 2021-06-29 2022-09-30 杭州海康威视数字技术股份有限公司 数据处理方法、装置及电子设备
CN115631049A (zh) * 2022-09-09 2023-01-20 平安银行股份有限公司 一种基于金融应用程序的文案切换方法、装置及电子设备
CN116610851A (zh) * 2023-05-17 2023-08-18 中国第一汽车股份有限公司 车辆的车机端语言切换方法、装置及车辆
CN119473479B (zh) * 2024-10-31 2025-11-25 武汉精臣智慧标识科技有限公司 一种多语言动态更新方法和装置

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101201818A (zh) * 2006-12-13 2008-06-18 李萍 用hmm计算语言结构、进行分词、机器翻译和语音识别的方法
CN104020991A (zh) * 2014-05-16 2014-09-03 可牛网络技术(北京)有限公司 应用程序的多语言切换方法及装置
US20150220515A1 (en) * 2006-10-10 2015-08-06 Abbyy Infopoisk Llc Deep model statistics method for machine translation
US20160179789A1 (en) * 2014-12-19 2016-06-23 Dropbox, Inc. Content localization using fallback translations
CN105867920A (zh) * 2016-03-29 2016-08-17 海尔优家智能科技(北京)有限公司 App的多语言切换方法和系统
CN106020825A (zh) * 2016-05-20 2016-10-12 珠海市魅族科技有限公司 一种信息展示方法以及移动终端

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6529902B1 (en) * 1999-11-08 2003-03-04 International Business Machines Corporation Method and system for off-line detection of textual topical changes and topic identification via likelihood based methods for improved language modeling
KR100664191B1 (ko) * 2005-01-11 2007-01-03 엘지전자 주식회사 다국어 지원 휴대단말기 및 시스템
CN101566946A (zh) * 2008-04-25 2009-10-28 北京闻言科技有限公司 一种灵活支持软件多语言版本的方法
US20150161114A1 (en) * 2011-06-30 2015-06-11 Google Inc. Rules-based language detection
CN103631772A (zh) * 2012-08-29 2014-03-12 阿里巴巴集团控股有限公司 机器翻译方法及装置

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150220515A1 (en) * 2006-10-10 2015-08-06 Abbyy Infopoisk Llc Deep model statistics method for machine translation
CN101201818A (zh) * 2006-12-13 2008-06-18 李萍 用hmm计算语言结构、进行分词、机器翻译和语音识别的方法
CN104020991A (zh) * 2014-05-16 2014-09-03 可牛网络技术(北京)有限公司 应用程序的多语言切换方法及装置
US20160179789A1 (en) * 2014-12-19 2016-06-23 Dropbox, Inc. Content localization using fallback translations
CN105867920A (zh) * 2016-03-29 2016-08-17 海尔优家智能科技(北京)有限公司 App的多语言切换方法和系统
CN106020825A (zh) * 2016-05-20 2016-10-12 珠海市魅族科技有限公司 一种信息展示方法以及移动终端

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111767104A (zh) * 2020-05-07 2020-10-13 北京奇艺世纪科技有限公司 一种语言种类切换方法、装置、计算机设备及存储介质
CN111767104B (zh) * 2020-05-07 2023-09-01 北京奇艺世纪科技有限公司 一种语言种类切换方法、装置、计算机设备及存储介质
CN118427199A (zh) * 2024-07-04 2024-08-02 杭州乒乓智能技术有限公司 多语言文案自适应适配方法及装置

Also Published As

Publication number Publication date
CN109669741B (zh) 2022-02-18
CN109669741A (zh) 2019-04-23

Similar Documents

Publication Publication Date Title
WO2020062640A1 (zh) 终端应用动态文案的语言切换方法、服务器及存储介质
WO2020147385A1 (zh) 数据录入方法、装置、终端及计算机可读存储介质
WO2021051558A1 (zh) 基于知识图谱的问答方法、装置和存储介质
CN112434059B (zh) 数据处理方法、装置、计算机设备和存储介质
WO2021006616A1 (en) Method for providing relational decentralized identifier service and blockchain node using the same
WO2020233089A1 (zh) 测试用例生成方法、装置、终端及计算机可读存储介质
WO2020224246A1 (zh) 基于区块链的数据管理方法、装置、设备和存储介质
WO2020015067A1 (zh) 数据采集方法、装置、设备及存储介质
WO2020082766A1 (zh) 输入法的联想方法、装置、设备及可读存储介质
WO2018149082A1 (zh) 合同生成方法、装置、服务器和存储介质
WO2020077832A1 (zh) 云桌面的访问方法、装置、设备及存储介质
WO2014101023A1 (zh) 一种防止业务非法访问的方法和装置
JP2004259271A (ja) 言語翻訳の方法およびシステム
WO2013077589A1 (ko) 음성인식 부가 서비스 제공 방법 및 이에 적용되는 장치
WO2020087981A1 (zh) 风控审核模型生成方法、装置、设备及可读存储介质
WO2012155709A1 (zh) 一种动态推送用户个人标签的方法和系统、存储介质
WO2021040166A1 (ko) 소프트웨어 업데이트를 위한 신구 데이터간의 차분 생성 방법 및 그 장치
WO2020177376A1 (zh) 数据的提取方法、装置、终端及计算机可读存储介质
WO2024075927A1 (en) Meta-searching method and apparatus
WO2018014594A1 (zh) 网络请求及响应的处理方法、装置、终端、服务器及存储介质
WO2016018048A1 (ko) 서비스 제어 장치 연동을 통한 단말간 컨텐츠 전송 방법
WO2020107591A1 (zh) 重复投保限制方法、装置、设备及可读存储介质
WO2021051492A1 (zh) 数据库服务节点切换方法、装置、设备及计算机存储介质
WO2020237849A1 (zh) 网络块设备快照读写方法、装置、设备及存储介质
WO2020073615A1 (zh) 设备软件的升级方法、数据转化器及可读存储介质

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 18935198

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 09.07.2021)

122 Ep: pct application non-entry in european phase

Ref document number: 18935198

Country of ref document: EP

Kind code of ref document: A1