Information processing program, information processing method, and information processing device
By optimizing word segmentation through multiple pattern division and neural network-based adjustment with vocabulary constraints, the method addresses high resource consumption in word splitter and subsequent model operations, improving natural language processing efficiency.
Patent Information
- Application Number
- JP2023031908
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2023-03-02
- Publication Date
- 2024-09-12
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The parallel operation of a word splitter and a subsequent machine learning model for natural language processing consumes excessive computational resources, making it difficult to implement in practical applications due to high memory and processing demands.
A method that involves dividing input text using multiple patterns, selecting optimal divisions based on inference quality, and adjusting the word splitter to improve performance while minimizing resource consumption, using a neural network-based word segmenter with vocabulary constraints.
Reduces computational resource consumption and enhances the performance of natural language processing by optimizing word segmentation without retraining the subsequent model, allowing for more efficient use of computational resources.
Smart Images

Figure 2024124026000001
Abstract
Description
[Technical field]
[0001] The present invention relates to an information processing program, an information processing method, and an information processing device. [Background technology]
[0002] In natural language processing using a machine learning model, character string data such as text that is input to the machine learning model may be divided into smaller units, such as tokens. A token is one or more character strings (phrases, words) obtained by dividing character string data at one or more positions.
[0003] For example, if the text is "voting rights for foreigners," splitting it in a certain way will give the tokens "foreigner," "voting," and "rights." Also, if the text is "award for best actor," splitting it in a certain way will give the tokens "a," "ward," "for," "b," "est," and "actor."
[0004] Hereinafter, for convenience, a token may be written as a "word." A "word" may include, for example, general words such as "foreigner" and "award," as well as subwords such as "right" and "est." The process of dividing character string data into tokens may be called "word division" or "tokenization."
[0005] The way text is divided in word segmentation, in other words, the segmentation pattern, can affect the performance of natural language processing using a machine learning model, for example, the accuracy of the inference results output from the machine learning model. This means that by changing the segmentation pattern, it may be possible to improve the performance of natural language processing without having to adjust the parameters of a trained machine learning model.
[0006] For example, a technique is known in which a word splitter (lexical splitter) that performs word splitting and a machine learning model subsequent to the word splitter (hereinafter sometimes referred to as the "subsequent model") are launched in parallel to simultaneously optimize (adjust) the word splitter and the subsequent model.
[0007] In this technique, for example, input data containing multiple texts is input to a word splitter, the resulting segmented text is input to a subsequent model, and the training results of the subsequent model are fed back to the word splitter, thereby optimizing the word splitter. [Prior art documents] [Non-patent literature]
[0008] [Non-Patent Document 1] Tatsuya Hiraoka, Sho Takase, Kei Uchiumi, Atsushi Keyaki, and Naoaki Okazaki, “Joint Optimization of Tokenization and Downstream Model”, In Findings of the Association for Computational Linguistics: ACL 2021, Association for Computational Linguistics, August 2021 Summary of the Invention [Problem to be solved by the invention]
[0009] In the above-mentioned method, the word segmenter and the latter model run in parallel. Therefore, in a computer that runs the word segmenter and the latter model, optimizing the word segmenter may increase the consumption of the computer's computational resources, such as the memory usage and the processor's processing power. For this reason, depending on the performance of the computer, it may be difficult to put the above-mentioned method into practical use.
[0010] In one aspect, the present invention aims to reduce the consumption of computational resources in tuning a lexical segmenter that inputs data into a trained machine learning model. [Means for solving the problem]
[0011] In one aspect, an information processing program may cause a computer to execute the following process. The process may input character string data to a first lexical segmenter, thereby acquiring, for each of a plurality of character string data included in a data set, a plurality of first divided character string data pieces obtained by dividing the character string data by a plurality of different first division patterns corresponding to the character string data. The process may use the first divided character string data as input data, and calculate an index indicating the quality of an inference result when the plurality of first divided character string data pieces for each of the plurality of character string data pieces are input to a trained machine learning model that performs an inference process according to the input data. The process may select, for each of the plurality of character string data pieces, a first divided character string data piece whose index indicating the quality or the quality satisfies a predetermined condition from among the corresponding plurality of first divided character string data pieces. The process may adjust a second lexical segmenter that inputs the input data to the trained machine learning model based on the first divided character string data piece selected for each of the plurality of character string data pieces. Effect of the Invention
[0012] In one aspect, the present invention can reduce the consumption of computational resources in tuning lexical segmenters that input data to a trained machine learning model. [Brief description of the drawings]
[0013] [Figure 1] 13A to 13C are diagrams illustrating an example of changes in the inference results of the subsequent model according to the word segmentation pattern. [Diagram 2] 13A and 13B are diagrams illustrating another example of changes in the inference results of the subsequent model according to the word segmentation pattern. [Diagram 3]FIG. 13 is a diagram for explaining an optimization technique for word segmentation according to a comparative example. [Figure 4] FIG. 2 is a block diagram showing an example of a hardware (HW) configuration of a computer that realizes a function of a server as an example of an embodiment. [Diagram 5] FIG. 2 is a block diagram illustrating an example of a software configuration of a server according to an embodiment. [Figure 6] FIG. 13 is a diagram for explaining an example of the operation of the training phase of the latter model and word segmenter B. [Figure 7] FIG. 13 is a diagram for explaining an example of the operation of the inference phase using a trained word segmenter B and a trained subsequent model. [Figure 8] FIG. 1 illustrates an example of a training dataset. [Figure 9] FIG. 13 is a diagram illustrating an example of a divided data set. [Figure 10] FIG. 13 is a diagram showing an example of a plurality of patterns of divided data sets. [Figure 11] FIG. 1 is a diagram illustrating an example of a partitioned training dataset. [Figure 12] FIG. 11 is a diagram for explaining an example of a method for selecting divided data from a divided data set. [Figure 13] 13 is a diagram for explaining an example of a score calculation process in a word segmenter B. FIG. [Figure 14] 13 is a diagram for explaining an example of a score calculation method by word segmenter B. FIG. [Figure 15] FIG. 13 is a diagram illustrating an example of vocabulary constraints. [Figure 16] FIG. 13 is a diagram illustrating an example of the effect on the performance of a trained subsequent model by a technique according to an embodiment. [Figure 17] 13 is a flowchart illustrating an example of the operation of machine learning processing of a later-stage model by a server according to an embodiment. [Figure 18] 13 is a flowchart for explaining an example of the operation of machine learning processing of a word segmenter B by a server according to an embodiment. [Figure 19]11 is a flowchart illustrating an example of an operation of an inference process by a server according to an embodiment. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0014] Hereinafter, the embodiments will be described with reference to the drawings. However, the embodiments shown below are merely examples, and are not intended to exclude the application of various modified examples and techniques not explicitly stated in the embodiments. For example, the present embodiment can be modified in various ways without departing from the spirit of the present invention. In addition, each figure does not intend to include only the components shown in the figure, but can include other functions, etc.
[0015] [A] Explanation of word division adjustment First, adjustment of word segmentation will be described. In one embodiment, a word segmenter (lexical segmenter) performs word segmentation of input text, and inputs multiple words resulting from the segmentation to a subsequent model. An example of a word segmenter is a tokenizer. Text is an example of character string data. Moreover, text segmented into multiple words (tokens) by the word segmenter is an example of segmented character string data.
[0016] The latter model is a machine learning model that executes various AI (Artificial Intelligence) tasks related to natural language processing. In one embodiment, the latter model may be, for example, a topic classifier that performs topic classification of the entirety (character string data) of a plurality of input words. Topic classification is an example of a document classification task.
[0017] Fig. 1 is a diagram showing an example of change in the inference result of the latter model according to the word segmentation pattern. Fig. 1 shows an example in which, when the text "Non-citizen suffrage" is input to the word segmenter 110, the word segmenter 110 segments the text into words using the following two segmentation patterns. Foreign / Carrot / Administration Foreign citizen / Participation in government / Rights
[0018] In the following, like the word patterns above, text divisions resulting from word division are represented by a slash ( / ). Additionally, parentheses conveniently represent the meaning of the words (tokens) obtained by word division in a language other than the words (English in the example in Figure 1). Note that tokens do not necessarily have to be units with meaning, but in the example shown in Figure 1, translations corresponding to tokens are added for interpretation purposes.
[0019] In the following description, a plurality of words obtained by word segmentation of text by the word segmenter 110 may be referred to as “segmented text.” The segmented text is an example of decomposed character string data.
[0020] The topic classifier 120 analyzes the latent meaning of the segmented text input from the word segmenter 110, and classifies the segmented text into one of a number of predetermined topics.
[0021] In the example of Fig. 1, the topic "Non-citizen suffrage" is appropriately classified as a "political topic." For example, the topic classifier 120 classifies the segmented text "foreigner / suffrage / rights" as a "political topic." On the other hand, the topic classifier 120 may classify the segmented text "foreigner / carrot / government" as a "food topic" due to the influence of the word "carrot."
[0022] The occurrence of such improper topic classification is not limited to languages without "word separation" such as Japanese and Chinese. In languages with "word separation", such as English, the word divider 110 may divide a word into subwords in addition to spaces between words.
[0023] Fig. 2 is a diagram showing another example of the change in the inference result of the latter model according to the word division pattern. Fig. 2 shows an example in which, when the text "prime contractor" is input to the word divider 110, the word divider 110 divides the text into words using the following two division patterns. prime / contr / actor prime / contract / or
[0024] 2, the topic of "prime contractor" is appropriate as the "Business" topic. For example, the topic classifier 120 classifies the segmented text "prime / contract / or" as the "Business" topic. On the other hand, the topic classifier 120 may classify the segmented text "prime / contr / actor" as the "Movie" topic due to the influence of the subword "actor."
[0025] In training (machine learning) of the topic classifier 120, for example, segmented text output by the word segmenter 110 according to any of the segmentation patterns for the input text is used as training data. For this reason, the topic classifier 120 may be trained using, for example, "foreign / ginseng / government", "prime / contr / actor", etc. as training data.
[0026] Even if the trained topic classifier 120 is trained using such inappropriate segmented text, it may be possible to output an appropriate topic classification result (inference result) depending on the segmentation pattern of the segmented text, as shown in Figures 1 and 2. In other words, by changing the segmentation pattern by the word segmenter 110 while leaving the parameters of the topic classifier 120 unchanged (fixed), it may be possible to improve the inference accuracy of the topic classifier 120.
[0027] Therefore, we consider creating a word splitter 110 that performs appropriate word splitting to improve the processing performance of a trained subsequent model, for example, word splitting such as "foreigner / voting / rights" or "prime / contract / or" that will give correct results when input to the subsequent model.
[0028] 3 is a diagram for explaining a word segmentation optimization method according to a comparative example. As shown in FIG. 3, a training data set 201 including a plurality of training texts is input to a word segmenter 210.
[0029] A word segmenter 210 performs word segmentation on each of the multiple training texts in a training dataset 201, and inputs a segmented training dataset 202 including the multiple segmented training data to a subsequent model 220.
[0030] The subsequent model 220 (e.g., a topic classifier) performs inference processing using each of the multiple divided training data included in the divided training dataset 202, and feeds back the inference results to the word divider 210 via a feedback mechanism 230 (optimization mechanism).
[0031] In this way, by incorporating the latter-stage model 220 into the word splitter 210 using an optimization mechanism and retraining the word splitter 210, the word splitter 210 can be optimized to perform appropriate word splitting.
[0032] However, in the method illustrated in Fig. 3, the latter model 220 and the optimization mechanism are started in parallel with the word segmenter 210. Therefore, in a computer that executes the word segmenter 210 and the latter model 220, the usage of the computer's computational resources, for example, memory, may increase compared to when only the word segmenter 210 is started. Therefore, depending on the processing performance of the computer, it may be difficult to put the method illustrated in Fig. 3 into practical use.
[0033] 3, a simple method such as a method using a unigram language model is adopted as the word splitter 210. For this reason, there may be restrictions on the variation of word splitting (splitting patterns) that the word splitter 210 can learn.
[0034] Such limitations may be overcome by using a word segmenter with high expressiveness, such as a neural word segmenter that uses a neural network.
[0035] However, since the neural word splitter has no or small restrictions on the "vocabulary" used when performing word splitting, there is a possibility that the word splitting by the neural word splitter will output "unknown words" that are not actually included in the vocabulary available to the latter-stage model 220. "Vocabulary" refers to words obtained by splitting text using word splitting, such as the above-mentioned phrases (tokens) such as "foreigner," "suffrage," and "right." "Unknown words" are, for example, words not used (not included in the training dataset) in training the latter-stage model 220, such as the word "suffrage."
[0036] For this reason, due to limitations in the vocabulary available to the latter-stage model 220, it may be difficult to simply apply a highly expressive word segmenter such as a neural word segmenter to the approach illustrated in FIG.
[0037] Thus, in one aspect, an embodiment describes an example of a technique for reducing the consumption of computational resources in tuning a word segmenter that inputs data to a trained machine learning model, and in another aspect, describes an example of a technique for achieving expressive tuning of the word segmenter while satisfying lexical constraints available in the trained machine learning model.
[0038] [B] Hardware configuration example The server 1 according to one embodiment (see FIG. 5) may be a virtual server (VM: Virtual Machine) or a physical server. The functions of the server 1 may be realized by one computer or by two or more computers. Furthermore, at least a part of the functions of the server 1 may be realized using hardware (HW) resources and network (NW) resources provided by a cloud environment.
[0039] 4 is a block diagram showing an example of a hardware (HW) configuration of a computer 10 that realizes the functions of the server 1 as an example of an embodiment. When multiple computers are used as HW resources that realize the functions of the server 1, each computer may have the HW configuration shown in FIG.
[0040] As shown in FIG. 4, the computer 10 may, as a HW configuration, illustratively include a processor 10a, a graphics processing unit 10b, a memory 10c, a storage unit 10d, an IF (Interface) unit 10e, an IO (Input / Output) unit 10f, and a reading unit 10g.
[0041] The processor 10a is an example of a processing unit that performs various controls and calculations. The processor 10a may be connected to each block in the computer 10 via a bus 10j so that they can communicate with each other. The processor 10a may be a multiprocessor including a plurality of processors, a multicore processor having a plurality of processor cores, or a configuration having a plurality of multicore processors.
[0042] Examples of the processor 10a include integrated circuits (ICs) such as a CPU, MPU, APU, DSP, ASIC, and FPGA. Note that a combination of two or more of these integrated circuits may be used as the processor 10a. CPU is an abbreviation for Central Processing Unit, and MPU is an abbreviation for Micro Processing Unit. APU is an abbreviation for Accelerated Processing Unit. DSP is an abbreviation for Digital Signal Processor, ASIC is an abbreviation for Application Specific IC, and FPGA is an abbreviation for Field-Programmable Gate Array.
[0043] The graphics processing device 10b controls screen display for an output device such as a monitor in the IO unit 10f. The graphics processing device 10b may also have a configuration as an accelerator that executes machine learning processing and inference processing using a machine learning model. The graphics processing device 10b may be various types of arithmetic processing device, such as a GPU (Graphics Processing Unit), an APU, a DSP, an ASIC, or an integrated circuit (IC) such as an FPGA.
[0044] The memory 10c is an example of HW that stores various data, programs, and other information. The memory 10c may be, for example, one or both of a volatile memory such as a dynamic random access memory (DRAM) and a non-volatile memory such as a persistent memory (PM).
[0045] The storage unit 10d is an example of HW that stores various data, programs, and other information. Examples of the storage unit 10d include various storage devices such as a magnetic disk device such as a hard disk drive (HDD), a semiconductor drive device such as a solid state drive (SSD), and a nonvolatile memory. Examples of the nonvolatile memory include a flash memory, a storage class memory (SCM), and a read only memory (ROM).
[0046] The storage unit 10d may store a program 10h (data processing program) that realizes all or part of the various functions of the computer 10.
[0047] For example, the processor 10a of the server 1 can implement the function of a control unit 30 (see FIG. 5) described later by loading a program 10h stored in the storage unit 10d into the memory 10c and executing it.
[0048] The IF unit 10e is an example of a communication IF that controls the connection and communication between the server 1 and other computers. For example, the IF unit 10e may include an adapter that complies with electrical communication (e.g., LAN (Local Area Network)) such as Ethernet (registered trademark) or optical communication such as FC (Fibre Channel). The adapter may support one or both of wireless and wired communication methods.
[0049] The program 10h may be downloaded to the computer 10 from a network via the communication IF and stored in the storage unit 10d.
[0050] The IO unit 10f may include one or both of an input device and an output device. Examples of the input device include a keyboard, a mouse, and a touch panel. Examples of the output device include a monitor, a projector, and a printer. The IO unit 10f may also include a touch panel in which the input device and the display device are integrated. The output device may be connected to the graphics processing device 10b.
[0051] The reading unit 10g is an example of a reader that reads out data or program information recorded on the recording medium 10i. The reading unit 10g may include a connection terminal or device to which the recording medium 10i can be connected or inserted. Examples of the reading unit 10g include an adapter that complies with USB (Universal Serial Bus) or the like, a drive device that accesses a recording disk, and a card reader that accesses a flash memory such as an SD card. The recording medium 10i may store a program 10h, and the reading unit 10g may read the program 10h from the recording medium 10i and store it in the storage unit 10d.
[0052] Examples of the recording medium 10i include non-transitory computer-readable recording media such as magnetic / optical disks and flash memories. Examples of the magnetic / optical disks include flexible disks, CDs (Compact Discs), DVDs (Digital Versatile Discs), Blu-ray Discs, and HVDs (Holographic Versatile Discs). Examples of the flash memory include semiconductor memories such as USB memories and SD cards.
[0053] The above-described HW configuration of the computer 10 is an example. Therefore, the HW in the computer 10 may be increased or decreased (for example, adding or deleting any block), divided, or integrated in any combination, or buses may be added or deleted, etc.
[0054] [C] Software configuration example 5 is a block diagram showing an example of the software configuration of the server 1 as an example of an embodiment. The server 1 is an example of a computer or information processing device that adjusts a word segmenter.
[0055] 5, the server 1 may illustratively include a division control unit 31, a first machine learning unit 32, a generation unit 33, a second machine learning unit 34, and an inference unit 35. The blocks 31 to 35 included in the server 1 are an example of the control unit 30. The function of the control unit 30 may be realized, for example, by the processor 10a of the computer 10 shown in FIG. 4 executing a program 10h deployed in the memory 10c.
[0056] Moreover, as shown in FIG. 5, the server 1 may, for example, be provided with a memory area capable of storing a training dataset 11, divided datasets 12, 13 and 16, a training divided dataset 14, an inference dataset 15 and an inference result 17.
[0057] Furthermore, the server 1 may include a storage area capable of storing data of the word segmenters 21 and 24, the latter-stage model 22, the trained latter-stage model 23, and the trained word segmenter 25. The trained latter-stage model 23 is the latter-stage model 22 trained by machine learning, and may be regarded as a machine learning model in which the parameters of the latter-stage model 22 have been changed. The trained word segmenter 25 is the word segmenter 24 trained by machine learning, and may be regarded as a machine learning model in which the parameters of the word segmenter 24 have been changed.
[0058] The storage area of the server 1 may be realized by, for example, one or both of the storage areas of the memory 10c and the storage unit 10d of the computer 10 shown in FIG.
[0059] The server 1 (control unit 30) may receive, for example, at least one of the training data set 11 and the inference data set 15 from another computer (not shown) via the IF unit 10e and a network, and store it in a memory area.
[0060] The server 1 (control unit 30) may also transmit, for example, at least one of the trained subsequent model 23, the trained word splitter 25, and the inference result 17 stored in the memory area to another computer (not shown) via the IF unit 10e and the network. The server 1 may also transmit intermediate data, for example at least one of the data 11 to 16, 21, 22, and 24, to another computer (not shown) via the IF unit 10e and the network.
[0061] Hereinafter, word segmenter 21 may be referred to as word segmenter A, word segmenter 24 may be referred to as word segmenter B, and trained word segmenter 25 may be referred to as trained word segmenter B.
[0062] The word splitter A is an example of a first lexical splitter. The word splitter A may be a word splitter that employs a simple method such as a method using a unigram language model, similar to the word splitter 110 shown in Figures 1 and 2 or the word splitter 210 shown in Figure 3. For example, the word splitter A may refer to a word list 21a that stores vocabulary that the word splitter A can handle, and perform word splitting using vocabulary included in the word list 21a.
[0063] Word splitter B is an example of a word splitter (lexical splitter, token splitter) with high expressiveness, and is an example of a second lexical splitter that inputs input data to the trained subsequent model 23. For example, word splitter B may be a neural word splitter using a neural network. As an example, word splitter B may be a neural word splitter using BiLSTM (Bidirectional Long Short-Term Memory). BiLSTM is an example of LSTM, RNN (Recurrent Neural Network). Note that word splitter A may be a neural word splitter similar to word splitter B.
[0064] The latter model 22 may be a machine learning model that executes various document classification tasks such as a topic classifier, a sentiment classifier, etc., and may be, for example, a document classifier such as a Support Vector Machine (SVM).
[0065] The AI task executed by the latter-stage model 22 is not limited to a document classification task, and may be capable of executing various AI tasks related to natural language processing. As an example, the latter-stage model 22 may be a machine learning model that can quantitatively measure the quality (e.g., accuracy) of the output result from the latter-stage model 22, such as a machine learning model that can calculate the loss for a teacher label.
[0066] FIG. 6 is a diagram for explaining an example of operation of the training phase of the subsequent model 22 and the word segmenter B, and FIG. 7 is a diagram for explaining an example of operation of the inference phase using the trained word segmenter B and the trained subsequent model 23.
[0067] As illustrated in FIG. 6, the segmentation control unit 31 inputs a training data set 11 including a plurality of training data to a word segmenter A (word segmenter 21).
[0068] Fig. 8 is a diagram showing an example of the training dataset 11. As shown in Fig. 8, the training dataset 11 may exemplarily include, as training data, text, which is an example of character string data, and a teacher label. As an example of the teacher label, as shown in Fig. 8, a topic can be given.
[0069] 8, it is assumed that the following training data is included in the training data set 11. Note that the parentheses indicate the teacher labels (topics) of the training data. "Debate about non-citizen suffrage" (Politics) "Prices of carrots etc. soar" (Economy) "Decided to provide disaster relief to Turkey" (Diplomacy) "Prime contractor information" (Business) "award for best actor" (Movie)
[0070] The segmentation control unit 31 may input each of the multiple training data to the word segmenter A to obtain a segmented data set 12 including segmented data for each training data.
[0071] The segmented data for each training data is an example of segmented character string data obtained by inputting the training data to the word segmenter A and segmenting the training data into words using a predetermined segmentation pattern. The predetermined segmentation pattern is an example of any one of a plurality of first segmentation patterns that the word segmenter A can execute for each of the plurality of training data based on the word list 21a.
[0072] As an example, the word splitter A may be capable of splitting words into N (e.g., 100) splitting patterns for each training data by a method such as N-best splitting (e.g., N=100). For example, the predetermined splitting pattern may be a splitting pattern with the highest score among a plurality of first splitting patterns, e.g., the N splitting patterns.
[0073] Fig. 9 is a diagram showing an example of the divided data set 12. Fig. 9 shows an example in which each of the training data shown in Fig. 8 is divided according to a predetermined division pattern as follows. "Discussion about foreign countries / carrots / government" (politics) "Prices of carrots, etc. are rising" (Economy) "Türkiye / Disaster / Aid / Decided / To / Be / Supported / by / Turkey" (Diplo "prime / contr / actor / inform / ation" (Business) "award / for / best / actor" (Movie)
[0074] The first machine learning unit 32 inputs the divided dataset 12, which is an example of a training dataset, to the subsequent model 22, and performs machine learning (training) of the subsequent model 22 using the divided dataset 12.
[0075] As an example, the first machine learning unit 32 may optimize parameters of the subsequent model 22 so that a classification result for the topic "politics" is output when "foreign countries / carrots / government / about / discussion" is input to the subsequent model 22. The machine learning of the subsequent model 22 may be realized by various known methods.
[0076] The trained subsequent model 23 is obtained by the machine learning process (see symbol A1) of the above-mentioned subsequent model 22 by the division control unit 31 and the first machine learning unit 32. The trained subsequent model 23 is an example of a trained machine learning model that performs inference processing according to input data.
[0077] Furthermore, the segmentation control unit 31 inputs the training data set 11 to the word segmenter A to obtain a plurality of patterns of segmented data sets 13. For example, the segmentation control unit 31 may input each of a plurality of training data sets to the word segmenter A to obtain a segmented data set 13 including a plurality of segmented data sets for each training data set.
[0078] The multiple divided data for each training data are examples of multiple first divided character string data obtained by inputting the training data into word divider A and dividing the training data using multiple different first division patterns corresponding to the training data.
[0079] For example, the segmentation control unit 31 may obtain multiple patterns of word segmentation results for one training data set, for each of multiple training data sets included in the training dataset 11, by performing word segmentation on the training data set in various variations using the word segmenter A.
[0080] Fig. 10 is a diagram showing an example of a plurality of patterns of segmented data sets 13. Fig. 10 shows an example in which the word segmenter A performs N-best word segmentation. For simplicity, Fig. 10 shows an example in which N=3, but this is not limited to this, and may be, for example, N=100 as described above.
[0081] Fig. 10 shows an example in which each of the training data shown in Fig. 8 is divided by multiple division patterns. As an example, the following three divided data are generated by word divider A from the training data of "Discussion on voting rights for foreigners" (politics). "Discussion about foreign countries / carrots / government" (politics) "Debate about foreigners' right to vote" (Politics) "Discussion on foreigners' right to vote" (Politics)
[0082] The generation unit 33 generates the training segmented data set 14 used for training the word segmenter B (word segmenter 24).
[0083] For example, the generation unit 33 performs inference processing using the trained subsequent-stage model 23 with a plurality of divided data included in the divided data set 13 as input data. The generation unit 33 also calculates an index indicating the quality of an inference result when a plurality of divided data for each of a plurality of training data is input to the trained subsequent-stage model 23.
[0084] An example of an index showing the quality of an inference result is a loss based on the output from the trained subsequent model 23 and the teacher label of the training data. The loss may be calculated using various loss functions such as cross-entropy error.
[0085] Furthermore, as an index indicating the quality of the inference result, for example, a prediction probability (prediction score) for each label of the trained subsequent model 23 for each piece of divided data included in the divided dataset 13 may be used. The prediction probability for each label is information indicating the degree of confidence that each label output by topic classification of the divided data by the trained subsequent model 23 is correct, and the higher the prediction probability, the higher the probability that the label is correct. The above-mentioned loss may be calculated based on the prediction probability for each label.
[0086] Then, the generating unit 33 selects, for each of the plurality of training data, from the corresponding plurality of divided data, divided data whose index indicating the quality of the inference result satisfies a predetermined condition, thereby acquiring the training divided data set 14 including the divided data selected for each of the plurality of training data. The predetermined condition may be, for example, that the index indicating the quality of the inference result is optimal, and as one example, that the loss is minimal. The selection process of the training divided data set 14 by the generating unit 33 will be described in detail later.
[0087] Fig. 11 is a diagram showing an example of the training divided data set 14. Fig. 11 shows an example in which the following divided data is selected from the multiple divided data shown in Fig. 10. "Debate about foreigners' right to vote" (Politics) "Prices of carrots, etc. are rising" (Economy) "Turkey disaster aid decision" (diplomacy) "prime / contract / or / inform / at / ion" (Business) "award / for / best / actor" (Movie)
[0088] For example, in the training divided dataset 14, divided data different from “foreign / carrot / government / discussion / about” in the divided dataset 12 is selected as divided data for “discussion on voting rights for foreigners” In addition, divided data different from “prime / contr / actor / inform / ation” in the divided dataset 12 is selected as divided data for “prime contract or information”.
[0089] In one embodiment, the generating unit 33 selects one divided data for one training data as the training divided data set 14, but is not limited to this. For example, the generating unit 33 may select one or more divided data for one training data, the index indicating the quality of the inference result satisfies a predetermined condition (for example, the loss is equal to or less than a predetermined value).
[0090] As described above, the division control unit 31 and the generation unit 33 perform the process of generating the divided training data set 14 (see reference symbol A21).
[0091] The second machine learning unit 34 inputs the acquired training segmented data set 14 to the word segmenter B, and adjusts the word segmenter B, for example, performs machine learning (training or retraining), based on the segmented data included in the training segmented data set 14. For example, the server 1 may adjust (optimize) the parameters of the word segmenter B by performing machine learning on the word segmenter B.
[0092] As an example, the second machine learning unit 34 may optimize parameters of the word splitter B so that when "Discussion about suffrage for foreigners" (politics), which is one of the training data, is input to the word splitter B, the output of the word splitter B is highly likely to be "Foreigners / suffrage / about / discussion" (politics), which is the segmented data selected by the generation unit 33. Details of the machine learning process of the word splitter B will be described later.
[0093] As described above, the second machine learning unit 34 performs the machine learning process (see reference symbol A22) of the word segmenter B using the training segmented dataset 14.
[0094] The segmentation control unit 31, the generation unit 33, and the second machine learning unit 34 adjust (see symbol A2) the above-mentioned word segmenter B, for example, by training, to obtain a trained word segmenter B (trained word segmenter 25).
[0095] As illustrated in FIG. 7, the inference unit 35 performs inference processing (see reference symbol A3) for the trained word splitter B and the trained subsequent-stage model 23.
[0096] For example, the inference unit 35 inputs the inference data set 15 to the trained word splitter B to obtain the split data set 16. The inference data set 15 may include a plurality of inference data, for example a plurality of texts. When the inference unit 35 evaluates the trained subsequent-stage model 23, the inference data set 15 may include a plurality of evaluation data.
[0097] For example, the inference unit 35 may input each of the multiple inference data to a trained word splitter B, thereby obtaining a segmented dataset 16 including segmented data for each of the inference data.
[0098] The segmented data for each piece of inference data is an example of segmented character string data obtained by inputting the inference data to the trained word segmenter B and segmenting the inference data in a predetermined segmentation pattern. The predetermined segmentation pattern is an example of any one of a plurality of first segmentation patterns that the trained word segmenter B can execute for each of a plurality of pieces of inference data.
[0099] Also, for example, the inference unit 35 may use a plurality of divided data included in the divided data set 16 as input data to execute an inference process using the trained subsequent-stage model 23, and obtain the inference result 17.
[0100] The inference unit 35 may evaluate the trained later-stage model 23 based on the inference dataset 15 and the inference result 17. For example, the inference unit 35 may obtain an index indicating the quality of inference by the trained later-stage model 23, and evaluate the trained later-stage model 23 based on the index. The server 1 may output the evaluation result together with the inference result 17 to another computer or the like.
[0101] As described above, according to the method of one embodiment, a training segmented data set 14 is created using a trained subsequent model 23 (see symbol A21 in Figure 6), and machine learning of a word segmenter B is performed using the training segmented data set 14 (see symbol A22).
[0102] By optimizing word segmentation through two-stage processing of symbols A21 and A22, the trained subsequent-stage model 23 only needs to be activated during the processing of symbol A21 of the two-stage processing, and does not need to be activated during the processing of symbol A22. Note that the word segmenter B does not need to be activated during the processing of symbol A21, and only needs to be activated during the processing of symbol A22.
[0103] This makes it possible to suppress (e.g., eliminate) the parallel startup of the trained latter-stage model 23 and the word segmenter B. This makes it possible to suppress an increase in the consumption of the computational resources of the computer, such as the memory usage and the consumption of the processing power of the processor, and to reduce the consumption of computational resources when adjusting the word segmenter B.
[0104] In addition, a new word splitter B is created in addition to the word splitter A that generated the segmented dataset 12 used to train the subsequent model 22, making it possible to adopt various word splitting methods, such as a word splitting method using a neural network.
[0105] [C-1] An example of a process for generating a split training dataset Next, an example of the process of generating the divided training data set 14 by the generating unit 33 (see reference symbol A21 in FIG. 6) will be described.
[0106] Fig. 12 is a diagram for explaining an example of a method for selecting divided data from the divided data set 13. Fig. 12 shows prediction probabilities (prediction scores) for each label of the trained subsequent-stage model 23 when each divided data of the divided data set 13 illustrated in Fig. 10 is input.
[0107] In FIG. 12, for each N pieces of divided data (for example, N=3 pieces) corresponding to the training data, the labels of the predicted probabilities shown in bold are the teacher labels (correct labels).
[0108] In FIG. 12, among the N pieces of divided data corresponding to each training data, the divided data with the highest prediction probability shown in bold can be said to be the divided data whose index indicating the quality of the inference result satisfies a predetermined condition.
[0109] Therefore, the generation unit 33 may select (extract) the divided data with the highest predicted probability, shown in bold, for each training data, and add it to the training divided dataset 14. In Fig. 12, the divided data selected by the generation unit 33 is indicated by a check added to the "Select" item. In this manner, the training divided dataset 14 (see Fig. 11) may be created.
[0110] [C-2] An example of word splitter B Next, a description will be given of an example of the word segmenter B. Fig. 13 is a diagram for explaining an example of a score calculation process in the word segmenter B.
[0111] In one embodiment, a word splitter with high expressiveness using a neural network or the like is used as the word splitter B. On the other hand, the trained subsequent model 23 is trained using a segmented data set 12 expressed within the range of vocabulary included in the word list 21a, output from a word splitter A with lower expressiveness than the word splitter B. Therefore, the segmented data output from the trained word splitter B may include words that the trained subsequent model 23 has not learned, in other words, "unknown words."
[0112] Therefore, the word segmenter B may be trained to suppress the output of the segmented data set resulting from word segmentation including unknown words through the score calculation process in order to satisfy the constraints of the available lexicons of the trained subsequent model 23.
[0113] The score calculation process is an example of a technique for imposing vocabulary constraints on the word segmenter B. For example, the word segmenter B uses the score calculation process to calculate a probability p(s'|s) for each of a plurality of segmented data corresponding to the input training data. Here, s is the training data (text) and s' is the segmented data. The probability is an example of a score. The score is not limited to the probability, and various indices may be used. Hereinafter, the probability p(s'|s) may be expressed as the score p(s'|s).
[0114] The score p(s'|s) may be calculated according to the following formula (1) or (2) depending on the case. All words in s' have been used to train the pre-trained subsequent model 23 (if they are in the word list 21a), p(s'|s) = f(s',s) (1) If a word that has not been used in training the trained subsequent model 23 (a word that does not exist in the word list 21a) is present in s', p(s'|s) = 0.0 (2)
[0115] As an example, assume that the training data is "foreigner's right to vote", the word splitter B outputs "foreigner / voting / right" as split data, and each of the words "foreigner", "voting", and "right" exists in the word list 21a. In this case, the score p(foreigner, voting, right|foreigner's right to vote) is calculated as "0.5", which is the result of the predetermined function f("foreigner, voting, right", "foreigner's right to vote") according to the above formula (1). Similarly, if the word "voting right" also exists in the word list 21a, the score p(foreigner, voting right|foreigner's right to vote) is calculated as "0.3", which is the result of the predetermined function f("foreigner, voting right", "foreigner's right to vote") according to the above formula (1).
[0116] On the other hand, assume that the training data is "foreigner's right to vote", the word splitter B outputs "foreign / right to vote" as split data, and the word "foreigner" is present in the word list 21a but the word "right to vote" is not present in the word list 21a. In this case, the score p(foreigner, right to vote|right to vote for foreigner) is calculated as "0.0" according to the above formula (2).
[0117] In addition, the multiple divided data obtained by inputting the training data or inference data into the word divider B are examples of multiple second divided character string data obtained by dividing the training data or inference data using multiple different second division patterns corresponding to the training data or inference data.
[0118] For example, the word segmenter B outputs the segmented data with the highest score among multiple segmented data (multiple candidates). Restricted segmented data that includes words that the trained subsequent model 23 has not learned (vocabulary not included in the trained subsequent model 23) will have the lowest score. For this reason, the word segmenter B can suppress output of restricted segmented data.
[0119] In addition, in the above formula (2), the value of the score p(s'|s) of the segmented data to be restricted is not limited to "0.0." For example, instead of the above formula (2), various formulas or methods may be used as long as they are capable of suppressing the output of the segmented data to be restricted from the word segmenter B.
[0120] Next, an example of a method for calculating the score p(s'|s) will be described. In the following description, it is assumed that the word segmenter B is a word segmenter that uses BiLSTM as a neural network.
[0121] Training data (text) s = c with K characters 1 ...c K For the word w starting with the i-th character and ending with the j-th character i,j The probability of occurrence of p(w i,j |s) can be calculated by the following formulas (3) to (7). Here, i and j are integers between 1 and K, and i <jである。
number
[0122] In the above formula (3), BiLSTM(v c1 ...v cK )k is the kth input v ck This is an operation to obtain the output of BiLSTM corresponding to the k-th input v ck is c K In the above formulas (4) and (5), MLP begin and MLPs end are different Multi-Layer Perceptrons (MLPs). In the above formula (6), σ(h i (begin)T h j (end) ) is the sigmoid function. h i (begin)T h j (end) h i (begin) and j (end)It is the inner product of V θ is the vocabulary available for the trained subsequent model23.
[0123] p(w i,j The score p(s'|s) of the divided data can be expressed as the product of the occurrence probability of each word w in the divided data s'.
[0124] Therefore, for example, when the training data s = "foreigners' right to vote", the score p (foreigners, suffrage, right | foreigners' right to vote) can be expressed by the following formulas (8) to (11) based on the above formula (3) and the above formulas (6) and (7). Note that in the following formula (8), "foreigners' right to vote" is written as s.
number
[0125] FIG. 14 is a diagram for explaining an example of a method for calculating a score by the word segmenter B. As illustrated in FIG. 14, the word segmenter B obtains a character embedding representation of input training data (text) by the character embedding unit 24a, and inputs the character embedding representation to the BiLSTM 24b. The word segmenter B calculates the score by calculating the output h k (see formula (3) above) is input to MLPbegin24c, which calculates formula (4) above, and MLPend24d, which calculates formula (5) above, k (begin) and h k (end) Obtain respectively.
[0126] The word splitter B is i,j ∈V θ In this case, the output of MLPbegin24c is h k (begin) and the output of MLPend24d, h k (end)The word segmenter B inputs the above-mentioned expressions (6) (expressions (9) to (11)) to the calculation unit 24e. Then, the word segmenter B calculates the occurrence probability p(w i,j The word segmenter B calculates score p(s'|s) for the segmented data by multiplying the occurrence probability calculated for each word by the calculation unit 24e.
[0127] On the other hand, the word splitter B uses w i,j ∈V θ If not, i.e., w i,j is a vocabulary not included in the trained later-stage model 23, the occurrence probability of the word may be determined to be "0.0". For example, the word splitter B may determine that each word is w i,j ∈V θ Determine whether or not w i,j ∈V θ If it is determined that the word is not, the calculation of the sigmoid function for the word is omitted, and the occurrence probability p(w i,j You can also find |s) = 0.0.
[0128] As mentioned above, the score p(s'|s) is calculated by dividing the occurrence probability p(w i,j Therefore, the word splitter B can be expressed as a product of w |s. i,j ∈V θ When it is detected that this is not the case, the score p(s'|s) of the divided data may be calculated as 0.0.
[0129] The word output from BiLSTM24b is w i,j ∈V θ In other words, w i,j ∈V θ The detection that the above is not the case can be performed, for example, by referring to an upper triangular matrix illustrated in FIG.
[0130] Fig. 15 is a diagram showing an example of vocabulary constraints. As shown in Fig. 15, table 24f is a table expressing the vocabulary constraints shown in the above formulas (6) and (7) by an upper triangular matrix when the training data s is "foreigners have the right to vote". The vertical axis of table 24f indicates the start of a word (token), and the horizontal axis of table 24f indicates the end of a word (token). Table 24f may be stored in, for example, a storage area.
[0131] In table 24f, words in shaded boxes are vocabulary that is not included in the trained later-stage model 23, and words in open boxes are vocabulary that is included in the trained later-stage model 23.
[0132] For example, the word divider B may refer to the table 24f shown in Fig. 15 and determine the occurrence probability p of the word present in the shaded box to be "0.0". In this way, the table 24f is an example of a mask for setting the occurrence probability p of the word in the shaded box to 0.0.
[0133] 13 to 15, the training data s is "Foreigner Voting Rights" (Japanese) as an example, but the same applies when the training data s is text in another language, for example, "prime contractor" (English). For example, the word splitter B calculates the occurrence probability p(w i,j |s) and calculate the score p(s'|s) for each divided data.
[0134] The second machine learning unit 34 (see FIG. 5) may optimize parameters of the word segmenter B in the machine learning process of the word segmenter B (see reference symbol A22 in FIG. 6) so as to increase the score of the segmented data included in the training segmented dataset 14. For example, the parameters of the word segmenter B may be optimized so as to minimize the loss Ls^ shown in the following formula (12) for each training data s^ (s^) corresponding to the training segmented dataset 14. Various known methods may be adopted as a method for determining the end of the machine learning of the word segmenter B.
number
[0135] In this way, the second machine learning unit 34 trains the word segmenter B to suppress output from the word segmenter B of character strings that match vocabulary that is not included in the segmented dataset 12 used to train the trained subsequent-stage model 23. This makes it possible to restrict the vocabulary that the word segmenter B can use, and to suppress output of unknown words from the trained word segmenter B.
[0136] For example, in training of the word splitter B by the second machine learning unit 34, the score of the segmented data including, as a segmentation result, a character string that matches a vocabulary not included in the trained subsequent-stage model 23 is adjusted, for example, to "0.0." This makes it possible to impose hard (fixed or semi-fixed) constraints on the vocabulary available to the word splitter B, and further suppresses the possibility of unknown words being output from the trained word splitter B.
[0137] Furthermore, in training of the word segmenter B by the second machine learning unit 34, the word segmenter B controls the score of the segmented data including a character string that matches a vocabulary not included in the trained subsequent-stage model 23 as a segmentation result so as to be smaller than the scores of each of the multiple segmented data. For example, the second machine learning unit 34 optimizes the parameters of the word segmenter B for each of the multiple training data so that the score of the segmented data that matches the segmented data selected by the generation unit 33 among the multiple segmented data obtained by inputting the training data to the word segmenter B is maximized. This allows the word segmenter B to be trained to output (reproduce) segmented data selected by the generation unit 33 and resulting from word segmentation that can contribute to improving the performance (e.g., inference accuracy) of the trained subsequent-stage model 23.
[0138] In the inference process (see symbol A3 in FIG. 7), the trained word segmenter B (see FIG. 5) may output segmented data s' that maximizes the following formula (13). As an example, the trained word segmenter B (e.g., the calculation unit 24e) may output segmented data s' that maximizes the following formula (13) by using a method such as the Viterbi algorithm.
number
[0139] Fig. 16 is a diagram for explaining an example of the effect on the performance of the trained subsequent model 23 by the method according to one embodiment. The table shown in Fig. 16 shows, as a comparison with the "trained subsequent model using the trained word segmenter B according to one embodiment" in item 4, the "method shown in Figs. 1 and 2" in item 1, the "comparative example shown in Fig. 3" in item 2, and the "trained subsequent model using the trained word segmenter B with vocabulary constraint omitted" in item 3. Item 3 is a method that omits the process for vocabulary constraint described with reference to Figs. 13 to 15.
[0140] In addition, FIG. 16 shows an example in which a latter-stage model trained on an emotion classification task is used as the trained latter-stage model 23.
[0141] As shown in “Performance (F1 value)” in FIG. 16, the method of item 4 achieved a performance of 45.41%, which is evident from the contribution to improving the performance of the trained subsequent model 23 compared to other methods.
[0142] As shown in the “recall rate of training data” in Figure 16, the methods of items 3 and 4 have high expressive power because they use neural networks, and the recall rate of the training data is almost 100% in both cases.
[0143] As shown in the “unknown word ratio” in Figure 16, in the method of item 4, vocabulary constraints can be used to suppress the output of segmented data for validation data that includes tokens that match unknown words that the trained subsequent model 23 cannot handle.
[0144] In addition, in the methods of items 3 and 4, when optimizing word segmenter B, it is possible to suppress the invocation of the trained subsequent model 23 in parallel with word segmenter B, thereby realizing a reduction in the consumption of computational resources.
[0145] For these reasons, the methods of items 3 and 4 make it possible to improve the performance of the trained subsequent model 23 at a lower cost than methods that modify the entire parameters of the trained subsequent model 23, such as retraining or additional learning.
[0146] [D] Example of operation Next, an example of the operation of the server 1 as one example of an embodiment configured as described above will be described with reference to FIGS.
[0147] [D-1] Machine learning processing Figure 17 is a flowchart for explaining an example of the operation of machine learning processing of the subsequent model 22 by the server 1 in one embodiment, and Figure 18 is a flowchart for explaining an example of the operation of machine learning processing of word splitter B by the server 1 in one embodiment.
[0148] As illustrated in FIG. 17, the segmentation control unit 31 inputs each of the multiple training data of the training data set 11 to a word segmenter A to obtain a segmented data set 12 including segmented data for each training data (step S1).
[0149] The first machine learning unit 32 executes machine learning of the subsequent model 22 using the divided dataset 12 (step S2), acquires the trained subsequent model 23, and the process ends. Note that various known methods may be adopted as the machine learning method of the subsequent model 22 and the method of determining the end of the machine learning.
[0150] As illustrated in FIG. 18, the splitting control unit 31 inputs each of the multiple training data of the training data set 11 to a word splitter A to obtain multiple patterns of split data sets 13, each of which includes multiple split data obtained by splitting the training data using multiple splitting patterns (step S11).
[0151] The generation unit 33 obtains the training divided dataset 14 by selecting, for each training data, divided data whose index indicating the quality of the inference result from the trained subsequent model 23 to which each of the multiple divided data of the divided dataset 13 has been input satisfies a predetermined condition (step S12).
[0152] The second machine learning unit 34 executes machine learning of the word segmenter B using the training segmented dataset 14 (step S13), obtains the trained word segmenter B, and the process ends.
[0153] [D-2] Inference processing FIG. 19 is a flowchart for explaining an example of the operation of the inference process by the server 1 according to an embodiment.
[0154] As illustrated in FIG. 19, the inference unit 35 inputs the inference data set 15 to the trained word segmenter B to obtain the segmented data set 16 (step S21).
[0155] The inference unit 35 executes inference by the trained subsequent model 23 using the divided data set 16 (step S22) and obtains the inference result 17.
[0156] The inference unit 35 evaluates the trained subsequent model 23 based on the inference result 17 (step S23), and the process ends.
[0157] The evaluation result may be output to another computer or the like together with the inference result 17. Also, the process of step S23 may be omitted.
[0158] [E] Other The technology according to the embodiment described above can be modified and changed as follows.
[0159] For example, the blocks 31 to 35 included in the server 1 shown in FIG. 5 may be merged in any combination, or each may be divided.
[0160] 5 may be configured such that a plurality of devices cooperate with each other via a network to realize each processing function. As an example, each of the blocks 31-35 may be an application server or a Web server, and the storage areas storing each of the data 11-17, 21-25 may be a DB (Database) server, etc. In this case, the Web server, application server, and DB server may cooperate with each other via a network to realize the processing function of the server 1.
[0161] [F] Notes Regarding the above embodiment, the following supplementary notes are further disclosed.
[0162] (Appendix 1) inputting character string data into a first lexical segmenter to obtain a plurality of first segmented character string data pieces obtained by segmenting the character string data by a plurality of different first segmentation patterns corresponding to the character string data, for each of a plurality of character string data pieces included in a data set; calculating an index indicating whether an inference result is good or bad when the first divided character string data for each of the plurality of character string data is input to a trained machine learning model that uses the first divided character string data as input data and performs inference processing according to the input data; selecting, for each of the plurality of pieces of character string data, a piece of first divided character string data whose index of quality satisfies a predetermined condition from among the corresponding pieces of first divided character string data; adjusting a second lexical segmenter that inputs the input data to the trained machine learning model based on the first segmented character string data selected for each of the plurality of character string data; An information processing program that causes a computer to execute processing.
[0163] (Appendix 2) The process of adjusting includes: training the second lexical segmenter to suppress output from the second lexical segmenter of strings that match vocabulary not included in a training dataset used to train the trained machine learning model; 2. An information processing program according to claim 1.
[0164] (Appendix 3) The training process includes: and adjusting a score of second divided character string data including a character string matching the vocabulary as a division result, among a plurality of second divided character string data obtained by inputting the plurality of character string data to the second lexical divider and dividing the character string data by a plurality of different second division patterns corresponding to the character string data. 2. An information processing program according to claim 1.
[0165] (Appendix 4) The process of adjusting the score includes: a process of controlling a score of second segmented character string data including a character string matching the vocabulary as a segmentation result so as to be smaller than each score of the plurality of second segmented character string data; The training process includes: optimizing parameters of the second lexical segmenter so that a score of the second segmented character string data that matches the first segmented character string data selected for the character string data among the second segmented character string data obtained by inputting the character string data to the second lexical segmenter is maximized for each of the plurality of character string data; 4. An information processing program according to claim 3.
[0166] (Appendix 5) The second lexical segmenter is a lexical segmenter using BiLSTM (Bidirectional Long Short-Term Memory), An information processing program according to any one of claims 1 to 4.
[0167] (Appendix 6) inputting character string data into a first lexical segmenter to obtain a plurality of first segmented character string data pieces obtained by segmenting the character string data by a plurality of different first segmentation patterns corresponding to the character string data, for each of a plurality of character string data pieces included in a data set; calculating an index indicating whether an inference result is good or bad when the first divided character string data for each of the plurality of character string data is input to a trained machine learning model that uses the first divided character string data as input data and performs inference processing according to the input data; selecting, for each of the plurality of pieces of character string data, a piece of first divided character string data whose index of quality satisfies a predetermined condition from among the corresponding pieces of first divided character string data; adjusting a second lexical segmenter that inputs the input data to the trained machine learning model based on the first segmented character string data selected for each of the plurality of character string data; An information processing method in which processing is performed by a computer.
[0168] (Appendix 7) The process of adjusting includes: training the second lexical segmenter to suppress output from the second lexical segmenter of strings that match vocabulary not included in a training dataset used to train the trained machine learning model; 6. An information processing method as described in Appendix 6.
[0169] (Appendix 8) The training process includes: and adjusting a score of second divided character string data including a character string matching the vocabulary as a division result, among a plurality of second divided character string data obtained by inputting the plurality of character string data to the second lexical divider and dividing the character string data by a plurality of different second division patterns corresponding to the character string data. 8. An information processing method as described in Appendix 7.
[0170] (Appendix 9) The process of adjusting the score includes: a process of controlling a score of second segmented character string data including a character string matching the vocabulary as a segmentation result so as to be smaller than each score of the plurality of second segmented character string data; The training process includes: optimizing parameters of the second lexical segmenter so that a score of the second segmented character string data that matches the first segmented character string data selected for the character string data among the second segmented character string data obtained by inputting the character string data to the second lexical segmenter is maximized for each of the plurality of character string data; 10. An information processing method as described in Appendix 8.
[0171] (Appendix 10) The second lexical segmenter is a lexical segmenter using BiLSTM (Bidirectional Long Short-Term Memory), An information processing method according to any one of Supplementary Notes 6 to 9.
[0172] (Appendix 11) inputting character string data into a first lexical segmenter to obtain a plurality of first segmented character string data pieces obtained by segmenting the character string data by a plurality of different first segmentation patterns corresponding to the character string data, for each of a plurality of character string data pieces included in a data set; calculating an index indicating whether an inference result is good or bad when the first divided character string data for each of the plurality of character string data is input to a trained machine learning model that uses the first divided character string data as input data and performs inference processing according to the input data; selecting, for each of the plurality of pieces of character string data, a piece of first divided character string data whose index of quality satisfies a predetermined condition from among the corresponding pieces of first divided character string data; adjusting a second lexical segmenter that inputs the input data to the trained machine learning model based on the first segmented character string data selected for each of the plurality of character string data; An information processing device comprising a control unit.
[0173] (Appendix 12) In the process of performing the adjustment, the control unit training the second lexical segmenter to suppress output from the second lexical segmenter of strings that match vocabulary that is not included in a training data set used to train the trained machine learning model; 12. The information processing device according to claim 11.
[0174] (Appendix 13) The control unit, in the training process, adjusting a score of second divided character string data that includes a character string matching the vocabulary as a division result, among a plurality of second divided character string data obtained by inputting the character string data to the second lexical divider and dividing the character string data using a plurality of different second division patterns corresponding to the character string data; 13. The information processing device according to claim 12.
[0175] (Appendix 14) The control unit is In the process of adjusting the score, A score of second segmented character string data including a character string matching the vocabulary as a segmentation result is controlled to be smaller than each score of the plurality of second segmented character string data; In the training process, optimizing parameters of the second lexical segmenter so that, for each of the plurality of pieces of character string data, a score of second segmented character string data that matches the first segmented character string data selected for the character string data is maximized among the plurality of second segmented character string data obtained by inputting the character string data to the second lexical segmenter; 14. The information processing device according to claim 13.
[0176] (Appendix 15) The second lexical segmenter is a lexical segmenter using BiLSTM (Bidirectional Long Short-Term Memory), The information processing device according to any one of claims 11 to 14. [Explanation of symbols]
[0177] 1 Server 10. Computers 11 Training Data Set 12,16 Split Data Set 13. Multiple Pattern Split Data Set 14 Split training dataset 15 Inference Dataset 17 Inference results 21,24,A,B Word Splitter 22 Rear model 23 Pre-trained model 24a Character embedding section 24b BiLSTM 24c MLPbegin 24d MLPend 24e Calculation section 24th floor table 25,B. Trained Word Segmenter 30 Control section 31 Division control section 32 Machine Learning Department 1 33 Generation part 34 Second Machine Learning Department 35 Reasoning part
Claims
1. inputting character string data into a first lexical segmenter to obtain a plurality of first segmented character string data pieces obtained by segmenting the character string data by a plurality of different first segmentation patterns corresponding to the character string data, for each of a plurality of character string data pieces included in the data set; calculating an index indicating whether an inference result is good or bad when the first divided character string data for each of the plurality of character string data is input to a trained machine learning model that performs inference processing according to the input data using the first divided character string data as input data; selecting, for each of the plurality of character string data, a piece of first divided character string data whose index of acceptability satisfies a predetermined condition from among the corresponding pieces of first divided character string data; adjusting a second lexical segmenter that inputs the input data to the trained machine learning model based on the first segmented character string data selected for each of the plurality of character string data; An information processing program that causes a computer to execute processing.
2. The process of adjusting includes: training the second lexical segmenter to suppress output from the second lexical segmenter of strings that match vocabulary not included in a training dataset used to train the trained machine learning model; The information processing program according to claim 1 .
3. The training process includes: and adjusting a score of second divided character string data including a character string matching the vocabulary as a division result, among a plurality of second divided character string data obtained by inputting the character string data to the second lexical divider and dividing the character string data by a plurality of different second division patterns corresponding to the character string data, for each of the plurality of character string data. The information processing program according to claim 2.
4. The process of adjusting the score includes: a process of controlling a score of second segmented character string data including a character string matching the vocabulary as a segmentation result so as to be smaller than each score of the plurality of second segmented character string data; The training process includes: optimizing a parameter of the second lexical segmenter so that a score of the second segmented character string data that matches the first segmented character string data selected for the character string data among the second segmented character string data obtained by inputting the character string data to the second lexical segmenter is maximized for each of the plurality of character string data; The information processing program according to claim 3.
5. The second lexical segmenter is a lexical segmenter using BiLSTM (Bidirectional Long Short-Term Memory). The information processing program according to any one of claims 1 to 4.
6. inputting character string data into a first lexical segmenter to obtain a plurality of first segmented character string data pieces obtained by segmenting the character string data by a plurality of different first segmentation patterns corresponding to the character string data, for each of a plurality of character string data pieces included in the data set; calculating an index indicating whether an inference result is good or bad when the first divided character string data for each of the plurality of character string data is input to a trained machine learning model that performs inference processing according to the input data using the first divided character string data as input data; selecting, for each of the plurality of character string data, a piece of first divided character string data whose index of acceptability satisfies a predetermined condition from among the corresponding pieces of first divided character string data; adjusting a second lexical segmenter that inputs the input data to the trained machine learning model based on the first segmented character string data selected for each of the plurality of character string data; An information processing method in which processing is performed by a computer.
7. inputting character string data into a first lexical segmenter to obtain a plurality of first segmented character string data pieces obtained by segmenting the character string data by a plurality of different first segmentation patterns corresponding to the character string data, for each of a plurality of character string data pieces included in the data set; calculating an index indicating whether an inference result is good or bad when the first divided character string data for each of the plurality of character string data is input to a trained machine learning model that performs inference processing according to the input data using the first divided character string data as input data; selecting, for each of the plurality of character string data, a piece of first divided character string data whose index of acceptability satisfies a predetermined condition from among the corresponding pieces of first divided character string data; adjusting a second lexical segmenter that inputs the input data to the trained machine learning model based on the first segmented character string data selected for each of the plurality of character string data; An information processing device comprising a control unit.
