当前位置:首页 >> 动力

提升支付宝搜索体验,蚂蚁、人民大学提出基于层次化对比学习文本的生成框架

来源:动力   2025年03月13日 02:07

RT embedding[7] 来作为每个路由

的调用,并用作一个 MLP 层来求学每条边的透露

。我们通过一个 graph attention (GAT) 层和 MLP 层来增量的设计地新版本ID在线中的的路由和边,每个增量中的我们可先通过如下的法则新版本边的透露:

这里

可以是

或者

然后根据新版本后的边

,我们通过一个 graph attention 层来新版本每个路由的透露:

这里

都是可求学的参数,

为注意力权重。为了防范分量销声匿迹的弊端,我们在

上加上了残差连接,给予该增量中的路由的透露

。我们用作再一一个增量的路由透露作为ID的透露,中有为 u。

ID对比 ID一般来说的对比来自于转换该词语的ID

和一个伪装(impostor)路由

。我们将转换该词语的转换成亦然样本中的提取的ID中有为

,它在上述ID在线中的的负亲戚路由中有为

,则

,ID一般来说的对比求学 loss 量度如下:

这里

用来指代

或者

,h(·) 用来透露靠近内积,在ID一般来说的对比求学中的我们选用了余弦相像度来量度两个点相互间的靠近。

串连一般来说对比求学 可以注意到上述该词语一般来说和ID一般来说的对比求学分别是在原产和点上实现,这样两个一般来说的法理对比也许由于差异比较大引发大幅提高视觉效果移向。对此,我们基于点和原产相互间的何氏靠近(Mahalanobis distance)[8] 重构各有不同一般来说相互间对比联系,使得尽量转换成ID到该词语原产的靠近尽也许小于 imposter 到该原产的靠近,从而弥补各一般来说法理对比也许带来的对比销声匿迹的缺陷。比如说,串连一般来说的何氏靠近对比求学希望尽也许缩减该词语的后验句法原产

相互间的靠近,同时尽也许拉大其与

相互间的靠近,重大损失线性如下:

这里

同样用来指代

或者

,而 h(·) 为何氏靠近。

实验室 Andrew 分析

实验室结果

我们在三个公开信息集 Douban(Dialogue)[9],QQP(Paraphrasing)[10][11] 和 RocStories(Storytelling)[12] 上进行时了实验室,均赢取了 SOTA 的视觉效果。我们对比的水平线还包括传统习俗的转化建模(e.g. CVAE[13],Seq2Seq[14],Transformer[15]),基于实专业训练建模的法则(e.g. Seq2Seq-DU[16],DialoGPT[17],BERT-GEN[7],T5[18])以及基于对比求学的法则(e.g. Group-wise[9],T5-CLAPS[19])。我们通过量度 BLEU score[20] 和句对相互间的 BOW embedding 靠近(extrema/erage/greedy)[21] 来作为控制系统评论指标,结果如下图右图:

我们在 QQP 信息集上还引入了人工评估的法则,3 个标明医护人员分别对 T5-CLAPS,DialoGPT,Seq2Seq-DU 以及我们的建模引发的结果进行时了标明,结果如下图右图:

消融分析

我们对确实引入ID、确实引入ID在线以及确实引入何氏靠近对比原产进行时了消融分析实验室,结果显示这三种内部设计对再一的结果确实起到了举足轻重的功用,实验室结果如下图右图。

GIS分析

为了科学研究各有不同层级对比求学的功用,我们对随机采样的 case 进行时了GIS,通过 t-sne[22] 进行时降维解决问题后给予下图。图中的可以显露,转换该词语的透露与放入的ID透露相比之下,这说明ID作为该词语中的最举足轻重的发送到者,一般而言亦会决定句法原产的一段距离。并且,在对比求学中的我们可以看到经过专业训练,转换该词语的原产与亦然样本格外相比之下,与负样本靠近,这说明对比求学可以起到帮助修亦然句法原产的功用。

ID举足轻重性分析

再一,我们探索采样各有不同ID的影响。如下表右图,对于一个转换弊端,我们通过 TextRank 放入和随机选择的法则分别提供ID作为控制句法原产的条件,并核查转化文本的质量。ID作为该词语中的最举足轻重的发送到者两节,各有不同的ID亦会引发各有不同的句法原产,引发各有不同的的测试,选择的ID趋多,转化的该词语趋准确。同时,其他建模转化的结果也展示在下表中的。

销售业务运用

这短文中的我们提出了一种串连一般来说的层次化对比求学机制,在多个文本转化的信息集上均超过了不具创新能力的水平线工作。基于该工作的 query 删去建模在也在淘宝关键字的单单销售业务场景成功落地,赢取了突出的视觉效果。淘宝关键字中的的维修服务看成行业宽广并且行业特色突出,用户的关键字 query 强调与维修服务的强调单单上巨大的字面差异,引发单独基于ID的匹配较难赢取难得的视觉效果(可有如用户转换 query“新主板汽车查阅”,不能复职维修服务 “新车主板查阅”),query 删去的尽量是在保持 query 意图基本上的意味著,将用户转换的 query 删去为格外贴近维修服务强调的法则,从而格外好的匹配到尽量维修服务。如下是一些删去示可有:

