表示直到时间t时候的对话状态的表示, 这种经典的状态结构通常叫做槽填充(Slot Filling)或者语义框架(Semantic Frame)
传统的方法在许多商业的实现中运用的很广泛, 通常是通过人工的规则去选择一些近似的回答, 这样的基于规则的系统容易产生错误而且结果大多数不是很正确
一个统计的对话系统维持着一个在多种关于真实状态的假设下的分布, 面临着噪声和模糊的问题
在对话状态跟踪挑战(DSTC)中, 每一轮对话中, 对于槽都有相应的概率分布的形式
各种统计方法,包括手工规则的健壮集合, 条件随机场, 最大熵模型和web风格排名方法出现在对话挑战(DSTC)中
最近, [20]在信念追踪中引入了深度学习, 它使用滑动窗口输出任意数量可能值的概率分布序列
[20] M. Henderson, B. Thomson, and S. Young. Deep neural network approach for the dialog state tracking challenge. In Proceedings of the SIGDIAL 2013 Conference, pages 467–471, 2013.
虽然这个只在一个领域进行训练, 但却可以轻易的迁移到另外一个领域.
还有其他人开发了multi-domain RNN 对话状态跟踪模型, 它一开始使用了所有有效的数据来训练一个非常一般的信念追踪模型, 并且使每个领域的一般模型专门化, 学习特殊领域的行为.
[48] N. Mrkˇsi´c, D. O S´eaghdha, B. Thomson, M. Gasic, P.- ´ H. Su, D. Vandyke, T.-H. Wen, and S. Young. Multidomain dialog state tracking using recurrent neural networks. In Proceedings of the 53rd Annual Meeting of the Association for Computational Linguistics and the 7th International Joint Conference on Natural Language Processing (Volume 2: Short Papers), pages 794–799, Beijing, China, July 2015. Association for Computational Linguistics
[49] 提出了一种神经信念跟踪器(NBT)来检测槽-值对(slot-value pairs), 它将用户输入之前的系统对话行为, 用户话语本身以及它需要作出的一个候选槽-值对作为输入做出决定, 然后在所有候选槽-值对上迭代以确定哪些刚才已经被用户表达了.
[49] N. Mrkˇsi´c, D. O S´eaghdha, T.-H. Wen, B. Thomson, ´ and S. Young. Neural belief tracker: Data-driven dialogue state tracking. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 1777–1788, Vancouver, Canada, July 2017. Association for Computational Linguistics.
3.1.3 策略学习
以来自状态跟踪器的状态表示作为条件, 策略学习就是去生成下一个有用的系统动作.
监督学习或者是强化学习, 都可以用来优化策略学习
**[9] H. Cuayhuitl, S. Keizer, and O. Lemon. Strategic dialogue management via deep reinforcement learning. arxiv.org, 2015. **
通常采用基于规则的agent来预热系统
[98] Z. Yan, N. Duan, P. Chen, M. Zhou, J. Zhou, and Z. Li. Building task-oriented dialogue systems for online shopping, 2017.
然后, 有监督的学习被基于规则生成的动作所引导, 在线上购物场景中, 如果对话状态是"推荐"的话, 那么"推荐"动作就会被触发, 系统将会在产品数据库中进行产品的搜索. 如果对话状态是"比较"的话, 系统将会比较目标产品/品牌.
对话策略能够被使用强化学习进一步的端到端的训练, 进而针对最后的表现制订出策略, [9]应用了深度强化学习在策略交流上, 同时的学习特征表达和对话策略, 该系统的表现优于随机的, 基于规则的和基于监督的方法.
3.1.4 自然语言生成
自然语言生成模块就是将抽象的对话动作转变为自然语言表达.
一个好的生成器应该依赖于以下几个因素:
NLG的传统方法是执行句子规划, 它将输入的语义符号映射到话语表示的中介形式, 比如树形或者模板, 然后将中间结构转换成最后的表达, 通过surface realization实现最后的回应.
[69] A. Stent, R. Prasad, and M. Walker. Trainable sentence planning for complex information presentation in spoken dialog systems. In Proceedings of the 42nd annual meeting on association for computational linguistics, page 79. Association for Computational Linguistics, 2004.
也有使用神经网络方法, 基于LSTM和RNNLM类似的结构来进行NLG.
[42] T. Mikolov, M. Karafi´at, L. Burget, J. Cernock`y, and S. Khudanpur. Recurrent neural network based language model. In Interspeech, volume 2, page 3, 2010
[81] T.-H. Wen, M. Gasic, D. Kim, N. Mrksic, P.-H. Su, D. Vandyke, and S. Young. Stochastic language generation in dialogue using recurrent neural networks with convolutional sentence reranking. In Proceedings of the 16th Annual Meeting of the Special Interest Group on Discourse and Dialogue, pages 275–284, Prague, Czech Republic, September 2015. Association for Computational Linguistics.
这个对话动作类型和它的槽-值对转换成one hot 控制向量, 作为额外的输入, 这样就可以保证生成的话语代表了预期的意义
[81]使用一个前向的RNN生成器以及一个CNN的重评分模块, 一个后向的RNN重评分模块.
所有的子模块都被联合优化, 进而生成以所需的对话动作为条件的语句, 为了处理slot信息在surface realization中省略和重复的问题, [82] 使用一个额外的控制单元来导向对话动作.
[82] T.-H. Wen, M. Gasic, N. Mrkˇsi´c, P.-H. Su, D. Vandyke, and S. Young. Semantically conditioned lstm-based natural language generation for spoken dialogue systems. In Proceedings of the 2015 Conference on Empirical Methods in Natural Language Processing, pages 1711–1721, Lisbon, Portugal, September 2015. Association for Computational Linguistics.
[72]扩展了这个方法, 通过用门控制LSTM的输入token向量对应相应的对话动作, 接着[83]通过多种适应性步骤扩展成多领域的模型.
[72] V. K. Tran and L. M. Nguyen. Semantic refinement gru-based neural language generation for spoken dialogue systems. In PACLING, 2017.
[83] T.-H. Wen, M. Gaˇsi´c, N. Mrkˇsi´c, L. M. RojasBarahona, P.-H. Su, D. Vandyke, and S. Young. Multidomain neural network language generation for spoken dialogue systems. In Proceedings of the 2016 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, pages 120–129, San Diego, California, June 2016. Association for Computational Linguistics.
[110]采用一个基于LSTM的编码器-解码器结构来合并问题信息, 语义槽值和对话动作类型, 来生成正确的答案, 它使用了注意力机制来关注以解码器当前的解码状态为条件的关键的信息, 将对话动作编码成Embedding向量, 基于神经网络的模型能够生成多样的回答对应不同对话动作类型.
[110] H. Zhou, M. Huang, and X. Zhu. Context-aware natural language generation for spoken dialogue systems. In COLING, pages 2032–2041, 2016.
[14]也给出了一个基于序列到序列的方法的自然语言生成器, 能够被训练成通过对话动作类型生成自然语言字符串和深度句法依存树结构一样
[14] O. Duˇsek and F. Jurcicek. Sequence-to-sequence generation for spoken dialogue via deep syntax trees and strings. In Proceedings of the 54th Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers), pages 45–51, Berlin, Germany, August 2016. Association for Computational Linguistics.
[13]在用户的表达和回应之前进行了扩展, 这使得模型会随着用户说话的方式而改变, 提供了适于上下文的回应
[13] O. Duˇsek and F. Jurcicek. A context-aware natural language generator for dialogue systems. In Proceedings of the 17th Annual Meeting of the Special Interest Group on Discourse and Dialogue, pages 185–190, Los Angeles, September 2016. Association for Computational Linguistics.
3.2 端到端方法
尽管在传统的面向任务对话系统中有很多的特定领域的人工处理方法, 但很难去适应新的领域.
传统的面向任务的管道方法有两个限制:
- 一个是信用分配问题,其中最终用户的反馈很难传播到每个上游模块
- 第二个是过程相互依赖, 一个组件的输入依赖于另一个组件的输出
当一个组件适应一个新的环境或者使用新的数据进行训练, 所有的其他组件需要通过保证全局优化方法来进行适应
槽和特征也会相应的改变, 这个操作需要人的重要的影响, 随着这几年端到端神经生成网络模型的增加, 许多都是试着构造一个对于面向任务的对话系统的端到端可训练框架. 当我们谈及非面向任务系统的时候, 我们会谈及更多的细节.
除了传统的管道模型, 端到端模型使用一个简单的模块并且和结构化外部数据库进行交互
[84]和[4]介绍了一种基于网络的端到端的可训练的面向任务的对话系统, 它们将对话系统学习看作是学习一种从对话历史到对话回应的映射, 应用编码器-解码器模型来训练整个系统
[4] A. Bordes, Y. L. Boureau, and J. Weston. Learning end-to-end goal-oriented dialog. 2017.
[84] T.-H. Wen, D. Vandyke, N. Mrkˇsi´c, M. Gasic, L. M. Rojas Barahona, P.-H. Su, S. Ultes, and S. Young. A network-based end-to-end trainable task-oriented dialogue system. In Proceedings of the 15th Conference of the European Chapter of the Association for Computational Linguistics: Volume 1, Long Papers, pages 438–449, Valencia, Spain, April 2017. Association for Computational Linguistics.
然而在有监督样式下的训练的系统, 不仅需要大量的数据, 而且可能缺少在训练数据中对于对话控制的探究
[107]首次提出了端到端的强化学习方法用于联合训练对话管理中的对话状态跟踪以及策略学习, 进而更为鲁棒性地优化系统动作
[107] T. Zhao and M. Eskenazi. Towards end-to-end learning for dialog state tracking and management using deep reinforcement learning. In Proceedings of the 17th Annual Meeting of the Special Interest Group on Discourse and Dialogue, pages 1–10, Los Angeles, September 2016. Association for Computational Linguistics.
在对话之中, agent询问用户Yes/No问题来找到正确的答案, 这个方法当应用于面向任务的对话问题(猜测用户想的有名的人)时看起来似乎有希望,
[36]训练了一个端到端的系统作为一个任务完成神经对话系统, 其目的也就是完成一个任务, 比如预定电影票
[36] X. Li, Y.-N. Chen, L. Li, and J. Gao. End-to-end taskcompletion neural dialogue systems. arXiv preprint arXiv:1703.01008, 2017.
面向任务的系统通常需要询问超出知识的范围, 之前的系统通过生成一个符号化询问到知识库基于它们的属性来搜索, 其中对输入执行语义解析, 进而构建代表agent关于用户目标的信念的符号查询([84; 90; 36]), 这个方法有两个缺点:
- 遍历搜索的结果并不能带有任何关于语义分析的不确定性的信息
- 遍历的操作不可微分, 因此分析器和对话策略分离地进行训练, 这样一旦系统被部署, 在线的端到端学习就会变得很困难
[15] 通过基于关注的可重用键值检索机制对现有的循环网络体系结构进行了扩展, 该机制受知识库的条目限制, 其受关键值记忆网络[44]启发.
[15] M. Eric and C. D. Manning. Key-value retrieval networks for task-oriented dialogue. arXiv preprint arXiv:1705.05414, 2017.
[44] A. Miller, A. Fisch, J. Dodge, A.-H. Karimi, A. Bordes, and J. Weston. Key-value memory networks for directly reading documents. In Proceedings of the 2016 Conference on Empirical Methods in Natural Language Processing, pages 1400–1409, Austin, Texas, November 2016. Association for Computational Linguistics.
[12]将符号化查询替换成在指示用户感兴趣的条目的知识库上的诱导的"软"后验分布, 集成软搜索处理和强化学习
[89]将RNN和特定领域知识编码相结合作为软件和系统动作的模板
[12] B. Dhingra, L. Li, X. Li, J. Gao, Y.-N. Chen, F. Ahmed, and L. Deng. Towards end-to-end reinforce- ment learning of dialogue agents for information access. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 484–495, Vancouver, Canada, July 2017. Association for Computational Linguistics.
[89] J. D. Williams, K. Asadi, and G. Zweig. Hybrid code networks: practical and efficient end-to-end dialog control with supervised and reinforcement learning. In Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 665–677, Vancouver, Canada, July 2017. Association for Computational Linguistics.
4. 非面向任务的对话系统
不向面向任务的对话系统, 目的是完成一个特定的任务, 非面向任务的对话系统(也可以称为chatbots)关注于和人类进行宽领域的谈话. 一般来说, chat bots实现的方案不是生成方法就是基于检索的方法.
生成模型能够生成更多的从未出现在语料库的合理回应, 基于检索的模型享有信息量和流畅响应的优势. 因为它们使用回应选择算法从仓库中去获取相应的回答.
接下来的部分, 将首次介绍神经生成模型, 研究热点中的其中一个, 我们会讨论该模型的优缺点以及可能的改进, 然后介绍深度学习在基于搜索的模型上的应用.
4.1 神经生成模型
[54]提出了一个生成概率模型, 基于基于分析的统计机器翻译, 在微博上对谈话进行建模, 它将回答的生成问题视为一个翻译问题, 然而回答的生成是要比语言之间的翻译要困难得多, 这是由于存在许多貌似正确的回应, 以及过去和回答之间的分析校准的缺失.
深度学习在机器翻译上的成功应用, 称神经机器翻译, 进而促进对神经生成对话系统的研究工作
在接下来的子模块里面, 我们会介绍序列到序列的模型, 这是生成神经模型的基础, 然后我们将讨论研究的热点, 包括合并对话上下文, 提高回答多样性, 制造话题和人格, 利用外部知识库, 互动学习和评价.
4.1.1 序列到序列的模型
给定一个原序列