Information processing device, information processing method, program, and computer-readable storage medium
The information processing device addresses the challenge of misrecognized characters in OCR processing by using a list of conversion rules to systematically convert character strings, reducing errors and the need for manual verification.
Patent Information
- Application Number
- JP2024010905
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Filing Date
- 2024-01-29
- Publication Date
- 2025-04-30
- Estimated Expiration
- 2044-01-29
AI Technical Summary
Existing OCR processing methods face challenges in accurately converting misrecognized characters due to variations in printing status and overlap between characters and background, often requiring manual verification to correct errors.
An information processing device is designed with a storage unit containing a list of conversion rules that associate strings with different numbers of characters, and a processing unit that sequentially matches these rules in ascending order of character count to convert misrecognized character strings into their correct forms.
This approach reduces erroneous conversions of character strings by systematically applying conversion rules based on character count, thereby minimizing the need for manual verification and improving the accuracy of OCR processing.
Smart Images

Figure 0007670882000001_ABST
Abstract
Description
[Technical field]
[0001] The present disclosure relates to an information processing device, an information processing method, a program, and a computer-readable storage medium, and, for example, to a technique for converting characters that are erroneously recognized in character recognition processing of image data of a document. [Background technology]
[0002] There is a known method of applying, for example, optical character recognition (OCR) processing to image data obtained by reading a document with a device such as a camera or scanner, and outputting recognized character data (for example, text data). Such character recognition processing can be used, for example, to digitize documents printed on paper to promote paperless operations. [Prior art documents] [Patent documents]
[0003] [Patent Document 1] Japanese Patent Application Publication No. 9-138836 Summary of the Invention [Problem to be solved by the invention]
[0004] In OCR processing, misrecognition of characters can occur due to the printing condition of characters in image data (hereinafter sometimes referred to as "document image") obtained by reading a document with a device such as a camera or scanner, or due to overlapping of characters with a background image, resulting in the generation of erroneous character data.
[0005] As an example of a method for correcting an erroneously recognized character string, a conversion list that specifies the correspondence between a correct character string and an erroneously recognized character string is prepared in advance (for example, Patent Document 1). In this method, the conversion list is used to mechanically convert an erroneously recognized character string into a correct character string in post-OCR processing.
[0006] However, for example, when the above-mentioned conversion list is mechanically applied to each word having a different number of characters, erroneous conversion may occur. For example, when a first word (character string) in which erroneous recognition occurs is converted to a correct character string, a word having a larger number of characters that includes the correct character string may be erroneously converted.
[0007] For example, if a conversion list that associates the correct word (character string) "vector" with the misrecognized character string "vector" is applied to the misrecognized character string "vector," it will be converted to the correct character string "vector."
[0008] However, for example, if the input string contains the correct word "spectrum", the same conversion list would be mechanically applied, resulting in the "spectrum" being misconverted to "spectrum vector" because the "spectrum" part would be converted to "vector". Ultimately, this may require a visual inspection and correction of the conversion results.
[0009] One of the objectives of the present disclosure is to reduce erroneous conversion of character strings that are misrecognized in character recognition processing of a document. [Means for solving the problem]
[0010] An information processing device according to one embodiment of the present disclosure includes a memory unit that stores a list of conversion rules in which each of a plurality of words having different numbers of characters is associated with a conversion target string for identifying a string including a misrecognized character as a conversion target, and a processing unit that compares the conversion rules in the list in ascending order of the number of characters for a string obtained by character recognition processing on a document, and sequentially converts a string that matches the conversion target string in the string obtained by the character recognition processing into a corresponding word. Effect of the Invention
[0011] According to the present disclosure, character strings obtained by character recognition processing of a document are converted into corresponding words by checking conversion rules in order, starting with words with the smallest number of characters, thereby reducing erroneous conversions of misrecognized character strings. [Brief description of the drawings]
[0012] [Figure 1] FIG. 13 is a diagram illustrating an example of a character string conversion process according to an embodiment. [Diagram 2] 1 is a block diagram showing an example of a configuration of an information processing device according to an embodiment; [Diagram 3] 4(a) to 4(c) are diagrams illustrating examples of conversion rules according to an embodiment. [Figure 4] FIG. 11 is a diagram illustrating an example of log data of a conversion process according to an embodiment. [Diagram 5] FIG. 11 is a diagram for explaining an example of generation of a conversion target character string according to an embodiment; [Figure 6] FIG. 2 is a diagram showing an example of the format of one record among a plurality of records constituting a list of conversion rules according to an embodiment. [Figure 7] FIG. 2 illustrates an example of a data structure that defines a list of conversion rules according to an embodiment. [Figure 8] 1 is an exemplary flowchart illustrating a character string conversion process according to an embodiment. [Figure 9] FIG. 11 is a diagram illustrating an example of a character string conversion process using a conversion rule according to an embodiment. [Figure 10] 11 is an exemplary flowchart illustrating a process for generating a conversion rule according to an embodiment. [Figure 11] 8A is a diagram showing an example of a conversion rule record generated in one embodiment, and FIG. 8B is a diagram showing an example in which the record shown in FIG. 8A is added to the list of conversion rules shown in FIG. [Figure 12] FIG. 12 is a diagram showing an example of conversion processing of a character string according to the list of conversion rules shown in FIG. [Figure 13]13(a) and 13(b) are diagrams showing an example of a list of conversion rules according to a modified example. [Figure 14] 13 is an exemplary flowchart for explaining a process of generating a conversion rule according to a modified example. [Figure 15] 13 is an exemplary flowchart for explaining a character string conversion process according to a modified example. [Figure 16] 3 is a diagram illustrating an example of a hardware configuration of the information processing device illustrated in FIG. 2. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0013] Hereinafter, the embodiments and examples will be described in detail with reference to the drawings. The same or similar reference numerals indicate the same or similar elements, and repeated explanations may be omitted. In the following description, when a numerical value is described, the numerical value is merely an example, and other numerical values may be used in addition or instead.
[0014] <Summary> Fig. 1 is a diagram showing an overview of an example of character string conversion processing according to an embodiment. Fig. 1 shows an example in which a character string "spectrum" included in an input character string is converted to a "vector" by application of conversion rule A, and a character string "spectrum", which includes the converted character string "vector" as a part, is converted to a "spectrum" by application of conversion rule B.
[0015] Conversion rule A associates the string "[bepepe]kutor", which contains a square bracket [], a regular expression, at the first character position, as the conversion target string for the four-letter correct string "vector". Conversion rule B associates the string "[bebepe]kutor", which contains a square bracket [], a regular expression, at the second character position, as the conversion target string for the five-letter correct string "spectrum".
[0016] <regular expression> A regular expression is a method of expressing multiple patterns of strings in a single format. Square brackets [] (also called metacharacters), which are one of the regular expressions, are used to express multiple patterns of strings that contain any one of the multiple characters enclosed in square brackets [] in a single string format.
[0017] For example, a string expressed as [ABC]DE represents three possible string patterns: "ADE", "BDE", and "CDE", where the character in the first character position is one of "A", "B", or "C".
[0018] Here, assume that the katakana "be" at the first character position in the correct answer string "vector" can be misrecognized in three ways: as the hiragana "be", the katakana "pe", and the hiragana "pe". In this case, three patterns of strings that contain one of the three misrecognition candidate characters [bepepe] at the first character position (in other words, misrecognized strings) are represented by a single string "[bepepe]kutor".
[0019] Similarly, assume that the katakana "pe" at the second character position of the correct character "spectrum" can be misrecognized in three ways: katakana "be," hiragana "be," and hiragana "pe." In this case, three patterns of character strings that include one of the three misrecognition candidate characters [bebepe] at the second character position are represented by one character string "S[bebepe]kutor."
[0020] Therefore, conversion rule A means that, in the input string, a string that matches any one of the three misrecognition candidate characters [bepepe] at the first character position of the four-character "vector" is converted to the correct string "vector".
[0021] Conversion rule B is applied to character strings with a greater number of characters than conversion rule A, and converts character strings that match any of the three misrecognition candidate characters [bebepe] in the second character position of the five-character "spectrum" into the correct character string "spectrum."
[0022] Thus, if the input string contains the word "spectrum", application of conversion rule A will convert the string "spectrum" to "vector", but then application of conversion rule B will convert it to the correct string word "spectrum".
[0023] In this way, in the conversion process illustrated in FIG. 1, conversion rules A and B are mechanically and sequentially applied in ascending order of the number of characters in the correct string, without confirming or determining whether the string (word) is a correct conversion or an incorrect conversion.
[0024] In other words, the conversion process allows cases where a misrecognized character string is converted to a correct character string, as well as cases where a correct character string is converted to an incorrect character string. Even if the latter conversion occurs, there is a chance that it will eventually be converted (or corrected) to a correct character string by applying another conversion rule for a word with a larger number of characters that contains the misrecognized character string.
[0025] "There is room" means that, since it is unrealistic to prepare comprehensive conversion rules in advance for all words with all numbers of characters, it is acceptable for cases to occur in which erroneous conversions cannot be completely corrected even by sequentially applying the above-mentioned conversion rules in ascending order according to the number of characters.
[0026] In the embodiment described below, an example is also described in which new (or additional) conversion rules are automatically generated for strings that ultimately contain erroneous conversions, and the list of conversion rules is updated, so that the probability of such cases occurring can be adaptively reduced.
[0027] <Explanation of terms etc.> To facilitate understanding of the embodiments described below, some terms used in this specification will be explained below.
[0028] A "document" is a document containing multiple characters or multiple strings of characters (e.g., words), and a "document image", as described above, means image data obtained by reading a document with a device such as a camera or scanner.
[0029] A "character" includes any character that can be used in a document, including, but not limited to, kanji, hiragana, katakana, alphabet, symbols, or numbers. In this embodiment, a document written in Japanese will be used as an example. In character recognition processing, erroneous recognition of characters may occur between these characters.
[0030] Converting (or replacing) a "character" or a "character string" to another character or character string may be understood as converting (or replacing) the character code corresponding to the character or the character code set corresponding to the character string.
[0031] A "correct character string" or a "correct word" refers to a correct character string or word that is free of misrecognition, and a "correct character" refers to each individual character that constitutes a correct character string. Note that a correct character string may be understood to be, for example, a predetermined character string as a word. A "misrecognized character candidate" is a concept that includes both an "misrecognized character" that has been confirmed to be misrecognized in the character recognition process result, and a candidate character that is expected to be misrecognized in the character recognition process.
[0032] A "conversion rule" is data that matches (or associates) a correct string (or correct word) with a "string to be converted," and a string in the input string that matches (or matches) the "string to be converted" is converted into the corresponding "correct string."
[0033] The "conversion target character string" refers to a character string for identifying a character string including a character that has been erroneously recognized in the character recognition process result as a conversion target. For example, the "conversion target character string" is collated or searched in the character recognition process result, and a character string that matches the "conversion target character string" is identified as a character string including a character that has been erroneously recognized. The character string identified in this manner is the target for conversion to a correct character string. Note that the term "identification" may be interchangeably interpreted as other terms such as "identification" or "detection" depending on the context, for example.
[0034] When there is one candidate (or pattern) for the "conversion target string," for example, when there is one pattern of a string that may be misrecognized as the correct string (misrecognized string), the "conversion target string" will match the one pattern of the "misrecognized string."
[0035] In contrast, when there are multiple candidates for the "character string to be converted," the "character string to be converted" can be expressed as a single character string using one or more regular expressions. By using regular expressions, it is not necessary to prepare individual conversion rules for the multiple candidates. Therefore, the number of conversion rules to be prepared for the conversion process can be reduced.
[0036] In the embodiment described below, the "plurality of candidates" (in other words, the plurality of character string patterns) may or may not include a correct character string pattern in addition to an erroneous recognition character string pattern.
[0037] An example of a case where the "multiple candidates" do not include the pattern of the correct string is when "one character" in the correct string may be misrecognized as multiple different characters. In this case, the "string to be converted" represents multiple patterns of misrecognized strings by one string using one regular expression corresponding to the "one character." The "string to be converted" in the conversion rules A and B shown in FIG. 1 corresponds to this case.
[0038] On the other hand, the case where the "multiple candidates" include the pattern of the correct answer string is a case where each of the "multiple characters" in the correct answer string may be erroneously recognized as one or more different characters. In this case, the "string to be converted" represents a string pattern that includes both the pattern of the misrecognized string and the pattern of the correct answer string, using a single string that uses multiple regular expressions corresponding to each of the "multiple characters." Note that the conversion rule in this case means that it is permissible to convert the correct answer string into the same correct answer string. The technical significance of this will be described later.
[0039] The meanings of the terms etc. have been explained above. Below, an embodiment for implementing the character string conversion process as shown in FIG.
[0040] <Configuration example> 2 is a block diagram showing an example of the configuration of an information processing device 1 according to an embodiment. The information processing device 1 may be understood to function as a character data processing device that processes character data that is a result of character recognition processing by OCR processing.
[0041] 2, the information processing device 1 includes, for example, a processing unit 10, a storage unit 20, and a display unit 30. The processing unit 10 performs, for example, processing on an input character string, which is an example of character data (for example, conversion processing of the character string on a word-by-word basis).
[0042] The storage unit 20 exemplarily stores information that is written or read appropriately by the processing unit 10 in response to the processing or operation of the processing unit 10. The storage unit 20 may be provided inside the information processing device 1 as shown in Fig. 2, or may be provided outside the information processing device 1 via a predetermined interface.
[0043] For example, the storage unit 20 may be provided in an external device that can be accessed by the processing unit 10 via a network interface. The network interface may be either a wireless or wired interface.
[0044] The information stored in the storage unit 20 may include, for example, a program or data. The data may include, for example, a list 200 (hereinafter sometimes abbreviated as "conversion list 200") of conversion rules 201-1 to 201-n (n is an integer of 2 or more) prepared separately for words with different numbers of characters. An example of the data structure of the conversion list 200 will be described later with reference to FIG. 7.
[0045] When there is no need to distinguish between the conversion rules 201-1 to 201-n, they will be abbreviated to "conversion rule 201." The data stored in the storage unit 20 may include log data 203. The log data 203 will be described later with reference to FIG.
[0046] The display unit 30 displays information indicating the process or result of processing by the processing unit 10, or information read from the storage unit 20 by the processing unit 10, according to display control of the processing unit 10. Exemplarily, the display unit 30 may display a conversion list 200 (or a conversion rule 201) or log data 203.
[0047] <About conversion rules> 3(a) to 3(c) are diagrams showing examples of conversion rules 201-1 to 201-3 according to this embodiment, respectively.
[0048] <The case where the conversion target string is expressed using multiple regular expressions> FIG. 3(a) shows an example of a conversion rule 201 for a case in which there are one or more misrecognition candidate characters for each of a plurality of characters (for example, the first and third characters) in a correct character string of the word "vector."
[0049] Figure 3(a) shows cases in which the first katakana character “be” in the correct string “vector” can be misrecognized in three ways: as “be,” as “pe,” as “pe,” and as “pe,” and the third katakana character “to” can be misrecognized as the kanji character “to.”
[0050] In this case, the string to be converted is represented by a string in which each of a plurality of characters that can be misrecognized in the correct string is replaced with a regular expression square bracket [], and each of the square brackets [] contains, in addition to the misrecognition candidate characters, the correct characters. In the following, the regular expression square brackets [] may be conveniently referred to as "regular expression []".
[0051] For example, as shown in FIG. 3(a), the string to be converted that is converted to the correct string "vector" by applying the conversion rule 201-1 is represented by a string including the regular expression [] at the first character position and the regular expression [] at the third character position.
[0052] The regular expression [] at the first character position includes a total of four characters, namely, the hiragana character "べ", the katakana character "ペ", and the hiragana character "ぺ" which are three misrecognition candidate characters, and the katakana character "ベ" which is the correct character. The regular expression [] at the third character position includes a total of two characters, namely, the kanji character "卜" which is one misrecognition candidate character and the katakana character "ト" which is the correct character.
[0053] Therefore, in the conversion rule 201-1, there are 4×2 = 8 patterns of candidates in the string to be converted, and among these 8 patterns, in addition to the pattern of the misrecognized string, there is also a pattern corresponding to the correct string.
[0054] In other words, when the string to be converted is a string represented by the regular expression [] at a plurality of character positions, the rule is to include, in the regular expression [], not only the pattern for converting the misrecognized string to the correct string, but also the pattern for converting the correct string to the correct string. This is because if the correct characters are not added to the regular expression [], a case where the conversion to the correct string is not supported may occur.
[0055] For example, in the conversion rule 201-1, when the string to be converted is represented as "[べぺペ]ク[ト卜]ル" which does not include the katakana character "ベ" which is the correct character in the regular expression [] for the first character position, "ベク卜ル" including the kanji character "卜" will not be the conversion target.
[0056] Therefore, when there are multiple characters (positions) that may be erroneously recognized in a correct character string, the regular expression [ ] for each character position includes the erroneously recognized candidate character and the correct character.
[0057] <The case where the conversion target string is expressed using one regular expression> FIG. 3(b) shows an example of the conversion rule 201-2 for a case where there are a plurality of erroneously recognized candidate characters for one character in the correct answer character string.
[0058] For example, the katakana "be" at the beginning of "Bayes' method" can be misrecognized in three ways: as the hiragana "be," the katakana "pe," and the hiragana "pe." Note that conversion rules A and B shown in Figure 1 also correspond to this case.
[0059] In this case, the conversion target string can be represented by a string in which one character that may be misrecognized in the correct string is replaced with the regular expression []. For example, in conversion rule 201-2, the conversion target string is represented as the string "[bepepe]is method" in which the first character of the correct string is replaced with one regular expression [] that includes three possible characters that may be misrecognized.
[0060] Unlike the case illustrated in Fig. 3(a), the correct character does not have to be included in this regular expression [ ]. For example, the correct character, katakana "be", does not have to be included in the regular expression [ ] at the beginning of "Bayes' method".
[0061] If the correct answer character were included in the regular expression [] for the first character, making it [bebepepe], a wasteful conversion would occur in which the correct string "Bayes' method" would be converted to the same correct string. Therefore, if the string to be converted can be expressed by a single regular expression [], the regular expression [] should not contain the correct answer character, preventing the occurrence of wasteful conversion and improving the efficiency of the conversion process.
[0062] <Cases where regular expressions are not used for conversion strings> Next, FIG. 3(c) shows an example of the conversion rule 201-3 for the case where there is one candidate for a misrecognized character for one character in the correct character string.
[0063] In this case, since the correct character string and the misrecognized character string have a one-to-one relationship, the conversion target string can be expressed without using the regular expression []. For example, for the three-character correct character string "projection method", when there is one candidate for misrecognition of the character "射" at the second character position, which is "彭", the misrecognized character string is one pattern of "射彭法". Therefore, in the conversion rule 201-3, the conversion target string is the string "射彭法" without using the regular expression [].
[0064] <Configuration example of the processing unit 10> Referring back to FIG. 2, the processing unit 10 illustratively includes a conversion processing unit 102 that sequentially executes string conversion processing by applying (or collating) the conversion rule 201 to the input string in ascending order of the number of characters, and a conversion rule generation processing unit 104 that generates the conversion rule 201.
[0065] <Configuration example of the conversion processing unit 102> The conversion processing unit 102 illustratively includes an acquisition unit 122, a collation unit 124, a conversion unit 126, and a log output unit 128.
[0066] The acquisition unit 122 acquires, for example, a character string that is the result of character recognition (e.g., OCR) of a document image. The document image is generated, for example, by reading a document such as an academic paper, a corporate technical report, or a computer software manual with an optical reading device such as a scanner.
[0067] The character recognition processing may be performed, for example, in the processing unit 10 through reading of a document by a reading device connected to the information processing device 1, or may be performed in a device (e.g., a server, etc.) located outside the information processing device 1.
[0068] Furthermore, the character string resulting from the character recognition process may be obtained, for example, from a document file (e.g., a text file) obtained by the character recognition process and stored in the storage unit 20. The document file may be provided to the information processing device 1 via a computer-readable storage medium or a network. The network may be a wired or wireless network, or a mixed wired and wireless network.
[0069] For example, the comparison unit 124 applies conversion rules 201 based on the number of characters stored in the memory unit 20 to the input character string acquired by the acquisition unit 122 on a word-by-word basis in ascending order of the number of characters, and checks whether or not there is a character string that matches the character string to be converted in the conversion rules 201.
[0070] For example, when a character string matching the conversion target character string is found in the input character string as a result of matching by the matching unit 124, the conversion unit 126 converts the character string into a correct character string associated with the conversion rule 201. The conversion unit 126 and the matching unit 124 may be functionally integrated into one block.
[0071] For example, the log output unit 128 generates log data 203 of the conversion process by the conversion unit 126 and outputs it to the storage unit 20. As a non-limiting example, the log output unit 128 can output the log data 203 in the form of a format 400 as shown in FIG. 4 by outputting the result of the conversion process to which the conversion rule 201 is applied for each original document image of the input character string and number (No.) information that manages the conversion rule 201.
[0072] 4 includes document number information 402 for identifying the document that is the source of the document image, record number (No.) information 404 of the conversion rule 201, an erroneously recognized character string 406, a converted character string 408, surrounding character information before conversion 410, and surrounding character information after conversion 412. The record number information 404 for managing (or identifying) the conversion rule 201 may be understood to correspond to a record number in the conversion list 200 described later.
[0073] The record number information 404 in the log data 203 is an example of information indicating which conversion rule 201 in the conversion list 200 was applied for matching. The incorrectly recognized character string 406 corresponds to, for example, a character string in the input character string that matches the character string to be converted in the conversion rule 201. The converted character string 408 corresponds to, for example, a character string that is converted into a correct character string by applying the conversion rule 201.
[0074] The surrounding character information 410 and 412 are, for example, information indicating characters included in a range of several characters to several tens of characters before and after the character string specified as the conversion target in the input character string before and after conversion. Fig. 4 shows an example in which the character string specified as the conversion target is highlighted by bolding and underlining so that it is easy to see. The highlighting may be performed alternatively or additionally in other manners such as color coding of the character color or color coding of the highlight applied to the character string.
[0075] The format 400 illustrated in FIG. 4 may be understood to correspond to an example display screen when the log data 203 is displayed on the display unit 30, or may be understood to correspond to an example printout when the log data 203 is printed.
[0076] Such log data 203 visualizes the process and contents of the conversion process, making it possible to clarify which conversion rule 201 of which record number in the conversion list 200 was used to execute the conversion process. Therefore, the validity of the conversion process contents can be easily confirmed, and appropriate operation management of the conversion list 200 can be achieved.
[0077] <Example of configuration of conversion rule generation processing unit 104> 2, conversion rule generation processing section 104 includes, for example, character string generation section 142, conversion rule generation section 144, and management section 146.
[0078] The character string generation unit 142 identifies, for example, characters that can be misrecognized for each correct character of a word using the character recognition correction data 502, and generates a conversion target character string as described above based on the identified characters that can be misrecognized. The characters that can be misrecognized can be identified, for example, by checking samples of character data for which the conversion process has ended or the log data 203 of the conversion process.
[0079] As a non-limiting example, as shown in FIGS. 2 and 5, the character string generation unit 142 generates a conversion target character string 506 including candidates for misrecognized character strings based on the character recognition correction data 502 and the correct character string (correct word) 504 of the word in which character misrecognition has occurred.
[0080] The character recognition correction data 502 is, for example, data that associates, on a character-by-character basis, the correct characters constituting a word with the characters (misrecognized characters) that the correct characters can be misrecognized as in the character recognition process. FIG. 5 shows, as a non-limiting example, character recognition correction data 502 in a table format, and examples in which each of the capital letter "I", the katakana "ト", the katakana "ベ", the katakana "ペ", and the Chinese character "影" has been misrecognized (or can be misrecognized) are shown.
[0081] In this case, in the character recognition correction data 502, the number "1" is associated as a misrecognized character with the capital letter "I" which is the correct character, and the Chinese character "卜" is associated as a misrecognized character with the katakana "ト" which is the correct character.
[0082] Similarly, in the character recognition correction data 502, the hiragana "べ", the katakana "ペ", and the hiragana "ぺ" are associated as misrecognized characters with the katakana "ベ" which is the correct character. Also, in the character recognition correction data 502, the katakana "ベ", the hiragana "べ", and the hiragana "ぺ" are associated as misrecognized characters with the katakana "ペ" which is the correct character. Further, in the character recognition correction data 502, another Chinese character "彭" is associated as a misrecognized character with the Chinese character "影" which is the correct character.
[0083] Similarly, for other characters not illustrated in FIG. 5, the correct characters and the misrecognized characters are registered in the character recognition correction data 502.
[0084] The character recognition correction data 502 and the correct words 504 may be prepared in advance, for example, based on samples of the character data for which the above-described conversion process has ended or the log data 203 of the conversion process. These character recognition correction data 502 and correct words 504 may be input to the character string generation unit 142 separately from the input character string to the acquisition unit 122, or may be stored in the storage unit 20.
[0085] Based on the character recognition correction data 502 and the correct character string 504 of the word (for example, "index vector"), the character string generation unit 142 generates, for example, a character string 506 (for example, "index [bebepepe] vect[tobo]tor") for specifying the object to be converted to the correct word 504.
[0086] This character string 506 corresponds to the case illustrated in FIG. 3(a). As illustrated in the lower part of FIG. 5, in the regular expressions [] assigned to the 7th and 10th character positions from the beginning, in addition to the misrecognized characters, the correct characters are included.
[0087] For example, in the regular expression [] at the 7th character position, the katakana "be" which is the correct character, the hiragana "be", the katakana "pe", and the hiragana "pe" which are misrecognized characters are included. Also, in the regular expression [] at the 10th character position, the katakana "to" which is the correct character and the Chinese character "bo" which is the misrecognized character are included.
[0088] Similarly, for other words not illustrated in FIG. 5, a conversion target character string 506 for the correct word 504 is generated based on the character recognition correction data 502 and the correct word 504.
[0089] Returning to FIG. 2, conversion rule generating unit 144 generates conversion rule 201 that associates conversion target character string 506 generated by character string generating unit 142 with correct word 504, for example.
[0090] For example, the management unit 146 manages the conversion rules 201 generated by the conversion rule generation unit 144 by adding them to the conversion list 200 in the storage unit 20. For example, the management unit 146 may manage the conversion rules 201 by sorting them in ascending order of the number of characters of the correct words.
[0091] Therefore, for example, the management unit 146 manages the conversion list 200 in units of records to which a record number based on the number of characters of the correct word and information indicating the number of characters of the correct word are assigned to the conversion rule 201.
[0092] In other words, one record (or one entry) constituting the conversion list 200 may be defined, for example, by a format that associates a number based on the number of characters in the correct word, a correct word, a string to be converted, and the number of characters in the correct word.
[0093] Fig. 6 shows an example of a format 600 of one of the multiple records constituting the conversion list 200. Fig. 6 shows, as a non-limiting example, a record of the conversion rule 201 in which the conversion target character string "[bebepepe]ku[totor]ru" expressed using the regular expression [] is associated with the correct answer character string "vector".
[0094] 6, the number of the conversion rule 201, i.e., the record number (No.), is a seven-digit number as a non-limiting example. The first two digits represent the number of characters in the correct answer character string (e.g., 04), and the following five digits represent a number (which may be called an "incremental value") that is incremented by one (+1) each time a record (or entry) is added. Note that the record number is not limited to seven digits, and may be any number of digits as long as it is a number form based on the number of characters in the correct answer character string.
[0095] The management unit 146 uses such record numbers as a key to sort the records in ascending order of record numbers, thereby updating the conversion list 200 so that records of conversion rules 201 with fewer characters in the correct string are positioned higher in the conversion list 200. Therefore, the management unit 146 can easily manage the conversion list 200 by, for example, sorting the conversion rules 201 in the conversion list 200 in ascending order of the number of characters in the correct word.
[0096] Fig. 7 shows an example of the data structure of the conversion list 200 in which the records of the conversion rules 201 are sorted in ascending order of the number of characters in the correct answer character string. Fig. 7 shows an example in which the records of the conversion rules 201 for each of the three correct answer character strings, "vector", "spectrum", and "bias vector", are sorted in ascending order of record numbers whose first two digits include a number indicating the "number of characters" (e.g., 04, 05, 08). In Fig. 7, the first two digits of the record numbers corresponding to the "number of characters" are shown in bold for the sake of convenience (the same applies hereinafter).
[0097] Since the conversion list 200 is managed in ascending order of the number of characters of the correct words, for example, the conversion processing unit 102 can apply the conversion rules 201 in ascending order of the number of characters of the correct words by reading the records in the conversion list 200 in ascending order of the record numbers. Therefore, for example, address control for reading the conversion rules 201 from the storage unit 20 can be simplified, and the conversion process using the conversion rules 201 can be speeded up or made more efficient. Note that it is not essential that the conversion list 200 is sorted in ascending order of the number of characters of the correct strings. For example, the processing unit 10 can control the order in which the conversion rules 201 are read from the conversion list 200 to realize the application of the conversion rules 201 in ascending order.
[0098] When performing conversion processing using the conversion list 200 illustrated in FIG. 7, for example, the misrecognized character string "bias spectrum" in the input character string is converted into the correct character string "bias vector" by conversion processing in the following order.
[0099] (1) By applying conversion rule 201 for record number = "0490068", the character string "vector" that matches the conversion target character string "[bebepepe]ku[tottor]ru" is converted to "vector".
[0100] (2) Next, by applying the conversion rule 201 of the record number = "0590069", the character string "spectra" that matches the conversion target character string "S[bebepepe]ku[ttor]ru" is converted to "spectra".
[0101] (3) Furthermore, by applying the conversion rule 201 of the record number = "0890070", the character string "bias spectrum" that matches the conversion target character string "bias [bebepepe] ku [tot] ru" is converted to "bias vector".
[0102] Note that the above-mentioned character string generating unit 142, conversion rule generating unit 144, and management unit 146 may be functionally integrated into one block in part or in whole.
[0103] <Processing example> An example of processing by the information processing device 1 having the above-mentioned configuration will be described below, with a character string conversion process by the conversion processing unit 102 and a process of generating the conversion rule 201 by the conversion rule generation processing unit 104 being separately described.
[0104] <Example of character string conversion processing> 8 is a flowchart showing an example of processing of the information processing device 1 focusing on character string conversion processing. As shown in FIG. 8, the processing unit 10 (e.g., the conversion processing unit 102) of the information processing device 1 acquires an input character string in the acquisition unit 122 (S802), and passes the acquired character string to the collation unit 124.
[0105] Furthermore, the conversion processing unit 102 reads, for example, the first record of the conversion list 200 from the storage unit 20, and passes the conversion rule 201 of the record to the collation unit 124 (S804). Note that the processes of S802 and S804 may be executed in reverse order, or may be executed in parallel.
[0106] The collation unit 124 compares (or collates) the input character string with the conversion target character string in the conversion rules 201 to check whether or not there is a character string in the input character string that matches the conversion target character string (S808).
[0107] If the confirmation process does not confirm the existence of a matching string (S808; NO), the conversion processing unit 102, for example, causes the comparison unit 124 to read the next record in the conversion list 200 (S816) and re-executes the comparison process of S806 using the conversion rule 201 of the next record.
[0108] This matching process is repeated by sequentially applying the next record in the conversion list 200 until a record of the conversion rule 201 that matches the input character string is found (until YES is determined in S808).
[0109] If the existence of a matching character string is confirmed in S808 (S808; YES), the conversion processing unit 102 converts the matching character string into a correct character string in the conversion unit 126 according to the conversion rules 201 regardless of whether the conversion is correct or not (S810).
[0110] Then, the conversion processing unit 102 records the result of the conversion process by the conversion unit 126 as a conversion history in the format 400 as exemplified in FIG. 4, for example, by the log output unit 128 (S812).
[0111] Thereafter, the conversion processing unit 102 checks, for example, whether or not there is a record of the conversion rule 201 that has not been applied in the conversion list 200, in other words, whether or not the record of the conversion rule 201 that was applied in S810 is the last record (S814).
[0112] If the confirmation process finds that there is a record of the conversion rule 201 that has not been applied (YES in S814), the conversion processing unit 102, for example, causes the collation unit 124 to read the next record in the conversion list 200 (S816) and re-executes the processes from S806 onwards.
[0113] The conversion processing unit 102 sequentially reads the next record in the conversion list 200 (S816) and repeats the processes from S806 onwards until there is no record of the conversion rule 201 that has not been applied in the conversion list 200 (until NO is determined in S814).
[0114] Here, in the conversion list 200, the records of the conversion rules 201 are arranged (sorted) in ascending order of the number of characters in the correct string as described above, so that the conversion rules 201 are applied to the input string in ascending order of the number of characters in the correct string by the repetitive process described above.
[0115] If all conversion rules 201 in the conversion list 200 have been applied (NO in S814), the conversion processing unit 102 outputs log data 203 (see FIG. 4) indicating the conversion history recorded for each execution of S812 to the memory unit 20 or the display unit 30 (S818).
[0116] FIG. 9 shows an example in which the character string "index spectrum" included in the input character string is converted sequentially by applying the conversion rules 201 in ascending order according to the above conversion process in the conversion processing unit 102.
[0117] As shown in FIG. 9, when the matching unit 124 applies the conversion rule 201-1 with the record number "0490068" to the input character string and performs matching, the substring "spectrum" of the character string "index spectrum" matches the character string to be converted "[bebepepe]ku[tottor]ru."
[0118] Therefore, the partial character string "spectrum" is converted to the correct character string "vector" by the conversion rule 201-1. Through this conversion, the character string before conversion "index spectrum" becomes "index vector".
[0119] Next, in the matching unit 124, when the conversion rule 201-2 for the record number = "0590069" is applied to the input character string including the converted character string "index_svector" and a match is performed, it is found that "svector", which is a substring of the character string "index_svector", matches the character string to be converted "S[bebepepe]ku[ttor]ru".
[0120] Therefore, the partial character string "spectra" is converted to the correct character string "spectra" by the conversion rule 201-2. Through this conversion, the character string before conversion "indexspectra" becomes "indexspectra".
[0121] If there is no conversion rule 201 for a correct word with a larger number of characters registered in the conversion list 200 other than the two conversion rules 201-1 and 201-2 described above, the conversion process ends and “index spectrum” becomes the final conversion process result.
[0122] Here, if “index vector” is a word of the correct character string, the conversion rule 201 corresponding to the character string “index spectrum”, which is the final result of the conversion process, is not registered in the conversion list 200, and therefore the erroneous conversion is not corrected.
[0123] Therefore, in this embodiment, a new conversion rule 201 corresponding to the character string for which an incorrect conversion has been confirmed is generated by the conversion rule generation processing unit 104 in accordance with an example of a generation process described below with reference to FIG. 10, and added to the conversion list 200.
[0124] <Example of conversion rule generation process> Fig. 10 is a flowchart showing an example of a generation process of a conversion rule according to an embodiment. As illustrated in Fig. 10, the conversion rule generation processing unit 104, for example, in the character string generating unit 142, collates each of the correct character strings constituting the correct word 504 with the correct characters registered in the character recognition correction data 502, and specifies all correct characters that may be erroneously recognized and all erroneously recognized characters that correspond to the correct characters (S902).
[0125] The correct word 504 is created in advance, for example, by a user of the information processing device 1 checking the log data 203 described above, identifying a word (e.g., "index spectrum") that includes an incorrectly recognized character, and correcting the word to a correct character string.
[0126] Then, the character string generating unit 142 determines whether the correct character string contains one character that may be erroneously recognized, and whether there is one erroneously recognized character for that one character (in other words, the correct character) (S904).
[0127] If the result of the determination in S904 is "YES", the character string generating unit 142 generates a conversion target character string without using the regular expression [] (S906). For example, the character string generating unit 142 generates a character string in which the corresponding character of the correct answer character string is replaced with an incorrectly recognized character as the conversion target character string.
[0128] On the other hand, if the result of the determination in S904 is "NO", the character string generating unit 142 determines whether the number of regular expressions [] used in the character string to be converted is one (S908). For example, if the correct character string contains one character that may be misrecognized and there are multiple misrecognized characters for that one character (correct character), the correct character can be replaced with the regular expression [], and the number of regular expressions [] is one (YES in S908).
[0129] In this case, the character string generation unit 142 generates a character string to be converted by including multiple misrecognized characters but not the correct character in the square brackets [] of the regular expression and replacing the correct character in the correct character string with the regular expression [] (S910).
[0130] On the other hand, if the correct string contains multiple characters that may be misrecognized, it is determined in S908 that there are multiple regular expressions [ ] (NO), and the string generation unit 142 replaces each of the multiple characters with the regular expression [ ].
[0131] In this case, the string generation unit 142 generates a string to be converted by including a correct character and one or more misrecognized characters in each of a plurality of regular expressions [ ] and replacing each of the correct characters that may be misrecognized in the correct string with the regular expression [ ] (S912).
[0132] The conversion target character string generated in character string generation unit 142 is passed to conversion rule generation unit 144 together with the correct string, and conversion rule generation unit 144 generates conversion rule 201 by associating the conversion target character string with the correct string (S914). The generated conversion rule 201 is passed from conversion rule generation unit 144 to management unit 146.
[0133] The management unit 146 adds, for example, a record number (the first two digits indicating the number of characters in the correct string + a five-digit number obtained by incrementing the existing incremental value by one) and information indicating the number of characters in the correct string to the conversion rule 201, and adds the record to the conversion list 200 (S916).
[0134] When a record of a new conversion rule 201 is added to the conversion list 200, the management unit 146 may output log data related to the update of the conversion list 200 to the storage unit 20 or the display unit 30, for example, for the purpose of maintaining, operating, and managing the conversion list 200. This log data may be in a format different from that of the log data 203 exemplified in FIG.
[0135] Fig. 11(a) shows an example of a record of the conversion rule 201 newly added to the conversion list 200. Fig. 11(a) shows an example of a record of the conversion rule 201 corresponding to the character string "index spectrum" that was erroneously converted in Fig. 9. The record number of this record is, for example, "1090071", which is a combination of the first two digits indicating the number of correct characters (=10 characters) and the following five digits "90071".
[0136] In addition, the conversion target character string in the conversion rule 201 of this record is generated by the process of S912 because the seventh and ninth correct characters of the correct character string "index vector" may be misrecognized. For example, the character string "index [bebepepe]ku[ttor]ru" using the regular expression [] at each of the seventh and ninth character positions is generated as the conversion target character string.
[0137] Then, the management unit 146, for example, adds a record of the additional conversion rule 201 to the conversion list 200, and sorts the records of the conversion list 200 in ascending order using a record number based on the number of characters in the correct character string as a key (S918). As a result, the conversion rules 201 are rearranged in the conversion list 200 in ascending order of the number of correct characters. Note that Fig. 11(b) shows an example of the result when the record of the conversion rule 201 illustrated in Fig. 11(a) is added to the conversion list 200 illustrated in Fig. 7 and sorted.
[0138] In this manner, a new conversion rule 201 corresponding to a character string in which an erroneous conversion has occurred is generated, and the conversion list 200 is updated. Therefore, as the conversion list 200 is updated, the probability of occurrence of a case in which an erroneous conversion cannot be completely corrected is adaptively reduced.
[0139] For example, the erroneously converted character string “index spectrum” in FIG. 9 is converted to the correct character string “index vector” as shown in FIG. 12 by applying the conversion rule 201 of the newly added record number “1090071” shown in FIG. 11, and the erroneous conversion is eliminated.
[0140] As described above, according to the embodiment described above, the conversion rules 201 are applied in the order from the fewest number of characters to the largest number of characters (i.e., ascending order) to sequentially convert the characters into the correct character string. Therefore, even if an erroneous conversion occurs during the conversion process by the conversion processing unit 102, the probability of eliminating the erroneous conversion is improved.
[0141] For example, the probability that a first character string converted into a first correct character string may remain as a misconversion into a second correct character string having a larger number of characters that includes the first correct character string as a part of the first character string can be reduced. Therefore, the accuracy of converting a misrecognized character string into a correct character string is improved.
[0142] In addition, since the order of the conversion rules 201 in the conversion list 200 is managed in ascending order of the number of characters in the correct answer character string, for example, it is possible to eliminate the need for the conversion processing unit 102 to control or manage the application order of the conversion rules 201. Therefore, for example, the processing efficiency is improved when the conversion process is mechanically performed using the conversion list 200.
[0143] Furthermore, in the conversion list 200, the conversion rules 201 are managed by record numbers having a number format based on the number of characters in the correct answer character string, so that the processing efficiency for managing the order of the conversion rules 201 in ascending order, for example, is improved.
[0144] Furthermore, when a new erroneous conversion is discovered, the conversion rule generation processor 104 generates a conversion rule 201 corresponding to the new erroneous conversion and adds it to the conversion list 200, so that it is possible to flexibly adapt to the new erroneous conversion.
[0145] <Modification> Next, modified examples of the above-described embodiment will be described with reference to Figures 13 to 15. In the modified examples, the configuration of the information processing device 1 may be the same as the configuration exemplified in Figure 2, and elements described with the same reference numerals as those already described may be understood to be the same as or similar to the already described elements, unless otherwise specified.
[0146] Figures 13(a) and 13(b) are diagrams showing an example of a conversion list 200 according to a modified example. The conversion list 200 shown in Figures 13(a) and 13(b) differs from the conversion list 200 shown in Figures 7 and 11(b) in that the format includes a flag field 210 as an example of control information for controlling (or instructing) whether or not to apply the conversion rule 201 on a record-by-record basis of the conversion rule 201. A flag indicating "0" or "1" is set in the flag field 210.
[0147] The flag can be set by, for example, conversion rule generation processing unit 104 (for example, management unit 146) illustrated in Fig. 2. After the conversion rule generation processing illustrated in Fig. 10, conversion rule generation processing unit 104 performs flag setting for each record by additionally executing the following processing for each record from the first to the last of conversion list 200 sorted in ascending order of the number of characters.
[0148] In Fig. 13(a), the character string "vector" in bold indicates that it is included as part of the words "bias vector" and "index vector" of a character string longer than the character string in question. Similarly, in Fig. 13(b), the character string in bold indicates that it is included as part of another word of a character string longer than the character string in question.
[0149] <Record comparison processing> The conversion rule generation processing unit 104, for example, sequentially checks from the higher entries (or records) in the conversion list 200 whether a character string corresponding to a word in the conversion rule 201 of the entry of interest (hereinafter also referred to as the "target record") is included in the conversion target character string of the conversion rule in the entry lower than the entry of interest.
[0150] As a non-limiting example, the conversion rule generation processing unit 104 sequentially compares and checks whether the "conversion target string" in the target record is included in the "correct answer string" in the conversion rule 201 of a lower record whose first two digits representing the number of characters are greater than those of the target record.
[0151] For example, in FIG. 13(a), a comparison is made to see whether a string that matches any of the multiple string patterns represented by the conversion target string “[bebepepe]ku[tottor]ru” in the target record with record number “0490068” is included in the “correct answer string” of a record lower than the target record.
[0152] In FIG. 13(a), the conversion target character string "vector" of record number "0490068" is included in the correct character string "bias vector" of record number "0890070" and the correct character string "index vector" of record number "1090071".
[0153] <Replacement process> If the comparison reveals that a lower-level record exists that contains the "conversion target string" in the target record as part of its "correct answer string," the conversion rule generation processing unit 104 replaces the part of the "conversion target string" of the lower-level record that corresponds to the "correct answer string" of the target record with the "correct answer string" of the target record.
[0154] For example, in FIG. 13(a), the "vector" portion in each of the conversion target character strings with record numbers "0890070" and "1090071" is replaced with the correct character string "vector" in the target record with record number "0490068" which has the smaller number of characters.
[0155] Therefore, the "conversion target string" for the correct string "bias vector" of record number "0890070" is the same "bias vector" as the correct string. Similarly, the "conversion target string" for the correct string "index vector" of record number "1090071" is the same "index vector" as the correct string.
[0156] As illustrated above, when the conversion rule generation processing unit 104 confirms in the conversion list 200 that a character string corresponding to a word in the conversion rule 201 of a target entry is included in a conversion target character string of a conversion rule in an entry lower than the target entry, the conversion rule generation processing unit 104 replaces the part of the conversion target character string corresponding to the word in the conversion rule 201 of the target entry with the word in the conversion rule 201 of the target entry for the corresponding lower entry.
[0157] <Flag setting process> The conversion rule generation processing unit 104 (e.g., the management unit 146) checks whether the conversion target character string of the conversion rule 201 in an entry lower than the entry of interest, which contains the word replaced in the above manner, is identical to the word associated with it in the conversion rule 201 of the lower entry.
[0158] If the result of the check is "same", the conversion rule generation processing unit 104 records, for example, a flag = 1 indicating "same" in the flag field 210 of the lower entry. On the other hand, if the result of the check is "different", the conversion rule generation processing unit 104 records, for example, a flag = 0 indicating "not same" in the flag field 210 of the lower entry. Note that "recording" a flag may be interpreted as "setting" or "assigning" a flag interchangeably.
[0159] For example, in FIG. 13(a), the "correct string" and the "conversion target string" after replacement in record numbers "0890070" and "1090071" are the same string. Therefore, flag=1 is set in flag field 210 of each record with record numbers "0890070" and "1090071". Note that in FIG. 13(a), since there are no records with record numbers smaller than "0490068", flag=0 is set in flag field 210 of the record with record number "0490068".
[0160] In this way, the flag indicating "same" is set to 1 when both the first and second conditions shown below associated with the "flag" are satisfied.
[0161] First condition: The correct answer string in a lower record with a higher record number than the target record contains the string to be converted in the target record.
[0162] Second condition: A string obtained by replacing a part of a conversion target string in a lower record that corresponds to a correct string of the target record with the correct string of the target record is identical to the correct string of the lower record.
[0163] If the first condition is met but the second condition is not met, i.e., if the "correct string" in the lower record and the "conversion target string" after replacement are different strings, the conversion rule generation processing unit 104 sets a flag indicating "not identical" = 0 in the flag field 210 of the lower record.
[0164] For example, as shown in FIG. 13(b), assume a case where a record (record number "0590072") of the conversion rule 201 in which the correct character string is "spectrum" is added to the conversion list 200 illustrated in FIG. 13(a).
[0165] In this case, the conversion target string "Spectrum" for the correct answer string "Vector" in record number "0490068" is included in the correct answer string "Spectrum" in the lower record number "0590072" which has a larger number of characters. Note that the conversion target string "Spectrum" in record number "0490068" is one of the multiple string patterns represented by the conversion target string "[bebepepe]ku[tottor]ru".
[0166] Therefore, the "spectru" portion of the conversion target string for the correct string "spectrum" of record number "0590072" is replaced with the correct string "vector" of record number "0490068" which has a smaller number of characters by the replacement process described above.
[0167] As a result, the conversion target character string for the correct answer character string "spectrum" of record number "0590072" is "spectrum". This conversion target character string "spectrum" is a character string different from the correct answer character string "spectrum". Therefore, conversion rule generation processing unit 104 sets flag = 0 in flag field 210 of the record of record number "0590072".
[0168] Furthermore, the character string to be converted, "s vector", of this record number "0590072" is included in the "bias vector" and "index vector", which are the correct character strings of the records with record numbers "0890070" and "1090071", respectively.
[0169] Therefore, the portion of the character string to be converted in each of these records that corresponds to "spectra" is replaced with "spectra", which is the correct character string for record number "0590072", by the replacement process described above.
[0170] As a result of this substitution, as shown in Fig. 13(b), the conversion target character string for the correct answer character string "bias vector" in record number "0890070" becomes "bia spectrum". Similarly, the conversion target character string for the correct answer character string "index vector" in record number "1090071" becomes "index spectrum".
[0171] The correct string and the conversion target string are different strings in each of the records with record numbers "0890070" and "1090071." Therefore, the conversion rule generation processor 104 sets flag=0 in the flag field 210 of each of the records with record numbers "0890070" and "1090071."
[0172] An example of processing including the above inter-record comparison processing, partial character string replacement processing, and flag setting processing is shown as a flowchart in Fig. 14. The flowchart shown in Fig. 14 is executed in the conversion rule generation processing unit 104 (e.g., the management unit 146) after the execution of the flowchart shown in Fig. 10, for example.
[0173] As shown in FIG. 14, for example, the conversion rule generation processor 104 reads, from the storage unit 20, the first record of the conversion list 200 sorted in ascending order of the number of characters in the correct answer string as the "target record" (S1402).
[0174] Then, the conversion rule generation processor 104 compares the conversion target character string of the "target record" with the correct answer character string of the lower "other record" that has a larger number of characters, and checks whether the conversion target character string of the "target record" is included in the correct answer character string of the "other record" (S1404). This check corresponds to checking whether the first condition described above is satisfied.
[0175] If the confirmation result indicates "YES", the conversion rule generation processing unit 104 replaces the part of the conversion target character string of the "other record" that corresponds to the correct character string of the "target record" with the correct character string of the "target record" (S1406).
[0176] Then, the conversion rule generation processing unit 104 checks whether the converted character string after the replacement is the same as the correct character string (S1410). This check corresponds to checking whether the above-mentioned second condition is satisfied.
[0177] If the check results in an identical result (YES in S1410), conversion rule generation processing unit 104 sets flag = 1 in flag field 210 of the "other record" (S1412). If the check results in an identical result (NO), conversion rule generation processing unit 104 sets flag = 0 in flag field 210 of the "other record" (S1414).
[0178] After setting the flag, the conversion rule generation processing unit 104 checks (S1416) whether the "target record" is the last record in the conversion list 200. If the "target record" is not the last record in the conversion list 200 (NO in S1416), the conversion rule generation processing unit 104 reads the next record in the conversion list 200 as the "target record" (S1418) and repeats the processing from S1404 onwards.
[0179] In addition, if it is determined in the processing of S1404 that the conversion target character string of the "target record" is not included in the correct character string of the "other records" (NO), the conversion rule generation processing unit 104 reads the next record in the conversion list 200 as the "target record" (S1418) and repeats the processing from S1404 onwards.
[0180] Then, when conversion rule generation processor 104 has completed setting the above-mentioned flag (S1412 or S1414) for the last record in conversion list 200 (YES in S1416), conversion rule generation processor 104 ends the process.
[0181] The flag set on a record-by-record basis in the conversion list 200 in the above manner is used as an example of information for controlling whether or not to apply the conversion rule 201 in the conversion process (see, for example, FIG. 8) using the above-described conversion list 200. For example, flag=0 indicates "apply," and flag=1 indicates "not apply."
[0182] Therefore, in the application of the conversion rules 201 in ascending order, the conversion rules 201 of the records with flag=0 are applied, and the conversion rules 201 of the records with flag=1 are not applied (in other words, the application is excluded or skipped).
[0183] In other words, as already described, flag = 1 indicates that the conversion target string and the correct string are the same string in conversion rule 201, so by not applying conversion rule 201 with flag = 1, redundant (or unnecessary or wasteful) conversion of the same string into the same string is prevented.
[0184] Fig. 15 shows an example of a flowchart in which the above-mentioned flag determination process is added to the conversion process shown in Fig. 8. As shown in Fig. 15, the flag determination process (S1505) according to this modification is performed, for example, after the record reading process (S804 and S816) and before the character string matching process (S806).
[0185] Therefore, if the flag field 210 of the read record is flag=0 (YES in S1505), the conversion processing unit 102 determines to apply the conversion rule 201 of the record, and executes the processes from S806 onward described in FIG.
[0186] On the other hand, if the flag field 210 has flag=1 (NO in S1505), the conversion processing unit 102 decides not to apply the conversion rule 201 to the record, and repeats reading the next record (S816) until a record with flag=0 is found.
[0187] As described above, according to this modification, the application of the conversion rule 201 that would cause redundant conversion due to the flag determination process is skipped, so that the efficiency of the conversion process can be improved.
[0188] <Additional information> The information processing device 1 illustrated in FIG. 2 may be configured with at least one computer. The computer may be a server computer or a client computer. The processing executed by the computer may be distributed and executed on a plurality of computers including the computer. The plurality of computers may be, for example, a group of cloud servers virtualized by virtualization technology.
[0189] 2, the above-described embodiment has been described with reference to an aspect in which the conversion processing unit 102 and the conversion rule generation processing unit 104 are provided in the processing unit 10 of one information processing device 1. However, the present invention is not limited to such an aspect, and the conversion processing unit 102 and the conversion rule generation processing unit 104 may be configured, for example, as separate information processing devices (for example, computers).
[0190] <Hardware configuration example of information processing device 1> 16 is a diagram showing an example of a hardware configuration of a computer 1300 functioning as an information processing device 1 according to an embodiment. The computer 1300 may be physically configured to include, for example, a central processing unit (CPU) 1302, a storage device 1304, an input device 1306, and an output device 1308. These devices are connected to each other so as to be able to communicate with each other by a bus 1310 such as an address bus or a data bus.
[0191] The term "apparatus" may be interchangeably read as other terms such as a circuit, a device, a unit, etc. The hardware configuration of the computer 1300 may be configured to include one or more of the devices shown in FIG. 16, or may be configured to exclude some of the devices.
[0192] Each function in the computer 1300 is realized, for example, by the CPU 1302 reading and executing the program 205 or data used in conjunction with the execution of the program 205 from the storage device 1304. The data used in conjunction with the execution of the program 205 is, for example, the conversion list 200 having the data structure exemplified in Fig. 7. The CPU 1302 may be a single-core CPU or a multi-core CPU.
[0193] The program 205 is a program that, when read and executed by the CPU 1302, causes the computer 1300 to execute at least a part of the functions or processes of the information processing device 1 described in the above-described embodiment.
[0194] For example, the processing unit 10 including one or both of the conversion processing unit 102 and the conversion rule generation processing unit 104 illustrated in FIG. 2 can be realized by the CPU 1302 executing a program 205 in which an instruction set that specifies the exemplary functions or processes described with reference to FIGS. 3 to 15 is written.
[0195] The program 205 may be, for example, prestored in the storage device 1304, or may be received by the computer 1300 via a computer-readable storage medium or a network (electrical communication line) and stored in the storage device 1304. The program 205 may also be incorporated as a part of the operating system (OS) of the computer 1300.
[0196] The storage device 1304 is an example of a computer-readable storage medium, and may correspond to the storage unit 20 illustrated in Fig. 2. For example, the storage device 1304 stores the above-mentioned conversion list 200, log data 203, and program 205, and at least one of the conversion list 200, the log data 203, and the program 205 is appropriately read by the CPU 1302.
[0197] The storage device 1304 may include at least one of various storage media such as a read only memory (ROM), an erasable programmable ROM (EPROM), an electrically erasable programmable ROM (EEPROM), a random access memory (RAM), and a solid state drive (SSD). These various storage media may be used, for example, as a working memory for the CPU 1302.
[0198] Additionally or alternatively, the storage device 1304 may be configured to include at least one of various storage media, such as an optical disk such as a CD-ROM (Compact Disc ROM), a hard disk drive (HDD), an SSD, a flexible disk, a magneto-optical disk (e.g., a compact disk, a Blu-ray (registered trademark) disk), and a flash memory.
[0199] The input device 1306 is an input device (e.g., a keyboard, a mouse, a microphone, a switch, a button, a sensor, etc.) that provides various input operation environments for the computer 1300 and accepts input to the computer 1300. In addition, the input device 1306 may include, for example, a device that accepts input by voice recognition or gesture operation.
[0200] The input device 1306 can input the character recognition correction data 502 and the correct word 504 illustrated in FIG. 2 to the CPU 1302 functioning as the processing unit 10 (e.g., the conversion rule generation processing unit 104) via the memory device 1304 or without via the memory device 1304.
[0201] The output device 1308 is an output device (for example, a display corresponding to the display unit 30 illustrated in FIG. 2, a speaker, etc.) that performs output to an external device. The display is a device that displays the state of an input operation or a calculation result according to the input operation, and may be, for example, a liquid crystal display or an organic EL (Electro Luminescence) display. The input device 1306 and the output device 1308 may be integrated into one configuration, such as a touch panel.
[0202] The hardware configuration illustrated in FIG. 16 is merely an example, and is not limited thereto. A part or all of the hardware configuration may be constructed in software, for example, by virtualization technology. In addition, a part or all of the devices in the hardware configuration may be located in different locations, and the devices may operate in cooperation with each other remotely via a network. Furthermore, the hardware configuration illustrated in FIG. 16 may be shared in order for a part or all of a plurality of information processing systems to operate.
[0203] Although the present disclosure has been described in detail above, it is clear to those skilled in the art that the spirit and scope of the present disclosure are not limited to the contents described throughout the present disclosure. The present disclosure can be implemented as modified and altered forms without departing from the spirit and scope of the present disclosure as defined by the claims. Therefore, the description of the present disclosure is intended for illustrative purposes and does not have any limiting meaning on the spirit and scope of the present disclosure. [Explanation of symbols]
[0204] 1. Information processing device 10 Processing section 102 Conversion processing section 122 Acquisition Department 124 Matching Unit 126 Conversion Unit 128 Log output section 104 Conversion rule generation processing unit 142 String generator 144 Conversion rule generation unit 146 Management Department 20 Memory section 200 Conversion List 201-1~201-n Conversion rules 210 Flags Field 203 Log Data 205 Programs 30 Display section 1300 Computer 1302 Central Processing Unit (CPU) 1304 Storage device 1306 Input Device 1308 Output Device 1310 Bus
Claims
1. An information processing device that performs conversion on a character string obtained by character recognition processing on a document, a storage unit that stores a list of conversion rules that associates a conversion target character string for identifying a character string including a misrecognized character as a conversion target for each of a plurality of words having different numbers of characters, the conversion target character string being included as a part of a word having a larger number of characters than the associated word; a processing unit that sequentially performs, for an input string, a comparison with the conversion rule and converts a string that matches the conversion target string into a corresponding word in ascending order of the number of characters in the list.
2. The information processing apparatus according to claim 1 , wherein each of the conversion rules further comprises control information for controlling whether or not the conversion rule is applied in the processing unit.
3. a character string generating unit that generates the conversion target character string using character recognition correction data that associates correct characters constituting a word with characters that may be erroneously recognized as the correct characters in a character recognition process for a document; a conversion rule generating unit for generating the list of conversion rules that associate the words with the character strings to be converted; The information processing device according to claim 1 , further comprising:
4. The character string generation unit When the number of correct characters that may be erroneously recognized in the word is one and there are a plurality of erroneously-recognized candidate characters for the correct character, the correct character is replaced with a regular expression including the plurality of erroneously-recognized candidate characters; When the number of correct characters that may be erroneously recognized in the word is plural, each of the correct characters is replaced with a regular expression that includes a plurality of erroneously recognized candidate characters for the correct character and the correct character; and When there is one correct character that may be erroneously recognized in the word and there is one erroneously-recognized candidate character for the correct character, the correct character is replaced with the erroneously-recognized candidate character. The information processing apparatus according to claim 3 , wherein the conversion target character string is generated by executing at least one of the following:
5. The character string to be converted is a character string in which one correct character that may be erroneously recognized in the word is replaced with a regular expression including a plurality of candidate characters for erroneous recognition for the correct character; a character string in which each of a plurality of correct characters that may be erroneously recognized in the word is replaced with a regular expression including the correct character and a plurality of candidate characters for erroneous recognition for the correct character; the character string obtained by replacing one correct character that may be erroneously recognized in the word with one erroneously-recognized candidate character for the correct character;
6. The conversion rules in the list are sorted in ascending order of the number of characters, The information processing apparatus according to claim 1 , wherein the processing unit reads the conversion rules in the list in order from the top, and performs the matching in ascending order of the number of characters.
7. The processing unit includes:
3. The information processing device according to claim 1, further comprising: a character string before conversion; a character string after conversion; a character string obtained by the character recognition process that includes the conversion target character string before conversion and a character string obtained by the character recognition process that includes the word after conversion.
8. An information processing device that performs conversion on a character string obtained by character recognition processing on a document, comprising: a list of conversion rules that associates a conversion target character string with each of a plurality of words having different numbers of characters, the conversion target character string being used to identify a character string including a character that has been erroneously recognized as a conversion target, the conversion target character string being included as a part of a word having a larger number of characters than the associated word; reading the conversion rules from a storage unit that stores the list of conversion rules; comparing an input string with the conversion rule and converting a string that matches the conversion target string into a corresponding word; sequentially in ascending order of the number of characters in the list.
9. A program for causing an information processing device to execute conversion of a character string obtained by character recognition processing of a document, the program comprising: a list of conversion rules that associates a conversion target character string with each of a plurality of words having different numbers of characters, the conversion target character string being used to identify a character string including a character that has been erroneously recognized as a conversion target, the conversion target character string being included as a part of a word having a larger number of characters than the associated word; reading the conversion rules from a storage unit that stores the list of conversion rules; comparing an input string with the conversion rule and converting a string that matches the conversion target string into a corresponding word; in ascending order of the number of characters.
10. A computer-readable storage medium storing the program according to claim 9.
11. a character string generating unit which, when a character is erroneously recognized in a character recognition process for a document, identifies characters which may be erroneously recognized for each correct character of the word using character recognition correction data which associates correct characters constituting the word with characters which may be erroneously recognized as the correct characters in the character recognition process, in order to identify a character string including the erroneously recognized character, and generates a conversion target character string based on the identified characters which may be erroneously recognized, in order to identify a character string including the erroneously recognized character as a conversion target; a conversion rule generation unit that generates a conversion rule that associates the word with the conversion target character string; a conversion rule management unit that manages the conversion rules as a list in ascending order of the number of characters of the words.
12. the conversion rule is managed in a conversion rule management unit in units of records in which a record number based on the number of characters of the word, the word, and the conversion target character string are associated with each other; The information processing apparatus according to claim 11 , wherein the conversion rule management unit manages the records as a list by arranging the records in ascending order of the record numbers so that the records are in ascending order of the number of characters of the words.
13. The character string generation unit When the number of correct characters that may be erroneously recognized in the word is one and there are a plurality of erroneously-recognized candidate characters for the correct character, the correct character is replaced with a regular expression including the plurality of erroneously-recognized candidate characters; When the number of correct characters that may be erroneously recognized in the word is plural, each of the correct characters is replaced with a regular expression that includes a plurality of erroneously recognized candidate characters for the correct character and the correct character; and When there is one correct character that may be erroneously recognized in the word and there is one erroneously-recognized candidate character for the correct character, the correct character is replaced with the erroneously-recognized candidate character. The information processing apparatus according to claim 11 , wherein the conversion target character string is generated by executing at least one of the following:
14. Each of the conversion rules further includes control information for controlling whether or not the conversion rule is applied; The conversion rule management unit Checking whether a character string corresponding to a word in a conversion rule of a target entry is included in a conversion target character string in a conversion rule of a lower entry in the list from the top entry of the list, For the conversion target string corresponding to the entry confirmed to contain a string corresponding to the word, a portion corresponding to the word in the conversion rule of the entry of interest is replaced with the word in the conversion rule of the entry of interest; 13. An information processing device as described in claim 11 or 12, wherein, if a conversion target string of a conversion rule in an entry lower than the target entry, including the replaced word, is the same as the word in the lower entry, information indicating non-application of the conversion rule in the lower entry is recorded in the control information, and if they are different, information indicating application of the conversion rule in the lower entry is recorded in the control information.
15. An information processing device for converting a character string obtained by character recognition processing on a document, comprising: In the character recognition process, when a character is erroneously recognized, character recognition correction data is used to associate correct characters constituting a word with characters that may be erroneously recognized as the correct characters in the character recognition process, in order to specify a character string including the erroneously recognized character, and the character recognition correction data is used to specify characters that may be erroneously recognized for each correct character of the word, and a conversion target character string is generated based on the specified characters that may be erroneously recognized, in order to specify a character string including the erroneously recognized character as a conversion target; generating a conversion rule that associates the word with the character string to be converted; Perform a process including The process, Reading the conversion rule stored in a storage unit; comparing an input string with the conversion rule and converting a string that matches the conversion target string into a corresponding word; sequentially in ascending order of the number of characters of the words.
16. A program for causing an information processing device to execute conversion of a character string obtained by character recognition processing of a document, the program comprising: In the character recognition process, when a character is erroneously recognized, character recognition correction data is used to associate correct characters constituting a correct character string of a word with characters that may be erroneously recognized as the correct characters in the character recognition process, in order to specify a character string including the erroneously recognized character, and the character recognition correction data is used to specify characters that may be erroneously recognized for each correct character of the word, and a conversion target character string is generated based on the specified characters that may be erroneously recognized, in order to specify a character string including the erroneously recognized character as a conversion target; generating a conversion rule that associates the word with the character string to be converted; causing the information processing device to execute a process including The process, Reading the conversion rule stored in a storage unit; comparing an input string with the conversion rule and converting a string that matches the conversion target string into a corresponding word; sequentially in ascending order of the number of characters of the words.
17. A computer-readable storage medium storing the program according to claim 16.
Citation Information
Patent Citations
Information processing device and information processing program
JP2020123232A
Correcting system of character recognizing result
JP1997138836A