{"id":9454,"date":"2025-10-30T16:49:51","date_gmt":"2025-10-30T08:49:51","guid":{"rendered":"\/?p=9454"},"modified":"2025-10-30T16:49:51","modified_gmt":"2025-10-30T08:49:51","slug":"rag%e6%9c%89%e5%93%aa%e4%ba%9b%e4%bc%98%e5%8c%96%e6%89%8b%e6%ae%b5","status":"publish","type":"post","link":"\/?p=9454","title":{"rendered":"RAG\u6709\u54ea\u4e9b\u4f18\u5316\u624b\u6bb5"},"content":{"rendered":"<p>\u5982\u679c\u4f60\u80fd\u7b54\u51fa\u4e00\u5957\u7cfb\u7edf\u5316\u7684RAG\u4f18\u5316\u601d\u8def\uff0c\u90a3\u9762\u8bd5\u5b98\u4e00\u5b9a\u4f1a\u89c9\u5f97\uff1a<strong>\u8fd9\u4eba\u6709\u5b9e\u8df5\u3001\u6709\u601d\u8003\u3002<\/strong><\/p>\n<h2>\u4e00\u3001RAG\u5230\u5e95\u5728\u4f18\u5316\u4ec0\u4e48\uff1f**unset**<strong>**unset<\/strong><\/h2>\n<p>\u5728\u804a\u4f18\u5316\u4e4b\u524d\uff0c\u5148\u628a\u95ee\u9898\u672c\u8eab\u7406\u6e05\u695a\u3002<\/p>\n<p>RAG\uff08Retrieval-Augmented Generation\uff09\u662f<strong>\u68c0\u7d22\u589e\u5f3a\u751f\u6210<\/strong>\u7684\u7b80\u79f0\uff0c\u6838\u5fc3\u6d41\u7a0b\u662f\uff1a<\/p>\n<ol>\n<li>\u7528\u6237\u63d0\u51fa\u95ee\u9898\uff1b<\/li>\n<li>\u7cfb\u7edf\u5728\u77e5\u8bc6\u5e93\u4e2d<strong>\u68c0\u7d22<\/strong>\u5230\u76f8\u5173\u6587\u6863\uff1b<\/li>\n<li>\u628a\u68c0\u7d22\u7ed3\u679c\u62fc\u63a5\u8fdbPrompt\uff1b<\/li>\n<li>\u4ea4\u7ed9LLM\u8fdb\u884c\u751f\u6210\u3002<\/li>\n<\/ol>\n<p>\u542c\u8d77\u6765\u5f88\u7b80\u5355\uff0c\u4f46\u771f\u6b63\u843d\u5730\u65f6\u4f1a\u9047\u5230\u4e09\u7c7b\u5178\u578b\u95ee\u9898\uff1a<\/p>\n<ul>\n<li><strong>\u68c0\u7d22\u4e0d\u51c6<\/strong>\uff1a\u53ec\u56de\u4e86\u4e00\u5806\u4e0d\u76f8\u5173\u7684\u6587\u672c\uff1b<\/li>\n<li><strong>\u68c0\u7d22\u4e0d\u5168<\/strong>\uff1a\u9057\u6f0f\u4e86\u5173\u952e\u5185\u5bb9\uff0c\u6a21\u578b\u201c\u7b54\u975e\u6240\u95ee\u201d\uff1b<\/li>\n<li><strong>\u751f\u6210\u4e0d\u7a33<\/strong>\uff1a\u6a21\u578b\u80e1\u8bf4\u516b\u9053\uff0c\u6216\u8005\u903b\u8f91\u6df7\u4e71\u3002<\/li>\n<\/ul>\n<p>\u6240\u4ee5\u4f18\u5316RAG\uff0c\u5176\u5b9e\u5c31\u662f\u5728\u4e09\u4e2a\u5c42\u9762\u53d1\u529b\uff1a<\/p>\n<blockquote>\n<p>\u201c\u68c0\u7d22\u5668\u4f18\u5316\u201d \u2192 \u201c\u7d22\u5f15\u4e0e\u5206\u5757\u4f18\u5316\u201d \u2192 \u201c\u751f\u6210\u5668\u4f18\u5316\u201d\u3002<\/p>\n<\/blockquote>\n<p>\u8fd9\u4e09\u90e8\u5206\u4e32\u8d77\u6765\uff0c\u6784\u6210\u4e86RAG\u6027\u80fd\u7684\u5168\u666f\u95ed\u73af\u3002<\/p>\n<h2>\u4e8c\u3001\u68c0\u7d22\u5668\u4f18\u5316\uff08Retrieval Optimization\uff09\u2014\u2014\u6838\u5fc3\u4e2d\u7684\u6838\u5fc3<\/h2>\n<p>\u9762\u8bd5\u5b98\u6700\u60f3\u542c\u5230\u7684\uff0c\u5176\u5b9e\u662f\u4f60\u5bf9\u68c0\u7d22\u73af\u8282\u7684\u7406\u89e3\u3002\u6bd5\u7adf\uff0c\u5982\u679c\u201c\u627e\u4e0d\u5230\u597d\u6750\u6599\u201d\uff0c\u751f\u6210\u518d\u806a\u660e\u4e5f\u6ca1\u7528\u3002<\/p>\n<h3><strong>1. \u6df7\u5408\u68c0\u7d22\uff08Hybrid Search\uff09<\/strong><\/h3>\n<p>\u5728\u5b9e\u9645\u9879\u76ee\u4e2d\uff0c\u6211\u4eec\u901a\u5e38\u4e0d\u4f1a\u53ea\u7528\u5355\u4e00\u68c0\u7d22\u65b9\u5f0f\u3002<\/p>\n<ul>\n<li><strong>\u7a00\u758f\u68c0\u7d22\uff08Sparse Retrieval\uff09<\/strong>\uff1a\u6bd4\u5982 BM25\u3001TF-IDF\uff0c\u57fa\u4e8e\u5173\u952e\u8bcd\u5339\u914d\uff0c\u4f18\u70b9\u662f\u53ef\u89e3\u91ca\u3001\u5feb\u901f\uff0c\u4f46\u5bf9\u8bed\u4e49\u7406\u89e3\u5dee\u3002<\/li>\n<li><strong>\u5bc6\u96c6\u68c0\u7d22\uff08Dense Retrieval\uff09<\/strong>\uff1a\u6bd4\u5982\u4f7f\u7528\u5411\u91cf\u6a21\u578b\uff08\u5982BERT\u3001E5\u3001bge\uff09\uff0c\u57fa\u4e8e\u8bed\u4e49\u76f8\u4f3c\u5ea6\uff0c\u80fd\u7406\u89e3\u201c\u540c\u4e49\u8868\u8fbe\u201d\uff0c\u4f46\u6709\u65f6\u4f1a\u5f15\u5165\u201c\u8bed\u4e49\u566a\u97f3\u201d\u3002<\/li>\n<\/ul>\n<p>\u4e8e\u662f\uff0c\u6700\u5e38\u89c1\u7684\u4f18\u5316\u624b\u6bb5\u5c31\u662f\u2014\u2014 <strong>\u6df7\u5408\u68c0\u7d22\uff08Hybrid Search\uff09<\/strong>\uff1a\u5c06\u7a00\u758f\u4e0e\u5bc6\u96c6\u7ed3\u679c\u878d\u5408\uff0c\u901a\u8fc7\u52a0\u6743\u6216\u91cd\u6392\u5e8f\u53d6\u957f\u8865\u77ed\u3002<\/p>\n<p>\u4e3e\u4e2a\u4f8b\u5b50\uff1a\u5047\u8bbe\u7528\u6237\u95ee\u300cRAG\u600e\u4e48\u4f18\u5316\u68c0\u7d22\u300d\uff0cBM25\u80fd\u547d\u4e2d\u5e26\u201c\u4f18\u5316\u201d\u5b57\u6837\u7684\u6587\u672c\uff0c\u800cDense\u80fd\u627e\u5230\u8bed\u4e49\u63a5\u8fd1\u201cimprove retrieval quality\u201d\u7684\u6587\u6863\u3002\u878d\u5408\u540e\u6548\u679c\u663e\u8457\u63d0\u5347\u3002<\/p>\n<h3><strong>2. \u4e24\u9636\u6bb5\u68c0\u7d22\uff08Recall + Rerank\uff09<\/strong><\/h3>\n<p>\u8fd9\u662f\u5f88\u591a\u6210\u719f\u65b9\u6848\uff08\u5982Cohere RAG\u3001LangChain RAG Fusion\uff09\u7684\u6807\u914d\u3002<\/p>\n<ul>\n<li><strong>\u9636\u6bb5\u4e00\uff1a\u53ec\u56de\uff08Recall\uff09<\/strong>\u7528\u8f7b\u91cf\u6a21\u578b\uff08\u5982\u5411\u91cf\u68c0\u7d22\uff09\u5feb\u901f\u7b5b\u51fatop-N\u5019\u9009\u6587\u6863\u3002\u91cd\u70b9\u662f<strong>\u53ec\u56de\u7387\u8981\u9ad8<\/strong>\uff0c\u5b81\u53ef\u591a\uff0c\u4e0d\u8981\u6f0f\u3002<\/li>\n<li><strong>\u9636\u6bb5\u4e8c\uff1a\u91cd\u6392\uff08Rerank\uff09<\/strong>\u7528\u66f4\u5f3a\u7684\u6a21\u578b\uff08\u5982Cross-Encoder\u3001bge-reranker\uff09\u5bf9\u53ec\u56de\u7ed3\u679c\u91cd\u65b0\u6253\u5206\u3002\u91cd\u70b9\u662f<strong>\u7cbe\u786e\u7387\u8981\u9ad8<\/strong>\uff0c\u628a\u566a\u97f3\u5e72\u6389\u3002<\/li>\n<\/ul>\n<p>\u8fd9\u5957\u201c\u5148\u5feb\u540e\u51c6\u201d\u7684\u8bbe\u8ba1\u601d\u8def\uff0c\u672c\u8d28\u4e0a\u662f\u641c\u7d22\u5f15\u64ce\u91cc\u7ecf\u5178\u7684\u300cRecall + Precision\u300d\u7b56\u7565\u5728RAG\u4e2d\u7684\u590d\u7528\u3002<\/p>\n<h3><strong>3. \u67e5\u8be2\u6539\u5199\/\u6269\u5c55\uff08Query Rewriting &amp; Expansion\uff09<\/strong><\/h3>\n<p>LLM\u7684\u52a0\u5165\u8ba9\u6211\u4eec\u53ef\u4ee5\u505a\u5f97\u66f4\u806a\u660e\u4e00\u70b9\u3002<\/p>\n<p>\u5f88\u591a\u65f6\u5019\uff0c\u7528\u6237\u7684\u95ee\u9898\u592a\u77ed\u6216\u592a\u6a21\u7cca\uff0c\u6bd4\u5982\uff1a<\/p>\n<blockquote>\n<p>\u201c\u5b83\u80fd\u8dd1\u672c\u5730\u6a21\u578b\u5417\uff1f\u201d<\/p>\n<\/blockquote>\n<p>\u5982\u679c\u4e0d\u7ed3\u5408\u4e0a\u4e0b\u6587\uff0c\u68c0\u7d22\u5668\u6839\u672c\u4e0d\u77e5\u9053\u201c\u5b83\u201d\u662f\u8c01\u3002<\/p>\n<p>\u4f18\u5316\u624b\u6bb5\u662f\u2014\u2014<strong>\u4f7f\u7528LLM\u5bf9\u67e5\u8be2\u8fdb\u884c\u6539\u5199<\/strong>\uff08Query Rewriting\uff09\uff0c\u6216\u8005\u5728\u591a\u8f6e\u5bf9\u8bdd\u573a\u666f\u4e0b<strong>\u81ea\u52a8\u8865\u5168\u4e0a\u4e0b\u6587<\/strong>\u3002<\/p>\n<p>\u8fdb\u4e00\u6b65\uff0c\u53ef\u4ee5\u7528<strong>Query Expansion<\/strong>\u7684\u65b9\u5f0f\uff0c\u8ba9\u6a21\u578b\u751f\u6210\u82e5\u5e72\u8bed\u4e49\u76f8\u8fd1\u7684\u5b50\u95ee\u9898\uff0c\u4ece\u591a\u4e2a\u89d2\u5ea6\u53bb\u68c0\u7d22\uff0c\u63d0\u5347\u8986\u76d6\u5ea6\u3002<\/p>\n<h2>\u4e09\u3001\u7d22\u5f15\u4e0e\u5206\u5757\u4f18\u5316\uff08Indexing &amp; Chunking\uff09<\/h2>\n<p>RAG\u7684\u7b2c\u4e8c\u4e2a\u5173\u952e\u73af\u8282\u662f\u201c\u77e5\u8bc6\u7ec4\u7ec7\u201d\uff0c\u4e5f\u5c31\u662f\u4f60\u5230\u5e95\u600e\u4e48\u628a\u6587\u6863\u5207\u5206\u548c\u5efa\u7d22\u5f15\u3002<\/p>\n<p>\u5927\u591a\u6570\u4eba\u53ea\u4f1a\u8bf4\u4e00\u53e5\u201c\u628a\u6587\u6863\u5206\u5757\u201d\uff0c\u4f46\u5176\u5b9e\u91cc\u9762\u7684\u5b66\u95ee\u975e\u5e38\u5927\u3002<\/p>\n<h3><strong>1. \u7cbe\u7ec6\u5316\u5206\u5757\uff08Chunking Strategy\uff09<\/strong><\/h3>\n<p>\u9ed8\u8ba4\u7684\u201c\u6bcf500\u5b57\u5207\u4e00\u5757\u201d\u770b\u4f3c\u7b80\u5355\uff0c\u5b9e\u5219\u4f4e\u6548\u3002\u5e38\u89c1\u95ee\u9898\uff1a<\/p>\n<ul>\n<li>\u5207\u5728\u53e5\u5b50\u4e2d\u95f4\uff0c\u8bed\u4e49\u65ad\u88c2\uff1b<\/li>\n<li>\u8fc7\u5927\u5bfc\u81f4\u68c0\u7d22\u4e0d\u51c6\uff1b<\/li>\n<li>\u8fc7\u5c0f\u5bfc\u81f4\u4e0a\u4e0b\u6587\u7f3a\u5931\u3002<\/li>\n<\/ul>\n<p><strong>\u66f4\u4f18\u7b56\u7565\uff1a<\/strong><\/p>\n<ul>\n<li>\u7ed3\u5408<strong>\u8bed\u4e49\u8fb9\u754c<\/strong>\u6216<strong>\u53e5\u5b50\u5206\u9694\u7b26<\/strong>\uff08\u5982\u53e5\u53f7\u3001\u6362\u884c\u7b26\uff09\uff1b<\/li>\n<li>\u7ed3\u5408<strong>\u6807\u9898\/\u6bb5\u843d\u5c42\u6b21<\/strong>\u505a\u5c42\u7ea7\u5207\u5206\uff1b<\/li>\n<li>\u5728\u5b9e\u9645\u5582LLM\u65f6\uff0c\u53ef\u4ee5\u91c7\u7528\u201c\u5c0f\u5757\u68c0\u7d22\uff0c\u5927\u5757\u751f\u6210\u201d\u7684\u7b56\u7565\uff1a \u7528\u5c0f\u5757\u4fdd\u8bc1\u68c0\u7d22\u51c6\u786e\uff0c\u7528\u5927\u5757\u62fc\u63a5\u4fdd\u8bc1\u4e0a\u4e0b\u6587\u5b8c\u6574\u3002<\/li>\n<\/ul>\n<h3><strong>2. \u5143\u6570\u636e\u4e0e\u56fe\u7ed3\u6784\uff08Metadata &amp; GraphRAG\uff09<\/strong><\/h3>\n<p>\u9664\u4e86\u5206\u5757\uff0c\u6709\u4e24\u4e2a\u9ad8\u7ea7\u4f18\u5316\u65b9\u5411\uff1a<\/p>\n<ul>\n<li><strong>\u5143\u6570\u636e\u7d22\u5f15<\/strong>\u7ed9\u6bcf\u4e2a\u6587\u6863\u52a0\u4e0a\u6765\u6e90\u3001\u65f6\u95f4\u3001\u7c7b\u522b\u7b49\u6807\u7b7e\uff0c\u4fbf\u4e8e\u68c0\u7d22\u5668\u8fc7\u6ee4\u3002\u4f8b\u5982\uff1a\u201c\u53ea\u53d6\u6700\u8fd130\u5929\u7684\u65b0\u95fb\u201d\u3002<\/li>\n<li><strong>\u56fe\u7ed3\u6784\u68c0\u7d22\uff08GraphRAG\uff09<\/strong>\u5fae\u8f6f\u8fd1\u5e74\u63d0\u51fa\u7684\u65b0\u65b9\u5411\uff0c\u628a\u77e5\u8bc6\u5e93\u6784\u9020\u6210\u56fe\uff08Graph\uff09\uff0c\u8282\u70b9\u662f\u5b9e\u4f53\u3001\u8fb9\u662f\u5173\u7cfb\u3002 \u68c0\u7d22\u65f6\u53ef\u4ee5\u6cbf\u7740\u8bed\u4e49\u8def\u5f84\u8d70\uff0c\u627e\u5230\u66f4\u6709\u903b\u8f91\u8054\u7cfb\u7684\u5185\u5bb9\u3002<\/li>\n<\/ul>\n<p>GraphRAG\u7684\u4f18\u52bf\u5728\u4e8e\uff0c\u5b83\u80fd\u8ba9\u201c\u77e5\u8bc6\u68c0\u7d22\u201d\u4ece\u5b64\u7acb\u7247\u6bb5\u53d8\u6210\u201c\u5173\u7cfb\u7f51\u7edc\u201d\uff0c\u5c24\u5176\u9002\u5408\u590d\u6742\u77e5\u8bc6\u95ee\u7b54\u6216\u4f01\u4e1a\u77e5\u8bc6\u5e93\u3002<\/p>\n<h2>\u56db\u3001\u751f\u6210\u5668\u4f18\u5316\uff08Generator Optimization\uff09<\/h2>\n<p>\u68c0\u7d22\u53ea\u662f\u4e0a\u534a\u573a\uff0c\u751f\u6210\u624d\u662f\u51b3\u5b9a\u201c\u7b54\u6848\u597d\u4e0d\u597d\u770b\u201d\u7684\u5173\u952e\u3002<\/p>\n<p>\u8fd9\u91cc\u7684\u4f18\u5316\u91cd\u70b9\u6709\u4e24\u4e2a\u65b9\u5411\uff1a<strong>Prompt\u8bbe\u8ba1<\/strong>\u548c<strong>\u8f93\u51fa\u540e\u5904\u7406<\/strong>\u3002<\/p>\n<h3><strong>1. \u4e0a\u4e0b\u6587\u6784\u5efa\uff08Prompt Engineering\uff09<\/strong><\/h3>\n<p>\u5f88\u591a\u4eba\u5ffd\u7565\u7684\u4e00\u70b9\u662f\uff0c<strong>RAG\u7684Prompt\u8d28\u91cf\uff0c\u76f4\u63a5\u51b3\u5b9a\u8f93\u51fa\u8d28\u91cf<\/strong>\u3002<\/p>\n<p>\u597d\u7684Prompt\u5e94\u8be5\u5305\u62ec\uff1a<\/p>\n<ol>\n<li><strong>\u660e\u786e\u4efb\u52a1\u6307\u4ee4<\/strong>\uff1a\u544a\u8bc9\u6a21\u578b\u201c\u5fc5\u987b\u57fa\u4e8e\u68c0\u7d22\u5185\u5bb9\u4f5c\u7b54\u201d\uff1b<\/li>\n<li><strong>\u63d2\u5165\u68c0\u7d22\u7247\u6bb5\u65f6\u8981\u6709\u683c\u5f0f<\/strong>\uff1a\u6bd4\u5982\u6bcf\u6bb5\u524d\u52a0\u4e0a<code>[Doc1]<\/code>\u3001<code>[Doc2]<\/code>\uff1b<\/li>\n<li><strong>\u5185\u5bb9\u9009\u62e9\u7b56\u7565<\/strong>\uff1atop-k\u4e0d\u4e00\u5b9a\u8d8a\u591a\u8d8a\u597d\uff0c\u5e94\u6839\u636etoken\u9884\u7b97\u505a\u52a8\u6001\u9009\u62e9\uff1b<\/li>\n<li><strong>\u4e0a\u4e0b\u6587\u878d\u5408\u65b9\u5f0f<\/strong>\uff1a\u53ef\u91c7\u7528CoT\u7ed3\u6784\uff08\u5148\u603b\u7ed3\u518d\u56de\u7b54\uff09\uff0c\u63d0\u5347\u63a8\u7406\u8fde\u8d2f\u6027\u3002<\/li>\n<\/ol>\n<p>\u4e00\u4e9b\u5b9e\u7528\u6280\u5de7\uff1a<\/p>\n<ul>\n<li>\n<p>\u4f7f\u7528\u6a21\u677f\u63d0\u793a\u8bcd\uff1a<\/p>\n<blockquote>\n<p>\u201c\u8bf7\u4e25\u683c\u6839\u636e\u4ee5\u4e0b\u8d44\u6599\u56de\u7b54\u95ee\u9898\uff0c\u82e5\u8d44\u6599\u4e2d\u65e0\u7b54\u6848\uff0c\u8bf7\u56de\u590d\u2018\u672a\u627e\u5230\u2019\u3002\u201d<\/p>\n<\/blockquote>\n<\/li>\n<li>\n<p>\u63a7\u5236\u8f93\u5165\u957f\u5ea6\uff1a \u8ba9\u6a21\u578b\u805a\u7126\u4e8e\u6838\u5fc3\u5185\u5bb9\uff0c\u800c\u975e\u88ab\u5197\u4f59\u6587\u672c\u5e72\u6270\u3002<\/p>\n<\/li>\n<\/ul>\n<h3><strong>2. \u540e\u5904\u7406\u4e0e\u8f93\u51fa\u8fc7\u6ee4\uff08Post-processing &amp; Verification\uff09<\/strong><\/h3>\n<p>RAG\u7684\u6700\u5927\u98ce\u9669\u4e4b\u4e00\uff0c\u662f\u6a21\u578b\u201c\u7f16\u6545\u4e8b\u201d\u2014\u2014\u4e5f\u5c31\u662f<strong>\u5e7b\u89c9\uff08Hallucination\uff09<\/strong>\u3002<\/p>\n<p>\u4f18\u5316\u624b\u6bb5\u5305\u62ec\uff1a<\/p>\n<ul>\n<li><strong>\u4e8b\u5b9e\u4e00\u81f4\u6027\u6821\u9a8c\uff08Fact Checking\uff09<\/strong>\uff1a \u7528embedding\u8ba1\u7b97\u6a21\u578b\u56de\u7b54\u4e0e\u68c0\u7d22\u7247\u6bb5\u7684\u76f8\u4f3c\u5ea6\uff0c\u82e5\u504f\u5dee\u8fc7\u5927\u5219\u5224\u5b9a\u4e3a\u5e7b\u89c9\u3002<\/li>\n<li><strong>\u591a\u6a21\u578b\u6821\u9a8c\uff08Self-consistency\uff09<\/strong>\uff1a \u8ba9LLM\u81ea\u5df1\u68c0\u67e5\u56de\u7b54\u662f\u5426\u7b26\u5408\u5f15\u7528\u6750\u6599\u3002<\/li>\n<li><strong>\u8f93\u51fa\u8fc7\u6ee4<\/strong>\uff1a \u5728\u4f01\u4e1a\u5e94\u7528\u4e2d\uff08\u5982\u533b\u7597\u3001\u91d1\u878d\uff09\uff0c\u53ef\u4ee5\u8bbe\u7f6e\u5173\u952e\u8bcd\u9ed1\u540d\u5355\u6216\u5408\u89c4\u6027\u89c4\u5219\uff0c\u5bf9\u8f93\u51fa\u505a\u8fc7\u6ee4\u6216\u88c1\u526a\u3002<\/li>\n<\/ul>\n<h2>\u4e94\u3001\u7cfb\u7edf\u7ea7\u4f18\u5316\u4e0e\u5de5\u7a0b\u843d\u5730<\/h2>\n<p>\u9664\u4e86\u6280\u672f\u7ec6\u8282\uff0c\u80fd\u5426\u843d\u5730\u4e5f\u5f88\u91cd\u8981\u3002\u8fd9\u91cc\u6709\u51e0\u4e2a\u5de5\u7a0b\u89d2\u5ea6\u7684\u4f18\u5316\u601d\u8def\uff0c\u9762\u8bd5\u5b98\u5f88\u5403\u8fd9\u4e00\u5957\u3002<\/p>\n<h3><strong>1. \u5411\u91cf\u5e93\u53c2\u6570\u8c03\u4f18<\/strong><\/h3>\n<ul>\n<li>\u8c03\u6574\u76f8\u4f3c\u5ea6\u8ba1\u7b97\u65b9\u5f0f\uff08cosine \/ dot \/ L2\uff09\uff1b<\/li>\n<li>\u4f18\u5316Top-K\u53c2\u6570\uff1b<\/li>\n<li>\u5bf9\u9ad8\u7ef4embedding\u505aPCA\u964d\u7ef4\u3001\u91cf\u5316\uff08FAISS PQ\u3001IVF\u7b49\uff09\u4ee5\u63d0\u5347\u901f\u5ea6\uff1b<\/li>\n<li>\u4f7f\u7528\u7f13\u5b58\u673a\u5236\u907f\u514d\u91cd\u590d\u68c0\u7d22\u3002<\/li>\n<\/ul>\n<h3><strong>2. \u6570\u636e\u5c42\u9762\u7684\u4f18\u5316<\/strong><\/h3>\n<ul>\n<li>\u53bb\u91cd\u3001\u53bb\u566a\u3001\u6807\u51c6\u5316\uff1b<\/li>\n<li>\u9488\u5bf9\u5e38\u95ee\u95ee\u9898\u5efa\u7acbFAQ\u4f18\u5148\u68c0\u7d22\uff1b<\/li>\n<li>\u52a8\u6001\u66f4\u65b0\u77e5\u8bc6\u5e93\uff0c\u907f\u514d\u65f6\u6548\u6027\u95ee\u9898\u3002<\/li>\n<\/ul>\n<h3><strong>3. \u8bc4\u6d4b\u4e0e\u6307\u6807<\/strong><\/h3>\n<p>\u53ef\u4ee5\u63d0\u5230\u4e00\u4e9bRAG\u5e38\u89c1\u8bc4\u4f30\u6307\u6807\uff1a<\/p>\n<ul>\n<li><strong>\u68c0\u7d22\u9636\u6bb5<\/strong>\uff1aRecall@K\u3001MRR\uff1b<\/li>\n<li><strong>\u751f\u6210\u9636\u6bb5<\/strong>\uff1aROUGE\u3001BLEU\u3001Faithfulness\uff1b<\/li>\n<li><strong>\u7aef\u5230\u7aef\u6548\u679c<\/strong>\uff1aHuman Eval\u3001\u7528\u6237\u6ee1\u610f\u5ea6\u3002<\/li>\n<\/ul>\n<p>\u80fd\u8bf4\u51fa\u8fd9\u4e9b\u8bc4\u6d4b\u6307\u6807\uff0c\u4f1a\u8ba9\u4f60\u7684\u7b54\u6848\u663e\u5f97\u201c\u6709\u5b9e\u64cd\u3001\u6709\u65b9\u6cd5\u8bba\u201d\u3002<\/p>\n<h2>\u516d\u3001\u9762\u8bd5\u5b98\u52a0\u5206\u9879\uff1a\u878d\u5408\u521b\u65b0\u4e0e\u524d\u6cbf\u65b9\u5411<\/h2>\n<p>\u5982\u679c\u4f60\u80fd\u5728\u6700\u540e\u518d\u8865\u4e00\u53e5\u524d\u6cbf\u63a2\u7d22\uff0c\u90a3\u5c31\u662f\u201c\u6ee1\u5206\u56de\u7b54\u201d\u3002<\/p>\n<ul>\n<li><strong>Multi-hop RAG<\/strong>\uff1a\u8ba9\u6a21\u578b\u652f\u6301\u591a\u8df3\u63a8\u7406\uff0c\u9010\u6b65\u68c0\u7d22\u548c\u56de\u7b54\uff1b<\/li>\n<li><strong>Active Retrieval<\/strong>\uff1a\u8ba9\u6a21\u578b\u80fd\u5728\u751f\u6210\u4e2d\u4e3b\u52a8\u89e6\u53d1\u8ffd\u52a0\u68c0\u7d22\uff1b<\/li>\n<li><strong>Adaptive Chunking<\/strong>\uff1a\u6839\u636e\u95ee\u9898\u52a8\u6001\u51b3\u5b9a\u5207\u5206\u7c92\u5ea6\uff1b<\/li>\n<li><strong>LLM as Retriever<\/strong>\uff1a\u8ba9\u6a21\u578b\u76f4\u63a5\u751f\u6210embedding\u6216\u53ec\u56de\u5019\u9009\uff1b<\/li>\n<li><strong>\u77e5\u8bc6\u878d\u5408RAG\uff08Knowledge-Augmented RAG\uff09<\/strong>\uff1a\u7ed3\u5408\u5916\u90e8\u77e5\u8bc6\u56fe\u8c31\u3001SQL\u68c0\u7d22\u7b49\u591a\u6e90\u6570\u636e\u3002<\/li>\n<\/ul>\n<p>\u8fd9\u4e9b\u65b9\u5411\u5982\u679c\u80fd\u4e3e\u51fa\u4e00\u4e24\u4e2a\u5b9e\u9645\u6848\u4f8b\uff0c\u6bd4\u5982\uff1a\u201c\u6211\u4eec\u9879\u76ee\u4e2d\u7528Hybrid RAG\u7ed3\u5408GraphRAG\uff0c\u663e\u8457\u63d0\u5347\u95ee\u7b54\u51c6\u786e\u7387\u201d\uff0c\u90a3\u57fa\u672c\u53ef\u4ee5\u7a33\u7a33\u62ff\u4e0b\u9762\u8bd5\u5b98\u7684\u8ba4\u53ef\u3002<\/p>\n<h2>\u4e03\u3001\u603b\u7ed3\uff1a\u600e\u4e48\u7cfb\u7edf\u56de\u7b54\u8fd9\u9053\u9898\uff1f<\/h2>\n<p>\u5982\u679c\u8981\u5728\u9762\u8bd5\u4e2d\u6d53\u7f29\u6210\u4e00\u5206\u949f\u56de\u7b54\uff0c\u53ef\u4ee5\u8fd9\u4e48\u8bf4\ud83d\udc47<\/p>\n<blockquote>\n<p>\u201cRAG\u7684\u4f18\u5316\u53ef\u4ee5\u4ece\u4e09\u4e2a\u5c42\u9762\u5c55\u5f00\uff1a<\/p>\n<ul>\n<li><strong>\u68c0\u7d22\u5668\u4f18\u5316<\/strong>\uff1a\u6df7\u5408\u68c0\u7d22\u3001\u4e24\u9636\u6bb5\u68c0\u7d22\u3001\u67e5\u8be2\u6539\u5199\uff1b<\/li>\n<li><strong>\u7d22\u5f15\u4f18\u5316<\/strong>\uff1a\u8bed\u4e49\u5206\u5757\u3001\u5143\u6570\u636e\u3001GraphRAG\uff1b<\/li>\n<li><strong>\u751f\u6210\u4f18\u5316<\/strong>\uff1aPrompt\u8bbe\u8ba1\u3001\u4e8b\u5b9e\u4e00\u81f4\u6027\u9a8c\u8bc1\u3001\u8f93\u51fa\u8fc7\u6ee4\u3002<\/li>\n<\/ul>\n<p>\u6211\u5728\u9879\u76ee\u4e2d\u4e3b\u8981\u901a\u8fc7Hybrid Search + Reranker\u7684\u65b9\u5f0f\u63d0\u5347\u4e86\u68c0\u7d22\u7cbe\u5ea6\uff0c\u540c\u65f6\u7ed3\u5408\u8bed\u4e49\u5206\u5757\u4e0ePrompt\u6a21\u677f\u663e\u8457\u964d\u4f4e\u4e86\u5e7b\u89c9\u7387\u3002\u201d<\/p>\n<\/blockquote>\n<p>\u8fd9\u79cd\u7b54\u6cd5\u65e2\u7cfb\u7edf\u3001\u53c8\u4f53\u73b0\u4e86\u5b9e\u8df5\u6df1\u5ea6\u3002<\/p>\n<h2>\u516b\u3001\u7ed3\u8bed<\/h2>\n<p>\u5728\u5927\u6a21\u578b\u9762\u8bd5\u4e2d\uff0cRAG\u662f\u6700\u5e38\u89c1\u7684\u5de5\u7a0b\u843d\u5730\u8bdd\u9898\u4e4b\u4e00\uff0c\u80fd\u7b54\u51fa\u201cRAG\u662f\u4ec0\u4e48\u201d\u662f\u57fa\u7840\uff0c\u80fd\u7b54\u51fa\u201cRAG\u600e\u4e48\u4f18\u5316\u201d\u624d\u662f\u771f\u6b63\u7684\u5b9e\u529b\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5982\u679c\u4f60\u80fd\u7b54\u51fa\u4e00\u5957\u7cfb\u7edf\u5316\u7684RAG\u4f18\u5316\u601d\u8def\uff0c\u90a3\u9762\u8bd5\u5b98\u4e00\u5b9a\u4f1a\u89c9\u5f97\uff1a\u8fd9\u4eba\u6709\u5b9e\u8df5\u3001\u6709\u601d\u8003\u3002 \u4e00\u3001RAG\u5230\u5e95\u5728\u4f18\u5316\u4ec0\u4e48\uff1f**unset****uns   \u2026 &#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"ngg_post_thumbnail":0},"categories":[287],"tags":[],"_links":{"self":[{"href":"\/index.php?rest_route=\/wp\/v2\/posts\/9454"}],"collection":[{"href":"\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=9454"}],"version-history":[{"count":1,"href":"\/index.php?rest_route=\/wp\/v2\/posts\/9454\/revisions"}],"predecessor-version":[{"id":9455,"href":"\/index.php?rest_route=\/wp\/v2\/posts\/9454\/revisions\/9455"}],"wp:attachment":[{"href":"\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=9454"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=9454"},{"taxonomy":"post_tag","embeddable":true,"href":"\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=9454"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}