Video recall method
By establishing a full-value pinyin and character-by-character pinyin recall database, extracting the pinyin features of film and television database titles, and correcting user voice expressions, the problem of inaccurate video retrieval is solved, achieving higher retrieval accuracy and user experience.
Patent Information
- Application Number
- CN202111262439.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-10-28
- Publication Date
- 2025-10-28
- Estimated Expiration
- 2041-10-28
AI Technical Summary
Existing video retrieval systems fail to consider user expression habits such as abbreviations and dysplaced expressions, resulting in the inability to accurately retrieve videos during speech recognition.
By establishing a pinyin full-value recall database and a character-by-character pinyin recall database, the pinyin features of the film and television database titles, including full-value features and character-by-character features, are extracted. The user's voice text is corrected using a preset recognition algorithm, and multi-dimensional pinyin feature similarity calculation is performed to determine the video recall results.
It improves the accuracy of video retrieval when users use abbreviations or dysplaced expressions, and enhances the intelligent interactive experience.
Smart Images

Figure CN113901269B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of natural language processing, and in particular to a video recall method. Background Art
[0002] With the integration of TV products with intelligent voice into people's lives, the number of users using voice-on-demand for film and television videos is increasing. However, due to differences in dialects, expression abilities, etc. among different users, and problems such as error rates in speech recognition, the standard film names usually cannot be recognized, causing great difficulties in video retrieval. Currently, based on the characteristic that the pronunciation of the user's expression and the speech recognition result is basically the same, the pinyin features can be used to recognize film names with similar pronunciations. However, it only considers the similarity of pronunciation and does not take into account the user's expression habits, such as abbreviated expressions, e.g., only saying "City Fort" for "You Are My City Fort", and expression transpositions, e.g., expressing "Good Voice 2021" as "2021 Good Voice", resulting in incorrect video retrieval. Summary of the Invention
[0003] The present invention aims to solve the problem of inaccurate existing video retrieval and proposes a video recall method.
[0004] The technical solution adopted by the present invention to solve the above technical problems is: a video recall method, including the following steps:
[0005] Step 1: After preprocessing the reading methods of all film name texts in the film and television database, extract pinyin features, where the pinyin features include full-value features and character-separated features. The full-value feature is the full-value pinyin without tones corresponding to the film name text, and the character-separated features include the full-value pinyin with tones corresponding to the film name text, the full-value pinyin sorted without tones, and the list of adjacent-character pinyins without tones;
[0006] Step 2: Create a full-value pinyin recall database and a character-separated pinyin recall database according to the extracted pinyin features. The key of the full-value pinyin recall database is the full-value feature of the film name text, and the value is the list of film name texts with the same full-value feature. The key of the character-separated pinyin recall database is the element of the list of adjacent-character pinyins without tones of the film name text, and the value is the list of film name features having this element. The film name features include: the film name text, its corresponding full-value pinyin with tones, and the full-value pinyin sorted without tones;
[0007] Step 3: When receiving the voice text input by the user, extract the text to be corrected that may be the film name text from the voice text according to the preset recognition algorithm, and perform the same reading preprocessing and pinyin feature extraction on the text to be corrected as in Step 1 to obtain the pinyin features corresponding to all reading methods of the text to be corrected;
[0008] Step 4: Based on the pinyin features corresponding to each pronunciation of the text to be corrected, perform full value feature recall and character segmentation feature recall based on the pinyin full value recall database and the character segmentation pinyin recall database respectively, and obtain the full value feature recall results and character segmentation feature recall results;
[0009] Step 5: If the full-value feature recall result contains a video title, then use that video title as the video recall result; otherwise, determine the similarity of each video title in the character segmentation feature recall result, and determine the video recall result based on the similarity.
[0010] Furthermore, before determining the similarity of each title in the word segmentation feature recall results, the process also includes:
[0011] The number of common substrings between the list of adjacent characters without tone marks in each title text in the character segmentation feature retrieval result and the list of adjacent characters without tone marks in the user-input voice text is obtained. If the number of common substrings is less than a first preset threshold, the corresponding title text is discarded. The first preset threshold is determined based on the length of the text to be corrected.
[0012] Furthermore, before determining the similarity of each title in the word segmentation feature recall results, the process also includes:
[0013] The text length difference between each title text and the text to be corrected in the character segmentation feature recall results is obtained. If the text length difference is greater than a second preset threshold, the corresponding title text is discarded.
[0014] Furthermore, before determining the similarity of each title in the word segmentation feature recall results, the process also includes:
[0015] Obtain the full-value pinyin with tones corresponding to the user-input speech text. Calculate the first pinyin edit distance score for each title text in the character segmentation feature recall results based on the full-value pinyin with tones corresponding to the speech text and the full-value pinyin with tones in the character segmentation feature recall results. If the first pinyin edit distance score is less than a third preset threshold, discard the corresponding title. The formula for calculating the first pinyin edit distance score is as follows:
[0016] l pn =lev(n pn ,t pn );
[0017] In the formula, l pn The first pinyin edit distance score is given, lev() is the edit distance algorithm, and n pn For the full-value pinyin with tone marks in the character segmentation feature recall results, t pn This is the full-value pinyin with tones corresponding to the spoken text.
[0018] Furthermore, methods for determining the similarity of different movie titles in the word segmentation feature recall results also include:
[0019] Calculate the second pinyin edit distance score corresponding to each movie title text in the word segmentation feature recall results after sorting;
[0020] Get the length of the list of adjacent characters without tone marks corresponding to the user's input voice text, the number of common substrings corresponding to each title text in the character segmentation feature recall results, and the maximum value of the number of common substrings in the character segmentation feature recall results;
[0021] The coefficient of the common substrings corresponding to each title text in the character segmentation feature recall results is calculated based on the first pinyin edit distance score, the second pinyin edit distance score, the length of the adjacent character pinyin list without tone corresponding to the speech text, the number of common substrings corresponding to each title text in the character segmentation feature recall results, and the maximum value of the number of common substrings in the character segmentation feature recall results.
[0022] The similarity of each title in the character segmentation feature recall results is calculated based on the first pinyin edit distance score, the second pinyin edit distance score, and the common substring coefficient.
[0023] Furthermore, the calculation method for the second Pinyin editing distance score is as follows:
[0024] If the first pinyin edit distance score of the title text in the character segmentation feature recall result is greater than the fourth preset threshold, then the first pinyin edit distance score of the title text will be used as the second pinyin edit distance score of the title text.
[0025] If the first pinyin edit distance score corresponding to the title text in the character segmentation feature recall result is less than or equal to the fourth preset threshold, then obtain the full value pinyin of the user-input speech text after sorting without tone, and calculate the second pinyin edit distance score corresponding to each title text in the character segmentation feature recall result based on the full value pinyin of the speech text after sorting without tone and the full value pinyin of the character segmentation feature recall result after sorting without tone.
[0026] The formula for calculating the second pinyin editing distance score is as follows:
[0027]
[0028] In the formula, l pr For the second pinyin edit distance score, n pr For the full-value pinyin without tone in the character segmentation feature recall results, t pr is the full-value pinyin of the speech text after sorting without tone marks, and r is the fourth preset threshold.
[0029] Furthermore, the formula for calculating the coefficients of the common substring is as follows:
[0030]
[0031] In the formula: s r Let l be the coefficient of the common substring. pn The distance score for the first Pinyin edit, l pr For the second pinyin editing distance score, t pl s represents the length of the list of adjacent characters in pinyin without tones corresponding to the spoken text. n s represents the number of common substrings corresponding to the movie title text in the character segmentation feature recall results. n_max This represents the maximum number of substrings found in the character segmentation feature recall results.
[0032] Furthermore, the similarity calculation formula for the film titles is as follows:
[0033]
[0034] Further, in step 5, if there is more than one title in the full-value feature recall result, the full-value pinyin with tone corresponding to each title text in the full-value feature recall result and the full-value pinyin with tone corresponding to the user-input voice text are obtained. The third pinyin edit distance score corresponding to each title text in the full-value feature recall result is calculated based on the full-value pinyin with tone corresponding to each title text in the full-value feature recall result and the full-value pinyin with tone corresponding to the user-input voice text. The title corresponding to the maximum value of the third pinyin edit distance score is taken as the video recall result.
[0035] Furthermore, in step 5, the method for determining the video recall result based on the similarity includes:
[0036] The maximum similarity value is determined. If the maximum similarity value is greater than the fifth preset threshold, the video title corresponding to the maximum similarity value is used as the video recall result; otherwise, the video recall result is empty.
[0037] The beneficial effects of this invention are: the video retrieval method described in this invention uses multi-dimensional character-based pinyin features to retrieve videos with similar titles, which improves the recognition accuracy when users use abbreviations or different expressions when searching for videos, and enhances the intelligent interactive experience of users using voice. Attached Figure Description
[0038] Figure 1 This is a schematic flowchart of the video recall method according to an embodiment of the present invention;
[0039] Figure 2 This is another schematic diagram of the video recall method described in an embodiment of the present invention.
[0040] Figure 3 This is a schematic diagram of the video recall structure according to an embodiment of the present invention; Detailed Implementation
[0041] The embodiments of the present invention will now be described in detail with reference to the accompanying drawings.
[0042] The video retrieval method of the present invention includes the following steps: Step 1: After preprocessing the pronunciation of all movie title texts in the film and television database, extract pinyin features. The pinyin features include full-value features and character-segmentation features. The full-value features are the full-value pinyin of the movie title text without tones. The character-segmentation features include the full-value pinyin of the movie title text with tones, the full-value pinyin sorted without tones, and a list of adjacent character pinyin without tones. Step 2: Create a full-value pinyin retrieval database and a character-segmentation pinyin retrieval database based on the extracted pinyin features. The key of the full-value pinyin retrieval database is the full-value feature of the movie title text, and the value is a list of movie title texts with the same full-value feature. The key of the character-segmentation pinyin retrieval database is an element of the list of adjacent character pinyin without tones of the movie title text, and the value is a list of movie title features containing that element. The title features include: the title text and its corresponding full-value pinyin with and without tones; Step 3: After receiving the user's input voice text, extract the text to be corrected from the voice text that may be the title text according to the preset recognition algorithm, and perform the same reading preprocessing and pinyin feature extraction as in Step 1 on the text to be corrected to obtain the pinyin features corresponding to all readings of the text to be corrected; Step 4: Based on the pinyin features corresponding to each reading of the text to be corrected, perform full-value feature recall and character-segment feature recall based on the full-value pinyin recall database and the character-segment pinyin recall database respectively to obtain the full-value feature recall result and the character-segment feature recall result; Step 5: If the title is in the full-value feature recall result, then the title is used as the video recall result; otherwise, determine the similarity of each title in the character-segment feature recall result, and determine the video recall result based on the similarity.
[0043] Specifically, this invention first establishes a full-value pinyin recall database and a character-segmented pinyin recall database based on all film titles in the film and television database. The full-value pinyin recall database is established using the full-value features in the pinyin features corresponding to the film title, while the character-segmented pinyin recall database is established using the character-segmented features in the pinyin features corresponding to the film title. The full-value features are the full-value pinyin of the film title text without tones, with characters separated by "-". The full-value features are used to recall film titles with completely identical pronunciations. The character segmentation features include three parts: (1) full-value pinyin with tone marks; the tone marks are represented by numbers and used to calculate the similarity between the original text and the target title; (2) full-value pinyin without tone marks; used to calculate the similarity between the sorted original text and the sorted target title, which is a feature for expressing dislocation; (3) a list of adjacent character pinyin without tone marks; when the number of characters in the text is 1, it is single-character pinyin; when the number of characters is 2, it is single-character pinyin + adjacent two-character pinyin; when the number of characters is 3, it is single-character pinyin + adjacent two-character pinyin + adjacent three-character pinyin; when the number of characters is 4, it is the first two single-character pinyin + adjacent two-character pinyin + adjacent three-character pinyin; when the number of characters is greater than 4, it is adjacent two-character pinyin + adjacent three-character pinyin, which is used for character segmentation feature recall to find titles similar to the text to be corrected.
[0044] When video retrieval is required based on user-inputted speech, the user-inputted speech text is preprocessed for pronunciation and then Pinyin features are extracted. Retrieval is performed in the Pinyin full-value recall database based on the extracted Pinyin features, and in the character-segmentation Pinyin recall database based on the extracted Pinyin features. If a video title is found in the full-value feature recall results, that video title is used as the video retrieval result. If no video title is found in the full-value feature recall results, the similarity between the video titles in the character-segmentation feature recall results is determined, and the video retrieval result is determined based on the similarity. Finally, the video retrieval result is output to the user.
[0045] Example
[0046] The video recall method described in this embodiment of the invention, such as Figure 1 As shown, it includes the following steps:
[0047] Step 1: After preprocessing the reading of all movie title texts in the film and television database, extract the pinyin features. The pinyin features include full value features and character segmentation features. The full value features are the full value pinyin of the movie title text without tone marks. The character segmentation features include the full value pinyin of the movie title text with tone marks, the full value pinyin sorted without tone marks, and a list of adjacent character pinyin without tone marks.
[0048] The reading method preprocessing is mainly used to process numbers. First, it extracts consecutive numbers from the text, then converts them into Chinese according to reading methods such as reading individual numbers and reading the whole number, and then embeds them into the original text.
[0049] Due to the large number of film title data with years, in order to reduce the recall pressure at the data level, according to the common habits of most people, if the difference in the pronunciation lengths of the two readings is greater than or equal to 2, the reading of reading individual digits is defaulted (except for 2000). For example: The reading of individual digits of "2012" is "er ling yi er", and the reading of the whole number is "two thousand and twelve", and the difference in length is equal to 2, so the former reading is defaulted. The reading of individual digits of "2002" is "er ling ling er", and the reading of the whole number is "two thousand and two", and the lengths are the same, so there are two default readings. For another example, 567 may be read as "wu liu qi" or "five hundred and sixty-seven". If the user's reading is inconsistent with the database data, it will affect the similarity, so it needs to be unified. Extract the continuous numbers in the text, then convert them into Chinese according to the readings of reading individual digits and the whole number, etc., and then embed them into the original text. This can handle the similarity loss caused by the difference between Arabic numerals and Chinese numerals in the film title.
[0050] Among them, the pinyin features are divided into full-value features and character-separated features.
[0051] The full-value feature is the full-value pinyin of the text without tones, separated by "-" between characters. The full-value feature is used to recall film titles with exactly the same pronunciation. For example: The full-value feature of "Siteng" is "si-teng".
[0052] The character-separated features are divided into three parts.
[0053] (1) The full-value pinyin with tones, and the tones are represented by numbers, which is used to calculate the similarity between the original text and the target film title. For example: The full-value feature with tones of "Siteng" is "si1-teng2", and the full-value feature with tones of "2021 Chuangzaoying" is "er4-ling2-er4-yi1-chuang4-zao4-ying2".
[0054] (2) The full-value pinyin sorted without tones, which is used to calculate the similarity between the sorted original text and the sorted target film title. For example: The full-value feature sorted without tones of "Siteng" is "si-teng", and the full-value feature sorted without tones of "2021 Chuangzaoying" is "chuang-er-er-ling-yi-ying-zao".
[0055] (3) The list of adjacent-character pinyin without tones, which is used for character-separated feature recall. When the number of characters is 1, it is the single-character pinyin; when the number of characters is 2, it is the single-character pinyin + the adjacent two-character pinyin; when the number of characters is 3, it is the single-character pinyin + the adjacent two-character pinyin + the adjacent three-character pinyin; when the number of characters is 4, it is the first two single-character pinyin + the adjacent two-character pinyin + the adjacent three-character pinyin; when the number of characters is greater than 4, it is the adjacent two-character pinyin + the adjacent three-character pinyin. The adjacent-character pinyin are separated by "-".
[0056] For example, the list of pinyin of adjacent characters without tones for "Siteng" is ["si-teng", "si", "teng"], and the list of pinyin of adjacent characters without tones for "2021 Produce Camp" is ["er-ling-er", "ling-er-yi", "er-yi-chuang", "yi-chuang-zao", "chuang-zao-ying", "er-ling", "ling-er", "er-yi", "yi-chuang", "chuang-zao", "zao-ying"].
[0057] Step 2: Create a full-value pinyin recall database and a segmented pinyin recall database based on the extracted pinyin features respectively. The key of the full-value pinyin recall database is the full-value feature of the title text, and the value is the list of title texts with the same full-value feature. The key of the segmented pinyin recall database is the element of the list of pinyin of adjacent characters without tones in the title text, and the value is the list of title features with this element. The title features include: the title text, its corresponding full-value pinyin with tones, and the full-value pinyin sorted without tones.
[0058] After obtaining the full-value features and segmented features corresponding to all title texts in the video database through Step 1, use an existing key-value database, and construct a full-value pinyin recall database based on the full-value features corresponding to all title texts, and construct a segmented pinyin recall database based on the segmented features corresponding to all title texts.
[0059] (1) Full-value pinyin recall database. The field is the full-value pinyin feature of the title text, and the value is the list of title texts with the same full-value feature.
[0060] For example, when the key is "si-teng", its corresponding value is ["Siteng"]; when the key is "wu-jian-dao", its corresponding value is ["Wujian Dao", "Wujiandao", "Wujian Dao"].
[0061] (2) Segmented pinyin recall database. The key is the element of the list of pinyin of adjacent characters without tones in the title, and the value is the list of title features with this element. The title features stored in the value include the title text, the full-value pinyin with tones, and the full-value pinyin sorted without tones, separated by "_" in sequence.
[0062] For example, if the field is "si-teng", the corresponding value is "["2014 Tencent T-Pai Summer Camp Tencent's Massive Way_er4-ling2-yi1-si4-teng2-xun4-t-pai4-xia4-ling4-ying2-teng2-xun4-de5-hai3-liang4-zhi1-dao4_dao-de-er-hai-liang-ling-ling-pai-si-t-teng-teng-xia-xun-xun-yi-ying-zhi","Si Teng_si1-teng2_si-teng"]".
[0063] Step 3: After receiving the voice text input by the user, extract the text to be corrected from the voice text that may be the title text according to the preset recognition algorithm, and perform the same reading preprocessing and pinyin feature extraction as in Step 1 on the text to be corrected to obtain the pinyin features corresponding to all readings of the text to be corrected.
[0064] Specifically, the text to be corrected that may be the title text in the speech text can be extracted according to the preset entity recognition algorithm bilstm-crf, and the possible pronunciations of the text to be corrected and the corresponding pinyin features of each pronunciation can be obtained by the same method as in step 1.
[0065] Step 4: Based on the pinyin features corresponding to each pronunciation of the text to be corrected, perform full value feature recall and character segmentation feature recall based on the pinyin full value recall database and the character segmentation pinyin recall database respectively, and obtain the full value feature recall results and character segmentation feature recall results;
[0066] It is understood that in this embodiment, each pronunciation obtained in step 3 is used to recall the title separately, and each recall is performed in the full-value pinyin recall database and the character-segmented pinyin recall database respectively.
[0067] Step 5: If the full-value feature recall result contains a video title, then use that video title as the video recall result; otherwise, determine the similarity of each video title in the character segmentation feature recall result, and determine the video recall result based on the similarity.
[0068] Specifically, the full value feature recall and word segmentation feature recall for a certain reading method are processed separately, with the full value feature recall being processed first.
[0069] Full-value feature recall: If a title is recalled, it is considered a perfect match with a similarity of 1, and the word segmentation feature recall result is not considered. If only one title is recalled using full-value feature recall, that title is used as the video recall result. Otherwise, the full-value pinyin with tones corresponding to each title text in the full-value feature recall result and the full-value pinyin with tones corresponding to the user-input speech text are obtained. The third pinyin edit distance score corresponding to each title text in the full-value feature recall result is calculated based on the full-value pinyin with tones corresponding to each title text in the full-value feature recall result and the user-input speech text. The title with the maximum third pinyin edit distance score is used as the video recall result. If full-value feature recall does not recall a title, the video recall result is determined based on the word segmentation feature recall result.
[0070] Character segmentation feature recall: divided into coarse screening and fine typesetting.
[0071] like Figure 2 and Figure 3 As shown, in this embodiment, the coarse screening includes three dimensions of filtration:
[0072] (1) Number of common substrings. The title meets the filtering criteria for this dimension only when the number of common substrings is greater than the first preset threshold. The filtering method is as follows: obtain the number of common substrings between the list of adjacent characters without tone marks in the title text corresponding to each title text in the character segmentation feature recall result and the list of adjacent characters without tone marks in the user input voice text. If the number of common substrings is less than the first preset threshold, the corresponding title is discarded. The first preset threshold is determined according to the length of the text to be corrected.
[0073] (2) Text length difference. The title meets the screening criteria for this dimension only when the text length difference is less than the second preset threshold. The filtering method is as follows: obtain the text length difference between each title text and the text to be corrected in the character segmentation feature recall results. If the text length difference is greater than the second preset threshold, the corresponding title is discarded.
[0074] (3) First Pinyin Edit Distance Score. The title only meets the filtering criteria for this dimension when the first Pinyin edit distance score is greater than the third threshold. The filtering method is as follows: Obtain the full-value Pinyin with tones corresponding to the user-input speech text; calculate the first Pinyin edit distance score corresponding to each title text in the character segmentation feature recall results based on the full-value Pinyin with tones corresponding to the speech text and the full-value Pinyin with tones in the character segmentation feature recall results; if the first Pinyin edit distance score is less than or equal to the third preset threshold, discard the corresponding title. The calculation formula for the first Pinyin edit distance score is as follows:
[0075] l pn =lev(n pn ,tpn );
[0076] In the formula, l pn The first pinyin edit distance score is given, lev() is the edit distance algorithm, and n pn For the full-value pinyin with tone marks in the character segmentation feature recall results, t pn This is the full-value pinyin with tones corresponding to the spoken text.
[0077] In this embodiment, fine ranking mainly involves three dimensions: the first pinyin edit distance score, the second pinyin edit distance score, and the common substring coefficient. Fine ranking determines the similarity of each title in the character segmentation feature recall results. Specific methods include:
[0078] Calculate the second pinyin edit distance score corresponding to each movie title text in the word segmentation feature recall results after sorting;
[0079] Get the length of the list of adjacent characters without tone marks corresponding to the user's input voice text, the number of common substrings corresponding to each title text in the character segmentation feature recall results, and the maximum value of the number of common substrings in the character segmentation feature recall results;
[0080] The coefficient of the common substrings corresponding to each title text in the character segmentation feature recall results is calculated based on the first pinyin edit distance score, the second pinyin edit distance score, the length of the adjacent character pinyin list without tone corresponding to the speech text, the number of common substrings corresponding to each title text in the character segmentation feature recall results, and the maximum value of the number of common substrings in the character segmentation feature recall results.
[0081] The similarity of each title in the character segmentation feature recall results is calculated based on the first pinyin edit distance score, the second pinyin edit distance score, and the common substring coefficient.
[0082] The calculation method for the second pinyin editing distance score is as follows:
[0083] If the first pinyin edit distance score of the title text in the character segmentation feature recall result is greater than the fourth preset threshold, then the first pinyin edit distance score of the title text will be used as the second pinyin edit distance score of the title text.
[0084] If the first pinyin edit distance score corresponding to the title text in the character segmentation feature recall result is less than or equal to the fourth preset threshold score, then obtain the full value pinyin without tone sorting corresponding to the user input voice text, and calculate the second pinyin edit distance score corresponding to each title text in the character segmentation feature recall result based on the full value pinyin without tone sorting corresponding to the voice text and the full value pinyin without tone sorting in the character segmentation feature recall result.
[0085] The formula for calculating the second pinyin editing distance score is as follows:
[0086]
[0087] In the formula, l pr For the second pinyin edit distance score, n pr For the full-value pinyin without tone in the character segmentation feature recall results, t pr is the full-value pinyin of the speech text after sorting without tone marks, and r is the fourth preset threshold.
[0088] The formula for calculating the coefficients of the common substring is as follows:
[0089]
[0090] In the formula: s r Let l be the coefficient of the common substring. pn The distance score for the first Pinyin edit, l pr For the second pinyin editing distance score, t pl s represents the length of the list of adjacent characters in pinyin without tones corresponding to the spoken text. n s represents the number of common substrings corresponding to the movie title text in the character segmentation feature recall results. n_max This represents the maximum number of substrings found in the character segmentation feature recall results.
[0091] The formula for calculating the similarity of the film titles is as follows:
[0092]
[0093] After obtaining the similarity of each video title in the segmented feature recall result according to the above method, the maximum similarity value is determined. If the maximum similarity value is greater than the fifth preset threshold, the video title corresponding to the maximum similarity value is taken as the video recall result; otherwise, the video recall result is empty.
[0094] In summary, the video recall method described in this embodiment utilizes the pinyin features of multiple dimensions corresponding to the user's statement to recall similar movie titles. The final similarity is calculated by the similarity of edit distance, common substring coefficient, and out-of-place similarity based on edit distance between the recalled movie title pinyin and the user's statement pinyin. The movie title with the highest similarity is selected as the result, which improves the accuracy of video recall when the user expresses the movie title in abbreviated form or in an out-of-place form.
Claims
1. A video recall method, characterized in that, Includes the following steps: Step 1: After preprocessing the reading of all movie title texts in the film and television database, extract the pinyin features. The pinyin features include full value features and character segmentation features. The full value features are the full value pinyin of the movie title text without tone marks. The character segmentation features include the full value pinyin of the movie title text with tone marks, the full value pinyin sorted without tone marks, and a list of adjacent character pinyin without tone marks. Step 2: Based on the extracted pinyin features, create a pinyin full-value recall database and a character-segmented pinyin recall database respectively. The key of the pinyin full-value recall database is the full-value feature of the title text, and the value is a list of title texts with the same full-value feature. The key of the character-segmented pinyin recall database is an element of the pinyin list of adjacent characters without tone marks in the title text, and the value is a list of title features containing that element. The title features include: the title text and its corresponding full-value pinyin with tone marks and the full-value pinyin sorted without tone marks. Step 3: After receiving the voice text input by the user, extract the text to be corrected from the voice text that may be the title text according to the preset recognition algorithm, and perform the same reading preprocessing and pinyin feature extraction as in Step 1 on the text to be corrected to obtain the pinyin features corresponding to all readings of the text to be corrected. Step 4: Based on the pinyin features corresponding to each pronunciation of the text to be corrected, perform full value feature recall and character segmentation feature recall based on the pinyin full value recall database and the character segmentation pinyin recall database respectively, and obtain the full value feature recall results and character segmentation feature recall results; Step 5: If the full-value feature recall result contains a video title, then use that video title as the video recall result; otherwise, determine the similarity of each video title in the character segmentation feature recall result, and determine the video recall result based on the similarity.
2. The video recall method as described in claim 1, characterized in that, Before determining the similarity of each title in the word segmentation feature recall results, the following steps are also included: The number of common substrings between the list of adjacent characters without tone marks in each title text in the character segmentation feature retrieval result and the list of adjacent characters without tone marks in the user-input voice text is obtained. If the number of common substrings is less than a first preset threshold, the corresponding title text is discarded. The first preset threshold is determined based on the length of the text to be corrected.
3. The video recall method as described in claim 1, characterized in that, Before determining the similarity of each title in the word segmentation feature recall results, the following steps are also included: The text length difference between each title text and the text to be corrected in the character segmentation feature recall results is obtained. If the text length difference is greater than a second preset threshold, the corresponding title text is discarded.
4. The video recall method as described in claim 1, characterized in that, Before determining the similarity of each title in the word segmentation feature recall results, the following steps are also included: Obtain the full-value pinyin with tones corresponding to the user-input speech text. Calculate the first pinyin edit distance score for each title text in the character segmentation feature recall results based on the full-value pinyin with tones corresponding to the speech text and the full-value pinyin with tones in the character segmentation feature recall results. If the first pinyin edit distance score is less than a third preset threshold, discard the corresponding title. The formula for calculating the first pinyin edit distance score is as follows: ; In the formula, The distance score is given to the first pinyin editor. To edit the distance algorithm, The full-value pinyin with tone marks is retrieved from the character segmentation feature recall results. This is the full-value pinyin with tones corresponding to the spoken text.
5. The video recall method as described in claim 4, characterized in that, Methods for determining the similarity of film titles in the word segmentation feature recall results also include: Calculate the second pinyin edit distance score corresponding to each movie title text in the word segmentation feature recall results after sorting; Get the length of the list of adjacent characters without tone marks corresponding to the user's input voice text, the number of common substrings corresponding to each title text in the character segmentation feature recall results, and the maximum value of the number of common substrings in the character segmentation feature recall results; The coefficient of the common substrings corresponding to each title text in the character segmentation feature recall results is calculated based on the first pinyin edit distance score, the second pinyin edit distance score, the length of the adjacent character pinyin list without tone corresponding to the speech text, the number of common substrings corresponding to each title text in the character segmentation feature recall results, and the maximum value of the number of common substrings in the character segmentation feature recall results. The similarity of each title in the character segmentation feature recall results is calculated based on the first pinyin edit distance score, the second pinyin edit distance score, and the common substring coefficient; The calculation method for the second Pinyin editing distance score is as follows: If the first pinyin edit distance score of the title text in the character segmentation feature recall result is greater than the fourth preset threshold, then the first pinyin edit distance score of the title text will be used as the second pinyin edit distance score of the title text. If the first pinyin edit distance score corresponding to the title text in the character segmentation feature recall result is less than or equal to the fourth preset threshold, then obtain the full value pinyin of the user-input speech text after sorting without tone, and calculate the second pinyin edit distance score corresponding to each title text in the character segmentation feature recall result based on the full value pinyin of the speech text after sorting without tone and the full value pinyin of the character segmentation feature recall result after sorting without tone. The formula for calculating the second pinyin editing distance score is as follows: ; In the formula, Score the distance to the second pinyin edit. The full-value pinyin (excluding tone marks) retrieved from the character segmentation feature recall results is the result of sorting the pinyin based on its full value. This is the full-value pinyin of the speech text, sorted without tones. The fourth preset threshold; The formula for calculating the coefficients of the common substring is as follows: ; In the formula: The coefficients of the common substrings, The distance score is given to the first pinyin editor. Score the distance to the second pinyin edit. This represents the length of the list of adjacent characters' pinyin without tones corresponding to the spoken text. This represents the number of common substrings corresponding to the movie title text in the character segmentation feature recall results. The maximum number of substrings found in the character segmentation feature recall results; The similarity of the movie titles The calculation formula is as follows: 。 6. The video recall method as described in claim 1, characterized in that, In step 5, if there is more than one title in the full-value feature recall result, the full-value pinyin with tone corresponding to each title text in the full-value feature recall result and the full-value pinyin with tone corresponding to the user-input voice text are obtained. The third pinyin edit distance score corresponding to each title text in the full-value feature recall result is calculated based on the full-value pinyin with tone corresponding to each title text in the full-value feature recall result and the full-value pinyin with tone corresponding to the user-input voice text. The title corresponding to the maximum value of the third pinyin edit distance score is taken as the video recall result.
7. The video recall method as described in claim 1, characterized in that, In step 5, the method for determining the video recall result based on the similarity includes: The maximum similarity value is determined. If the maximum similarity value is greater than the fifth preset threshold, the video title corresponding to the maximum similarity value is used as the video recall result; otherwise, the video recall result is empty.
Citation Information
Patent Citations
Method and device for retrieving work order address of power distribution network
CN106503033A
POI text retrieval method and device, and electronic equipment
CN110765262A