参考文献

[1] Seanie Lee, Dong Bok Lee, and Sung Ju Hwang. 2021. Contrastive learning with adversarial perturbations for conditional text generation. In 9th International Conference on Learning Representations, ICLR.

[2] Hengyi Cai, Hongshen Chen, Yonghao Song, Zhuoye Ding, Yongjun Bao, Weipeng Yan, and Xiaofang Zhao. 2020. Group-wise contrastive learning for neural dialogue generation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: Findings, EMNLP 2020.

[3] Jiwei Li, Minh-Thang Luong, and Dan Jurafsky. 2015. A hierarchical neural autoencoder for paragraphs and documents. arXiv preprint.

[4] Meng-Hsuan Yu, Juntao Li, Zhangming Chan, Dongyan Zhao, and Rui Yan. 2021. Content learning with structure-aware writing: A graph-infused dual conditional variational autoencoder for automatic storytelling. In Proceedings of the AAAI Conference on Artificial Intelligence.

[5] Solomon Kullback and Richard A Leibler. 1951. On information and sufficiency. The annals of mathematical statistics.

[6] Rada Mihalcea and Paul Tarau. 2004. Textrank: Bringing order into text. In Proceedings of the 2004 conference on empirical methods in natural language processing.

[7] Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2018. Bert: Pre-training of deep bidirectional transformers for language understanding. arXiv preprint.

[8] Roy De Maesschalck, Delphine Jouan-Rimbaud, and Désiré L Massart. 2000. The mahalanobis distance. Chemometrics and intelligent laboratory systems.

[9] Hengyi Cai, Hongshen Chen, Yonghao Song, Zhuoye Ding, Yongjun Bao, Weipeng Yan, and Xiaofang Zhao. 2020. Group-wise contrastive learning for neural dialogue generation. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: Findings, EMNLP 2020.

[10] Shankar Iyer, Nikhil Dandekar, and Kornel Csernai. 2017. First quora dataset release: Question pairs.

[11] Alex Wang, Amanpreet Singh, Julian Michael, Felix Hill, Omer Levy, and Samuel R. Bowman. 2019. GLUE: A multi-task benchmark and ysis platform for natural language understanding. In the Proceedings of ICLR.

[12] Nasrin Mostafazadeh, Nathanael Chambers, Xiaodong He, Devi Parikh, Dhruv Batra, Lucy Vanderwende, Pushmeet Kohli, and James Allen. 2016. A corpus and cloze evaluation for deeper understanding of commonsense stories. In Proceedings of the 2016 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies.

[13] Tiancheng Zhao, Ran Zhao, and Maxine Eskenazi. 2017. Learning discourse-level diversity for neural dialog models using conditional variational autoencoders. arXiv preprint.

[14] Ilya Sutskever, Oriol Vinyals, and Quoc V. Le. 2014. Sequence to sequence learning with neural networks. In Advances in Neural Information Processing Systems 27: Annual Conference on Neural Information.

[15] Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, and Illia Polosukhin. 2017. Attention is all you need. In Advances in Neural Information Processing Systems 30: Annual Conference on Neural Information Processing Systems 2017.

[16] Yue Feng, Yang Wang, and Hang Li. 2021. A sequence-to-sequence approach to dialogue state tracking. ACL 2021.

[17] Yizhe Zhang, Siqi Sun, Michel Galley, Yen-Chun Chen, Chris Brockett, Xiang Gao, Jianfeng Gao, Jingjing Liu, and Bill Dolan. 2020. Dialogpt: Large-scale generative pre-training for conversational response generation. In ACL, system demonstration.

[18] Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, and Peter J. Liu. 2020. Exploring the limits of transfer learning with a unified text-to-text transformer. J. Mach. Learn. Res.

[19] Seanie Lee, Dong Bok Lee, and Sung Ju Hwang. 2021.

Contrastive learning with adversarial perturbations for conditional text generation. In 9th International Conference on Learning Representations, ICLR 2021.

[20] Kishore Papineni, Salim Roukos, Todd Ward, and Wei-Jing Zhu. 2002. Bleu: a method for automatic evaluation of machine translation. In ACL.

[21] Xiaodong Gu, Kyunghyun Cho, Jung-Woo Ha, and Sunghun Kim. 2019. DialogWAE: Multimodal response generation with conditional wasserstein autoencoder. In International Conference on Learning Representations.

[22] Laurens van der Maaten and Geoffrey Hinton. 2008. Visualizing data using t-sne. Journal of machine learning research.

咽喉肿痛有异物感
太极药业
宫颈癌是什么原因引起的
角膜炎怎么治疗好的快
经常便秘吃什么药好
芬必得和英太青功效一样吗
气虚怎么办
湿气重吃什么排湿最快医生是这么说的
怎么治疗类风湿关节炎好的快
快速止痛痛风怎么办
友情链接