Model creation method, information processing method, and program

The model generation method addresses the challenge of estimating sentence relationships by using a fixed separator to balance sentence lengths, enabling accurate break detection and improved text readability.

JP2024128740APending Publication Date: 2024-09-24THE JAPAN RES INST
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
JP2023037909
Authority / Receiving Office
JP · JP
Patent Type
Applications
Current Assignee / Owner
Filing Date
2023-03-10
Publication Date
2024-09-24

AI Technical Summary

Technical Problem

Existing language models struggle to accurately estimate the relationship between sentences, particularly in determining whether sentences before and after an important sentence should be extracted together, as they do not effectively detect these relationships.

Method used

A model generation method that uses a learning model trained on fixed-position separator data to estimate the relationship between sentences, utilizing a fixed separator at the center position to balance the input lengths of sentences and improve context analysis.

Benefits of technology

Enables accurate estimation of sentence relationships, allowing for appropriate insertion of paragraph, section, and chapter breaks, enhancing the extraction of important sentences and improving readability of texts.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 2024128740000001
    Figure 2024128740000001
Patent Text Reader

Abstract

To provide a model creation method for a learning model that can estimate the relationship between sentences in the sentences.SOLUTION: A computer acquires a plurality of pieces of training data including the combination of a first sentence and a second sentence and relationship information indicating the relationship between the first sentence and the second sentence. The computer fixes the position of a separator to the center, which is inserted between the first sentence and the second sentence regardless of the number of words in the first sentence and the second sentence, and then uses the plurality of pieces of training data to create a learning model that outputs the relationship information indicating the relationship between the first sentence and the second sentence upon receiving input of all or part of the first sentence and the second sentence included in each training data.SELECTED DRAWING: Figure 1
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] The present disclosure relates to a model generation method, an information processing method, and a program. [Background technology]

[0002] In the field of natural language processing, language models that can process text taking into account context are used. For example, language models based on BERT (Bidirectional Encoder Representations from Transformers) or the like are used to extract important sentences in text and automatically summarize text. Patent Document 1 discloses a text analysis device that classifies words in text into categories using a learning model that classifies text using BERT or the like. [Prior art documents] [Patent documents]

[0003] [Patent Document 1] JP 2022-177365 A Summary of the Invention [Problem to be solved by the invention]

[0004] When extracting important parts in a sentence, for example, there is a demand to check not only the sentence extracted from the sentence using a language model, but also the sentences before and after it and the context to determine whether the extracted sentence is really important. Therefore, rather than extracting only the important sentence as the important part, it is possible to extract, for example, the sentence extracted as the important sentence and the sentences before and after it. In this case, it is necessary to determine whether the sentences before and after the important sentence are sentences that should be extracted together with the important sentence, but it is difficult to estimate the relationship between the important sentence and the sentence before or after it. The technology disclosed in Patent Document 1 does not detect the relationship between each sentence.

[0005] The present disclosure has been made in consideration of the above circumstances, and its purpose is to provide a model generation method for a learning model capable of estimating the relationship between each sentence in a text. [Means for solving the problem]

[0006] The model generation method of the present disclosure includes a process in which a computer executes a process of acquiring a plurality of training data including a combination of a first sentence and a second sentence and relationship information indicating the relationship between the first sentence and the second sentence, fixing the position of a separator to be inserted between the first sentence and the second sentence to the center regardless of the number of words in the first sentence and the second sentence, and using the plurality of training data, generating a learning model that outputs relationship information indicating the relationship between the first sentence and the second sentence when all or a part of the first sentence and the second sentence included in the training data are input. Effect of the Invention

[0007] The present disclosure makes it possible to infer relationships between each sentence in a text. [Brief description of the drawings]

[0008] [Figure 1] 1 is a block diagram showing an example of the configuration of an information processing device; [Diagram 2] FIG. 1 is an explanatory diagram of a learning model. [Diagram 3] FIG. 2 is an explanatory diagram illustrating an example of the configuration of a tokenizer. [Figure 4] 13 is a flowchart illustrating an example of a learning model generation processing procedure. [Diagram 5] 13 is a flowchart showing an example of a processing procedure for estimating a relationship between sentences; [Figure 6] FIG. 11 is an explanatory diagram of an estimation process. [Figure 7] FIG. 13 is an explanatory diagram showing an example of a screen. [Figure 8] FIG. 13 is an explanatory diagram showing a modified example of the learning model. [Figure 9] FIG. 13 is an explanatory diagram illustrating an example of a record layout of an exclusion target DB. [Figure 10] 13 is a flowchart showing an example of a learning model generation processing procedure of the second embodiment. [Figure 11] 13 is a flowchart showing an example of an estimation process procedure according to the second embodiment. [Figure 12] 13 is a flowchart showing an example of an estimation process procedure according to the third embodiment. [Figure 13] 13 is a flowchart showing an example of an estimation process procedure according to the fourth embodiment. [Figure 14] FIG. 2 is an explanatory diagram showing an example of the configuration of a learning model. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0009] The model generation method, information processing method, and program of the present disclosure will be described in detail below with reference to the drawings showing embodiments thereof.

[0010] (Embodiment 1) In this embodiment, an information processing device that predicts the position of each break, such as a paragraph break, a section break, or a chapter break, in a text including a plurality of sentences will be described. Note that the prediction target is not limited to a paragraph break, a section break, or a chapter break, but may be the position of a break of each element that constitutes a text, such as a paragraph break. Fig. 1 is a block diagram showing an example of the configuration of the information processing device.

[0011] The information processing device 10 is an information processing device capable of various information processing and transmitting and receiving information, and is a server computer, a personal computer, or the like. The information processing device 10 includes a control unit 11, a storage unit 12, a communication unit 13, an input unit 14, a display unit 15, a reading unit 16, and the like, and these units are connected to each other via a bus. The control unit 11 includes one or more processors such as a CPU (Central Processing Unit), an MPU (Micro-Processing Unit), a GPU (Graphics Processing Unit), or an AI chip (semiconductor for AI). The control unit 11 executes various information processing and control processing to be performed by the information processing device 10 by appropriately executing a program 12P stored in the storage unit 12.

[0012] The storage unit 12 includes a RAM (Random Access Memory), a flash memory, a hard disk, an SSD (Solid State Drive), and the like. The storage unit 12 stores a program 12P (program product) executed by the control unit 11 and various data required for executing the program 12P. The storage unit 12 also temporarily stores data and the like generated when the control unit 11 executes the program 12P. The storage unit 12 also stores a learning model 12a that has learned training data by machine learning, for example, and a tokenizer 12b associated with the learning model 12a. The learning model 12a is expected to be used as a program module constituting artificial intelligence software. The learning model 12a performs a predetermined calculation on an input value and outputs the calculation result, and the storage unit 12 stores data such as coefficients and thresholds of a function that specifies this calculation as the learning model 12a.

[0013] The communication unit 13 is a communication module for performing processes related to wired or wireless communication, and transmits and receives information to and from other devices via a network. The network may be the Internet or a public telephone line network, or may be a LAN (Local Area Network) constructed in a facility where the information processing device 10 is installed. The input unit 14 accepts operation input by a user and sends a control signal corresponding to the operation content to the control unit 11. The display unit 15 is a liquid crystal display or an organic EL display, etc., and displays various information according to instructions from the control unit 11. The input unit 14 and the display unit 15 may be a touch panel configured as an integrated unit, or the touch panel may be configured to be externally attached to the information processing device 10.

[0014] The reading unit 16 reads information stored in a portable storage medium 10a including a CD (Compact Disc), a DVD (Digital Versatile Disc), a USB (Universal Serial Bus) memory, an SD (Secure Digital) card, etc. The program 12P and various data stored in the storage unit 12 may be read by the control unit 11 from the portable storage medium 10a via the reading unit 16 and stored in the storage unit 12. In addition, the program 12P and various data may be written in the storage unit 12 during the manufacturing stage of the information processing device 10, or the control unit 11 may download them from another device via the communication unit 13 and store them in the storage unit 12.

[0015] In this embodiment, the information processing device 10 may be a multi-computer consisting of multiple computers, may be a virtual machine virtually constructed by software in one device, or may be a cloud server. The information processing device 10 does not necessarily require the input unit 14 and the display unit 15, and may be configured to accept operations through a connected computer, or may be configured to output information to be displayed to an external display device. The program 12P may be executed on a single computer, or may be executed on multiple computers connected to each other via a network.

