{"id":292,"date":"2025-07-27T18:31:19","date_gmt":"2025-07-27T10:31:19","guid":{"rendered":"http:\/\/anyone.anuoblog.cn\/?p=292"},"modified":"2025-07-29T11:14:49","modified_gmt":"2025-07-29T03:14:49","slug":"attention-is-all-you-need","status":"publish","type":"post","link":"http:\/\/anyone.anuoblog.cn\/index.php\/2025\/07\/27\/attention-is-all-you-need\/","title":{"rendered":"Attention Is All You Need"},"content":{"rendered":"\n<p><a href=\"https:\/\/arxiv.org\/abs\/1706.03762\"> Attention Is All You Need[1706.03762] Attention Is All You Need<\/a><\/p>\n\n\n\n<h1 class=\"wp-block-heading\">0 \u6458\u8981<\/h1>\n\n\n\n<details class=\"wp-block-details is-layout-flow wp-block-details-is-layout-flow\"><summary>\u7ffb\u8bd1<\/summary>\n<p>\u4e3b\u6d41\u7684\u5e8f\u5217\u8f6c\u6362\u6a21\u578b\u57fa\u4e8e\u590d\u6742\u7684\u5faa\u73af\u795e\u7ecf\u7f51\u7edc\u6216\u5377\u79ef\u795e\u7ecf\u7f51\u7edc\uff0c\u8fd9\u7c7b\u6a21\u578b\u5305\u542b\u7f16\u7801\u5668\u4e0e\u89e3\u7801\u5668\u7ed3\u6784\u3002\u6027\u80fd\u6700\u4f73\u7684\u6a21\u578b\u8fd8\u901a\u8fc7\u6ce8\u610f\u529b\u673a\u5236\u5b9e\u73b0\u7f16\u7801\u5668\u4e0e\u89e3\u7801\u5668\u7684\u8fde\u63a5\u3002\u672c\u6587\u63d0\u51fa\u4e00\u79cd\u5168\u65b0\u7684\u7b80\u5355\u7f51\u7edc\u67b6\u6784 \u2014\u2014Transformer\uff0c\u8be5\u67b6\u6784\u5b8c\u5168\u57fa\u4e8e\u6ce8\u610f\u529b\u673a\u5236\uff0c\u5f7b\u5e95\u6452\u5f03\u4e86\u5faa\u73af\u7ed3\u6784\u4e0e\u5377\u79ef\u64cd\u4f5c\u3002<\/p>\n\n\n\n<p>\u5728\u4e24\u9879\u673a\u5668\u7ffb\u8bd1\u4efb\u52a1\u4e0a\u7684\u5b9e\u9a8c\u8868\u660e\uff0cTransformer \u6a21\u578b\u4e0d\u4ec5\u8d28\u91cf\u66f4\u4f18\uff0c\u8fd8\u5177\u5907\u66f4\u5f3a\u7684\u5e76\u884c\u6027\uff0c\u4e14\u8bad\u7ec3\u65f6\u95f4\u663e\u8457\u7f29\u77ed\u3002\u5728 WMT 2014 \u82f1\u8bed\u5230\u5fb7\u8bed\u7ffb\u8bd1\u4efb\u52a1\u4e2d\uff0c\u8be5\u6a21\u578b\u53d6\u5f97\u4e86 28.4 \u7684 BLEU \u503c\uff0c\u8d85\u8d8a\u4e86\u5305\u62ec\u96c6\u6210\u6a21\u578b\u5728\u5185\u7684\u73b0\u6709\u6700\u4f73\u7ed3\u679c\uff0cBLEU \u503c\u63d0\u5347\u8d85\u8fc7 2 \u4e2a\u70b9\u3002\u5728 WMT 2014 \u82f1\u8bed\u5230\u6cd5\u8bed\u7ffb\u8bd1\u4efb\u52a1\u4e2d\uff0c\u7ecf\u8fc7 8 \u5757 GPU\u30013.5 \u5929\u7684\u8bad\u7ec3\uff0c\u6a21\u578b\u521b\u4e0b\u4e86 41.8 \u7684\u5355\u6a21\u578b BLEU \u503c\u65b0\u7eaa\u5f55\uff0c\u5176\u8bad\u7ec3\u6210\u672c\u4ec5\u4e3a\u6587\u732e\u4e2d\u6700\u4f73\u6a21\u578b\u7684\u4e00\u5c0f\u90e8\u5206\u3002\u6b64\u5916\uff0c\u901a\u8fc7\u5728\u82f1\u8bed constituency parsing \u4efb\u52a1\uff08\u65e0\u8bba\u8bad\u7ec3\u6570\u636e\u89c4\u6a21\u5927\u5c0f\uff09\u4e0a\u7684\u6210\u529f\u5e94\u7528\uff0c\u672c\u6587\u9a8c\u8bc1\u4e86 Transformer \u5177\u6709\u826f\u597d\u7684\u4efb\u52a1\u6cdb\u5316\u80fd\u529b\u3002<\/p>\n<\/details>\n\n\n\n<p>1\u3001\uff08\u52a8\u673a\uff09\u5728\u6b64\u8bba\u6587\u4e4b\u524d\uff0c\u4e3b\u6d41\u7684\u5e8f\u5217\u8f6c\u6362\u6a21\u578b\u57fa\u4e8e\u590d\u6742\u7684RNN\u6216CNN\uff0c\u8fd9\u7c7b\u6a21\u578b\u4e5f\u5305\u542b\u4e86\u7f16\u7801\u5668\u4e0e\u89e3\u7801\u5668\uff0c\u6027\u80fd\u6700\u4f73\u7684\u6a21\u578b\u4e5f\u8fd8\u901a\u8fc7\u6ce8\u610f\u529b\u673a\u5236\u5b9e\u73b0\u7f16\u7801\u5668\u4e0e\u89e3\u7801\u5668\u7684\u8fde\u63a5\u3002<\/p>\n\n\n\n<p>\u8fd9\u7c7b\u6a21\u578b\u7684\u7f3a\u70b9\uff1a<\/p>\n\n\n\n<p><strong>\u5e76\u884c\u8ba1\u7b97\u80fd\u529b\u5dee\u3001\u8bad\u7ec3\u6548\u7387\u4f4e<\/strong>\uff08RNN\u56fa\u6709\u5c40\u9650\uff0c\u5904\u7406\u4e00\u4e2a\u53e5\u5b50\u65f6\uff0c\u5fc5\u987b\u73b0\u8ba1\u7b97\u7b2c\u4e00\u4e2a\u8bcd\uff0c\u65e0\u6cd5\u5e76\u884c\u5904\u7406\uff1bCNN\u5c40\u90e8\u6027\u9650\u5236\uff0cCNN\u867d\u7136\u53ef\u4ee5\u5e76\u884c\u5904\u7406\uff0c\u4f46\u662f\u4f9d\u8d56\u5377\u79ef\u6838\u7684\u5c40\u90e8\u611f\u53d7\u91ce\uff0c\u82e5\u8981\u6355\u6349\u957f\u8ddd\u79bb\u4f9d\u8d56\u5173\u7cfb\uff0c\u9700\u901a\u8fc7\u591a\u5c42\u5377\u79ef\u5806\u53e0\uff08\u5982\u589e\u5927\u611f\u53d7\u91ce\uff09\uff0c\u8fd9\u4f1a\u589e\u52a0\u6a21\u578b\u590d\u6742\u5ea6\u548c\u8ba1\u7b97\u6210\u672c\uff0c\u4e14\u957f\u8ddd\u79bb\u4fe1\u606f\u4f20\u9012\u6548\u7387\u4ecd\u4f4e\u4e8e\u6ce8\u610f\u529b\u673a\u5236\uff09<\/p>\n\n\n\n<p><strong>\u957f\u8ddd\u79bb\u4f9d\u8d56\u5efa\u6a21\u80fd\u529b\u6709\u9650<\/strong>\uff08RNN\u7684\u8bb0\u5fc6\u8870\u9000\u3001CNN\u7684\u95f4\u63a5\u4f9d\u8d56\uff09<\/p>\n\n\n\n<p>2\u3001\uff08\u8d21\u732e\uff09\u672c\u6587\u63d0\u51fa\u4e00\u79cd\u5168\u65b0\u7684\u7b80\u5355\u7f51\u7edc\u67b6\u6784&#8211;Transformer\uff0c\u8be5\u67b6\u6784\u5b8c\u5168\u57fa\u4e8e\u6ce8\u610f\u529b\u673a\u5236\uff0c\u4ece\u800c\u5f7b\u5e95\u6452\u5f03\u4e86\u5faa\u73af\u7ed3\u6784\u548c\u5377\u79ef\u64cd\u4f5c\uff0cTransformer\u6a21\u578b\u4e0d\u4ec5\u8d28\u91cf\u66f4\u4f18\uff0c\u8fd8\u5177\u5907\u66f4\u5f3a\u7684\u5e76\u884c\u6027\uff0c\u4e14\u8bad\u7ec3\u65f6\u95f4\u663e\u8457\u7f29\u77ed\uff0c\u8bad\u7ec3\u901f\u7387\u5f97\u5230\u663e\u8457\u63d0\u5347\uff1b<\/p>\n\n\n\n<p>\u5b9e\u9a8c\u8bc1\u660e\uff1a<\/p>\n\n\n\n<p>\u5728\u4e24\u9879\u673a\u5668\u7ffb\u8bd1\u4efb\u52a1\u4e0a\u8fdb\u884c\u5b9e\u9a8c\uff1a<\/p>\n\n\n\n<p>\u5728 <strong>WMT 2014 \u82f1\u8bed\u5230\u5fb7\u8bed\u7ffb\u8bd1\u4efb\u52a1<\/strong>\u4e0e<strong>WMT 2014 \u82f1\u8bed\u5230\u6cd5\u8bed\u7ffb\u8bd1\u4efb\u52a1<\/strong>\u4e24\u9879\u5b9e\u9a8c\uff0cTransformer\u6a21\u578b\u8bad\u7ec3\u65f6\u95f4\u66f4\u77ed\uff0c\u5e76\u884c\u8ba1\u7b97\u80fd\u529b\u66f4\u5f3a\uff0c\u6a21\u578b\u8d28\u91cf\u66f4\u597d\uff1b<\/p>\n\n\n\n<details class=\"wp-block-details is-layout-flow wp-block-details-is-layout-flow\"><summary>\u672f\u8bed\u8bf4\u660e<\/summary>\n<p><strong>sequence transduction<\/strong>\uff1a\u5e8f\u5217\u8f6c\u6362\uff08\u6307\u5c06\u4e00\u79cd\u5e8f\u5217\u8f6c\u6362\u4e3a\u53e6\u4e00\u79cd\u5e8f\u5217\u7684\u4efb\u52a1\uff0c\u5982\u7ffb\u8bd1\uff09<\/p>\n\n\n\n<p><strong>recurrent neural networks<\/strong>\uff1a\u5faa\u73af\u795e\u7ecf\u7f51\u7edc\uff08RNN\uff09<\/p>\n\n\n\n<p><strong>convolutional neural networks<\/strong>\uff1a\u5377\u79ef\u795e\u7ecf\u7f51\u7edc\uff08CNN\uff09<\/p>\n\n\n\n<p><strong>encoder and decoder<\/strong>\uff1a\u7f16\u7801\u5668\u4e0e\u89e3\u7801\u5668<\/p>\n\n\n\n<p><strong>attention mechanism<\/strong>\uff1a\u6ce8\u610f\u529b\u673a\u5236<\/p>\n\n\n\n<p><strong>Transformer<\/strong>\uff1aTransformer \u6a21\u578b\uff08\u7279\u5b9a\u67b6\u6784\u540d\u79f0\uff0c\u4fdd\u7559\u539f\u540d\uff09<\/p>\n\n\n\n<p><strong>recurrence<\/strong>\uff1a\u5faa\u73af\u7ed3\u6784\uff08\u6307 RNN \u4e2d\u7684\u65f6\u5e8f\u4f9d\u8d56\u673a\u5236\uff09<\/p>\n\n\n\n<p><strong>convolutions<\/strong>\uff1a\u5377\u79ef\u64cd\u4f5c<\/p>\n\n\n\n<p><strong>parallelizable<\/strong>\uff1a\u53ef\u5e76\u884c\u6027\uff08\u6307\u6a21\u578b\u8ba1\u7b97\u7684\u5e76\u884c\u5904\u7406\u80fd\u529b\uff09<\/p>\n\n\n\n<p><strong>BLEU<\/strong>\uff1a\u53cc\u8bed\u8bc4\u4f30\u66ff\u6362\uff08\u4e00\u79cd\u8861\u91cf\u7ffb\u8bd1\u8d28\u91cf\u7684\u81ea\u52a8\u8bc4\u4f30\u6307\u6807\uff09<\/p>\n\n\n\n<p><strong>WMT 2014<\/strong>\uff1a2014 \u5e74\u673a\u5668\u7ffb\u8bd1\u7814\u8ba8\u4f1a\uff08\u56fd\u9645\u6743\u5a01\u7684\u673a\u5668\u7ffb\u8bd1\u8bc4\u6d4b\u57fa\u51c6\uff09<\/p>\n\n\n\n<p><strong>ensemble<\/strong>\uff1a\u96c6\u6210\u6a21\u578b\uff08\u591a\u4e2a\u6a21\u578b\u7684\u7ec4\u5408\uff09<\/p>\n\n\n\n<p><strong>constituency parsing<\/strong>\uff1a\u7ec4\u5757\u89e3\u6790\uff08\u53e5\u6cd5\u5206\u6790\u7684\u4e00\u79cd\uff0c\u5c06\u53e5\u5b50\u5206\u89e3\u4e3a\u53e5\u6cd5\u6210\u5206\uff09<\/p>\n\n\n\n<p><strong>generalizes<\/strong>\uff1a\u6cdb\u5316\uff08\u6307\u6a21\u578b\u5bf9\u672a\u89c1\u8fc7\u7684\u6570\u636e\u6216\u65b0\u4efb\u52a1\u7684\u9002\u5e94\u80fd\u529b\uff09<\/p>\n<\/details>\n\n\n\n<h1 class=\"wp-block-heading\">1 \u5f15\u8a00<\/h1>\n\n\n\n<details class=\"wp-block-details is-layout-flow wp-block-details-is-layout-flow\"><summary>\u7ffb\u8bd1<\/summary>\n<p>\u9012\u5f52\u795e\u7ecf\u7f51\u7edc\uff0c\u5c24\u5176\u662f\u957f\u77ed\u671f\u8bb0\u5fc6\u7f51\u7edc [13] \u548c\u95e8\u63a7\u9012\u5f52\u795e\u7ecf\u7f51\u7edc [7]\uff0c\u5df2\u88ab\u786e\u7acb\u4e3a\u5e8f\u5217\u5efa\u6a21\u548c\u8f6c\u6362\u95ee\u9898\uff08\u5982\u8bed\u8a00\u5efa\u6a21\u4e0e\u673a\u5668\u7ffb\u8bd1 [35, 2, 5]\uff09\u4e2d\u7684\u6700\u5148\u8fdb\u65b9\u6cd5\u3002\u6b64\u540e\uff0c\u5927\u91cf\u7814\u7a76\u6301\u7eed\u7a81\u7834\u9012\u5f52\u8bed\u8a00\u6a21\u578b\u4e0e\u7f16\u7801\u5668 &#8211; \u89e3\u7801\u5668\u67b6\u6784\u7684\u6027\u80fd\u8fb9\u754c [38, 24, 15]\u3002<\/p>\n\n\n\n<p>\u9012\u5f52\u6a21\u578b\u7684\u8ba1\u7b97\u901a\u5e38\u6cbf\u8f93\u5165\u548c\u8f93\u51fa\u5e8f\u5217\u7684\u7b26\u53f7\u4f4d\u7f6e\u5c55\u5f00\u3002\u901a\u8fc7\u5c06\u4f4d\u7f6e\u4e0e\u8ba1\u7b97\u65f6\u95f4\u6b65\u5bf9\u9f50\uff0c\u6a21\u578b\u751f\u6210\u4e00\u7cfb\u5217\u9690\u85cf\u72b6\u6001\\(h_t\\)\uff0c\u5176\u503c\u7531\u524d\u4e00\u65f6\u523b\u7684\u9690\u85cf\u72b6\u6001\\(h_{t-1}\\)\u548c\u5f53\u524d\u4f4d\u7f6et\u7684\u8f93\u5165\u5171\u540c\u51b3\u5b9a\u3002\u8fd9\u79cd\u56fa\u6709\u7684\u5e8f\u5217\u7279\u6027\u5bfc\u81f4\u8bad\u7ec3\u6837\u672c\u5185\u90e8\u65e0\u6cd5\u5e76\u884c\u8ba1\u7b97\uff1b\u5f53\u5e8f\u5217\u957f\u5ea6\u8f83\u957f\u65f6\uff0c\u8fd9\u4e00\u95ee\u9898\u5c24\u4e3a\u5173\u952e \u2014\u2014 \u5185\u5b58\u9650\u5236\u4f1a\u8fdb\u4e00\u6b65\u5236\u7ea6\u6837\u672c\u95f4\u7684\u6279\u5904\u7406\u6548\u7387\u3002\u5c3d\u7ba1\u8fd1\u671f\u7814\u7a76\u901a\u8fc7\u56e0\u5b50\u5206\u89e3\u6280\u5de7 [21] \u548c\u6761\u4ef6\u8ba1\u7b97 [32] \u5728\u8ba1\u7b97\u6548\u7387\u4e0a\u53d6\u5f97\u4e86\u663e\u8457\u63d0\u5347\uff0c\u4e14\u540e\u8005\u8fd8\u6539\u5584\u4e86\u6a21\u578b\u6027\u80fd\uff0c\u4f46\u5e8f\u5217\u8ba1\u7b97\u8fd9\u4e00\u6839\u672c\u7ea6\u675f\u4ecd\u672a\u89e3\u51b3\u3002<\/p>\n\n\n\n<p>\u6ce8\u610f\u529b\u673a\u5236\u5df2\u6210\u4e3a\u5404\u7c7b\u5e8f\u5217\u5efa\u6a21\u4e0e\u8f6c\u6362\u4efb\u52a1\u4e2d\u9ad8\u6027\u80fd\u6a21\u578b\u7684\u6838\u5fc3\u7ec4\u4ef6\uff0c\u5b83\u80fd\u591f\u5efa\u6a21\u8f93\u5165\u6216\u8f93\u51fa\u5e8f\u5217\u4e2d\u4efb\u610f\u8ddd\u79bb\u7684\u4f9d\u8d56\u5173\u7cfb [2, 19]\u3002\u7136\u800c\uff0c\u9664\u5c11\u6570\u4f8b\u5916 [27]\uff0c\u8fd9\u7c7b\u6ce8\u610f\u529b\u673a\u5236\u591a\u4e0e\u9012\u5f52\u7f51\u7edc\u7ed3\u5408\u4f7f\u7528\u3002<\/p>\n\n\n\n<p>\u5728\u672c\u6587\u4e2d\uff0c\u6211\u4eec\u63d0\u51fa\u4e00\u79cd\u5168\u65b0\u6a21\u578b\u67b6\u6784 \u2014\u2014Transformer\uff0c\u5b83\u6452\u5f03\u4e86\u9012\u5f52\u7ed3\u6784\uff0c\u5b8c\u5168\u4f9d\u8d56\u6ce8\u610f\u529b\u673a\u5236\u6765\u6355\u6349\u8f93\u5165\u4e0e\u8f93\u51fa\u4e4b\u95f4\u7684\u5168\u5c40\u4f9d\u8d56\u5173\u7cfb\u3002Transformer \u652f\u6301\u66f4\u9ad8\u7a0b\u5ea6\u7684\u5e76\u884c\u8ba1\u7b97\uff0c\u4ec5\u9700\u5728 8 \u5757 P100 GPU \u4e0a\u8bad\u7ec3 12 \u5c0f\u65f6\uff0c\u5c31\u80fd\u5728\u7ffb\u8bd1\u8d28\u91cf\u4e0a\u8fbe\u5230\u65b0\u7684\u6700\u5148\u8fdb\u6c34\u5e73\u3002<\/p>\n<\/details>\n\n\n\n<p>\u5148\u524d\u5904\u7406\u5e8f\u5217\u5efa\u6a21\u4e0e\u8f6c\u6362\u95ee\u9898\u5efa\u6a21\u4e0e\u673a\u5668\u7ffb\u8bd1\u7684\u65b9\u6cd5\uff1aRNN\uff08\u9012\u5f52\u795e\u7ecf\u7f51\u7edc\uff09\u3001LSTM\uff08long short-term memory\uff0c\u957f\u77ed\u671f\u8bb0\u5fc6\u7f51\u7edc\uff09\u3001Encoder-Deconder\uff08\u7f16\u7801\u5668-\u89e3\u7801\u5668\u67b6\u6784\uff09\u3001GRU\uff08\u95e8\u63a7\u9012\u5f52\u795e\u7ecf\u7f51\u7edc\uff09\uff1b<\/p>\n\n\n\n<p><strong>\u8fd9\u4e9b\u6a21\u578b\u7684\u95ee\u9898\uff1a<\/strong><\/p>\n\n\n\n<p>\u9012\u5f52\u6a21\u578b\u7684\u8ba1\u7b97\u901a\u5e38\u6cbf\u8f93\u5165\u548c\u8f93\u51fa\u5e8f\u5217\u7684\u7b26\u53f7\u4f4d\u7f6e\u5c55\u5f00\uff0c\u65e0\u6cd5\u5e76\u884c\u8ba1\u7b97\uff1b<\/p>\n\n\n\n<p>\u5f53\u5904\u7406\u5e8f\u5217\u8f83\u957f\uff0c\u5185\u5b58\u8017\u8d39\u8fc7\u5927\uff0c\u4f7f\u6837\u672c\u5904\u7406\u7684\u6548\u7387\u53d8\u5dee\uff1b<\/p>\n\n\n\n<p>\u5c3d\u7ba1\u6b64\u540e\u7814\u7a76\u5728\u8ba1\u7b97\u6548\u7387\u4e0a\u53d6\u5f97\u663e\u8457\u63d0\u793a\uff0c\u4f46\u662f\u65e0\u6cd5\u5bf9\u5e8f\u5217\u5e76\u884c\u8ba1\u7b97\u8fd9\u4e00\u6839\u672c\u95ee\u9898\u4ecd\u4e3a\u89e3\u51b3\uff1b<\/p>\n\n\n\n<p><strong>\u672c\u6587\u6539\u8fdb\uff1a<\/strong><\/p>\n\n\n\n<p>\u6ce8\u610f\u529b\u673a\u5236\u53ef\u4ee5\u5728RNN\u4e0a\u4f7f\u7528\uff0c\u901a\u8fc7\u6ce8\u610f\u529b\u673a\u5236\u628aencoder\u7684\u4fe1\u606f\u4f20\u7ed9decoder\uff0c\u53ef\u4ee5\u5141\u8bb8\u4e0d\u8003\u8651\u8f93\u5165\u8f93\u51fa\u5e8f\u5217\u7684\u8ddd\u79bb\u5efa\u6a21\u3002<\/p>\n\n\n\n<p>\u63d0\u51fa\u5168\u65b0\u6a21\u578b\u67b6\u6784&#8211;Transformer\uff0c\u6452\u5f03\u4e86\u9012\u5f52\u7ed3\u6784\uff0c\u6452\u5f03\u4e86\u9012\u5f52\u7ed3\u6784\uff0c<strong>\u5b8c\u5168\u4f9d\u8d56\u6ce8\u610f\u529b\u673a\u5236\u6765\u6355\u6349\u8f93\u5165\u4e0e\u8f93\u51fa\u4e4b\u95f4\u7684\u5168\u5c40\u4f9d\u8d56\u5173\u7cfb<\/strong>\uff0c\u652f\u6301\u66f4\u9ad8\u7a0b\u5ea6\u7684\u5e76\u884c\u8ba1\u7b97\uff0c\u8bad\u7ec3\u6548\u7387\u9ad8\uff0c\u7ffb\u8bd1\u8d28\u91cf\u9ad8\uff1b<\/p>\n\n\n\n<details class=\"wp-block-details is-layout-flow wp-block-details-is-layout-flow\"><summary>\u672f\u8bed\u8bf4\u660e<\/summary>\n<p><strong>Recurrent neural networks<\/strong>\uff1a\u9012\u5f52\u795e\u7ecf\u7f51\u7edc\uff08RNN\uff09<\/p>\n\n\n\n<p><strong>long short-term memory (LSTM)<\/strong>\uff1a\u957f\u77ed\u671f\u8bb0\u5fc6\u7f51\u7edc<\/p>\n\n\n\n<p><strong>gated recurrent neural networks (GRU)<\/strong>\uff1a\u95e8\u63a7\u9012\u5f52\u795e\u7ecf\u7f51\u7edc<\/p>\n\n\n\n<p><strong>state of the art<\/strong>\uff1a\u6700\u5148\u8fdb\uff08\u65b9\u6cd5 \/ \u6027\u80fd\uff09<\/p>\n\n\n\n<p><strong>sequence modeling and transduction<\/strong>\uff1a\u5e8f\u5217\u5efa\u6a21\u4e0e\u8f6c\u6362<\/p>\n\n\n\n<p><strong>encoder-decoder architectures<\/strong>\uff1a\u7f16\u7801\u5668 &#8211; \u89e3\u7801\u5668\u67b6\u6784<\/p>\n\n\n\n<p><strong>hidden states<\/strong>\uff1a\u9690\u85cf\u72b6\u6001<\/p>\n\n\n\n<p><strong>parallelization<\/strong>\uff1a\u5e76\u884c\u8ba1\u7b97<\/p>\n\n\n\n<p><strong>batching<\/strong>\uff1a\u6279\u5904\u7406<\/p>\n\n\n\n<p><strong>factorization tricks<\/strong>\uff1a\u56e0\u5b50\u5206\u89e3\u6280\u5de7<\/p>\n\n\n\n<p><strong>conditional computation<\/strong>\uff1a\u6761\u4ef6\u8ba1\u7b97<\/p>\n\n\n\n<p><strong>attention mechanisms<\/strong>\uff1a\u6ce8\u610f\u529b\u673a\u5236<\/p>\n\n\n\n<p><strong>global dependencies<\/strong>\uff1a\u5168\u5c40\u4f9d\u8d56\u5173\u7cfb<\/p>\n<\/details>\n\n\n\n<h1 class=\"wp-block-heading\">2 \u76f8\u5173\u5de5\u4f5c<\/h1>\n\n\n\n<details class=\"wp-block-details is-layout-flow wp-block-details-is-layout-flow\"><summary>\u7ffb\u8bd1<\/summary>\n<p>\u51cf\u5c11\u5e8f\u5217\u8ba1\u7b97\u91cf\u7684\u76ee\u6807\u540c\u6837\u662f Extended Neural GPU [16]\u3001ByteNet [18] \u548c ConvS2S [9] \u7684\u8bbe\u8ba1\u57fa\u7840\u3002\u8fd9\u4e9b\u6a21\u578b\u5747\u4ee5\u5377\u79ef\u795e\u7ecf\u7f51\u7edc\u4e3a\u57fa\u672c\u6784\u5efa\u5757\uff0c\u5bf9\u6240\u6709\u8f93\u5165\u548c\u8f93\u51fa\u4f4d\u7f6e\u7684\u9690\u85cf\u8868\u793a\u8fdb\u884c\u5e76\u884c\u8ba1\u7b97\u3002\u5728\u8fd9\u7c7b\u6a21\u578b\u4e2d\uff0c\u5173\u8054\u4efb\u610f\u4e24\u4e2a\u8f93\u5165\u6216\u8f93\u51fa\u4f4d\u7f6e\u4fe1\u53f7\u6240\u9700\u7684\u8fd0\u7b97\u91cf\uff0c\u968f\u4f4d\u7f6e\u95f4\u8ddd\u79bb\u7684\u589e\u52a0\u800c\u589e\u957f\uff1aConvS2S \u5448\u7ebf\u6027\u589e\u957f\uff0cByteNet \u5448\u5bf9\u6570\u589e\u957f\u3002\u8fd9\u4f7f\u5f97\u6a21\u578b\u96be\u4ee5\u5b66\u4e60\u8fdc\u8ddd\u79bb\u4f4d\u7f6e\u95f4\u7684\u4f9d\u8d56\u5173\u7cfb [12]\u3002\u5728 Transformer \u4e2d\uff0c\u8fd9\u4e00\u8fd0\u7b97\u91cf\u88ab\u7f29\u51cf\u4e3a\u5e38\u6570\u7ea7\uff0c\u5c3d\u7ba1\u4ee3\u4ef7\u662f\u7531\u4e8e\u5bf9\u6ce8\u610f\u529b\u52a0\u6743\u4f4d\u7f6e\u8fdb\u884c\u5e73\u5747\u800c\u5bfc\u81f4\u6709\u6548\u5206\u8fa8\u7387\u964d\u4f4e \u2014\u2014 \u5bf9\u6b64\uff0c\u6211\u4eec\u901a\u8fc7 3.2 \u8282\u6240\u8ff0\u7684\u591a\u5934\u6ce8\u610f\u529b\u673a\u5236\u8fdb\u884c\u7f13\u89e3\u3002<\/p>\n\n\n\n<p>\u81ea\u6ce8\u610f\u529b\uff08\u6709\u65f6\u79f0\u4e3a\u5185\u90e8\u6ce8\u610f\u529b\uff09\u662f\u4e00\u79cd\u5173\u8054\u5355\u4e2a\u5e8f\u5217\u4e2d\u4e0d\u540c\u4f4d\u7f6e\u4ee5\u8ba1\u7b97\u5e8f\u5217\u8868\u793a\u7684\u6ce8\u610f\u529b\u673a\u5236\u3002\u81ea\u6ce8\u610f\u529b\u5df2\u6210\u529f\u5e94\u7528\u4e8e\u591a\u79cd\u4efb\u52a1\uff0c\u5305\u62ec\u9605\u8bfb\u7406\u89e3\u3001\u62bd\u8c61\u6458\u8981\u3001\u6587\u672c\u8574\u542b\u63a8\u7406\u4ee5\u53ca\u5b66\u4e60\u4efb\u52a1\u65e0\u5173\u7684\u53e5\u5b50\u8868\u793a [4, 27, 28, 22]\u3002<\/p>\n\n\n\n<p>\u7aef\u5230\u7aef\u8bb0\u5fc6\u7f51\u7edc\u57fa\u4e8e\u9012\u5f52\u6ce8\u610f\u529b\u673a\u5236\u800c\u975e\u5e8f\u5217\u5bf9\u9f50\u7684\u9012\u5f52\u7ed3\u6784\uff0c\u5df2\u88ab\u8bc1\u660e\u5728\u7b80\u5355\u8bed\u8a00\u95ee\u7b54\u548c\u8bed\u8a00\u5efa\u6a21\u4efb\u52a1\u4e2d\u8868\u73b0\u4f18\u5f02 [34]\u3002<\/p>\n\n\n\n<p>\u7136\u800c\uff0c\u636e\u6211\u4eec\u6240\u77e5\uff0cTransformer \u662f\u9996\u4e2a\u5b8c\u5168\u4f9d\u8d56\u81ea\u6ce8\u610f\u529b\u6765\u8ba1\u7b97\u8f93\u5165\u548c\u8f93\u51fa\u8868\u793a\u7684\u8f6c\u6362\u6a21\u578b\uff0c\u65e0\u9700\u4f7f\u7528\u5e8f\u5217\u5bf9\u9f50\u7684\u5faa\u73af\u795e\u7ecf\u7f51\u7edc\u6216\u5377\u79ef\u64cd\u4f5c\u3002\u5728\u540e\u7eed\u7ae0\u8282\u4e2d\uff0c\u6211\u4eec\u5c06\u8be6\u7ec6\u63cf\u8ff0 Transformer\uff0c\u9610\u8ff0\u81ea\u6ce8\u610f\u529b\u7684\u8bbe\u8ba1\u52a8\u673a\uff0c\u5e76\u8ba8\u8bba\u5176\u76f8\u5bf9\u4e8e [17, 18, 9] \u7b49\u6a21\u578b\u7684\u4f18\u52bf\u3002<\/p>\n<\/details>\n\n\n\n<p>1\u3001\u4f7f\u7528CNN\u6a21\u578b\u4ee3\u66ffRNN\uff08\u51cf\u5c11\u5e8f\u5217\u8ba1\u7b97\u91cf\u7684\u76ee\u6807\u540c\u6837\u662f Extended Neural GPU [16]\u3001ByteNet [18] \u548c ConvS2S [9] \u7684\u8bbe\u8ba1\u57fa\u7840\u3002\uff09<\/p>\n\n\n\n<p><strong>\u4f18\u70b9\uff1a<\/strong><\/p>\n\n\n\n<p>\u51cf\u5c11\u5e8f\u5217\u8ba1\u7b97<\/p>\n\n\n\n<p><strong>\u95ee\u9898\uff1a<\/strong><\/p>\n\n\n\n<p><\/p>\n\n\n\n<details class=\"wp-block-details is-layout-flow wp-block-details-is-layout-flow\"><summary>\u672f\u8bed\u8bf4\u660e<\/summary>\n<p><strong>Extended Neural GPU<\/strong>\uff1a\u6269\u5c55\u795e\u7ecf GPU\uff08\u4e00\u79cd\u5e76\u884c\u8ba1\u7b97\u6a21\u578b\uff09<\/p>\n\n\n\n<p><strong>ByteNet\/ConvS2S<\/strong>\uff1a\u57fa\u4e8e\u5377\u79ef\u7684\u5e8f\u5217\u8f6c\u6362\u6a21\u578b\uff08\u5177\u4f53\u6a21\u578b\u540d\u79f0\uff09<\/p>\n\n\n\n<p><strong>self-attention\/intra-attention<\/strong>\uff1a\u81ea\u6ce8\u610f\u529b \/ \u5185\u90e8\u6ce8\u610f\u529b\uff08\u5173\u6ce8\u5e8f\u5217\u5185\u90e8\u4f4d\u7f6e\u5173\u8054\u7684\u673a\u5236\uff09<\/p>\n\n\n\n<p><strong>reading comprehension<\/strong>\uff1a\u9605\u8bfb\u7406\u89e3<\/p>\n\n\n\n<p><strong>abstractive summarization<\/strong>\uff1a\u62bd\u8c61\u6458\u8981\uff08\u751f\u6210\u5f0f\u6458\u8981\uff09<\/p>\n\n\n\n<p><strong>textual entailment<\/strong>\uff1a\u6587\u672c\u8574\u542b\u63a8\u7406\uff08\u5224\u65ad\u6587\u672c\u95f4\u7684\u903b\u8f91\u5173\u7cfb\uff09<\/p>\n\n\n\n<p><strong>end-to-end memory networks<\/strong>\uff1a\u7aef\u5230\u7aef\u8bb0\u5fc6\u7f51\u7edc\uff08\u57fa\u4e8e\u8bb0\u5fc6\u673a\u5236\u7684\u795e\u7ecf\u7f51\u7edc\uff09<\/p>\n\n\n\n<p><strong>transduction model<\/strong>\uff1a\u8f6c\u6362\u6a21\u578b\uff08\u5c06\u4e00\u79cd\u5e8f\u5217\u8f6c\u6362\u4e3a\u53e6\u4e00\u79cd\u5e8f\u5217\u7684\u6a21\u578b\uff09<\/p>\n\n\n\n<p><strong>sequence-aligned RNNs<\/strong>\uff1a\u5e8f\u5217\u5bf9\u9f50\u7684\u5faa\u73af\u795e\u7ecf\u7f51\u7edc\uff08\u6309\u65f6\u5e8f\u6b65\u9aa4\u5904\u7406\u7684 RNN\uff09<\/p>\n<\/details>\n\n\n\n<h1 class=\"wp-block-heading\">3 \u6a21\u578b\u67b6\u6784<\/h1>\n\n\n\n<details class=\"wp-block-details is-layout-flow wp-block-details-is-layout-flow\"><summary>\u7ffb\u8bd1<\/summary>\n<p>\u5927\u591a\u6570\u5177\u6709\u7ade\u4e89\u529b\u7684\u795e\u7ecf\u5e8f\u5217\u8f6c\u6362\u6a21\u578b\u90fd\u91c7\u7528\u7f16\u7801\u5668 &#8211; \u89e3\u7801\u5668\u7ed3\u6784 [5, 2, 35]\u3002\u5176\u4e2d\uff0c\u7f16\u7801\u5668\u5c06\u8f93\u5165\u7684\u7b26\u53f7\u8868\u793a\u5e8f\u5217\uff08x\u2081, \u2026, x\u2099\uff09\u6620\u5c04\u4e3a\u8fde\u7eed\u8868\u793a\u5e8f\u5217 z =\uff08z\u2081, \u2026, z\u2099\uff09\u3002\u7ed9\u5b9a z \u540e\uff0c\u89e3\u7801\u5668\u4f1a\u9010\u4e2a\u751f\u6210\u8f93\u51fa\u7b26\u53f7\u5e8f\u5217\uff08y\u2081, \u2026, y\u2098\uff09\u3002\u5728\u6bcf\u4e00\u6b65\u4e2d\uff0c\u6a21\u578b\u91c7\u7528\u81ea\u56de\u5f52\u65b9\u5f0f [10]\uff0c\u5373\u751f\u6210\u4e0b\u4e00\u4e2a\u7b26\u53f7\u65f6\uff0c\u4f1a\u5c06\u4e4b\u524d\u5df2\u751f\u6210\u7684\u7b26\u53f7\u4f5c\u4e3a\u989d\u5916\u8f93\u5165\u3002<\/p>\n\n\n\n<p>Transformer \u9075\u5faa\u8fd9\u4e00\u6574\u4f53\u67b6\u6784\uff0c\u5176\u7f16\u7801\u5668\u548c\u89e3\u7801\u5668\u5747\u7531\u5806\u53e0\u7684\u81ea\u6ce8\u610f\u529b\u5c42\u548c\u9010\u70b9\u5168\u8fde\u63a5\u5c42\u6784\u6210\uff0c\u5206\u522b\u5bf9\u5e94\u56fe 1 \u7684\u5de6\u534a\u90e8\u5206\u548c\u53f3\u534a\u90e8\u5206\u3002<\/p>\n<\/details>\n\n\n\n<figure class=\"wp-block-image size-full\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='http:\/\/anyone.anuoblog.cn\/wp-content\/uploads\/2025\/07\/image-110.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" width=\"874\" height=\"886\" data-original=\"http:\/\/anyone.anuoblog.cn\/wp-content\/uploads\/2025\/07\/image-110.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\" class=\"wp-image-325\"  sizes=\"auto, (max-width: 874px) 100vw, 874px\" \/><\/div><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">3.1 \u7f16\u7801\u5668\u4e0e\u89e3\u7801\u5668\u5806\u53e0\u7ed3\u6784<\/h2>\n\n\n\n<details class=\"wp-block-details is-layout-flow wp-block-details-is-layout-flow\"><summary>\u7ffb\u8bd1<\/summary>\n<p>\u7f16\u7801\u5668\uff1a\u7f16\u7801\u5668\u7531N=6\u4e2a\u76f8\u540c\u5c42\u7684\u5806\u6808\u7ec4\u6210\u3002\u6bcf\u4e00\u5c42\u6709\u4e24\u4e2a\u5b50\u5c42\u3002\u7b2c\u4e00\u79cd\u662f\u591a\u5934\u81ea\u6211\u6ce8\u610f\u673a\u5236\uff0c\u7b2c\u4e8c\u79cd\u662f\u7b80\u5355\u7684\u3001\u4f4d\u7f6e\u4e0a\u5b8c\u5168\u8fde\u63a5\u7684\u524d\u9988\u7f51\u7edc\u3002\u6211\u4eec\u5728\u4e24\u4e2a\u5b50\u5c42\u7684\u6bcf\u4e00\u4e2a\u5468\u56f4\u4f7f\u7528\u6b8b\u5dee\u8fde\u63a5[11]\uff0c\u7136\u540e\u8fdb\u884c\u5c42\u5f52\u4e00\u5316[1]\u3002\u4e5f\u5c31\u662f\u8bf4\uff0c\u6bcf\u4e2a\u5b50\u5c42\u7684\u8f93\u51fa\u662fLayerNorm\uff08x+\u5b50\u5c42\uff08x\uff09\uff09\uff0c\u5176\u4e2d\u5b50\u5c42\uff08x\uff09\u662f\u5b50\u5c42\u672c\u8eab\u5b9e\u73b0\u7684\u51fd\u6570\u3002\u4e3a\u4e86\u4fc3\u8fdb\u8fd9\u4e9b\u6b8b\u4f59\u8fde\u63a5\uff0c\u6a21\u578b\u4e2d\u7684\u6240\u6709\u5b50\u5c42\u4ee5\u53ca\u5d4c\u5165\u5c42\u90fd\u4f1a\u4ea7\u751f\u7ef4\u5ea6dmodel=512\u7684\u8f93\u51fa\u3002<\/p>\n\n\n\n<p>\u89e3\u7801\u5668\uff1a\u89e3\u7801\u5668\u4e5f\u7531N=6\u4e2a\u76f8\u540c\u5c42\u7684\u5806\u6808\u7ec4\u6210\u3002\u9664\u4e86\u6bcf\u4e2a\u7f16\u7801\u5668\u5c42\u4e2d\u7684\u4e24\u4e2a\u5b50\u5c42\u5916\uff0c\u89e3\u7801\u5668\u8fd8\u63d2\u5165\u4e86\u7b2c\u4e09\u4e2a\u5b50\u5c42\uff0c\u8be5\u5b50\u5c42\u5bf9\u7f16\u7801\u5668\u5806\u6808\u7684\u8f93\u51fa\u6267\u884c\u591a\u5934\u6ce8\u610f\u529b\u3002\u4e0e\u7f16\u7801\u5668\u7c7b\u4f3c\uff0c\u6211\u4eec\u5728\u6bcf\u4e2a\u5b50\u5c42\u5468\u56f4\u4f7f\u7528\u6b8b\u5dee\u8fde\u63a5\uff0c\u7136\u540e\u8fdb\u884c\u5c42\u5f52\u4e00\u5316\u3002\u6211\u4eec\u8fd8\u4fee\u6539\u4e86\u89e3\u7801\u5668\u5806\u6808\u4e2d\u7684\u81ea\u5173\u6ce8\u5b50\u5c42\uff0c\u4ee5\u9632\u6b62\u4f4d\u7f6e\u5173\u6ce8\u540e\u7eed\u4f4d\u7f6e\u3002\u8fd9\u79cd\u63a9\u853d\uff0c\u518d\u52a0\u4e0a\u8f93\u51fa\u5d4c\u5165\u504f\u79fb\u4e86\u4e00\u4e2a\u4f4d\u7f6e\u7684\u4e8b\u5b9e\uff0c\u786e\u4fdd\u4e86\u4f4d\u7f6ei\u7684\u9884\u6d4b\u53ea\u80fd\u4f9d\u8d56\u4e8e\u5c0f\u4e8ei\u7684\u4f4d\u7f6e\u5904\u7684\u5df2\u77e5\u8f93\u51fa\u3002<\/p>\n<\/details>\n\n\n\n<p>\u7f16\u7801\u5668\uff08Encoder\uff09\u75316\u4e2a\u7ed3\u6784\u76f8\u540c\u7684Encode\u7ec4\u6210\uff0c\u6bcf\u4e2aEncode\u4e2d\u542b\u6709\u4e24\u4e2a\u5b50\u5c42\uff1a\u591a\u5934\u6ce8\u610f\u529b\u673a\u5236\u3001\u524d\u9988\u795e\u7ecf\u7f51\u7edc\uff1b\u5b50\u5c42\u4e4b\u95f4\u4e5f\u8fd8\u4f7f\u7528\u4e86\u6b8b\u5dee\u8fde\u63a5\uff0c\u5bf9\u5904\u7406\u4e4b\u540e\u7684\u7ed3\u679c\u8fdb\u884c\u5c42\u5f52\u4e00\u5316\uff08LayerNorm\uff09\uff1b<\/p>\n\n\n\n<p>\u89e3\u7801\u5668\uff08Decoder\uff09\uff0c\u662f\u7531\u516d\u4e2a\u7ed3\u6784\u76f8\u540c\u7684Decode\u7ec4\u6210\uff0c\u6bcf\u4e2aDecode\u4e2d\u7684\u5b50\u5c42\u9664\u4e86\u6709Encode\u4e2d\u7684\u4e24\u4e2a\u5c42\u5916\uff0c\u5728\u5176\u4e24\u4e2a\u5c42\u4e4b\u524d\u53c8\u52a0\u4e86\u4e00\u4e2a\u6709\u63a9\u7801\u7684\u591a\u5934\u6ce8\u610f\u529b\uff1bDecoder\u63a5\u6536Encoder\u7684\u8f93\u51fa\u4f5c\u4e3a\u8f93\u5165\uff1b<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">3.2 \u6ce8\u610f\u529b\u673a\u5236<\/h2>\n\n\n\n<details class=\"wp-block-details is-layout-flow wp-block-details-is-layout-flow\"><summary>\u7ffb\u8bd1<\/summary>\n<p>\u6ce8\u610f\u529b\u51fd\u6570\u53ef\u63cf\u8ff0\u4e3a\u5c06\u4e00\u4e2a\u67e5\u8be2\uff08query\uff09\u548c\u4e00\u7ec4\u952e\u503c\u5bf9\uff08key-value pairs\uff09\u6620\u5c04\u5230\u8f93\u51fa\u7684\u8fc7\u7a0b\uff0c\u5176\u4e2d\u67e5\u8be2\u3001\u952e\u3001\u503c\u53ca\u8f93\u51fa\u5747\u4e3a\u5411\u91cf\u3002\u8f93\u51fa\u7684\u8ba1\u7b97\u65b9\u5f0f\u662f\u5bf9\u6240\u6709\u503c\u8fdb\u884c\u52a0\u6743\u6c42\u548c\uff0c\u800c\u6bcf\u4e2a\u503c\u6240\u5206\u914d\u7684\u6743\u91cd\uff0c\u5219\u901a\u8fc7\u67e5\u8be2\u4e0e\u5bf9\u5e94\u952e\u7684\u517c\u5bb9\u6027\u51fd\u6570\u8ba1\u7b97\u5f97\u51fa\u3002<\/p>\n<\/details>\n\n\n\n<figure class=\"wp-block-image size-large\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='http:\/\/anyone.anuoblog.cn\/wp-content\/uploads\/2025\/07\/image-111-1024x593.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"593\" data-original=\"http:\/\/anyone.anuoblog.cn\/wp-content\/uploads\/2025\/07\/image-111-1024x593.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" alt=\"\" class=\"wp-image-328\"  sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/div><\/figure>\n\n\n\n<details class=\"wp-block-details is-layout-flow wp-block-details-is-layout-flow\"><summary>\u672f\u8bed\u8bf4\u660e<\/summary>\n<p><strong>attention function<\/strong>\uff1a\u6ce8\u610f\u529b\u51fd\u6570\uff08\u5b9e\u73b0 \u201c\u5173\u6ce8\u91cd\u8981\u4fe1\u606f\u201d \u7684\u6838\u5fc3\u8ba1\u7b97\u903b\u8f91\uff09\u3002<\/p>\n\n\n\n<p><strong>query, keys, values<\/strong>\uff1a\u67e5\u8be2\u3001\u952e\u3001\u503c\uff08\u6ce8\u610f\u529b\u673a\u5236\u4e2d\u7684\u4e09\u4e2a\u6838\u5fc3\u5411\u91cf\uff0c\u7c7b\u6bd4\u4fe1\u606f\u68c0\u7d22\uff1a\u7528 \u201c\u67e5\u8be2\u201d \u5339\u914d \u201c\u952e\u201d\uff0c\u518d\u7528\u5339\u914d\u7ed3\u679c\u5bf9 \u201c\u503c\u201d \u52a0\u6743\uff09\u3002<\/p>\n\n\n\n<p><strong>weighted sum of the values<\/strong>\uff1a\u503c\u7684\u52a0\u6743\u548c\uff08\u6ce8\u610f\u529b\u8f93\u51fa\u7684\u8ba1\u7b97\u65b9\u5f0f\uff0c\u91cd\u8981\u6027\u9ad8\u7684 \u201c\u503c\u201d \u5360\u6bd4\u66f4\u9ad8\uff09\u3002<\/p>\n\n\n\n<p><strong>compatibility function<\/strong>\uff1a\u517c\u5bb9\u6027\u51fd\u6570\uff08\u8861\u91cf\u67e5\u8be2\u4e0e\u952e\u5339\u914d\u7a0b\u5ea6\u7684\u51fd\u6570\uff0c\u5982\u70b9\u79ef\u3001\u7f29\u653e\u70b9\u79ef\u7b49\uff09\u3002<\/p>\n<\/details>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Attention Is All You Need[1706.03762] Attention Is All  [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-292","post","type-post","status-publish","format-standard","hentry","category-message"],"_links":{"self":[{"href":"http:\/\/anyone.anuoblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/292","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/anyone.anuoblog.cn\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/anyone.anuoblog.cn\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/anyone.anuoblog.cn\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/anyone.anuoblog.cn\/index.php\/wp-json\/wp\/v2\/comments?post=292"}],"version-history":[{"count":3,"href":"http:\/\/anyone.anuoblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/292\/revisions"}],"predecessor-version":[{"id":329,"href":"http:\/\/anyone.anuoblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/292\/revisions\/329"}],"wp:attachment":[{"href":"http:\/\/anyone.anuoblog.cn\/index.php\/wp-json\/wp\/v2\/media?parent=292"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/anyone.anuoblog.cn\/index.php\/wp-json\/wp\/v2\/categories?post=292"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/anyone.anuoblog.cn\/index.php\/wp-json\/wp\/v2\/tags?post=292"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}