Auto-sync: 2026-04-18 12:03

This commit is contained in:
2026-04-18 12:03:11 +08:00
parent 1a82750f1c
commit 7d361490b2
85 changed files with 2857 additions and 7 deletions

View File

@@ -0,0 +1,57 @@
---
title: "RAG从入门到精通系列1基础RAG"
type: source
tags: [RAG, LLM, 教程]
date: 2025-12-18
---
## Source File
- [[raw/AI/RAG从入门到精通系列1基础RAG.md]]
## Summary
- 核心主题:基础 RAG检索增强生成技术介绍
- 问题域LLM 如何使用外部数据(私有数据或最新数据)
- 方法/机制Indexing索引→ Retrieval检索→ Generation生成
- 结论/价值RAG 是连接 LLM 与外部数据源的通用方法,使 LLM 能基于外部知识生成回答
## Key Claims
- RAG 是一种将 LLM 与外部数据源连接的通用方法,允许 LLM 使用外部数据生成输出
- 基础 RAG 流程包含三个核心阶段:索引构建、文档检索、答案生成
- Embedding向量化将文本转为固定长度的数值向量捕获文本语义
- 文档需要切分成满足 Embedding Model Context Window 的 Split文档块
- Vector Store向量数据库存储 Embedding Vector 并实现相似度比较
- LangChain 和 LlamaIndex 框架简化了 RAG 管道的构建
## Key Quotes
> "RAGRetrieval Augmented Generation检索增强生成是一种将 LLM 与外部数据源(例如私有数据或最新数据)连接的通用方法。它允许 LLM 使用外部数据来生成其输出。"
## Key Concepts
- [[RAG]]:检索增强生成,连接 LLM 与外部数据源的技术
- [[LLM]]:大型语言模型,功能强大但不总是使用最新或相关数据
- [[向量嵌入]]:将文本转换为数值向量,捕获语义信息
- [[Token]]:模型处理文本的基本单位,中文约 1 token/汉字,英文约 1 token/3-4 字母
- [[Vector Store]]:向量数据库,存储 Embedding Vector 并实现相似度检索
- [[LangChain]]:简化 RAG 管道构建的框架
- [[Qdrant]]Rust 编写的开源向量数据库
## Key Entities
- [[LangChain]]:提供 160+ 文档加载器的 RAG 框架
- [[Qwen]]:文中使用的 LLM 示例
- [[BAAI]]:开源 Embedding Model 系列
- [[PyTorch研习社]]:文章来源公众号
## Connections
- [[RAG]] ← depends_on ← [[向量嵌入]]
- [[向量嵌入]] ← depends_on ← [[Token]]
- [[LangChain]] ← implements ← [[RAG]]
- [[Qdrant]] ← stores ← [[向量嵌入]]
- [[Qwen]] ← provides ← [[LLM]]
## Contradictions
- (暂无)
## 相关技术栈
- **LLM**: Qwen
- **Embedding Model**: BAAI 系列
- **Vector Store**: Qdrant
- **Framework**: LangChain