[0016] The information processing device 10 having the above-mentioned configuration performs a process of predicting the relationship between two consecutive sentences (sentences) in a sentence including a plurality of sentences, for example. Specifically, the information processing device 10 predicts whether the space between the two sentences (sentences) is a paragraph break, a section break, a chapter break, or no break. The information processing device 10 of this embodiment uses a learning model 12a when predicting the relationship between the two sentences (sentences).

[0017] FIG. 2 is an explanatory diagram of the learning model 12a, FIG. 2A shows a configuration example of the learning model 12a, and FIG. 2B shows input data of the learning model 12a. FIG. 3 is an explanatory diagram showing a configuration example of the tokenizer 12b. The learning model 12a is trained to receive a combination of a first sentence and a second sentence as input, perform a calculation to determine the relationship between the first sentence and the second sentence (whether it is a paragraph break, a section break, or a chapter break, or whether it is not a break) based on the input sentence, and output the calculation result (relationship information indicating the relationship between the first sentence and the second sentence). The learning model 12a is, for example, BERT. BERT is a natural language processing model using bidirectional encoding representation by Transformers, and is configured by connecting Transformer Encoders in a network shape. In addition, the learning model 12a may be composed of algorithms such as BERT, LSTM (Long Short Term Memory), RNN (Recurrent Neural Network), GPT (Generative Pre-trained Transformer), SVM (Support Vector Machine), Seq2Seq (Sequence to Sequence), Random Forest, and Decision Tree, or may be composed of a combination of multiple algorithms.

[0018] The learning model 12a has an input layer to which a combination of a first sentence and a second sentence is input, an intermediate layer to perform calculations based on the data of the input sentences, and an output layer to output relationship information indicating the relationship between the first sentence and the second sentence based on the calculation results of the intermediate layer. The input layer has input nodes to which each token obtained by dividing the input data according to a predetermined rule is input. As shown in FIG. 2B, the input data includes a CLS token, which is a special token indicating the beginning of a sentence (input data), a first sentence, an SEP token, which is a special token indicating the end of the first sentence, a second sentence, and an SEP token, which is a special token indicating the end of the second sentence, in this order. The CLS token and the SEP token are data for one token. The first sentence and the second sentence are divided into multiple tokens as shown in each rectangular frame at the bottom of FIG. 2B. The first sentence and the second sentence are divided into each token using a tokenizer 12b prepared for each type of the learning model 12a. As shown in Fig. 3, when, for example, one sentence is input, the tokenizer 12b divides the input sentence into units such as words, morphemes, and phrases. In Fig. 3, a rectangular frame of the input data indicates one sentence, and a rectangular frame of the output data indicates each one token divided from the sentence. The units of tokens divided by the tokenizer 12b are not limited to words, morphemes, and phrases, and can be character strings divided by a division method (predetermined rule) suitable for the input of the corresponding learning model 12a.

[0019] The learning model 12a in this embodiment is a model with an upper limit on the number of tokens that can be input, and for example, a model with a maximum number of tokens that can be input of 512 is used. In this case, the input data of the learning model 12a includes 509 tokens of the first sentence and the second sentence excluding the CLS token and two SEP tokens. In this embodiment, half of the 509 tokens, that is, 254 tokens, are used as tokens for the first sentence, and 255 tokens are used as tokens for the second sentence. Note that the number of tokens for the first sentence and the number of tokens for the second sentence are not limited to this, and the number of tokens for the first sentence may be 255 and the number of tokens for the second sentence may be 254. That is, in this embodiment, the SEP token (separator) inserted between the first sentence and the second sentence is fixed at approximately the center position (near the center position, close to the center position) of the maximum number of tokens that can be input, and the tokens of the first sentence are inserted in front of this SEP token, and the tokens of the second sentence are inserted in the rear of this SEP token, and this data is used as input data for the learning model 12a.

[0020] The intermediate layer of the learning model 12a calculates a vector corresponding to each token input from the input layer using various functions and thresholds. The output layer has four output nodes corresponding to the respective relationships between the input first and second sentences. In the example of FIG. 2A, output node 0 outputs the probability (certainty) that the space between the first and second sentences should be determined to be a paragraph break (break of a paragraph), output node 1 outputs the probability (certainty) that the space should be determined to be a section break (break of a section), output node 2 outputs the probability (certainty) that the space should be determined to be a chapter break (break of a chapter), and output node 3 outputs the probability (certainty) that the space should be determined to be other (for example, not a break). The output value from each output node is, for example, a value between 0 and 1, and the sum of the probabilities output from each output node is 1.0 (100%).

[0021] With the above-mentioned configuration, the learning model 12a outputs an output value (certainty of each relationship) indicating the relationship between the first sentence and the second sentence when data is input in which the SEP token inserted between the first sentence and the second sentence is fixed at the approximate center position of the maximum number of tokens that can be input, and the token of the first sentence is inserted before this SEP token and the token of the second sentence is inserted after it. The information processing device 10 specifies the output node that outputs the maximum output value (certainty) among the output values ​​from each output node in the above-mentioned learning model 12a, and determines the relationship (delimiter) associated with the specified output node as the relationship (delimiter) between the input first sentence and the second sentence. The output layer of the learning model 12a may have a configuration having one output node that outputs information indicating the relationship (delimiter) with the maximum degree of certainty, instead of having multiple output nodes as described above. In addition, the relationship predicted by the learning model 12a is not limited to the above-mentioned paragraphs, sections, and chapters, and may include other relationships (e.g., term delimiters), and may have a configuration having the number of output nodes to be predicted.

[0022] The learning model 12a can be generated by machine learning using training data including training input data and relationship information (correct answer label) indicating the relationship between a first sentence and a second sentence included in the input data. The training data is generated by extracting two consecutive sentences from a sentence having a paragraph break, a section break, or a chapter break, generating input data from the two extracted sentences, and adding a correct answer label to the generated input data indicating that the space between the two sentences is a paragraph break, a section break, or a chapter break, or that the space is not a break. The input data is generated by inserting a CLS token at the beginning, an SEP token at the center position and at the end, inserting a token obtained by dividing the previous sentence (first sentence) between the CLS token and the SEP token at the center position, and inserting a token obtained by dividing the subsequent sentence (second sentence) between the two SEP tokens.

[0023] Here, when the tokens obtained by dividing the previous sentence are inserted as tokens for the first sentence, if all the tokens cannot be inserted, the number of tokens that can be inserted is extracted from the end of the previous sentence and inserted between the CLS token and the SEP token at the center position. Specifically, if the number of tokens obtained by dividing the previous sentence is greater than the number of tokens for the first sentence (e.g., 254), the number of tokens for the first sentence is extracted from the end of the previous sentence and inserted. That is, the leading portion of the previous sentence that cannot be inserted as a token for the first sentence is removed from the input data. Similarly, when the tokens obtained by dividing the subsequent sentence are inserted as tokens for the second sentence, if all the tokens cannot be inserted, the number of tokens that can be inserted is extracted from the beginning of the subsequent sentence and inserted between the two SEP tokens. Specifically, if the number of tokens obtained by dividing the subsequent sentence is greater than the number of tokens for the second sentence (e.g., 255), the number of tokens for the second sentence is extracted from the beginning of the subsequent sentence and inserted. That is, the leading portion of the subsequent sentence that cannot be inserted as a token for the second sentence is removed from the input data. In this manner, in this embodiment, approximately the same number of tokens are extracted from two consecutive sentences, with the boundary between the two sentences as the criterion, and are used in the input data.

[0024] Also, when an empty space is generated when a token obtained by dividing the previous sentence is inserted as a token for the first sentence, the number of tokens that can be inserted in the empty space is extracted from the end of the sentence (the third sentence connected to the first sentence) that precedes the previous sentence, and inserted into the empty space between the CLS token and the SEP token at the center position. Specifically, when the number of tokens obtained by dividing the previous sentence is less than the number of tokens for the first sentence (for example, 254), the end of the previous sentence is used as a reference, and tokens are extracted from the previous sentence and the sentence that precedes it by the number of tokens for the first sentence and inserted. In other words, when an empty space is generated in the token for the first sentence with only the previous sentence, the sentence that precedes it is also included in the input data. Similarly, when an empty space is generated when a token obtained by dividing the latter sentence is inserted as a token for the second sentence, the number of tokens that can be inserted in the empty space is extracted from the beginning of the sentence that precedes the latter sentence (the fourth sentence connected to the second sentence) and inserted into the empty space between the two SEP tokens. Specifically, if the number of tokens into which the latter sentence is divided is less than the number of tokens for the second sentence (e.g., 255), the beginning of the latter sentence is used as a reference, and tokens of the number of tokens for the second sentence are extracted and inserted from the latter sentence as well as from the further succeeding sentence. In other words, if there is free space in the tokens for the second sentence with just the one latter sentence, the further succeeding sentence is also included in the input data. In this way, in this embodiment, from a sentence having multiple sentences, tokens with approximately the same number of tokens are extracted before and after the break between two consecutive sentences as a reference, and used in the input data.

