提问 HN:如何开始使用 RAG?
1 分•作者: mettamage•5 个月前
目前我的工作是把代码与大语言模型的 API 连接起来。 实际上,只需要一些 Python 和常识。在我的脚本中,大语言模型可以访问某些 Python 脚本,这些脚本会调用特定的 API 来获取更多数据,然后我将这些数据放回提示中,以便模型可以基于这些数据进行推理(这些数据对于大语言模型来说足够简单)。
我注意到,现在出现了一些关于“知识库”的项目。在我看来,这听起来像是他们需要 RAG(检索增强生成),因为数据量会大得多,你不能再简单地把所有数据都放到提示/上下文中了。但我对 RAG 了解不多,只知道一些基本原理。
那么,我该如何开始学习如何使用 RAG 来扩展这样的系统呢?
查看原文
At my job I'm currently hooking up code to the APIs of LLMs. Just some Python and some common sense, really. In my scripts, the LLMs have access to certain Python scripts that call certain APIs to get more data and I put that back into the prompt so it can reason on it (the data is simple enough for an LLM to be able to do that).<p>And I've noticed there are some projects coming up where people want a "knowledge base". That to me sounds like they need RAG as that's a lot more data and you can't just put that into the prompt/context anymore. But I don't really know much about it other than some basic principles.<p>So how do I get started on learning how to extend such a system with RAG?