TW201719452A - A system and method for training robots through voice - Google Patents

A system and method for training robots through voice Download PDF

Info

Publication number
TW201719452A
TW201719452A TW105120437A TW105120437A TW201719452A TW 201719452 A TW201719452 A TW 201719452A TW 105120437 A TW105120437 A TW 105120437A TW 105120437 A TW105120437 A TW 105120437A TW 201719452 A TW201719452 A TW 201719452A
Authority
TW
Taiwan
Prior art keywords
statement
preset
conditional statement
robot
training
Prior art date
Application number
TW105120437A
Other languages
Chinese (zh)
Other versions
TWI594136B (en
Inventor
蔡明峻
Original Assignee
芋頭科技(杭州)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 芋頭科技(杭州)有限公司 filed Critical 芋頭科技(杭州)有限公司
Publication of TW201719452A publication Critical patent/TW201719452A/en
Application granted granted Critical
Publication of TWI594136B publication Critical patent/TWI594136B/en

Links

Classifications

    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS OR SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING; SPEECH OR AUDIO CODING OR DECODING
    • G10L15/00Speech recognition
    • G10L15/02Feature extraction for speech recognition; Selection of recognition unit

Abstract

The invention discloses a system and method for training robots through voice, a receiving unit of the system for training robots through voice is used for receiving voice signals; a parsing unit connects to the receiving unit, and is used for parsing the voice signals, matching the voice signals with preset statements, to acquire conditional statements matching with the preset statements and corresponding to the voice signals and execute statements corresponding to the voice signals; a processing unit connects to the parsing unit, and is used for combining the conditional statements and the execute statements to generate a target entry; a storage unit connects to the processing unit, and is used for storing a preset entry, and training robots according to the preset entry; the processing unit performs weighting calculation according to the target entry, and performs corresponding process according to the weighting results.

Description

一種通過語音對機器人進行訓練的系統及方法System and method for training robot by voice

本發明涉及機器人領域,尤其涉及一種通過語音對機器人進行訓練的系統及方法。The present invention relates to the field of robots, and more particularly to a system and method for training a robot by voice.

目前對機器人行爲進行訓練的方法僅限於使用編程開發的方式來對機器人的邏輯進行修改,開發者通過修改機器人的程序邏輯,完成在滿足某項條件下執行某種動作的設定。這種訓練方式對於機器人底層開發是必須的,但進入上層邏輯開發時,則出現開發效率低,錯誤率高等缺陷;這種訓練方式不適用於不具備編程開發專業技能的普通用戶,如果普通用戶想對機器人的行爲做少許修改,則需要耗費大量的時間進行學習。At present, the method of training robot behavior is limited to the use of programming development to modify the logic of the robot. The developer modifies the program logic of the robot to complete the setting of performing certain actions under certain conditions. This training method is necessary for the underlying development of the robot, but when it enters the upper logic development, it has the defects of low development efficiency and high error rate; this training method is not suitable for ordinary users who do not have the professional skills of programming development, if ordinary users If you want to make a small change to the behavior of the robot, it will take a lot of time to learn.

綜上所述,上述訓練方法適用範圍窄、效率低且錯誤率高。In summary, the above training method has a narrow application range, low efficiency, and high error rate.

針對現有的對機器人進行訓練的方法存在的上述問題,現提供一種旨在實現支持沒有編程開發基礎的用戶通過語音對機器人進行訓練的系統及方法。In view of the above problems existing in the existing methods of training robots, there is now provided a system and method for implementing support for a robot that supports a robot without speech based on programming.

具體技術方案如下:The specific technical solutions are as follows:

一種通過語音對機器人進行訓練的系統,包括:A system for training robots by voice, including:

一接收單元,用於接收語音信號;a receiving unit, configured to receive a voice signal;

一解析單元,連接所述接收單元,用於對所述語音信號進行解析,將所述語音信號與預設語句進行匹配,獲取與所述預設語句匹配的且與所述語音信號對應的條件語句,及與所述語音信號對應的執行語句;An analyzing unit, configured to connect the receiving unit, to parse the voice signal, match the voice signal with a preset statement, and acquire a condition that matches the preset statement and corresponds to the voice signal a statement, and an execution statement corresponding to the voice signal;

一處理單元,連接所述解析單元,用於將所述條件語句與所述執行語句結合生成一目標條目;a processing unit, coupled to the parsing unit, configured to combine the conditional statement with the execution statement to generate a target entry;

一存儲單元,連接所述處理單元,用以存儲預設條目,根據所述預設條目對機器人進行訓練;a storage unit, connected to the processing unit, for storing a preset item, and training the robot according to the preset item;

所述處理單元根據所述目標條目進行權重計算,並根據所述權重計算結果進行相應的處理。The processing unit performs weight calculation according to the target item, and performs corresponding processing according to the weight calculation result.

優選的,所述解析單元包括:Preferably, the parsing unit comprises:

一第一轉換模組,用於將所述語音信號轉換爲文字信息;a first conversion module, configured to convert the voice signal into text information;

一語義分析模組,連接所述第一轉換模組,用於對所述文字信息進行解析,將所述文字信息與所述預設語句進行匹配,獲取與所述預設語句匹配的且與所述文字信息對應的條件語句,並識別所述條件語句是標準式條件語句或反饋式條件語句;a semantic analysis module, connected to the first conversion module, configured to parse the text information, match the text information with the preset statement, and obtain a match with the preset statement and The conditional statement corresponding to the text information, and identifying that the conditional statement is a standard conditional statement or a feedback conditional statement;

若所述條件語句是標準式條件語句,則獲取與所述文件信息對應的執行語句;If the conditional statement is a standard conditional statement, acquiring an execution statement corresponding to the file information;

若所述條件語句是反饋式條件語句,則進行權重運算,使所述機器人執行上一次任務的操作。If the conditional statement is a feedback conditional statement, a weighting operation is performed to cause the robot to perform an operation of the last task.

優選的,所述解析單元還包括:Preferably, the parsing unit further includes:

一第二轉換模組,連接所述語義分析模組,用於將所述執行語句轉換爲相應的音頻信號,並輸出。A second conversion module is connected to the semantic analysis module for converting the execution statement into a corresponding audio signal and outputting the same.

優選的,每一條所述預設條目包括預設條件語句和預設執行語句。Preferably, each of the preset items includes a preset condition statement and a preset execution statement.

優選的,所述處理單元根據所述目標條目中的所述條件語句,遍曆所述存儲單元中的所有所述預設條目中的所述預設條件語句,以獲取所述條件語句是否與所述預設條件語句重複,若不重複,則進行所述權重運算,並將所述目標條目存儲於所述存儲單元中以形成新的所述預設條目,根據所述預設條目對機器人進行訓練;若重複則進行所述權重運算,並根據所述權重計算結果進行相應的處理。Preferably, the processing unit traverses the preset conditional statement in all the preset entries in the storage unit according to the conditional statement in the target entry to obtain whether the conditional statement is related to The preset condition statement is repeated, if not repeated, performing the weighting operation, and storing the target item in the storage unit to form a new preset item, and the robot is determined according to the preset item Perform training; if it is repeated, perform the weighting operation, and perform corresponding processing according to the weight calculation result.

一種通過語音對機器人進行訓練的方法,包括下述步驟:A method of training a robot by voice, comprising the following steps:

S1. 採集語音信號;S1. Acquiring a voice signal;

S2. 對所述語音信號進行解析,將所述語音信號與預設語句進行匹配,獲取與所述預設語句匹配的且與所述語音信號對應的條件語句,及與所述語音信號對應的執行語句;S2. Parsing the voice signal, matching the voice signal with a preset statement, acquiring a conditional statement matching the preset statement and corresponding to the voice signal, and corresponding to the voice signal Execute statement

S3. 將所述條件語句與所述執行語句結合生成一目標條目;S3. Combining the conditional statement with the execution statement to generate a target entry;

S4. 根據所述目標條目進行權重計算,並根據所述權重計算結果進行相應的處理。S4. Perform weight calculation according to the target item, and perform corresponding processing according to the weight calculation result.

優選的,所述步驟S2具體包括:Preferably, the step S2 specifically includes:

S21. 將所述語音信號轉換爲文字信息;S21. converting the voice signal into text information;

S22. 對所述文字信息進行解析,將所述文字信息與所述預設語句進行匹配,獲取與所述預設語句匹配的且與所述文字信息對應的條件語句,並識別所述條件語句是標準式條件語句或反饋式條件語句;S22. Parsing the text information, matching the text information with the preset statement, acquiring a conditional statement matching the preset statement and corresponding to the text information, and identifying the conditional statement Is a standard conditional statement or a feedback conditional statement;

若所述條件語句是標準式條件語句,則獲取與所述文件信息對應的執行語句;If the conditional statement is a standard conditional statement, acquiring an execution statement corresponding to the file information;

若所述條件語句是反饋式條件語句,則進行權重運算,使所述機器人執行上一次任務的操作。If the conditional statement is a feedback conditional statement, a weighting operation is performed to cause the robot to perform an operation of the last task.

優選的,所述步驟S2還包括:Preferably, the step S2 further includes:

S23. 將所述執行語句轉換爲相應的音頻信號,並輸出。S23. Convert the execution statement into a corresponding audio signal and output.

優選的,每一條所述預設條目包括預設條件語句和預設執行語句。Preferably, each of the preset items includes a preset condition statement and a preset execution statement.

優選的,所述步驟S3具體包括:Preferably, the step S3 specifically includes:

S31. 根據所述目標條目中的所述條件語句,遍曆所述存儲單元中的所有所述預設條目中的所述預設條件語句;S31. traversing the preset conditional statement in all the preset entries in the storage unit according to the conditional statement in the target entry;

S32. 獲取遍曆結果,判斷所述條件語句是否與所述預設條件語句重複,S32. Acquire a traversal result, and determine whether the conditional statement is repeated with the preset conditional statement.

若所述條件語句與所述預設條件語句不重複,則執行步驟S33;If the conditional statement does not overlap with the preset conditional statement, step S33 is performed;

若所述條件語句與所述預設條件語句重複,則執行步驟S34;If the conditional statement is repeated with the preset conditional statement, step S34 is performed;

S33. 進行所述權重運算,並將所述目標條目存儲於所述存儲單元中以形成新的所述預設條目,根據所述預設條目對機器人進行訓練;S33. Perform the weighting operation, and store the target item in the storage unit to form a new preset item, and train the robot according to the preset item;

S34. 進行所述權重運算,並根據所述權重計算結果進行相應的處理。S34. Perform the weighting operation, and perform corresponding processing according to the weight calculation result.

上述技術方案的有益效果:The beneficial effects of the above technical solutions:

本技術方案中,在通過語音對機器人進行訓練的系統中,通過解析單元對語音信號進行解析獲取相應的條件語句和執行語句,通過處理單元將條件語句和執行語句結合生成條目,使機器人根據條目進行相應的訓練,效率高且錯誤率低。在通過語音對機器人進行訓練的方法中,只需用戶輸入語音信號即可對機器人進行訓練,操作簡單,適用範圍廣且效率高。In the technical solution, in the system for training the robot by voice, the parsing unit parses the speech signal to obtain a corresponding conditional statement and an execution statement, and the processing unit combines the conditional statement and the execution statement to generate an entry, so that the robot according to the entry The corresponding training is carried out with high efficiency and low error rate. In the method of training the robot by voice, the robot can be trained only by inputting a voice signal, and the operation is simple, and the scope of application is wide and the efficiency is high.

下面將結合本發明實施例中的附圖,對本發明實施例中的技術方案進行清楚、完整地描述,顯然,所描述的實施例僅僅是本發明一部分實施例,而不是全部的實施例。基於本發明中的實施例,本領域普通技術人員在沒有作出創造性勞動的前提下所獲得的所有其他實施例,都屬於本發明保護的範圍。The technical solutions in the embodiments of the present invention are clearly and completely described in the following with reference to the accompanying drawings in the embodiments of the present invention. It is obvious that the described embodiments are only a part of the embodiments of the present invention, but not all embodiments. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments of the present invention without creative efforts are within the scope of the present invention.

需要說明的是,在不衝突的情况下,本發明中的實施例及實施例中的特徵可以相互組合。It should be noted that the embodiments in the present invention and the features in the embodiments may be combined with each other without conflict.

下面結合附圖和具體實施例對本發明作進一步說明,但不作爲本發明的限定。The invention is further illustrated by the following figures and specific examples, but is not to be construed as limiting.

如圖1所示,一種通過語音對機器人進行訓練的系統,包括:As shown in FIG. 1, a system for training a robot by voice, comprising:

一接收單元1,用於接收語音信號;a receiving unit 1 for receiving a voice signal;

一解析單元2,連接接收單元1,用於對語音信號進行解析,將語音信號與預設語句進行匹配,獲取與預設語句匹配的且與語音信號對應的條件語句,及與語音信號對應的執行語句;An analyzing unit 2 is connected to the receiving unit 1 for parsing the voice signal, matching the voice signal with the preset statement, acquiring a conditional statement matching the preset sentence and corresponding to the voice signal, and corresponding to the voice signal Execute statement

一處理單元3,連接解析單元2,用於將條件語句與執行語句結合生成一目標條目;a processing unit 3, connected to the parsing unit 2, for combining a conditional statement with an execution statement to generate a target entry;

一存儲單元4,連接處理單元3,用以存儲預設條目,根據預設條目對機器人進行訓練;a storage unit 4, connected to the processing unit 3, for storing a preset item, and training the robot according to the preset item;

處理單元3根據目標條目進行權重計算,並根據權重計算結果進行相應的處理。The processing unit 3 performs weight calculation according to the target entry, and performs corresponding processing according to the weight calculation result.

在本實施例中,採用語音對機器人進行訓練的系統可應用於兒童類玩具中,雖然兒童不具備專業的編程開發技能,但兒童可以通過自然語言與機器人交流,並訓練機器人執行相應的動作。In the present embodiment, the system for training robots by voice can be applied to children's toys. Although children do not have professional programming development skills, children can communicate with robots through natural language and train robots to perform corresponding actions.

在本實施例中,針對機器人行爲邏輯開發的優化過程,選擇了適合普通用戶與機器人進行交互的方式,使用戶在對機器人進行訓練的過程專注於訓練邏輯本身,而非開發語言,提高了工作效率且降低了錯誤率。通過解析單元2對語音信號進行解析獲取相應的條件語句和執行語句,通過處理單元3將條件語句和執行語句結合生成條目,使機器人根據條目進行相應的訓練,效率高且錯誤率低。In this embodiment, for the optimization process of the robot behavior logic development, a method suitable for the common user to interact with the robot is selected, so that the user concentrates on the training logic itself in the process of training the robot, instead of developing the language, improving the work. Efficiency and reduced error rate. The parsing unit 2 parses the speech signal to obtain a corresponding conditional statement and an execution statement, and the processing unit 3 combines the conditional statement and the execution statement to generate an item, so that the robot performs corresponding training according to the item, and the efficiency is high and the error rate is low.

在優選的實施例中,解析單元2包括:In a preferred embodiment, the parsing unit 2 comprises:

一第一轉換模組21,用於將語音信號轉換爲文字信息;a first conversion module 21 for converting a voice signal into text information;

一語義分析模組22,連接第一轉換模組21,用於對文字信息進行解析,將文字信息與預設語句進行匹配,獲取與預設語句匹配的且與文字信息對應的條件語句,並識別條件語句是標準式條件語句或反饋式條件語句;a semantic analysis module 22 is connected to the first conversion module 21 for parsing the text information, matching the text information with the preset statement, and acquiring a conditional statement matching the preset sentence and corresponding to the text information, and The recognition conditional statement is a standard conditional statement or a feedback conditional statement;

若條件語句是標準式條件語句,則獲取與文件信息對應的執行語句;If the conditional statement is a standard conditional statement, obtaining an execution statement corresponding to the file information;

若條件語句是反饋式條件語句,則進行權重運算,使機器人執行上一次任務的操作。If the conditional statement is a feedback conditional statement, a weighting operation is performed to cause the robot to perform the operation of the previous task.

在本實施例中,目標條目對應的句式可以是: 當A時,就B; 如果A時,則B; 不要再在A時,做B; 這個時候應該做B; 這是錯誤的; 這樣做是不對的等。In this embodiment, the sentence corresponding to the target entry may be: when A, B; if A, then B; do not do B when A; B should be done at this time; this is wrong; It is wrong to do it.

其中,“當A時”,“如果A時”,“不要再在A時”,以及“這個時候”均爲標準式條件語句;“這是錯誤的”和“這樣做是不對的”均爲反饋式條件語句。Among them, "when A", "if A", "don't be at A", and "this time" are standard conditional statements; "this is wrong" and "this is wrong" Feedback conditional statement.

採用語音對機器人進行訓練的系統的整個訓練過程爲:當識別到訓練關鍵句式時機器人進入訓練模式,用戶可使用與上述相似的句式與機器人對話時,通過解析單元2的語義分析模組22將用戶說的話劃分爲部分A和部分B,經過語義轉換,將部分A轉換爲條件開發語句,將部分B轉換爲執行動作開發語句,把部分A和部分B的關聯關係追加到本地的訓練知識庫(存儲單元4),並將部分A和部分B結合形成新的條目,如果部分A與訓練知識庫中的條件開發語句相同,部分B與訓練知識庫中相應的執行動作開發語句不同,則部分A爲兩條條件一樣但執行不同動作的知識條目,需進行權重運算,權重運算包含用戶的正負反饋,追加時間進行考量,並將新知識條目追加到本地知識庫,並更新訓練知識庫。當識別到普通自然語言交流時,訓練模式結束,機器人結束訓練回歸到輪詢判斷模式,曆遍訓練知識庫中的所有條目,當命中某一條知識條目時,則執行知識條目中所包含的執行動作開發語句。The whole training process of the system for training the robot by voice is: when the training key sentence pattern is recognized, the robot enters the training mode, and the user can use the semantic analysis module of the parsing unit 2 when using the sentence pattern similar to the above to talk with the robot. 22 The user's words are divided into part A and part B. After semantic conversion, part A is converted into a conditional development statement, part B is converted into an execution action development statement, and the relationship between part A and part B is added to the local training. Knowledge base (storage unit 4), and combines part A and part B to form a new entry. If part A is the same as the conditional development statement in the training knowledge base, part B is different from the corresponding execution action development statement in the training knowledge base. Then part A is a knowledge item with the same two conditions but performing different actions, and a weight operation is required. The weight operation includes the user's positive and negative feedback, the additional time is considered, and the new knowledge item is added to the local knowledge base, and the training knowledge base is updated. . When the normal natural language communication is recognized, the training mode ends, the robot ends the training and returns to the polling judgment mode, and all the entries in the knowledge base are trained, and when a certain knowledge item is hit, the execution included in the knowledge item is executed. Action development statement.

在本實施例中,第一轉換模組21可採用自動語音識別(Automatic Speech Recognition,ASR)技術,ASR技術可將人類語音中的詞彙內容轉換爲計算機可讀的內容並輸入計算機,並且與計算機進行交互。In this embodiment, the first conversion module 21 can adopt Automatic Speech Recognition (ASR) technology, and the ASR technology can convert the vocabulary content in the human voice into computer readable content and input the computer into the computer, and the computer Interact.

語義分析模組22採用人工智能的自然語言處理(Natural Language Processing,NLP)技術,通過NLP技術獲取文字信息中的條件語句和執行語句。The semantic analysis module 22 uses artificial intelligence natural language processing (NLP) technology to obtain conditional statements and execution statements in the text information through the NLP technology.

在優選的實施例中,解析單元2還包括:In a preferred embodiment, the parsing unit 2 further includes:

一第二轉換模組23,連接語義分析模組22,用於將執行語句轉換爲相應的音頻信號,並輸出。A second conversion module 23 is connected to the semantic analysis module 22 for converting the execution statement into a corresponding audio signal and outputting it.

在本實施例中,第二轉換模組23採用TTS(Text To Speech)即將文本轉換爲語音技術,該技術是人機對話的一部分,通過TTS使機器人能夠說話。In this embodiment, the second conversion module 23 uses TTS (Text To Speech) to convert the text into a voice technology, which is part of the human-machine dialogue, and enables the robot to speak through the TTS.

在優選的實施例中,每一條預設條目包括預設條件語句和預設執行語句。In a preferred embodiment, each of the preset entries includes a preset conditional statement and a preset execution statement.

在優選的實施例中,處理單元3根據目標條目中的條件語句,遍曆存儲單元中的所有預設條目中的預設條件語句,以獲取條件語句是否與預設條件語句重複,若不重複,則進行權重運算,並將目標條目存儲於存儲單元中4以形成新的預設條目,根據預設條目對機器人進行訓練;若重複則進行權重運算,並根據權重計算結果進行相應的處理。In a preferred embodiment, the processing unit 3 traverses the preset conditional statements in all the preset entries in the storage unit according to the conditional statement in the target entry to obtain whether the conditional statement is repeated with the preset conditional statement, if not Then, the weighting operation is performed, and the target item is stored in the storage unit 4 to form a new preset item, and the robot is trained according to the preset item; if it is repeated, the weighting operation is performed, and the corresponding processing is performed according to the weight calculation result.

在本實施例中,可在追加新知識條目或原有知識條目後,當收到用戶的正負反饋時,進行權重運算,整理整個訓練知識庫,進行壓縮等工作,以保證機器人在條件輪詢判斷時的效率。In this embodiment, after adding a new knowledge item or an original knowledge item, when receiving the positive and negative feedback of the user, performing weight calculation, arranging the entire training knowledge base, performing compression, etc., to ensure that the robot is in conditional polling. The efficiency at the time of judgment.

如圖2所示,一種通過語音對機器人進行訓練的方法,包括下述步驟:As shown in FIG. 2, a method for training a robot by voice includes the following steps:

S1. 採集語音信號;S1. Acquiring a voice signal;

S2. 對語音信號進行解析,將語音信號與預設語句進行匹配,獲取與預設語句匹配的且與語音信號對應的條件語句,及與語音信號對應的執行語句;S2. parsing the voice signal, matching the voice signal with the preset statement, acquiring a conditional statement matching the preset statement and corresponding to the voice signal, and an execution statement corresponding to the voice signal;

S3. 將條件語句與執行語句結合生成一目標條目;S3. Combining the conditional statement with the execution statement to generate a target entry;

S4. 根據目標條目進行權重計算,並根據權重計算結果進行相應的處理。S4. Perform weight calculation according to the target item, and perform corresponding processing according to the weight calculation result.

在本實施例中,只需用戶輸入語音信號即可對機器人進行訓練,操作簡單,適用範圍廣且效率高。In this embodiment, the robot can be trained only by inputting a voice signal, and the operation is simple, the scope of application is wide, and the efficiency is high.

如圖3所示,在優選的實施例中,步驟S2具體包括:As shown in FIG. 3, in a preferred embodiment, step S2 specifically includes:

S21. 將語音信號轉換爲文字信息;S21. Converting the voice signal into text information;

S22. 對文字信息進行解析,將文字信息與預設語句進行匹配,獲取與預設語句匹配的且與文字信息對應的條件語句,並識別條件語句是標準式條件語句或反饋式條件語句;S22. Parsing the text information, matching the text information with the preset statement, obtaining a conditional statement matching the preset statement and corresponding to the text information, and identifying that the conditional statement is a standard conditional statement or a feedback conditional statement;

若條件語句是標準式條件語句,則獲取與文件信息對應的執行語句;If the conditional statement is a standard conditional statement, obtaining an execution statement corresponding to the file information;

若條件語句是反饋式條件語句,則進行權重運算,使機器人執行上一次任務的操作。If the conditional statement is a feedback conditional statement, a weighting operation is performed to cause the robot to perform the operation of the previous task.

在本實施例中,將語音信號轉換爲文字信息可採用自動語音識別(Automatic Speech Recognition,ASR)技術,ASR技術可將人類語音中的詞彙內容轉換爲計算機可讀的輸入,並且與計算機進行交互。In this embodiment, the voice signal is converted into text information by using Automatic Speech Recognition (ASR) technology, which converts vocabulary content in human speech into computer readable input and interacts with a computer. .

對文字信息進行解析可採用人工智能的自然語言處理(Natural Language Processing,NLP)技術,通過NLP技術獲取文字信息中的條件語句和執行語句。The text information can be parsed by the artificial language natural language processing (NLP) technology, and the conditional statements and execution statements in the text information are obtained by the NLP technology.

在優選的實施例中,步驟S2還包括:In a preferred embodiment, step S2 further includes:

S23. 將執行語句轉換爲相應的音頻信號,並輸出。S23. Convert the execution statement to the corresponding audio signal and output it.

在本實施例中,採用TTS(Text To Speech,將文本轉換爲語音)技術將執行語句轉換爲相應的音頻信號,該技術是人機對話的一部分,通過TTS使機器人能夠說話。In this embodiment, the TTS (Text To Speech) technique is used to convert the execution statement into a corresponding audio signal, which is part of the human-machine dialogue, enabling the robot to speak through the TTS.

在優選的實施例中,每一條預設條目包括預設條件語句和預設執行語句。In a preferred embodiment, each of the preset entries includes a preset conditional statement and a preset execution statement.

如圖4所示,在優選的實施例中,步驟S3具體包括:As shown in FIG. 4, in a preferred embodiment, step S3 specifically includes:

S31. 根據目標條目中的條件語句,遍曆存儲單元中的所有預設條目中的預設條件語句;S31. traversing a preset conditional statement in all preset entries in the storage unit according to the conditional statement in the target entry;

S32. 獲取遍曆結果,並進行權重計算S32. Acquire traversal results and perform weight calculation

判斷條件語句是否與預設條件語句重複,Determine whether the conditional statement is a duplicate of a preset conditional statement.

若條件語句與預設條件語句不重複,則執行步驟S33;If the conditional statement does not overlap with the preset conditional statement, step S33 is performed;

若條件語句與預設條件語句重複,則執行步驟S34;If the conditional statement is repeated with the preset conditional statement, step S34 is performed;

S33. 進行權重運算,並將目標條目存儲於存儲單元中以形成新的預設條目,根據預設條目對機器人進行訓練;S33. Perform a weighting operation, and store the target item in the storage unit to form a new preset item, and train the robot according to the preset item;

S34. 進行權重運算,並根據權重計算結果進行相應的處理。S34. Perform a weighting operation and perform corresponding processing according to the weight calculation result.

在本實施例中,當機器人在下午的時候聽到用戶說“你好”時,用戶訓練機器人回復“XXX(人名),下午好”的訓練步驟如下: A1. 用戶對機器人說“你好”,“這個時候應該說,XXX,下午好” A2. 對用戶說的內容進行語義解析,分離出說話內容中的執行語句即“說XXX,下午好”,“說”是對應機器人的TTS服務,“XXX”命中當前互動的用戶的名字,“下午”命中當前的時間,“XXX,下午好”對應TTS服務的內容; A3. 根據語義解析結果生成新的知識庫條目,判斷權重後追加到本地知識庫; A4. 機器人執行新的知識庫,結束; 在完成這次互動訓練後,當用戶對機器人說“你好”時,機器人就會回答“XXX,下午好”,從而達到預期訓練目的。In this embodiment, when the robot hears the user saying "hello" in the afternoon, the training steps of the user training robot to reply "XXX (person name), good afternoon" are as follows: A1. The user says "hello" to the robot, "This time should say, XXX, good afternoon" A2. Semantic analysis of the content spoken by the user, separating the execution statement in the speech content, that is, "say XXX, good afternoon", "say" is the TTS service corresponding to the robot, " XXX" hits the name of the currently interacting user, "afternoon" hits the current time, "XXX, good afternoon" corresponds to the content of the TTS service; A3. Generates a new knowledge base entry based on the semantic analysis result, and then adds the weight to the local knowledge after determining the weight A4. The robot executes a new knowledge base and ends; after completing this interactive training, when the user says "hello" to the robot, the robot will answer "XXX, Good afternoon" to achieve the intended training purpose.

本發明可使用戶在訓練機器人時解放雙手,在不需要寫任何代碼的情况下,實現對機器人行爲的修正,使用戶在訓練過程中更專注於訓練內容本身,而非如何編寫代碼等基礎問題上。The invention enables the user to free hands when training the robot, and realizes the modification of the robot behavior without writing any code, so that the user concentrates more on the training content itself in the training process, instead of how to write the code and the like. The problem.

以上所述僅爲本發明較佳的實施例,並非因此限制本發明的實施方式及保護範圍,對於本領域技術人員而言,應當能夠意識到凡運用本發明說明書及圖示內容所作出的等同替換和顯而易見的變化所得到的方案,均應當包含在本發明的保護範圍內。The above is only a preferred embodiment of the present invention, and is not intended to limit the scope of the embodiments and the scope of the present invention, and those skilled in the art should be able to Alternatives and obvious variations are intended to be included within the scope of the invention.

1‧‧‧接收單元
2‧‧‧解析單元
21‧‧‧第一轉換模組
22‧‧‧語義分析模組
23‧‧‧第二轉換模組
3‧‧‧處理單元
4‧‧‧存儲單元
S1-S4‧‧‧步驟
S21-S23‧‧‧步驟
S31-S34‧‧‧步驟
1‧‧‧ receiving unit
2‧‧‧ analytical unit
21‧‧‧First conversion module
22‧‧‧Semantic Analysis Module
23‧‧‧Second conversion module
3‧‧‧Processing unit
4‧‧‧ storage unit
S1-S4‧‧‧ steps
S21-S23‧‧‧Steps
S31-S34‧‧‧Steps

圖1爲本發明所述通過語音對機器人進行訓練的系統的一種實施例的模組圖; 圖2爲本發明所述通過語音對機器人進行訓練的方法的一種實施的流程圖; 圖3爲對語音信號進行解析的方法流程圖; 圖4爲根據遍曆結果對所述目標條目進行相應的處理的方法流程圖。1 is a block diagram of an embodiment of a system for training a robot by voice according to the present invention; FIG. 2 is a flow chart of an implementation of a method for training a robot by voice according to the present invention; A flowchart of a method for parsing a speech signal; FIG. 4 is a flowchart of a method for performing corresponding processing on the target entry according to a traversal result.

1‧‧‧接收單元 1‧‧‧ receiving unit

2‧‧‧解析單元 2‧‧‧ analytical unit

21‧‧‧第一轉換模組 21‧‧‧First conversion module

22‧‧‧語義分析模組 22‧‧‧Semantic Analysis Module

23‧‧‧第二轉換模組 23‧‧‧Second conversion module

3‧‧‧處理單元 3‧‧‧Processing unit

4‧‧‧存儲單元 4‧‧‧ storage unit

Claims (10)

一種通過語音對機器人進行訓練的系統,包括: 一接收單元,用於接收語音信號; 一解析單元,連接所述接收單元,用於對所述語音信號進行解析,將所述語音信號與預設語句進行匹配,獲取與所述預設語句匹配的且與所述語音信號對應的條件語句,及與所述語音信號對應的執行語句; 一處理單元,連接所述解析單元,用於將所述條件語句與所述執行語句結合生成一目標條目; 一存儲單元,連接所述處理單元,用以存儲預設條目,根據所述預設條目對機器人進行訓練; 所述處理單元根據所述目標條目進行權重計算,並根據所述權重計算結果進行相應的處理。A system for training a robot by voice, comprising: a receiving unit for receiving a voice signal; a parsing unit connected to the receiving unit, configured to parse the voice signal, and the voice signal and a preset The statement is matched to obtain a conditional statement matching the preset statement and corresponding to the voice signal, and an execution statement corresponding to the voice signal; a processing unit, connected to the parsing unit, for The conditional statement is combined with the execution statement to generate a target entry; a storage unit is connected to the processing unit for storing a preset entry, and the robot is trained according to the preset entry; the processing unit is configured according to the target entry The weight calculation is performed, and corresponding processing is performed according to the weight calculation result. 如申請專利範圍第1項所述的通過語音對機器人進行訓練的系統,所述解析單元包括: 一第一轉換模組,用於將所述語音信號轉換爲文字信息; 一語義分析模組,連接所述第一轉換模組,用於對所述文字信息進行解析,將所述文字信息與所述預設語句進行匹配,獲取與所述預設語句匹配的且與所述文字信息對應的條件語句,並識別所述條件語句是標準式條件語句或反饋式條件語句; 若所述條件語句是標準式條件語句,則獲取與所述文件信息對應的執行語句; 若所述條件語句是反饋式條件語句,則進行權重運算,使所述機器人執行上一次任務的操作。The system for training a robot by voice according to the first aspect of the invention, wherein the parsing unit comprises: a first conversion module, configured to convert the voice signal into text information; a semantic analysis module, The first conversion module is connected to parse the text information, and the text information is matched with the preset statement to obtain a matching with the preset statement and corresponding to the text information. a conditional statement, and identifying that the conditional statement is a standard conditional statement or a feedback conditional statement; if the conditional statement is a standard conditional statement, acquiring an execution statement corresponding to the file information; if the conditional statement is feedback For the conditional statement, a weighting operation is performed to cause the robot to perform the operation of the previous task. 如申請專利範圍第2項所述的通過語音對機器人進行訓練的系統,所述解析單元還包括: 一第二轉換模組,連接所述語義分析模組,用於將所述執行語句轉換爲相應的音頻信號,並輸出。The system for training a robot by voice according to the second aspect of the patent application, the parsing unit further comprising: a second conversion module, connected to the semantic analysis module, configured to convert the execution statement into Corresponding audio signal and output. 如申請專利範圍第2項所述的通過語音對機器人進行訓練的系統,每一條所述預設條目包括預設條件語句和預設執行語句。A system for training a robot by voice according to the second aspect of the patent application, each of the preset items includes a preset conditional statement and a preset execution statement. 如申請專利範圍第4項所述的通過語音對機器人進行訓練的系統,所述處理單元根據所述目標條目中的所述條件語句,遍曆所述存儲單元中的所有所述預設條目中的所述預設條件語句,以獲取所述條件語句是否與所述預設條件語句重複,若不重複,則進行所述權重運算,並將所述目標條目存儲於所述存儲單元中以形成新的所述預設條目,根據所述預設條目對機器人進行訓練;若重複則進行所述權重運算,並根據所述權重計算結果進行相應的處理。The system for training a robot by voice according to claim 4, wherein the processing unit traverses all of the preset entries in the storage unit according to the conditional statement in the target entry. The preset conditional statement to obtain whether the conditional statement is repeated with the preset conditional statement, if not, performing the weighting operation, and storing the target item in the storage unit to form The new preset item is trained according to the preset item; if it is repeated, the weighting operation is performed, and corresponding processing is performed according to the weight calculation result. 一種通過語音對機器人進行訓練的方法,包括下述步驟: S1. 採集語音信號; S2. 對所述語音信號進行解析,將所述語音信號與預設語句進行匹配,獲取與所述預設語句匹配的且與所述語音信號對應的條件語句,及與所述語音信號對應的執行語句; S3. 將所述條件語句與所述執行語句結合生成一目標條目; S4. 根據所述目標條目進行權重計算,並根據所述權重計算結果進行相應的處理。A method for training a robot by voice, comprising the following steps: S1. collecting a voice signal; S2. parsing the voice signal, matching the voice signal with a preset statement, and acquiring the preset statement a conditional statement matching the voice signal and an execution statement corresponding to the voice signal; S3. combining the conditional statement with the execution statement to generate a target entry; S4. performing, according to the target entry The weight is calculated and processed according to the weight calculation result. 如申請專利範圍第6項所述通過語音對機器人進行訓練的方法,所述步驟S2具體包括: S21. 將所述語音信號轉換爲文字信息; S22. 對所述文字信息進行解析,將所述文字信息與所述預設語句進行匹配,獲取與所述預設語句匹配的且與所述文字信息對應的條件語句,並識別所述條件語句是標準式條件語句或反饋式條件語句; 若所述條件語句是標準式條件語句,則獲取與所述文件信息對應的執行語句; 若所述條件語句是反饋式條件語句,則進行權重運算,使所述機器人執行上一次任務的操作。The method for training a robot by voice according to the sixth aspect of the patent application, the step S2 specifically includes: S21. converting the voice signal into text information; S22. parsing the text information, Matching the text information with the preset statement, acquiring a conditional statement that matches the preset statement and corresponding to the text information, and identifying that the conditional statement is a standard conditional statement or a feedback conditional statement; The conditional statement is a standard conditional statement, and an execution statement corresponding to the file information is acquired; if the conditional statement is a feedback conditional statement, a weighting operation is performed to cause the robot to perform an operation of the previous task. 如申請專利範圍第7項所述通過語音對機器人進行訓練的方法,所述步驟S2還包括: S23. 將所述執行語句轉換爲相應的音頻信號,並輸出。The method for training a robot by voice according to the seventh aspect of the patent application, the step S2 further includes: S23. Converting the execution statement into a corresponding audio signal, and outputting. 如申請專利範圍第6項所述通過語音對機器人進行訓練的方法,每一條所述預設條目包括預設條件語句和預設執行語句。The method for training a robot by voice according to item 6 of the patent application scope, each of the preset items includes a preset condition statement and a preset execution statement. 如申請專利範圍第9項所述通過語音對機器人進行訓練的方法,所述步驟S3具體包括: S31. 根據所述目標條目中的所述條件語句,遍曆所述存儲單元中的所有所述預設條目中的所述預設條件語句; S32. 獲取遍曆結果,判斷所述條件語句是否與所述預設條件語句重複, 若所述條件語句與所述預設條件語句不重複,則執行步驟S33; 若所述條件語句與所述預設條件語句重複,則執行步驟S34; S33. 進行所述權重運算,並將所述目標條目存儲於所述存儲單元中以形成新的所述預設條目,根據所述預設條目對機器人進行訓練; S34. 進行所述權重運算,並根據所述權重計算結果進行相應的處理。The method for training a robot by voice according to the ninth application of the patent application, the step S3 specifically includes: S31. traversing all of the storage units according to the conditional statement in the target entry. Determining the preset conditional statement in the entry; S32. Obtaining a traversal result, determining whether the conditional statement is repeated with the preset conditional statement, if the conditional statement does not overlap with the preset conditional statement, Step S33 is performed; if the conditional statement is repeated with the preset conditional statement, step S34 is performed; S33. performing the weighting operation, and storing the target entry in the storage unit to form a new Presetting an item, training the robot according to the preset item; S34. performing the weighting operation, and performing corresponding processing according to the weighting calculation result.
TW105120437A 2015-06-30 2016-06-29 A system and method for training robots through voice TWI594136B (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510383547.9A CN106326208B (en) 2015-06-30 2015-06-30 A kind of system and method that robot is trained by voice

Publications (2)

Publication Number Publication Date
TW201719452A true TW201719452A (en) 2017-06-01
TWI594136B TWI594136B (en) 2017-08-01

Family

ID=57607864

Family Applications (1)

Application Number Title Priority Date Filing Date
TW105120437A TWI594136B (en) 2015-06-30 2016-06-29 A system and method for training robots through voice

Country Status (4)

Country Link
CN (1) CN106326208B (en)
HK (1) HK1231592A1 (en)
TW (1) TWI594136B (en)
WO (1) WO2017000786A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108172226A (en) * 2018-01-27 2018-06-15 上海萌王智能科技有限公司 A kind of voice control robot for learning response voice and action
WO2021110870A1 (en) 2019-12-05 2021-06-10 Acib Gmbh Method for producing a fermentation product

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060100855A1 (en) * 2004-10-27 2006-05-11 Rozen Suan D Disambiguation method for complex sentences
US7646857B2 (en) * 2005-05-19 2010-01-12 Verizon Business Global Llc Systems and methods for providing voicemail services including caller identification
CN101075435B (en) * 2007-04-19 2011-05-18 深圳先进技术研究院 Intelligent chatting system and its realizing method
KR101060183B1 (en) * 2009-12-11 2011-08-30 한국과학기술연구원 Embedded auditory system and voice signal processing method
US8719023B2 (en) * 2010-05-21 2014-05-06 Sony Computer Entertainment Inc. Robustness to environmental changes of a context dependent speech recognizer
CN202736475U (en) * 2011-12-08 2013-02-13 华南理工大学 Chat robot
CN103065629A (en) * 2012-11-20 2013-04-24 广东工业大学 Speech recognition system of humanoid robot
CN103853646A (en) * 2012-12-04 2014-06-11 鸿富锦精密工业(武汉)有限公司 Called prompting system and method

Also Published As

Publication number Publication date
WO2017000786A1 (en) 2017-01-05
TWI594136B (en) 2017-08-01
CN106326208B (en) 2019-06-07
HK1231592A1 (en) 2017-12-22
CN106326208A (en) 2017-01-11

Similar Documents

Publication Publication Date Title
JP6726800B2 (en) Method and apparatus for human-machine interaction based on artificial intelligence
TWI576825B (en) A voice recognition system of a robot system ?????????????????????????????? and method thereof
KR100679043B1 (en) Apparatus and method for spoken dialogue interface with task-structured frames
JP5405672B2 (en) Foreign language learning apparatus and dialogue system
WO2018034118A1 (en) Dialog system and computer program therefor
CN111402861B (en) Voice recognition method, device, equipment and storage medium
JP2017107078A (en) Voice interactive method, voice interactive device, and voice interactive program
JP2014191030A (en) Voice recognition terminal and voice recognition method using computer terminal
KR20210154849A (en) 2-pass end-to-end speech recognition
JP2014106523A (en) Voice input corresponding device and voice input corresponding program
WO2020048143A1 (en) Machine learning-based simultaneous interpretation method and device
CN114330371A (en) Session intention identification method and device based on prompt learning and electronic equipment
CN116821290A (en) Multitasking dialogue-oriented large language model training method and interaction method
TWI594136B (en) A system and method for training robots through voice
KR20100081534A (en) Multilingual dialogue system and method thereof
Lekova et al. System software architecture for enhancing human-robot interaction by Conversational AI
JP2016045253A (en) Data structure, voice interaction device, and electronic apparatus
KR102564008B1 (en) Device and Method of real-time Speech Translation based on the extraction of translation unit
JP6306447B2 (en) Terminal, program, and system for reproducing response sentence using a plurality of different dialogue control units simultaneously
CN115731915A (en) Active dialogue method and device for dialogue robot, electronic device and storage medium
KR102181583B1 (en) System for voice recognition of interactive robot and the method therof
JP2013239021A (en) Conference support system and method, computer program, and recording medium
JP7363307B2 (en) Automatic learning device and method for recognition results in voice chatbot, computer program and recording medium
Bharathi et al. A cost effective implementation of a voice assisted home automation system
JP7224278B2 (en) Apparatus, program and method for estimating response sentence to user's utterance sentence