[0025] The learning model 12a learns so that when input data included in the training data generated as described above is input, the output value from the output node corresponding to the correct label (relationship information) included in the training data approaches 1 and the output value from the other output node approaches 0. In the learning process, the learning model 12a performs calculations in the intermediate layer and the output layer based on the input data input, and calculates an output value from each output node. The learning model 12a compares the calculated output value of each output node with a value corresponding to the correct label (1 for the output node corresponding to the correct label, and 0 for the other output node), and optimizes parameters used in the calculation process in the intermediate layer and the output layer so that the two are close to each other. The parameters are weights (coupling coefficients) between nodes in the intermediate layer and the output layer, etc. The method of optimizing the parameters is not particularly limited, but the backpropagation method, the steepest descent method, etc. can be used. As a result, when input data is input, the learning model 12a is obtained, which predicts the relationship between the first sentence and the second sentence included in the input data and outputs the prediction result.

[0026] The information processing device 10 prepares such a learning model 12a in advance and uses it when determining the relationship between sentences in a document including multiple sentences. The learning of the learning model 12a may be performed by another learning device. The trained learning model 12a generated by training on the other learning device is downloaded from the learning device to the information processing device 10 via a network or a portable storage medium 10a, for example, and stored in the storage unit 12.

[0027] The process of generating the learning model 12a by learning the above-mentioned training data will be described below. Fig. 4 is a flowchart showing an example of the procedure of the process of generating the learning model 12a. The following process is executed by the control unit 11 of the information processing device 10 according to the program 12P stored in the storage unit 12, but may be executed by another learning device. In the following process, the control unit 11 first generates training data based on an arbitrary sentence, and uses the generated training data to train the learning model 12a.

[0028] The control unit 11 of the information processing device 10 acquires data of sentences used to generate training data (S11). The data of sentences may be obtained by downloading various sentences published via a network by the communication unit 13, or by reading sentences acquired in advance from another device and stored in the storage unit 12. Note that the sentences used to generate training data are preferably sentences that include multiple sentences and have clear paragraph breaks, section breaks, and chapter breaks. For example, a paragraph break can be determined as a break at a position where a predetermined number of spaces are inserted after a line break. For example, when a chapter number and a section number are present in a sentence, a chapter break and a section break can be determined as a break at a position where the chapter number and the section number are inserted. Furthermore, the sentences used to generate training data may be sentences in which an annotation person or the like has determined whether each sentence break in the sentence is a paragraph break, a section break, or a chapter break, and the determination result is added to each sentence break.

[0029] The control unit 11 extracts one sentence (first sentence) from the acquired text (S12). The control unit 11 performs a process of extracting each sentence in order from the beginning of the text, and here, extracts the first sentence of the text, specifically, the sentence from the beginning to the first comma. The control unit 11 divides the extracted first sentence into tokens using the tokenizer 12b (S13). Then, the control unit 11 extracts each token divided by the tokenizer 12b in order from the end of the first sentence, and inserts them into the input data as tokens for the first sentence (S14). Note that the control unit 11 inserts (fixes) a CLS token at the beginning and an SEP token at the center and end as input data for the learning model 12a, and inserts the tokens obtained by dividing the first sentence between the CLS token and the SEP token at the center. At this time, the control unit 11 inserts the number of tokens for the first sentence so that the token at the end of the first sentence is on the SEP token side. That is, the tokens of the first sentence are inserted between the CLS token and the SEP token in the center position, close to the SEP token side (right-justified). Therefore, if the number of tokens into which the first sentence is divided is greater than the number of tokens for the first sentence (e.g., 254), the control unit 11 excludes tokens (character strings) in the first sentence that precede the tokens (character strings) inserted as tokens for the first sentence from the input data.

[0030] On the other hand, if the number of tokens into which the first sentence is divided is less than the number of tokens for the first sentence (for example, 254), an empty area is generated in the tokens for the first sentence. Therefore, the control unit 11 judges whether or not there is an empty area (S15), and if it judges that there is an empty area (S15: YES), it extracts the sentence (third sentence) before the first sentence extracted in step S12 (S16). Then, the control unit 11 executes the process of steps S13 to S14 on the extracted previous sentence. That is, the control unit 11 divides the third sentence into tokens using the tokenizer 12b (S13), extracts each divided token in order from the end of the third sentence, and inserts it into the input data as a token for the first sentence (S14). Here, the control unit 11 inserts the tokens into which the third sentence is divided into the empty area of ​​the token for the first sentence. Then, the control unit 11 judges whether or not there is an empty area in the token for the first sentence (S15), and repeats the processing of steps S13 to S16 until it is judged that there is no empty area. As a result, one sentence (first sentence) is extracted from the sentence to be processed as the first sentence included in the training input data, and if the first sentence alone is not enough to satisfy the token for the first sentence, the sentence before the first sentence (third sentence) is extracted, and each token obtained by dividing the extracted sentence is used as the token for the first sentence. Note that if there is no sentence before the first sentence, for example, if the first sentence extracted in step S12 is the first sentence, the control unit 11 may skip the processing of steps S15 to S16. In this case, even if an empty area occurs in the token for the first sentence, it may be left as an empty area, or a special token indicating a blank may be inserted into the empty area. Note that the SEP token inserted at the approximately center position of the input data is not necessarily limited to a configuration fixed to the center position. For example, if there is no sentence before the first sentence, the empty space in the token for the first sentence may be moved toward the beginning of the input data, and the SEP token fixed at the center position may also be moved toward the beginning, and the remaining space may be used for the token for the second sentence. In this case, when there are only a few sentences to be inserted as the first sentence, the number of tokens that can be input can be used effectively by using the empty space for the token for the second sentence.

[0031] When it is determined that there is no free space in the token for the first sentence (S15: NO), the control unit 11 identifies a break between the first sentence extracted in step S12 and the next sentence (second sentence) (S17). Here, the control unit 11 determines whether the space between the two sentences is a paragraph break, a section break, a chapter break, or not a break. For example, the control unit 11 determines that the space is a paragraph break when there is a line break after the first sentence and a space of a predetermined number of characters (for example, one character) is inserted after the line break. The control unit 11 also determines that the space is a chapter break or a section break when a chapter number or a section number is inserted after the first sentence. Furthermore, when information indicating a paragraph break, a section break, or a chapter break is added to the break between each sentence in the text, the control unit 11 determines that the space between the two sentences is a paragraph break, a section break, a chapter break, or not a break from the added information.

[0032] Next, the control unit 11 extracts the next sentence (second sentence) (S18). Here, the control unit 11 extracts a sentence from the comma to the next comma of the sentence extracted in step S12. Then, the control unit 11 divides the extracted second sentence into tokens using the tokenizer 12b (S19), extracts each divided token in order from the beginning of the second sentence, and inserts them into the input data as tokens for the second sentence (S20). Here, the control unit 11 inserts the tokens obtained by dividing the second sentence between two SEP tokens. At this time, the control unit 11 inserts the number of tokens for the second sentence so that the token at the beginning of the second sentence is on the side of the SEP token at the center position. That is, the tokens of the second sentence are inserted between the two SEP tokens, close to the side of the SEP token at the center position (left-justified). Therefore, if the number of tokens into which the second sentence is divided is greater than the number of tokens for the second sentence (e.g., 255), the control unit 11 excludes from the input data any tokens (character strings) in the second sentence that come after the token (character string) inserted as a token for the second sentence.

