WO2017000809A1 - 一种语言交互方法 - Google Patents

一种语言交互方法 Download PDF

Info

Publication number
WO2017000809A1
WO2017000809A1 PCT/CN2016/086490 CN2016086490W WO2017000809A1 WO 2017000809 A1 WO2017000809 A1 WO 2017000809A1 CN 2016086490 W CN2016086490 W CN 2016086490W WO 2017000809 A1 WO2017000809 A1 WO 2017000809A1
Authority
WO
WIPO (PCT)
Prior art keywords
statement
feedback
domain
empty
semantic
Prior art date
Application number
PCT/CN2016/086490
Other languages
English (en)
French (fr)
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 WO2017000809A1 publication Critical patent/WO2017000809A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/33Querying
    • G06F16/332Query formulation
    • G06F16/3329Natural language query formulation or dialogue systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/205Parsing
    • G06F40/211Syntactic parsing, e.g. based on context-free grammar [CFG] or unification grammars
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/30Semantic analysis

Definitions

  • the invention relates to the field of oral natural language understanding, in particular to a human-machine natural language interaction method based on domain sentence classification.
  • the existing dialogue management techniques adopted by natural language interaction mainly include a statistical-based dialogue management method and a rule-based dialogue management method.
  • the statistical-based dialogue management method is a data-driven method that can label the real conversation corpus and learn the dialogue mode from the corpus according to the statistical model, thus guiding the human-machine dialogue process.
  • a large amount of manual expert knowledge is not required to build a dialogue management system.
  • the shortcomings of statistical dialogue management methods require a large amount of real corpus data and annotations. However, in the early days of building a real dialogue management system, it was often difficult for designers to collect enough corpus for training due to various constraints.
  • the rule-based dialog management method is a method of manually setting the flow of the dialogue based on expert knowledge. Since contextual connections are common in multiple rounds of human-computer interaction, the statements output by the user may partially omit components, such as omitting the subject, predicates only retaining the object, and so on. Therefore, it is difficult to parse out the user's true intention when analyzing a sentence simply. It is necessary to contact the context of the previous conversations to semantically parse the current statement. Although it is not necessary to collect a large amount of data, the designer needs to have a certain understanding of the flow, rules, and the like of the dialogue, which increases the design difficulty of the designer and the corresponding workload.
  • the voice interaction method of an event includes the following steps:
  • Step 1 Obtain the natural language statement output by the user
  • Step 2 Perform semantic analysis on the natural language statement to obtain a corresponding semantic analysis result
  • Step 3 The robot processes according to the semantic analysis result to output a corresponding response result
  • Step 4 Acquire a feedback statement output by the user
  • Step 5 Determine whether the feedback statement is an end instruction, and if so, execute step 7; if not, execute step 6;
  • Step 6 Perform semantic analysis on the feedback statement to obtain the corresponding semantic analysis result, and return to perform step 3;
  • step 2 is:
  • Step 21 Match the natural language statement with all preset domain sentence patterns to obtain a first parsing result
  • Step 22 Determine whether the initial semantic parsing result is empty
  • step 23 is performed.
  • Step 23 The first parsing result is used as the semantic parsing result, and the step 3 is performed.
  • the first parsing result when the first parsing result is not empty, the first parsing result includes a domain attribute of a domain to which the natural language statement belongs, and/or a user intent corresponding to the domain attribute, and/or Describe key information in natural language statements.
  • step 6 is:
  • Step 61 Match the feedback statement with all preset domain sentence patterns to obtain a feedback analysis result
  • Step 62 Determine whether the feedback analysis result is empty
  • step 63 is performed.
  • step 64 is performed
  • Step 63 The feedback analysis result is used as the semantic analysis result, and the step 3 is performed;
  • Step 64 Match all the foregoing semantic parsing results obtained in the voice interaction process of the event of the present item to all the common sentence patterns respectively, and obtain corresponding matching results, and all the matching results are obtained. Convergence to obtain a fusion statement;
  • Step 65 Determine whether the fusion statement is empty
  • step 66 is performed
  • Step 66 Perform the step 3 by using the fusion sentence as the semantic analysis result.
  • the feedback parsing result when the feedback parsing result is not empty, the feedback parsing result includes a domain attribute of a domain to which the feedback statement belongs, and/or a user intent corresponding to the domain attribute, and/or the feedback statement. Key information in .
  • the fusion statement when the fusion statement is not empty, the fusion statement includes a domain attribute of a domain to which the feedback statement belongs, and/or a user intent corresponding to the domain attribute, and/or in the feedback sentence. Key Information.
  • the domain sentence expression is represented by a regular expression.
  • the general sentence pattern is represented by a regular expression.
  • the language interaction method can parse the natural language statement output by the user to obtain a corresponding parsing result, and parse the feedback sentence output by the user again, so as to realize the dialogue between the human and the machine in the multi-round dialogue.
  • the context is fully parsed to achieve optimal resolution results, reducing the designer's workload and design difficulty.
  • FIG. 1 is a flow chart of a first embodiment of a language interaction method according to the present invention.
  • FIG. 2 is a flowchart of a second embodiment of a language interaction method according to the present invention.
  • FIG. 3 is a flow chart of another embodiment of a language interaction method according to the present invention.
  • a language interaction method is used in a language interaction process between a user and a robot, and a storage unit is used to store a preset semantic statement, and the semantic statement includes a domain sentence expression and a representation indicating a single domain attribute.
  • the semantic statement includes a domain sentence expression and a representation indicating a single domain attribute.
  • the voice interaction method of an event includes the following steps:
  • Step 1 Obtain the natural language statement output by the user
  • Step 2 Perform semantic analysis on the natural language statement to obtain the corresponding semantic analysis result
  • Step 3 The robot processes according to the semantic analysis result to output a corresponding response result
  • Step 4 Obtain a feedback statement output by the user
  • Step 5 Determine whether the feedback statement is an end instruction, and if so, execute step 7; if not, execute step 6;
  • Step 6 Perform semantic analysis on the feedback statement to obtain the corresponding semantic analysis result, and return to step 3;
  • the domain sentence formula refers to a sentence pattern with explicit domain attributes, that is, the semantics passed by the sentence pattern can clearly determine the domain in which it is located;
  • the general sentence pattern refers to a sentence pattern that does not have a unique domain attribute, that is, The semantics conveyed by a sentence cannot uniquely determine the domain in which it is located, and may correspond to multiple fields.
  • the storage unit may pre-store all the domain sentences when the user wants to book an airline ticket, such as: "booking a ticket from $origin to $destination", where "$origin” indicates departure "$destination” indicates the destination; for the "booking ticket” field as an example, for the statement "book tickets from $origin to $destination", where "booking tickets” belong to the domain sentence.
  • the robot asks "Where do you want to book a flight ticket?"
  • the user's answer may be just a place name, such as "Shanghai”
  • the corresponding sentence is "$destination”. It is difficult to determine the field in which this sentence is used alone, because other fields, such as "book tickets", may have the same sentence pattern, so this sentence is a general sentence.
  • the feedback statement may include an end instruction, and the end instruction is used to end the language interaction of the current event, that is, to end the interaction task.
  • the language interaction method may parse the natural language statement output by the user to obtain a corresponding parsing result, and parse the feedback sentence output by the user again, so as to implement the human-machine dialogue process in multiple rounds of dialogue.
  • the context is comprehensively analyzed to obtain optimal analytical results, which not only reduces the designer's workload and design difficulty, but also has high resolution efficiency.
  • step 2 the specific process of step 2 is:
  • Step 21 Match the natural language statement with all preset domain sentences to obtain the first parsing result
  • Step 22 Determine whether the initial semantic analysis result is empty
  • step 23 is performed.
  • step 3 If the first parsing result is empty, the output semantic result is empty, and step 3 is performed;
  • Step 23 The first analysis result is used as the semantic analysis result, and step 3 is performed.
  • the domain to which the domain sentence corresponding to the natural language sentence belongs can be obtained, so that the robot can perform corresponding according to the domain corresponding to the semantic analysis result. Process or find, so that you can respond quickly and interact with users to improve the user experience.
  • the first parsing result when the first parsing result is not empty, the first parsing result includes a domain attribute of a domain to which the natural language statement belongs, and/or a user intent corresponding to the domain attribute, and/or a natural language statement Key Information.
  • each domain attribute may correspond to multiple user intents.
  • the domain language attribute of the domain belongs to the natural language statement, the user intent corresponding to the domain attribute may be acquired at the same time to quickly obtain the user's purpose or Claim.
  • step 6 is:
  • Step 61 Match the feedback statement with all preset domain sentences to obtain a feedback analysis result
  • Step 62 Determine whether the feedback analysis result is empty
  • step 63 is performed.
  • step 64 is performed
  • Step 63 The feedback analysis result is used as a semantic analysis result, and step 3 is performed;
  • Step 64 Match all previous semantic parsing results obtained in the voice interaction process of the event with all common sentence patterns, obtain corresponding matching results, and fuse all matching results to obtain a fusion sentence;
  • Step 65 Determine whether the fusion statement is empty
  • step 66 is performed;
  • step 3 is performed
  • Step 66 The fusion sentence is used as the result of the semantic analysis, and step 3 is performed.
  • the robot can search for the corresponding data from the database according to the semantic analysis result, or ask the user for the necessary information according to the current state.
  • the domain to which the domain sentence corresponding to the natural language sentence belongs can be obtained, or according to the matching in the multi-round human-machine dialogue process.
  • the context is fully parsed to fuse all the matching results to obtain the optimal parsing result, so that the robot can process or search according to the domain corresponding to the semantic parsing result, so that the corresponding Responsively interact with the user to improve the user experience while reducing the designer's workload and design difficulty.
  • the feedback parsing result when the feedback parsing result is not empty, includes feedback The domain attribute of the realm to which the statement belongs, and/or the user intent corresponding to the domain attribute, and/or key information in the feedback statement.
  • each domain attribute may correspond to multiple user intents.
  • the domain language attribute of the domain belongs to the natural language statement, the user intent corresponding to the domain attribute may be acquired at the same time to quickly obtain the user's purpose or Claim.
  • the fusion statement when the fusion statement is not empty, the fusion statement includes domain attributes of the domain to which the feedback statement belongs, and/or user intent corresponding to the domain attribute, and/or key information in the feedback statement.
  • each domain attribute may correspond to multiple user intents.
  • the domain language attribute of the domain belongs to the natural language statement
  • the user intent corresponding to the domain attribute may be acquired at the same time to quickly obtain the user's purpose or Claim.
  • both the domain sentence and the general sentence can be represented by a regular expression.
  • a regular expression also known as a regular representation or a conventional representation
  • a regular representation is a concept of computer science that uses a single string to describe and match a series of rules that conform to a certain syntax. String. Can be applied in a text editor, regular expressions are often used as a tool to retrieve and replace text that conforms to a pattern.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computational Linguistics (AREA)
  • Artificial Intelligence (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • General Health & Medical Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Mathematical Physics (AREA)
  • Human Computer Interaction (AREA)
  • Machine Translation (AREA)

Abstract

一种语言交互方法,用于用户与机器人之间的语言交互过程中,采用一存储单元储存预设的语义语句,所述语义语句包括表示单一领域属性的领域句式和表示多个领域属性的通用句式;一件事件的所述语音交互方法包括下述步骤:步骤1获取用户输出的自然语言语句;步骤2对所述自然语言语句进行语义解析,以获取相应的语义解析结果;步骤3所述机器人根据所述语义解析结果进行处理,以输出相应的响应结果;步骤4获取所述用户输出的反馈语句;步骤5判断所述反馈语句是否为结束指令,若是,则执行步骤7;若否,则执行步骤6;步骤6对所述反馈语句进行语义解析,以获取相应的所述语义解析结果,返回执行所述步骤3;步骤7结束。

Description

一种语言交互方法 技术领域
本发明涉及口语自然语言理解领域,尤其涉及一种基于领域句式分类的人机自然语言交互方法。
背景技术
随着科技的发展智能设备普及和语音识别技术的逐步成熟,由于自然语言交互具有方便、自然、快捷等优点,因此在人机交互过程中自然语言交互凸显的尤为重要。在人机交互过程中,由于用户自然语言的多样性,以及领域情景的特殊性,通常一轮人机交互不能满足机器人的动作需求,需要经过多轮人机交互才能为机器人提供进行相应动作的必要信息。
现有的自然语言交互采用的对话管理技术主要包括基于统计的对话管理方法和基于规则的对话管理方法。
基于统计的对话管理方法属于数据驱动的方法,可对真实的对话语料进行标注,根据统计模型从语料中学习对话的模式,从而指导人机对话流程的方法。在构建对话管理系统时不需要大量的人工专家知识。统计的对话管理方法存在的缺点有需要大量的真实语料数据及标注。然而,在构建真实的对话管理系统的初期,由于多方面的条件限制,设计人员通常很难收集到足够的语料进行训练。
基于规则的对话管理方法是根据专家知识,人工设定对话的流程的方法。由于在多轮人机交互过程中普遍存在上下文联系,因此用户输出的语句可能存在部分省略成分,例如:省略了主语、谓语仅保留宾语等。因此,在单纯的分析一句语句时很难解析出用户的真实意图,需要联系前几次对话的上下文对当前的语句进行语义解析。虽然,不需要搜集大量的数据,但是需要设计者对对话的流程、规则等具有一定的了解,增加了设计者的设计难度及相应的工作量。
发明内容
针对现有的自然语言交互存在的上述问题,现提供一种旨在实现可降低设计人员的工作量和设计难度的语言交互方法。
具体技术方案如下:
一种语言交互方法,用于用户与机器人之间的语言交互过程中,采用一存储单元储存预设的语义语句,所述语义语句包括表示单一领域属性的领域句式和表示多个领域属性的通用句式;
一件事件的所述语音交互方法包括下述步骤:
步骤1.获取用户输出的自然语言语句;
步骤2.对所述自然语言语句进行语义解析,以获取相应的语义解析结果;
步骤3.所述机器人根据所述语义解析结果进行处理,以输出相应的响应结果;
步骤4.获取所述用户输出的反馈语句;
步骤5.判断所述反馈语句是否为结束指令,若是,则执行步骤7;若否,则执行步骤6;
步骤6.对所述反馈语句进行语义解析,以获取相应的所述语义解析结果,返回执行所述步骤3;
步骤7.结束。
优选的,所述步骤2的具体过程为:
步骤21.将所述自然语言语句与预设的所有的所述领域句式进行匹配,以获取第一解析结果;
步骤22.判断所述初次语义解析结果是否为空;
若所述第一解析结果不为空,则执行步骤23;
若所述第一解析结果为空,输出所述语义结果为空,并执行所述步骤3;
步骤23.将所述第一解析结果作为所述语义解析结果,执行所述步骤3。
优选的,当所述第一解析结果不为空时,所述第一解析结果包括所述自然语言语句所属领域的领域属性,和/或与所述领域属性对应的用户意图,和/或所述自然语言语句中的关键信息。
优选的,所述步骤6的具体过程为:
步骤61.将所述反馈语句与预设的所有的所述领域句式进行匹配,以获取反馈解析结果;
步骤62.判断所述反馈解析结果是否为空;
若所述反馈解析结果不为空,则执行步骤63;
若所述反馈解析结果为空,则执行步骤64;
步骤63.将所述反馈解析结果作为所述语义解析结果,执行所述步骤3;
步骤64.将本件所述事件的语音交互过程中获得的之前所有的所述语义解析结果分别与所有的所述通用句式进行匹配,获得相应的所述匹配结果,将所有的所述匹配结果进行融合,以获得融合语句;
步骤65.判断所述融合语句是否为空;
若所述融合语句不为空,则执行步骤66;
若所述反馈解析结果为空,输出所述语义解析结果为空,并执行所述步 骤3;
步骤66.将所述融合语句作为所述语义解析结果,执行所述步骤3。
优选的,当所述反馈解析结果不为空时,所述反馈解析结果包括所述反馈语句所属领域的领域属性,和/或与所述领域属性对应的用户意图,和/或所述反馈语句中的关键信息。
优选的,当所述融合语句不为空时,所述融合语句包括所述反馈语句所属领域的领域属性,和/或与所述领域属性对应的用户意图,和/或所述反馈语句中的关键信息。
优选的,所述领域句式采用正则表达式表示。
优选的,所述通用句式采用正则表达式表示。
上述技术方案的有益效果:
本技术方案中,语言交互方法可将用户输出的自然语言语句进行解析,以获得相应的解析结果,并对用户再次输出的反馈语句进行解析,以实现在多轮对话中对人机对话过程中的上下文进行全面的解析,从而获得最优的解析结果,降低了设计人员的工作量和设计难度。
附图说明
图1为本发明所述的语言交互方法的第一种实施例的流程图;
图2为本发明所述的语言交互方法的第二种实施例的流程图;
图3为本发明所述的语言交互方法的另一种实施例的流程图。
具体实施方式
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而 不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有作出创造性劳动的前提下所获得的所有其他实施例,都属于本发明保护的范围。
需要说明的是,在不冲突的情况下,本发明中的实施例及实施例中的特征可以相互组合。
下面结合附图和具体实施例对本发明作进一步说明,但不作为本发明的限定。
如图1所示,一种语言交互方法,用于用户与机器人之间的语言交互过程中,采用一存储单元储存预设的语义语句,语义语句包括表示单一领域属性的领域句式和表示多个领域属性的通用句式;
一件事件的语音交互方法包括下述步骤:
步骤1.获取用户输出的自然语言语句;
步骤2.对自然语言语句进行语义解析,以获取相应的语义解析结果;
步骤3.机器人根据语义解析结果进行处理,以输出相应的响应结果;
步骤4.获取用户输出的反馈语句;
步骤5.判断反馈语句是否为结束指令,若是,则执行步骤7;若否,则执行步骤6;
步骤6.对反馈语句进行语义解析,以获取相应的语义解析结果,返回执行步骤3;
步骤7.结束。
其中,领域句式是指具有明确的领域属性的句式,即通过句式所传递的语义,可以明确的确定其所在的领域;通用句式是指不具有唯一领域属性的句式,即通过句式所传递的语义,不能唯一的确定其所在的领域,可能对应多个领域。
具体地,存储单元可预先存储所有的有关用户想要订飞机票时的领域句式,如:“订从$origin到$destination的飞机票”,其中“$origin”表示出发 地,“$destination”表示目的地;以“订飞机票”领域为例,对于语句“订从$origin到$destination的飞机票”,其中,“订飞机票”属于领域句式。但是在某些情况下,例如:当机器人发问“您要订到哪里的飞机票?”,用户的回答可能仅仅是一地名,比如“上海”,其对应的句式即为“$destination”,单单针对这一条句式很难判定其所在的领域,因为其他领域,比如“订火车票”也可能存在同样的句式,因此这种句式为通用句式。
在本实施例中,反馈语句可包括结束指令,结束指令用以表示结束本次事件的语言交互,即结束本次交互任务。
在本实施例中,语言交互方法可将用户输出的自然语言语句进行解析,以获得相应的解析结果,并对用户再次输出的反馈语句进行解析,以实现在多轮对话中对人机对话过程中的上下文进行全面的解析,从而获得最优的解析结果,不但降低设计人员的工作量和设计难度,而且解析效率高。
如图2所示,在优选的实施例中,步骤2的具体过程为:
步骤21.将自然语言语句与预设的所有的领域句式进行匹配,以获取第一解析结果;
步骤22.判断初次语义解析结果是否为空;
若第一解析结果不为空,则执行步骤23;
若第一解析结果为空,输出语义结果为空,并执行步骤3;
步骤23.将第一解析结果作为语义解析结果,执行步骤3。
在本实施例中,通过将自然语言语句与预设的所有的领域句式进行匹配,可获取自然语言语句对应的领域句式所属的领域,以方便机器人根据语义解析结果对应的领域进行相应的处理或查找,从而可快速的做出相应的响应,与用户互动,以提高用户的体验效果。
在优选的实施例中,当第一解析结果不为空时,第一解析结果包括自然语言语句所属领域的领域属性,和/或与领域属性对应的用户意图,和/或自然语言语句中的关键信息。
在本实施例中,每个领域属性可对应多个用户意图,当获取自然语言语句存在所属领域的领域属性时,可同时获取与该领域属性对应的用户意图,以快速的获取用户的目的或要求。
如图3所示,在优选的实施例中,步骤6的具体过程为:
步骤61.将反馈语句与预设的所有的领域句式进行匹配,以获取反馈解析结果;
步骤62.判断反馈解析结果是否为空;
若反馈解析结果不为空,则执行步骤63;
若反馈解析结果为空,则执行步骤64;
步骤63.将反馈解析结果作为语义解析结果,执行步骤3;
步骤64.将本件事件的语音交互过程中获得的之前所有的语义解析结果分别与所有的通用句式进行匹配,获得相应的匹配结果,将所有的匹配结果进行融合,以获得融合语句;
步骤65.判断融合语句是否为空;
若融合语句不为空,则执行步骤66;
若反馈解析结果为空,输出语义解析结果为空,并执行步骤3;
步骤66.将融合语句作为语义解析结果,执行步骤3。
机器人可根据语义解析结果从数据库中搜索的相应的数据,或者根据当前的状态向用户询问必要的信息。
在本实施例中,通过将用户输出的反馈语句与预设的所有的领域句式进行匹配,可获取自然语言语句对应的领域句式所属的领域,或根据多轮人机对话过程中的匹配结果,对上下文进行全面的解析,以将所有的匹配结果融合,从而获得最优的解析结果,以方便机器人根据语义解析结果对应的领域进行相应的处理或查找,从而可快速的做出相应的响应,与用户互动,以提高用户的体验效果,同时降低设计人员的工作量和设计难度。
在优选的实施例中,当反馈解析结果不为空时,反馈解析结果包括反馈 语句所属领域的领域属性,和/或与领域属性对应的用户意图,和/或反馈语句中的关键信息。
在本实施例中,每个领域属性可对应多个用户意图,当获取自然语言语句存在所属领域的领域属性时,可同时获取与该领域属性对应的用户意图,以快速的获取用户的目的或要求。
在优选的实施例中,当融合语句不为空时,融合语句包括反馈语句所属领域的领域属性,和/或与领域属性对应的用户意图,和/或反馈语句中的关键信息。
在本实施例中,每个领域属性可对应多个用户意图,当获取自然语言语句存在所属领域的领域属性时,可同时获取与该领域属性对应的用户意图,以快速的获取用户的目的或要求。通过根据多轮人机对话过程中的匹配结果,对上下文进行全面的解析,可将所有的匹配结果融合,从而获得最优的解析结果,以方便机器人根据语义解析结果对应的领域进行相应的处理或查找,从而使机器人快速的做出相应的响应。
在优选的实施例中,领域句式和通用句式均可采用正则表达式表示。
在本实施例中,正则表达式(Regular Expression),又称正规表示法或常规表示法,正则表达式是计算机科学的一个概念,采用单个字符串来描述、匹配一系列符合某个句法规则的字符串。可应用在文本编辑器中,正则表达式通常被用来作为检索、替换符合某个模式的文本的工具。
以上所述仅为本发明较佳的实施例,并非因此限制本发明的实施方式及保护范围,对于本领域技术人员而言,应当能够意识到凡运用本发明说明书及图示内容所作出的等同替换和显而易见的变化所得到的方案,均应当包含在本发明的保护范围内。

Claims (8)

  1. 一种语言交互方法,用于用户与机器人之间的语言交互过程中,其特征在于,采用一存储单元储存预设的语义语句,所述语义语句包括表示单一领域属性的领域句式和表示多个领域属性的通用句式;
    一件事件的所述语音交互方法包括下述步骤:
    步骤1.获取用户输出的自然语言语句;
    步骤2.对所述自然语言语句进行语义解析,以获取相应的语义解析结果;
    步骤3.所述机器人根据所述语义解析结果进行处理,以输出相应的响应结果;
    步骤4.获取所述用户输出的反馈语句;
    步骤5.判断所述反馈语句是否为结束指令,若是,则执行步骤7;若否,则执行步骤6;
    步骤6.对所述反馈语句进行语义解析,以获取相应的所述语义解析结果,返回执行所述步骤3;
    步骤7.结束。
  2. 如权利要求1所述的语言交互方法,其特征在于,所述步骤2的具体过程为:
    步骤21.将所述自然语言语句与预设的所有的所述领域句式进行匹配,以获取第一解析结果;
    步骤22.判断所述初次语义解析结果是否为空;
    若所述第一解析结果不为空,则执行步骤23;
    若所述第一解析结果为空,输出所述语义结果为空,并执行所述步骤3;
    步骤23.将所述第一解析结果作为所述语义解析结果,执行所述步骤3。
  3. 如权利要求2所述的语言交互方法,其特征在于,当所述第一解析结 果不为空时,所述第一解析结果包括所述自然语言语句所属领域的领域属性,和/或与所述领域属性对应的用户意图,和/或所述自然语言语句中的关键信息。
  4. 如权利要求1所述的语言交互方法,其特征在于,所述步骤6的具体过程为:
    步骤61.将所述反馈语句与预设的所有的所述领域句式进行匹配,以获取反馈解析结果;
    步骤62.判断所述反馈解析结果是否为空;
    若所述反馈解析结果不为空,则执行步骤63;
    若所述反馈解析结果为空,则执行步骤64;
    步骤63.将所述反馈解析结果作为所述语义解析结果,执行所述步骤3;
    步骤64.将本件所述事件的语音交互过程中获得的之前所有的所述语义解析结果分别与所有的所述通用句式进行匹配,获得相应的所述匹配结果,将所有的所述匹配结果进行融合,以获得融合语句;
    步骤65.判断所述融合语句是否为空;
    若所述融合语句不为空,则执行步骤66;
    若所述反馈解析结果为空,输出所述语义解析结果为空,并执行所述步骤3;
    步骤66.将所述融合语句作为所述语义解析结果,执行所述步骤3。
  5. 如权利要求4所述的语言交互方法,其特征在于,当所述反馈解析结果不为空时,所述反馈解析结果包括所述反馈语句所属领域的领域属性,和/或与所述领域属性对应的用户意图,和/或所述反馈语句中的关键信息。
  6. 如权利要求4所述的语言交互方法,其特征在于,当所述融合语句不为空时,所述融合语句包括所述反馈语句所属领域的领域属性,和/或与所述领域属性对应的用户意图,和/或所述反馈语句中的关键信息。
  7. 如权利要求1所述的语言交互方法,其特征在于,所述领域句式采用 正则表达式表示。
  8. 如权利要求1所述的语言交互方法,其特征在于,所述通用句式采用正则表达式表示。
PCT/CN2016/086490 2015-06-30 2016-06-20 一种语言交互方法 WO2017000809A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201510387071.6 2015-06-30
CN201510387071.6A CN106326307A (zh) 2015-06-30 2015-06-30 一种语言交互方法

Publications (1)

Publication Number Publication Date
WO2017000809A1 true WO2017000809A1 (zh) 2017-01-05

Family

ID=57607824

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2016/086490 WO2017000809A1 (zh) 2015-06-30 2016-06-20 一种语言交互方法

Country Status (4)

Country Link
CN (1) CN106326307A (zh)
HK (1) HK1231595A1 (zh)
TW (1) TWI588816B (zh)
WO (1) WO2017000809A1 (zh)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11749255B2 (en) 2019-04-30 2023-09-05 Boe Technology Group Co., Ltd. Voice question and answer method and device, computer readable storage medium and electronic device
CN117892828A (zh) * 2024-03-18 2024-04-16 青岛市勘察测绘研究院 一种地理信息系统自然语言交互方法、装置、设备及介质
CN117892828B (zh) * 2024-03-18 2024-05-31 青岛市勘察测绘研究院 一种地理信息系统自然语言交互方法、装置、设备及介质

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108044621B (zh) * 2017-09-20 2020-01-10 广东拓斯达科技股份有限公司 一种计算机可读存储介质和应用该介质的机器人
CN109726387A (zh) * 2017-10-31 2019-05-07 科沃斯商用机器人有限公司 人机交互方法和系统
CN110459211B (zh) 2018-05-07 2023-06-23 阿里巴巴集团控股有限公司 人机对话方法、客户端、电子设备及存储介质
CN111414760B (zh) * 2018-12-18 2023-06-16 广东美的白色家电技术创新中心有限公司 自然语言处理方法及相关设备、系统和存储装置
CN109960806A (zh) * 2019-03-26 2019-07-02 北京博瑞彤芸文化传播股份有限公司 一种自然语言处理方法
CN112307742B (zh) * 2019-08-23 2021-10-22 上海松鼠课堂人工智能科技有限公司 会话式人机交互口语测评方法、装置及存储介质
CN112017629B (zh) * 2020-07-15 2021-12-21 马上消费金融股份有限公司 语音机器人的会话控制方法及设备、存储介质
CN113113005A (zh) * 2021-03-19 2021-07-13 大众问问(北京)信息科技有限公司 语音数据处理方法、装置、计算机设备和存储介质
CN115346523A (zh) * 2021-05-14 2022-11-15 联发科技(新加坡)私人有限公司 语音设备的语音交互方法及装置

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101923539A (zh) * 2009-06-11 2010-12-22 珠海市智汽电子科技有限公司 基于自然语言的人机对话系统
CN103760984A (zh) * 2014-01-24 2014-04-30 成都万先自动化科技有限责任公司 人机对话系统
CN104008160A (zh) * 2014-05-29 2014-08-27 吴春尧 一种实现并行话题控制的模糊推理聊天机器人方法和系统
CN104199810A (zh) * 2014-08-29 2014-12-10 科大讯飞股份有限公司 一种基于自然语言交互的智能服务方法及系统

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI314271B (en) * 2005-01-27 2009-09-01 Delta Electronics Inc Vocabulary generating apparatus and method thereof and speech recognition system with the vocabulary generating apparatus
TW201013635A (en) * 2008-09-24 2010-04-01 Mitac Int Corp Intelligent voice system and method thereof
CN101753471A (zh) * 2008-12-04 2010-06-23 中国移动通信集团海南有限公司 一种im交互式文本应答方法及应答系统
CN101923857A (zh) * 2009-06-17 2010-12-22 复旦大学 一种人机交互的可扩展语音识别方法
CN103078995A (zh) * 2012-12-18 2013-05-01 苏州思必驰信息科技有限公司 一种在移动终端使用的可定制的个性化应答方法和系统
CN103198831A (zh) * 2013-04-10 2013-07-10 威盛电子股份有限公司 语音操控方法与移动终端装置
CN103744836A (zh) * 2014-01-08 2014-04-23 苏州思必驰信息科技有限公司 一种人机对话方法及装置
CN104408639A (zh) * 2014-10-22 2015-03-11 百度在线网络技术(北京)有限公司 多轮会话交互方法和系统

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101923539A (zh) * 2009-06-11 2010-12-22 珠海市智汽电子科技有限公司 基于自然语言的人机对话系统
CN103760984A (zh) * 2014-01-24 2014-04-30 成都万先自动化科技有限责任公司 人机对话系统
CN104008160A (zh) * 2014-05-29 2014-08-27 吴春尧 一种实现并行话题控制的模糊推理聊天机器人方法和系统
CN104199810A (zh) * 2014-08-29 2014-12-10 科大讯飞股份有限公司 一种基于自然语言交互的智能服务方法及系统

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11749255B2 (en) 2019-04-30 2023-09-05 Boe Technology Group Co., Ltd. Voice question and answer method and device, computer readable storage medium and electronic device
CN117892828A (zh) * 2024-03-18 2024-04-16 青岛市勘察测绘研究院 一种地理信息系统自然语言交互方法、装置、设备及介质
CN117892828B (zh) * 2024-03-18 2024-05-31 青岛市勘察测绘研究院 一种地理信息系统自然语言交互方法、装置、设备及介质

Also Published As

Publication number Publication date
TWI588816B (zh) 2017-06-21
HK1231595A1 (zh) 2017-12-22
CN106326307A (zh) 2017-01-11
TW201701270A (zh) 2017-01-01

Similar Documents

Publication Publication Date Title
TWI588816B (zh) 一種語言交互方法
US11797609B2 (en) Semantic representation and realization for conversational systems
US10845937B2 (en) Semantic representation and realization for conversational systems
US11816435B1 (en) Applied artificial intelligence technology for contextualizing words to a knowledge base using natural language processing
US9330659B2 (en) Facilitating development of a spoken natural language interface
JP6667504B2 (ja) オーファン発話検出システム及び方法
US20220004714A1 (en) Event extraction method and apparatus, and storage medium
US9740685B2 (en) Generation of natural language processing model for an information domain
JP2022539138A (ja) 自然言語理解(nlu)フレームワークを使用して意味探索を実行するシステムおよび方法
WO2015135455A1 (en) Natural language question answering method and apparatus
RU2509350C2 (ru) Способ семантической обработки естественного языка с использованием графического языка-посредника
JP6676109B2 (ja) 発話文生成装置とその方法とプログラム
KR102445519B1 (ko) 대화형 지능 서비스 제공 챗봇 제작 시스템 및 방법
JP2018028752A (ja) 対話システム及びそのためのコンピュータプログラム
WO2020233386A1 (zh) 基于aiml的智能问答方法、装置、计算机设备及存储介质
KR20160058531A (ko) 딥 러닝을 이용하는 구문 분석 모델 구축 방법 및 이를 수행하는 장치
KR101677859B1 (ko) 지식 베이스를 이용하는 시스템 응답 생성 방법 및 이를 수행하는 장치
US20220365956A1 (en) Method and apparatus for generating patent summary information, and electronic device and medium
CN115392264A (zh) 一种基于rasa的任务型智能多轮对话方法及相关设备
Fuckner et al. Using a personal assistant for exploiting service interfaces
JP2013190985A (ja) 知識応答システム、方法およびコンピュータプログラム
EP3407204A1 (en) Methods and systems for translating natural language requirements to a semantic modeling language statement
CN113792542A (zh) 一种融合句法分析和语义角色剪枝的意图理解方法
Wang et al. A framework for intelligent building information spoken dialogue system (iBISDS)
Xiao et al. Lightweight natural language driven intent translation mechanism for intent based networking

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 16817173

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 16817173

Country of ref document: EP

Kind code of ref document: A1