[0033] On the other hand, if the number of tokens into which the second sentence is divided is less than the number of tokens for the second sentence (for example, 255), an empty area is generated in the tokens for the second sentence. Therefore, the control unit 11 judges whether or not there is an empty area (S21), and if it judges that there is an empty area (S21: YES), it extracts the next sentence (fourth sentence) of the second sentence extracted in step S18 (S22). Then, the control unit 11 executes the process of steps S19 to S20 for the next sentence extracted. That is, the control unit 11 divides the fourth sentence into tokens using the tokenizer 12b (S19), extracts each divided token in order from the beginning of the fourth sentence, and inserts it into the input data as a token for the second sentence (S20). Here, the control unit 11 inserts the tokens into which the fourth sentence is divided into the empty area of ​​the token for the second sentence. Then, the control unit 11 judges whether or not there is an empty space in the token for the second sentence (S21), and repeats the processing of steps S19 to S22 until it is judged that there is no empty space. As a result, one sentence (second sentence) is extracted from the sentence to be processed as the second sentence included in the training input data, and if the second sentence alone is not enough to satisfy the token for the second sentence, the sentence next to the second sentence (fourth sentence) is extracted, and each of the extracted tokens is used as the token for the second sentence. Note that if there is no sentence next to the second sentence, for example, if the second sentence extracted in step S18 is the last sentence, the control unit 11 may skip the processing of steps S21 to S22. In this case, even if an empty space occurs in the token for the second sentence, it may be left as it is, or a special token indicating a space may be inserted into the empty space.

[0034] When it is determined that there is no free space in the token for the second sentence (S21: NO), the control unit 11 fixes the CLS token at the beginning and the SEP token at the center and end, and then generates training data by assigning a correct label according to the break specified in step S17 to the input data including the token for the first sentence inserted in step S14 and the token for the second sentence inserted in step S20, and stores the training data in the storage unit 12 (S23). Specifically, if the specified break is a paragraph break, the control unit 11 assigns a correct label indicating a paragraph break to the input data, if the specified break is a section break, assigns a correct label indicating a section break to the input data, if the specified break is a chapter break, assigns a correct label indicating a chapter break to the input data, and if the specified break is not a break, assigns a correct label indicating other to the input data. The control unit 11 stores the generated training data in, for example, a training DB (not shown) prepared in the storage unit 12.

[0035] The control unit 11 judges whether or not there is an unprocessed sentence that has not been used to generate training data in the sentences acquired in step S11 (S24). When it is judged that there is an unprocessed sentence (S24: YES), the control unit 11 returns to the process of step S12 and performs the processes of steps S12 to S23 on the unprocessed sentence. In addition, in this step S12, the control unit 11 extracts the second sentence extracted in the most recent step S18 as the first sentence. As a result, the second sentence included in the most recently generated training data becomes the first sentence included in the training data to be generated next, and the training data is generated with the sentence next to this first sentence as the second sentence. The control unit 11 repeats the processes of steps S12 to S24 until it judges that there is no unprocessed sentence. As a result, based on the input data including the first sentence and the second sentence extracted from the sentences acquired for generating the training data and the information indicating the relationship between the first sentence and the second sentence, training data to be used for learning the learning model 12a is generated and stored in the training DB.

[0036] When the control unit 11 determines that there is no unprocessed sentence (S24: NO), the control unit 11 performs learning of the learning model 12a using the training data stored in the training DB as described above. The control unit 11 reads out one of the training data stored in the training DB by the above-mentioned processing (S25). Then, the control unit 11 performs learning processing of the learning model 12a based on the read training data (S26). Here, the control unit 11 inputs input data included in the training data to the learning model 12a, and obtains an output value output from the learning model 12a by inputting the input data. The control unit 11 compares the output value of each output node output from the learning model 12a with a value corresponding to the correct label included in the training data (1 for the output node corresponding to the correct label, and 0 for the other output nodes), and trains the learning model 12a so that the two are close to each other. In the learning processing, the learning model 12a optimizes parameters used for arithmetic processing in the intermediate layer and the output layer. For example, the control unit 11 optimizes parameters such as weights (coupling coefficients) between nodes in the intermediate layer and the output layer using an error backpropagation method that sequentially updates parameters from the output layer to the input layer of the learning model 12a.

[0037] The control unit 11 judges whether there is unprocessed training data that has not been subjected to learning processing among the training data stored in the training DB (S27). If it is judged that there is unprocessed training data (S27: YES), the control unit 11 returns to the processing of step S25 and performs the processing of steps S25 to S26 on the training data that has not been subjected to learning processing. If it is judged that there is no unprocessed training data (S27: NO), the control unit 11 ends the series of processing.

[0038] By the above-mentioned learning process, when the input data having the above-mentioned configuration is input, a learning model 12a is generated that outputs an output value indicating the possibility that the relationship between the first sentence and the second sentence included in the input data is a paragraph break, a section break, or a chapter break, or the possibility that it is not a break. Therefore, by using the learning model 12a, the information processing device 10 can obtain information (certainty for each relationship) regarding whether the relationship between the first sentence and the second sentence included in the above-mentioned input data is a paragraph break, a section break, a chapter break, or not a break. In the above-mentioned process, the generation process of the training data by steps S11 to S24 and the generation process of the learning model 12a by steps S25 to S27 may be performed by different devices. The learning model 12a is a pre-trained model, and the learning model 12a of this embodiment can be constructed by fine-tuning it by the above-mentioned learning process.

[0039] The following describes a process for estimating the relationship between adjacent sentences in a document having multiple sentences in the information processing device 10 of this embodiment. Fig. 5 is a flowchart showing an example of the process procedure for estimating the relationship between sentences, Fig. 6 is an explanatory diagram of the estimation process, and Fig. 7 is an explanatory diagram showing an example screen. In this embodiment, the breaks between paragraphs, sections, and chapters are estimated as the relationship between sentences.

[0040] The control unit 11 of the information processing device 10 acquires data of a sentence to be processed (S31). The data of the sentence to be processed is assumed to be acquired, for example, via a network or a portable storage medium 10a and stored in the storage unit 12, and here, the control unit 11 reads out the data of the sentence stored in the storage unit 12. FIG. 6A shows an example of the sentence to be processed (the sentence before processing), and the sentence to be processed is a plain sentence including a plurality of sentences and without line breaks, paragraph breaks, section breaks, chapter breaks, etc. inserted therein. Note that the sentence to be processed may have line breaks, etc. inserted in some parts. The data of the sentence to be processed may also be text data of the speech content generated by performing speech recognition processing on speech data uttered by a speaker, for example.

[0041] The control unit 11 performs the same processing as steps S12 to S16 in Fig. 4 on the acquired sentence (S32 to S36). Specifically, the control unit 11 extracts a first sentence from the sentence (S32), divides the first sentence into tokens using the tokenizer 12b (S33), extracts each token in order from the end of the first sentence, and inserts them into the input data as tokens for the first sentence (S34). Again, the control unit 11 inserts (fixes) a CLS token at the beginning and SEP tokens at the center and end of the input data to be input to the learning model 12a in order to estimate the relationship between the sentences, and inserts the tokens obtained by dividing the first sentence between the CLS token and the SEP token at the center. Then, the control unit 11 judges whether or not there is an empty space in the token for the first sentence (S35), and if it judges that there is an empty space (S35: YES), it extracts the sentence (third sentence) before the first sentence extracted in step S32 (S36), and executes the processing of steps S33 to S34 on the extracted third sentence. This makes it possible to generate input data including, as the first sentence, the first sentence extracted from the sentence to be processed, and the third sentence before the first sentence if the token for the first sentence cannot be filled with the first sentence alone. Here again, if there is no sentence before the first sentence, the control unit 11 may skip the processing of steps S35 to S36, and if an empty space occurs in the token for the first sentence, it may leave it as an empty space, or may insert a special token indicating a space into the empty space.

[0042] When it is determined that there is no free space in the token for the first sentence (S35: NO), the control unit 11 performs the same process as steps S18 to S22 in Fig. 4 (S37 to S41). Specifically, the control unit 11 extracts the second sentence following the first sentence (S37), divides the second sentence into tokens using the tokenizer 12b (S38), extracts each token in order from the beginning of the second sentence, and inserts them into the input data as tokens for the second sentence (S39). Here, the control unit 11 inserts the tokens obtained by dividing the second sentence between two SEP tokens in the input data. Then, the control unit 11 judges whether or not there is an empty space in the token for the second sentence (S40), and if it judges that there is an empty space (S40: YES), it extracts the sentence (fourth sentence) next to the second sentence extracted in step S37 (S41), and executes the processing of steps S38 to S39 on the extracted fourth sentence. This makes it possible to generate input data including, as the second sentence, the second sentence extracted from the sentence to be processed, and the fourth sentence next to the second sentence if the token for the second sentence cannot be filled with the second sentence alone. Here again, if there is no sentence next to the second sentence, the control unit 11 may skip the processing of steps S40 to S41, and if an empty space occurs in the token for the second sentence, it may leave it as an empty space, or may insert a special token indicating a space into the empty space.

[0043] When it is determined that there is no free space in the token for the second sentence (S40: NO), the control unit 11 fixes the CLS token at the beginning and the SEP token at the center and end, and estimates the boundary between the first sentence and the second sentence contained in the input data based on the input data including the token for the first sentence inserted in step S34 and the token for the second sentence inserted in step S39 (S42). Specifically, the control unit 11 inputs the generated input data to the learning model 12a and acquires output values ​​from each output node of the learning model 12a. The control unit 11 identifies the output node that outputs the maximum output value from the acquired output values, and identifies the boundary associated with the identified output node as the boundary between the first sentence and the second sentence here.

[0044] The control unit 11 stores the estimation result in the storage unit 12 (S43). For example, the control unit 11 assigns identification information (for example, a sentence ID) to each sentence extracted from the sentence to be processed, and stores the delimiter of the estimation result in the storage unit 12 in association with, for example, the sentence ID of the second sentence. The control unit 11 judges whether or not there is an unprocessed sentence for which the above-mentioned estimation process has not been performed in the sentence acquired in step S31 (S44). If it is judged that there is an unprocessed sentence (S44: YES), the control unit 11 returns to the process of step S32 and performs the processes of steps S32 to S43 on the unprocessed sentence. Note that in this step S32, the control unit 11 extracts the second sentence extracted in the most recent step S37 as the first sentence. As a result, the second sentence in the most recent estimation process becomes the first sentence in the next estimation process, and in the next estimation process, the relationship between this first sentence and the second sentence following this first sentence is estimated.

[0045] The control unit 11 repeats the processing of steps S32 to S44 until it is determined that there is no unprocessed sentence, and when it is determined that there is no unprocessed sentence (S44: NO), it creates a sentence reflecting the estimation result for each sentence stored in step S43 (S45). FIG. 6B shows an example of a sentence reflecting the estimation result, and the control unit 11 creates a sentence as shown in FIG. 6B from the sentence to be processed as shown in FIG. 6A based on the result of the estimation process for each sentence. In the sentence shown in FIG. 6B, for example, a line break is inserted at the location of the paragraph break, and a space of one character is inserted at the beginning of the sentence immediately after the paragraph break. In addition, a chapter number such as Chapter 1, Chapter 2, etc. is inserted at the location of the chapter break, and a section number such as Section 1, Section 2, etc. is inserted at the location of the section break. Note that a space of one character may be inserted before the section number.

[0046] The control unit 11 displays the text reflecting the estimation result on the display unit 15 (S46). For example, the control unit 11 displays a screen as shown in FIG. 7A on the display unit 15 and presents it to the user of the information processing device 10. The screen shown in FIG. 7A displays the text reflecting the estimation result, and is provided with a save button, a send button, and a print button as operation buttons for processes that can be executed on the displayed text. When the save button is operated, the control unit 11 stores the displayed text in the storage unit 12, when the send button is operated, the control unit 11 transmits the displayed text to a specified device, and when the print button is operated, the control unit 11 transmits the displayed text to a printer with which the information processing device 10 can communicate and executes a print process. This makes it possible to provide a text reflecting the estimation result by the process desired by the user.

[0047] The screen shown in FIG. 7A is configured to accept correction of paragraph breaks, section breaks, or chapter breaks for the text being displayed, and an edit button is provided. When the edit button is operated, the control unit 11 displays an edit screen as shown in FIG. 7B on the display unit 15. In the edit screen shown in FIG. 7B, the paragraph breaks, section breaks, and chapter breaks in the text are underlined, and when a selection operation (e.g., right-click) is performed on the underlined parts, a menu field is displayed in which either a paragraph break, a section break, a chapter break, or no break can be selected. When one of them is selected via the menu field, the control unit 11 updates the paragraph breaks, section breaks, and chapter breaks in the text on the edit screen of FIG. 7B according to the selected content. When a selection operation (e.g., right-click) is performed on any comma in the text on the edit screen (arrow A in FIG. 7B), a similar menu field is displayed, and a correction instruction to a paragraph break, section break, or chapter break can be received via the menu field for a part determined to be no break. The editing screen has an end editing button for instructing the user to end the editing process. When the end editing button is operated, the control unit 11 ends the display of the editing screen, returns to the display of the screen in FIG. 7A, and displays the edited text.

[0048] The above-mentioned process makes it possible to insert paragraph breaks, section breaks, and chapter breaks between each sentence in a plain sentence having a plurality of sentences, and to provide a sentence that is easy to read and understand. In addition, for example, when extracting an important part in a sentence, it is possible to specify a sentence to be extracted together with the important sentence by estimating the relationship between a sentence determined to be an important sentence and the sentences before and after it. In addition, in the input data of the learning model 12a, the SEP token for separating two sentences is fixed at a substantially central position of the input data, so that the two sentences input to the learning model 12a are of approximately the same amount. In the conventional technology for analyzing a sentence using BERT, input data in which an SEP token is inserted between two sentences is also input to BERT. However, since the input length of the two sentences is not taken into consideration, when the earlier sentence is long, the proportion of the earlier sentence in the input data becomes large, and the area in which the later sentence is inserted becomes small. With such input data, there are cases where the amount of context information that contributes to the sentence analysis result cannot be sufficiently learned for the later sentence, and when such input data is used, there are cases where appropriate sentence analysis cannot be realized. In contrast, in this embodiment, by balancing the sentence lengths (input lengths) of the two sentences input to the learning model 12a, it is possible to realize sentence analysis processing that makes maximum use of the context information of the two sentences, thereby making it possible to appropriately estimate the breaks between each sentence.

[0049] In this embodiment, when the number of tokens divided from the first sentence is greater than the number of tokens for the first sentence in the input data, a token is extracted from the end of the first sentence and inserted into the input data as a token for the first sentence, but this is not limited to the configuration. For example, a token may be extracted from the beginning of the first sentence and inserted into the input data as a token for the first sentence. In this configuration, the relationship between the two sentences can be estimated using data (sentences) at the beginning of each of the first sentence and the second sentence. In addition, when the number of tokens divided from the second sentence is greater than the number of tokens for the second sentence in the input data, in addition to the configuration of extracting a token from the beginning of the second sentence and inserting it into the input data as a token for the second sentence, a configuration of extracting a token from the end of the second sentence and inserting it into the input data as a token for the second sentence may be used.

[0050] In this embodiment, when text data of the speech content generated from voice data uttered by a speaker is used as the sentence to be processed, it is possible to generate sentences with paragraph breaks, section breaks, and chapter breaks inserted from voice data recorded at a lecture, for example, making it possible to create minutes of meetings that are easy to read and understand.

[0051] FIG. 8 is an explanatory diagram showing a modified example of the learning model 12a. The learning model 12a of this embodiment is configured to determine whether the space between the first sentence and the second sentence included in the input data is a paragraph break, a section break, a chapter break, or no break, but is not limited to such a configuration. For example, the learning model 12a may be configured to determine whether the space between the first sentence and the second sentence included in the input data is a paragraph break or not, as shown in FIG. 8. In the example of FIG. 8, the output layer of the learning model 12a has two output nodes, and the output node 0 outputs the probability (confidence) that the space between the first sentence and the second sentence should be determined to be a paragraph break, and the output node 1 outputs the probability (confidence) that the space between the first sentence and the second sentence should not be determined to be a paragraph break. In the configuration shown in FIG. 8, the output value from each output node is, for example, a value between 0 and 1, and the sum of the probabilities output from each output node is 1.0. In the case of the configuration shown in FIG. 8, for example, the learning model 12a may be generated for determining a paragraph break, for determining a section break, and for determining a chapter break.

[0052] (Embodiment 2) In this embodiment, an information processing device that excludes predetermined words and phrases from input targets in a first sentence and a second sentence to be included in the input data of the learning model 12a will be described. The information processing device of this embodiment has a similar configuration to the information processing device 10 of the first embodiment shown in Fig. 1, so a description of the configuration will be omitted. In the information processing device 10 of this embodiment, the storage unit 12 stores an exclusion target DB in which excluded targets (filtered targets) words and phrases (character strings) that are not to be included in the input data of the learning model 12a are registered.

[0053] FIG. 9 is an explanatory diagram showing an example of a record layout of an exclusion target DB. For example, as shown in FIG. 9, the exclusion target DB stores the types of words to be excluded in association with various words. In the example of FIG. 9, particles, periods, and nouns are registered as exclusion targets, but are not limited to these. For example, words (character strings) that have no meaning when divided into one token, words (character strings) that have a low contribution to the learning model 12a estimating the relationship between two sentences, words (character strings) that have a low contribution to the learning model 12a performing effective learning, and the like can be registered as exclusion targets.

[0054] Fig. 10 is a flowchart showing an example of a generation process procedure for the learning model 12a of the second embodiment. The process shown in Fig. 10 is obtained by adding steps S51 to S54 instead of step S14 and steps S55 to S58 instead of step S20 in the process shown in Fig. 4. Explanations of the same steps as in Fig. 4 will be omitted. Note that steps S11 to S12, S17 to S18, and S23 to S27 in Fig. 4 are not shown in Fig. 10.

[0055] In the information processing device 10 of this embodiment, the control unit 11 executes the process of steps S11 to S13 in FIG. 4. Then, the control unit 11 extracts one token obtained by dividing the first sentence from the end of the first sentence (S51), and judges whether the extracted token is an object to be excluded (S52). Here, the control unit 11 judges whether the phrase (character string) of the extracted token is stored in the exclusion object DB. If it is judged to be an object to be excluded (S52: YES), the control unit 11 returns to the process of step S51, extracts the next token (S51), and judges whether the extracted token is an object to be excluded (S52). If it is judged not to be an object to be excluded (S52: NO), the control unit 11 inserts the extracted token into the input data as a token for the first sentence (S53). Note that the control unit 11 inserts tokens that are not objects to be excluded between the CLS token and the SEP token at the center so that the token at the end of the first sentence is on the SEP token side. The control unit 11 determines whether or not there are any unprocessed tokens that have not been extracted from the tokens divided in step S13 (S54). If it is determined that there are unprocessed tokens (S54: YES), the control unit 11 returns to the process of step S51. If it is determined that there are no unprocessed tokens (S54: NO), the control unit 11 proceeds to the process of step S15. Then, if there is free space in the token for the first sentence, the sentence before the first sentence is divided into tokens and inserted into the token for the first sentence.

[0056] Similarly, after the process of step S19, the control unit 11 extracts one token obtained by dividing the second sentence from the beginning of the second sentence (S55), and judges whether or not the extracted token is to be excluded (S56). If it is judged to be the object of exclusion (S56: YES), the control unit 11 returns to the process of step S55, extracts the next token (S55), and judges whether or not the extracted token is to be excluded (S56). If it is judged not to be the object of exclusion (S56: NO), the control unit 11 inserts the extracted token into the input data as a token for the second sentence (S57). Note that the control unit 11 inserts the tokens that are not to be excluded between the two SEP tokens so that the token at the beginning of the second sentence is on the side of the SEP token at the center position. The control unit 11 judges whether or not there is an unprocessed token that has not been extracted in the tokens divided in step S19 (S58). If it is determined that there is an unprocessed token (S58: YES), the control unit 11 returns to the process of step S55. If it is determined that there is no unprocessed token (S58: NO), the control unit 11 proceeds to the process of step S21. Then, if there is free space in the token for the second sentence, the sentence following the second sentence is divided into tokens and inserted into the token for the second sentence.

[0057] In the present embodiment, the above-described process can exclude words and phrases that are registered in the excluded target DB in advance from the input data used for learning the learning model 12a. Therefore, by registering words and phrases (character strings) that have a low contribution to the estimation process using the learning model 12a as excluded targets, training data using words and phrases that have a high contribution to the estimation process can be generated. By using such training data, it becomes possible to efficiently execute learning of the learning model 12a.

[0058] Fig. 11 is a flowchart showing an example of an estimation process procedure according to the second embodiment. The process shown in Fig. 11 is obtained by adding steps S61 to S64 instead of step S34 and steps S65 to S68 instead of step S39 in the process shown in Fig. 5. Explanations of the same steps as in Fig. 5 will be omitted. Note that steps S31 to S32 and S42 to S46 in Fig. 5 are not shown in Fig. 11.

[0059] In the information processing device 10 of this embodiment, the control unit 11 executes the process of steps S31 to S33 in Fig. 5. Then, the control unit 11 performs the same process as steps S51 to S54 in Fig. 10 (S61 to S64). Specifically, the control unit 11 extracts one token obtained by dividing the first sentence from the end of the first sentence (S61), and judges whether the extracted token is to be excluded or not (S62). If the control unit 11 judges that the extracted token is to be excluded (S62: YES), it returns to the process of step S61, and if it judges that the extracted token is not to be excluded (S62: NO), it inserts the extracted token into the input data as a token for the first sentence (S63). Then, the control unit 11 determines whether or not there are any unprocessed tokens that have not been extracted from the tokens divided in step S33 (S64). If it determines that there are unprocessed tokens (S64: YES), it returns to the processing of step S61, and if it determines that there are no unprocessed tokens (S64: NO), it proceeds to the processing of step S35.

[0060] Similarly, after the process of step S38, the control unit 11 performs the same processes as steps S55 to S58 in FIG. 10 (S65 to S68). Specifically, the control unit 11 extracts one token obtained by dividing the second sentence from the beginning of the second sentence (S65), and judges whether or not the extracted token is to be excluded (S66). If the control unit 11 judges that the extracted token is to be excluded (S66: YES), the control unit 11 returns to the process of step S65, and if the control unit 11 judges that the extracted token is not to be excluded (S66: NO), the control unit 11 inserts the extracted token into the input data as a token for the second sentence (S67). Then, the control unit 11 judges whether or not there is an unprocessed token that has not been extracted in the tokens divided in step S38 (S68), and if it judges that there is an unprocessed token (S68: YES), the control unit 11 returns to the process of step S65, and if it judges that there is no unprocessed token (S68: NO), the control unit 11 proceeds to the process of step S40.

[0061] In the present embodiment, the above-described process allows the words registered in the excluded target DB to be excluded from the input data to be input to the learning model 12a in the estimation process using the learning model 12a. Therefore, by registering words (character strings) that have a low contribution to the estimation process using the learning model 12a as excluded targets, it becomes possible to execute the estimation process using words that have a high contribution to the estimation process. This allows the estimation process to be executed with high accuracy using the learning model 12a.

[0062] (Embodiment 3) In this embodiment, an information processing device is described that identifies the relationship between each sentence in a document based on the result of estimating the relationship between each sentence (paragraph breaks, section breaks, and chapter breaks) using a learning model 12a. The information processing device of this embodiment has a configuration similar to that of the information processing device 10 of the first embodiment shown in Fig. 1, so a description of the configuration is omitted. Note that in this embodiment, the generation of the learning model 12a can be achieved by the same process as that of Fig. 4.

[0063] Fig. 12 is a flowchart showing an example of an estimation process procedure according to the third embodiment. The process shown in Fig. 12 is obtained by adding steps S71 and S72 between steps S42 and S43 in the process shown in Fig. 5. Explanations of the same steps as in Fig. 5 will be omitted. Note that steps S31 to S41 and S44 to S46 in Fig. 5 are not shown in Fig. 12.

[0064] In the information processing device 10 of this embodiment, the control unit 11 executes the process of steps S31 to S42 in FIG. 5. As a result, for a combination of a first sentence and a second sentence in a sentence to be processed, a relationship between the two sentences (paragraph break, section break, chapter break, or no break) is estimated. Then, the control unit 11 judges whether or not to adopt the result estimated for each sentence so far according to a preset rule (S71). For example, in a sentence, each break of a paragraph break, a section break, and a chapter break rarely appear consecutively. When paragraph breaks appear consecutively, paragraphs with only one sentence occur frequently, and such sentences are highly likely to be inappropriate. Therefore, it is conceivable to set a rule that one paragraph contains a predetermined number (e.g., three) or more sentences. According to this rule, the control unit 11 can be configured to judge whether or not there is another sentence estimated as a paragraph break in a predetermined number (e.g., three) sentences before the estimated portion here when the estimation result in step S42 is a paragraph break, and to judge whether or not to adopt the estimation result according to the judgment result. Specifically, when it is determined that there is another sentence estimated as a paragraph break, the control unit 11 determines to adopt the estimation result for either the sentence at the estimated location here or the other sentence estimated as a paragraph break, and not to adopt the estimation result for the other sentence. The sentence for which the estimation result is adopted may be the sentence that appears first, the sentence that appears later, or the sentence that has a larger output value (confidence level for the paragraph break that is the estimated result) output by the learning model 12a when estimated as a paragraph break. In addition, the control unit 11 may determine the relationship between the two sentences using the learning model 12c that determines whether the relationship between the two sentences is an implication relationship, a contradiction relationship, a consecutive relationship, or the like when two sentences are input, as in the learning model 12c of the fifth embodiment described later, and determine which of the estimation results for the sentence to adopt based on the determination result.

[0065] It is also possible to set a rule that one section or chapter includes multiple paragraphs. According to this rule, when the estimation result in step S42 is a section break or a chapter break, the control unit 11 can be configured to determine whether or not the section between the sentence immediately before the estimated location here and the sentence before that is estimated to be a section break or a chapter break, and to determine whether or not to adopt the estimated result according to the determination result. Specifically, when the section between the sentence immediately before and the sentence before that is estimated to be a section break or a chapter break, the control unit 11 determines to adopt the estimated result for either the sentence at the estimated location here or the sentence immediately before, and not to adopt the estimated result for the other. Here again, the sentence whose estimated result is adopted may be the sentence that appears first or the sentence that appears later, or may be the sentence that has a larger output value (confidence for the estimated result) output by the learning model 12a when estimated to be a section break or a chapter break.

[0066] In the above-mentioned determination process, for example, the estimation results for each of a plurality of adjacent sentences are taken into consideration to determine which of the sentences is to be a delimiter. In addition, it may be determined whether or not to adopt the estimation result for each of the sentences without taking into consideration the estimation results for other sentences. For example, it may be configured to determine whether or not the output value (confidence for the estimation result) output by the learning model 12a when estimating the estimation result for each of the sentences is equal to or greater than a predetermined threshold (e.g., 0.5), and adopt the estimation result if it is equal to or greater than the predetermined threshold, and not adopt the estimation result if it is less than the predetermined threshold. At this time, for example, the estimation process may be performed once for each sentence in the text, the average confidence for the estimation results obtained in each estimation process may be calculated, and the average confidence may be set to the predetermined threshold, or the confidence that is in the top 20% of the confidence for each estimation result may be specified, and the specified confidence may be set to the predetermined threshold.

[0067] When the control unit 11 determines that the estimation result so far is to be adopted by the above-mentioned process (S71: YES), the control unit 11 proceeds to the process of step S43. In this case, the control unit 11 stores the result estimated in step S42 in the storage unit 12, which is the same process as in the first embodiment. On the other hand, when the control unit 11 determines that the estimation result so far is not to be adopted (S71: NO), the control unit 11 changes the estimation result for the portion (between sentences) for which the estimation result is determined not to be adopted by the above-mentioned process (S72). For example, the control unit 11 changes the estimation result for the portion estimated as a paragraph break to no break. In addition to changing to no break, the control unit 11 may change to a section break or chapter break, and changes to the content according to the estimation result for each surrounding sentence. Note that the control unit 11 maintains the estimation result for the portion for which the estimation result is determined to be adopted. As described above, by registering a predetermined rule in advance, the control unit 11 can specify whether or not to adopt the estimation result for each sentence according to the rule.

[0068] By the above-mentioned process, in this embodiment, it is possible to appropriately correct the relationship between each sentence in a text, which is estimated using the learning model 12a. For example, when consecutive parts (between each sentence) are estimated to have the same division, the relationship between each part can be appropriately corrected so as to satisfy a preset rule. Therefore, a text can be created in which paragraph divisions, section divisions, and chapter divisions are more appropriately specified.

[0069] The configuration of this embodiment can be applied to the information processing device 10 of the above-mentioned embodiments 1 and 2, and even when applied to the information processing device 10 of the embodiments 1 and 2, similar processing can be executed and similar effects can be obtained. Also, in this embodiment, the modified examples appropriately described in the above-mentioned embodiments 1 and 2 can be applied.

[0070] (Embodiment 4) In this embodiment, a learning model 12a is prepared for each type of sentence, and an information processing device is described that estimates the relationship between each sentence in a sentence using the learning model 12a corresponding to the type of sentence to be processed. The information processing device of this embodiment has a configuration similar to that of the information processing device 10 of the first embodiment shown in FIG. 1, so a description of the configuration is omitted. In this embodiment, a plurality of learning models 12a are stored in the storage unit 12, and each learning model 12a is stored in association with the type of sentence to be processed. Each learning model 12a can be generated based on each type of sentence by the same process as in FIG. 4.

[0071] Fig. 13 is a flowchart showing an example of an estimation process procedure according to the fourth embodiment. The process shown in Fig. 13 is obtained by adding steps S81 and S82 between steps S31 and S32 in the process shown in Fig. 5. Explanations of the same steps as in Fig. 5 will be omitted. Note that steps S44 to S46 in Fig. 5 are not shown in Fig. 13.

[0072] In the information processing device 10 of this embodiment, the control unit 11 executes the process of step S31 in FIG. 5. Then, the control unit 11 determines the type of the acquired text (S81). For example, the control unit 11 determines whether the text is a legal document, a recipe document (specification, etc.), a financial document (securities report, financial statement summary, analyst report, etc.), a paper, various documents published on the Web, a medical document (medical certificate, doctor's opinion, etc.), etc. The type to be determined is a type associated with the learning model 12a prepared in advance. Specifically, the format of each type of text is stored in the storage unit 12 in association with each of the above-mentioned types, and the control unit 11 identifies the type of the acquired text by comparing the acquired text with the format of each type of text. In addition, terms that appear frequently in each type of text may be stored in the storage unit 12, and the control unit 11 may identify terms that appear a predetermined number of times or more in the acquired text, and identify the type corresponding to the identified term.

[0073] The control unit 11 reads out the learning model 12a corresponding to the identified type of sentence from the storage unit 12 (S82), and proceeds to the process of step S32. In this embodiment, the control unit 11 estimates the boundary between the first sentence and the second sentence included in the input data in step S42, using the learning model 12a read out in step S82 (S42). Note that this embodiment is the same as the first embodiment, except that the learning model 12a used in the process of estimating the relationship between the sentences differs depending on the type of sentence to be processed, and therefore a description thereof will be omitted.

[0074] The configuration of this embodiment can be applied to the information processing device 10 of the above-mentioned embodiments 1 to 3, and even when applied to the information processing device 10 of the embodiments 1 to 3, similar processing can be executed and similar effects can be obtained. Also, in this embodiment, the modified examples appropriately described in the above-mentioned embodiments 1 to 3 can be applied.

[0075] (Embodiment 5) The information processing device 10 of the above-mentioned first to fourth embodiments is configured to estimate any one of paragraph breaks, section breaks, chapter breaks, and others (no breaks) as the relationship between each sentence in a text. In this embodiment, an information processing device that predicts any one of implication relationships, contradiction relationships, consecutive relationships, etc. as the relationship between each sentence in a text will be described. The information processing device of this embodiment has the same configuration as the information processing device 10 of the first embodiment shown in FIG. 1, so the description of the configuration will be omitted. In this embodiment, in addition to or instead of the learning model 12a, a learning model 12c is stored in the storage unit 12.

[0076] FIG. 14 is an explanatory diagram showing a configuration example of the learning model 12c. The learning model 12c of this embodiment has a configuration similar to that of the learning model 12a in the first to fourth embodiments, and the configuration of the input data input to the learning model 12c is the same as that of the input data input to the learning model 12a. The output layer of the learning model 12c has, for example, four output nodes, and in the example of FIG. 14A, the output node 0 outputs the probability (certainty) that the relationship between the first sentence and the second sentence included in the input data should be determined to be an implication relationship, the output node 1 outputs the probability (certainty) that the relationship should be determined to be a contradiction relationship, the output node 2 outputs the probability (certainty) that the relationship should be determined to be a consecutive relationship, and the output node 3 outputs the probability (certainty) that the relationship should be determined to be other. The output value from each output node is, for example, a value between 0 and 1, and the sum of the probabilities output from each output node is 1.0 (100%). The output layer of the learning model 12c may have a configuration having one output node that outputs information indicating a relationship with the highest degree of certainty instead of having multiple output nodes as described above. Furthermore, the relationships predicted by the learning model 12c are not limited to the relationships described above, but may include relationships such as forward connections, reverse connections, parallel connections, and contrasts, and may be configured to have as many output nodes as the number of objects to be predicted.

[0077] The learning model 12c can be generated by the same process as in FIG. 4. The training data used for learning the learning model 12c can be generated, for example, from a sentence in which the relationship between two consecutive sentences is predetermined, or a sentence in which a word (for example, a conjunction) capable of discriminating each relationship is used. For example, two consecutive sentences are extracted from such a sentence, input data is generated from the two extracted sentences, the relationship between the two sentences is specified for the generated input data, and a correct answer label indicating that the relationship between the two sentences is an implication relationship, a contradiction relationship, or a consecutive relationship, or a relationship other than that is assigned to the generated input data. Specifically, in step S17 in FIG. 4, the control unit 11 of the information processing device 10 specifies the relationship between the first sentence and the second sentence from among an implication relationship, a contradiction relationship, a consecutive relationship, and other relationships, instead of specifying a break between the first sentence and the second sentence. This makes it possible to generate training data as described above, and by performing learning using such training data, a learning model 12c is obtained that, when input data is input, predicts whether the relationship between a first sentence and a second sentence included in the input data is an implication relationship, a contradiction relationship, a consecutive relationship, or other relationships, and outputs a prediction result. Learning of the learning model 12c may also be performed by another learning device, and the trained learning model 12c generated by learning performed by the other learning device is downloaded from the learning device to the information processing device 10 via a network or a portable storage medium 10a and stored in the storage unit 12.

[0078] The information processing device 10 of the present embodiment can estimate the relationship between each sentence in a sentence using the learning model 12c by executing the same process as that in FIG. 5, and can provide a sentence reflecting the estimation result. In step S42 in FIG. 5, the control unit 11 inputs the input data generated in steps S32 to S41 into the learning model 12c, and estimates the relationship between the first sentence and the second sentence included in the input data based on the output value from each output node of the learning model 12c. Here, instead of identifying the break between the first sentence and the second sentence, the control unit 11 estimates any of an implication relationship, a contradiction relationship, a consecutive relationship, and others as the relationship between the first sentence and the second sentence. In addition, in step S45, the control unit 11 creates a sentence reflecting the estimation result by adding a mark or a message or the like according to the estimated relationship between each sentence in the sentence to be processed. By such a process, in the present embodiment, the relationship between each consecutive sentence in a sentence can be estimated and presented, so that a sentence in which the context of each sentence is easy to understand can be provided.

[0079] In this embodiment, the learning model used to estimate the relationship between each sentence in a text may be configured as shown in Fig. 14B by combining the configuration of the learning model 12a shown in Fig. 2A and the configuration of the learning model 12c shown in Fig. 14A. Fig. 14B shows an example of the configuration of the learning model 12d. The output layer of the learning model 12d shown in Fig. 14B has seven output nodes, and outputs the probability that the relationship between the first sentence and the second sentence included in the input data should be determined to be a paragraph break from output node 0, the probability that the relationship should be determined to be a section break from output node 1, the probability that the relationship should be determined to be a chapter break from output node 2, the probability that the relationship between the first sentence and the second sentence should be determined to be an implication relationship from output node 3, the probability that the relationship should be determined to be a contradiction relationship from output node 4, the probability that the relationship should be determined to be a consecutive relationship from output node 5, and the probability that the relationship should be determined to be other from output node 6. In the learning model 12d, the output value from each output node is, for example, a value between 0 and 1, and the sum of the probabilities output from each output node is 1.0. When the learning model 12d configured in this way is used, it is possible to collectively estimate whether the relationship between the first sentence and the second sentence included in the input data is a paragraph break, a section break, or a chapter break, or whether it is an implication relationship, a contradiction relationship, or a consecutive relationship.

[0080] The configuration of this embodiment can be applied to the information processing device 10 of the above-mentioned embodiments 1 to 4, and even when applied to the information processing device 10 of the embodiments 1 to 4, similar processing can be executed and similar effects can be obtained. Also, in this embodiment, the modified examples appropriately described in the above-mentioned embodiments 1 to 4 can be applied.

[0081] In the above-mentioned first to fifth embodiments, the input data of the learning model 12a is a sentence written in Japanese, but is not limited to this configuration. For example, a sentence written in English may be used as the input data. In this case, the learning model 12a may be configured with a BERT that supports English. Therefore, it is possible to insert paragraph breaks, section breaks, and chapter breaks into sentences written in foreign languages ​​such as English, and it is also possible to provide sentences that can present the relationship between each consecutive sentence.

[0082] The matters described in each embodiment can be combined with each other. In addition, the independent claims and dependent claims described in the claims can be combined with each other in any and all combinations regardless of the citation format. Furthermore, the claims use a format in which a claim cites two or more other claims (multiple claim format), but this is not limited to this. The claims may also be written in a format in which a multiple claim cites at least one other multiple claim (multi-multi claim).

[0083] The embodiments disclosed herein are illustrative in all respects and should not be considered as limiting. The scope of the present invention is defined by the claims, not by the above meaning, and is intended to include all modifications within the scope and meaning equivalent to the claims. [Explanation of symbols]

[0084] 10. Information processing device 11 Control section 12 Storage section 13. Communications Department 14 Input section 15 Display section 12a Learning Model 12b Tokenizer

Claims

1. acquiring a plurality of training data including combinations of a first sentence and a second sentence and relationship information indicating a relationship between the first sentence and the second sentence; A learning model is generated that uses a plurality of training data sets to output relationship information indicating a relationship between the first sentence and the second sentence when all or a part of the first sentence and the second sentence included in the training data are input, while fixing the position of a separator to be inserted between the first sentence and the second sentence in the center, regardless of the number of words in the first sentence and the second sentence. A model generation method in which processing is performed by a computer.

2. The separator is fixed at a central position, and a first sentence is entirely or partially inserted in front of the central position, and a second sentence is entirely or partially inserted in rear of the central position. The model generating method according to claim 1 , wherein the processing is executed by the computer.

3. inserting the first sentence from the end of the first sentence in a forward region starting from the central position toward the central position; The second sentence is inserted from the beginning of the second sentence in a rear area starting from the central position, while being moved toward the central position. The model generating method according to claim 2 , wherein the processing is executed by the computer.

4. if there is a free space when the entire first sentence is inserted, inserting a third sentence adjacent to the first sentence from the end of the third sentence into the free space; If there is a free space when the entire second sentence is inserted, the beginning of a fourth sentence continuing from the second sentence is inserted into the free space. The model generating method according to claim 2 or 3, wherein processing is executed by the computer.

5. The words to be filtered are stored in a storage unit; The words and phrases to be filtered that are included in the first sentence and the second sentence are excluded from the input objects of the learning model.

4. The model generating method according to claim 1, wherein the processing is executed by the computer.

6. Obtaining a combination of a first sentence and a second sentence; A learning model is trained to output relationship information indicating the relationship between a first sentence and a second sentence when the position of a separator to be inserted between the first sentence and the second sentence is fixed at the center and all or part of the first sentence and the second sentence are input, and a separator is inserted at the fixed center position, and all or part of the first sentence inserted before the separator and all or part of the second sentence inserted after the separator are input to obtain relationship information indicating the relationship between the first sentence and the second sentence. An information processing method in which processing is performed by a computer.

7. the learning model is trained to output relationship information indicating whether or not a portion between the first sentence and the second sentence is a paragraph break; Obtain a sentence to be processed that contains multiple sentences; Extracting two consecutive sentences from the sentence to be processed; Sequentially inputting all or part of the two extracted sentences into the learning model, and acquiring relationship information indicating whether the space between the two sentences is a paragraph break or not; Identifying which two sentences are to be a paragraph break based on whether or not the two sentences are a paragraph break The information processing method according to claim 6 , wherein the processing is executed by the computer.

8. Obtaining a combination of a first sentence and a second sentence; A learning model is trained to output relationship information indicating the relationship between a first sentence and a second sentence when the position of a separator to be inserted between the first sentence and the second sentence is fixed at the center and all or part of the first sentence and the second sentence are input, and a separator is inserted at the fixed center position, and all or part of the first sentence inserted before the separator and all or part of the second sentence inserted after the separator are input to obtain relationship information indicating the relationship between the first sentence and the second sentence. A program that causes a computer to carry out processing.

Citation Information

Patent Citations

  • Computer system, computer program and computer-implemented method (causal knowledge identification and extraction)

    JP2023002475A

  • Sentence analysis apparatus and program thereof

    JP2022177365A