大家好,我是小昭
今天要分享的内容是:理解 Token、上下文窗口、温度、幻觉与 RAG 这五个概念,就能更清楚地使用和判断 AI。
Master the core ideas behind AI without getting lost.
掌握人工智能背后的核心概念,而不迷失在术语里。

正文内容
Let me be frank. Most people who talk about AI either sound like they're giving textual definitions, or they're completely clueless when someone mentions terms like LLMs or neural networks. You don't have to be either of them. I believe that there are these five terms, five concepts that, if you actually understand them—not just memorise—you'll be miles ahead of almost everyone else in the room. Whether you're in tech, business, education, or just someone curious about where the world is heading. Let's start.
坦白说,大多数谈论 AI 的人,要么像在背术语定义;要么一听到大语言模型、神经网络这些词就完全摸不着头脑。你不必成为其中任何一种人。我相信,只要真正理解下面这五个术语、五个概念——而不只是死记硬背——无论你身处科技、商业、教育领域,还是只是好奇世界将走向哪里,你都会远远领先身边的大多数人。开始吧。
1. Tokens
一、Token:词元
The very first thing that you must register in your brain is that AI models don't read words. They don't even read letters. They read tokens. So what's a token? Imagine you're reading a book, but instead of reading all the words, you're reading chunks of words. Sometimes a chunk is a complete word like “cat.” Sometimes it's part of a word like “un” or “tion.” Sometimes it's punctuation. That piece of text is a token. For example, the sentence “I love pizza” can be broken into three tokens: “I”, “ love”, “ pizza”.
你首先必须记住:AI 模型不读“单词”,甚至不读“字母”,它们读的是 Token,也就是词元。什么是词元?想象你在读一本书,但不是逐个读完整单词,而是读取一块块文字。有时一块就是完整单词,例如“cat”;有时只是词的一部分,例如“un”或“tion”;有时则是标点符号。这一小块文本,就是一个 Token。例如,“I love pizza”可以被拆成三个词元:“I”“ love”“ pizza”。
Why does this matter to you? Because every AI product you use—ChatGPT, Claude, Gemini—is counting tokens behind the scenes. The more tokens you send, the more the model has to process. The more it generates, the more expensive it becomes to run. When people talk about a model's context window, they're talking about how many tokens it can hold in memory at once. Some older models could handle 4,000 tokens. Newer ones can handle over a million.
这和你有什么关系?因为你使用的每一种 AI 产品——ChatGPT、Claude、Gemini——都在后台计算 Token。你发送的词元越多,模型需要处理的内容越多;它回复时生成的词元越多,运行成本也越高。人们谈论模型的“上下文窗口”时,指的就是它一次能在记忆中容纳多少 Token。有些较老模型只能处理4000个词元,新模型则能处理超过100万个。
This is why AI sometimes forgets earlier parts of a long conversation. Once the conversation fills up the context window, the oldest tokens are dropped—like when your RAM fills up and your computer starts lagging. Tokens are the atoms of AI language. Once you understand that, you start to see why some prompts work better than others, why AI forgets in long chats, and why API pricing is measured in tokens per thousand.
这也解释了为什么 AI 有时会忘记长对话的前半部分。一旦对话填满上下文窗口,最早的 Token 就会被丢弃,就像电脑内存占满后开始变卡一样。Token 是 AI 语言的原子。理解它之后,你就能明白为什么有些提示词更有效、为什么 AI 在长对话中会遗忘,以及为什么 API 的价格常按每千个 Token 计算。
2. Context window
二、Context window:上下文窗口
Imagine you're talking to someone, but they have a very specific kind of memory. They can only remember the last X minutes of a conversation. Everything before that? Gone. Forgotten. That's a context window. It is the total amount of text, measured in tokens, that an AI model can see and consider at one time. This includes your instructions, the conversation history, documents you share, and the model's own replies.
想象你在和一个人交谈,但对方有一种非常特殊的记忆:他只能记住谈话最近的 X 分钟,之前的一切都会消失。这就是上下文窗口。它指 AI 模型一次能看见并纳入考虑的全部文本量,以 Token 为单位计算;其中包括你的指令、聊天记录、你分享的文档,以及模型自己此前的回复。
Think of it like a whiteboard. The context window is the size of the whiteboard. You can write whatever you want on it. But once it is full, you have to erase something old to write something new. A small context window, such as 4K tokens, means AI can only work with a few pages of text at once. A large one, such as 200K tokens, means you can paste an entire book and ask questions about it.
把它想成一块白板。上下文窗口就是白板的大小,你可以在上面写任何内容;但一旦写满,要写新的东西,就得擦掉旧的。较小的窗口,例如4000个 Token,意味着 AI 一次只能处理几页文本;较大的窗口,例如20万个 Token,则意味着你甚至可以粘贴一本书再向它提问。
This is why people got excited when Claude announced a 200,000-token context window, or when Gemini pushed towards one million. It fundamentally changes what you can do with the model. The practical lesson is simple: when summarizing a long document or analyzing data, remember that AI may be forgetting earlier parts of the conversation. That is not necessarily a bug. The whiteboard may simply be running out of space.
这就是为什么 Claude 宣布20万 Token 上下文窗口、Gemini 向100万 Token 推进时,人们会如此兴奋。这会从根本上改变你能让模型做什么。实际使用中的提醒很简单:当你总结长文档或分析数据时,要始终意识到 AI 可能正在遗忘对话前面的内容。这不一定是故障,可能只是白板空间用完了。
3. Temperature
三、Temperature:温度
This one is my personal favourite to explain, because once people hear it, they never forget it. When you ask an AI to write something, there is a setting known as temperature that decides how random or predictable the output will be. Low temperature, closer to zero, means the AI plays it safe. It picks the most likely word every time. The output is consistent, accurate, and a little boring—like someone who always sends the same email template.
这是我最喜欢解释的概念,因为人们一旦听懂,就很难忘记。让 AI 写内容时,有一个叫“温度”的设置,决定输出会有多随机或多可预测。低温度,接近0,意味着 AI 会选择保守路线:每次都选择最可能出现的词。结果会稳定、准确,但也会有点无聊,像一个总是发送同一封邮件模板的人。
High temperature, closer to one or beyond, means the AI takes risks. It chooses surprising words, unusual turns, and interesting ideas. Sometimes brilliant, but not always. Ask an AI to complete “The cat sat on the…” At low temperature it will likely say “mat” or “floor”: predictable and safe. At high temperature it may say “philosophical dilemma” or “crumbling empire of Tuesday.” Creative? Yes. Useful for a legal brief? Absolutely not.
高温度,接近1或更高,意味着 AI 会冒险:选择意外的词、不同寻常的转折和有趣的想法。有时很惊艳,但并不总是如此。让 AI 补全“The cat sat on the…”,低温度下它大概率会说“mat”或“floor”,可预测也安全;高温度下,它可能会说“philosophical dilemma”或“crumbling empire of Tuesday”。有创意吗?有。适合用于法律文书吗?完全不适合。
The unwritten rule is this: for factual tasks—summarizing, coding, extracting information—you want low temperature. You need precision, not creativity. For creative tasks—fiction, brainstorming, marketing copy—increase the temperature. Most consumer apps do not let you touch this dial directly; they use a middle ground. But in an AI API or developer tool, you will see it, and now you know what to do with it.
其中有一条不成文规则:处理事实任务,例如总结、编程、提取信息时,你需要低温度,需要精确而非创意;创作小说、头脑风暴、写营销文案时,则可以提高温度,你需要意外性。多数面向消费者的应用不会让你直接调整这个旋钮,而是设在中间值;但当你使用 AI API 或开发工具时会看到它,现在你已经知道该如何选择。
4. Hallucination
四、Hallucination:幻觉
This is the term everyone has heard, but not everyone understands why it happens—and that is the important part. Hallucination is when an AI gives wrong answers with absolute confidence. No hesitation: a false answer stated as fact. Ask it about a book and it may provide a title, author, year, and plot summary that are all invented. The book does not exist, but AI presents it as if it were reading Wikipedia.
这是人人都听过、却不一定理解其成因的术语,而成因恰恰最重要。AI 幻觉是指 AI 用绝对自信的语气给出错误答案:毫不犹豫地把虚假内容当作事实陈述。比如你问它一本书,它可能给出书名、作者、年份和情节概要,而这些全是编造的。那本书根本不存在,但 AI 的说法却像在读取维基百科。
AI language models are not databases. They do not look up facts. They predict the next most likely token from patterns learned during training. They are autocomplete at a massive scale. So when AI does not know something, it may not say “I don't know”; it generates an answer that sounds correct, because that is literally what it was trained to do.
AI 语言模型不是数据库,它们不会主动查找事实。它们是根据训练中学到的模式,预测下一个最可能出现的 Token;本质上,它们是大规模自动补全工具。因此,当 AI 不知道某件事时,它未必会说“我不知道”,而可能生成一个听起来正确的答案,因为它被训练的任务正是这样。
The danger is not simply that AI makes mistakes. Every tool makes mistakes. The danger is that AI makes mistakes with the same confidence it uses when it is right. Never blindly trust AI for facts, statistics, medical advice, legal information, or anything where being wrong has real consequences. Use it as a starting point, then verify. People who understand hallucination do not stop using AI. They just use it smarter.
危险不只是 AI 会犯错,所有工具都会犯错;真正危险的是,它犯错时也会和答对时一样自信。不要盲信 AI 给出的事实、统计数字、医疗建议、法律信息,或任何出错会带来真实后果的内容。把它当作起点,然后自行核验。理解幻觉的人不会停止使用 AI,他们只是会更聪明地使用它。
5. RAG
五、RAG:检索增强生成
RAG is the most misunderstood of the five. RAG stands for Retrieval-Augmented Generation, and it is actually a simple idea. A regular AI model was trained on data up to a certain date. It knows nothing about your company’s internal documents, events from last week, or the PDF you just uploaded. So how do products such as “Chat with your PDF” work? This is RAG.
RAG 是五个概念中最容易被误解的一个。RAG 是 Retrieval-Augmented Generation 的缩写,中文通常译为“检索增强生成”,其实思路非常简单。普通 AI 模型只学习到某个截止日期之前的数据,它不知道你公司的内部文档、不知道上周发生的事,也不知道你刚上传的 PDF。那“和 PDF 聊天”这类产品是如何工作的?答案就是 RAG。
When you upload a document, the system does not feed the whole thing into the AI’s brain. It breaks the document into chunks and stores them in a vector database that understands meaning, not just keywords. When you ask a question, the system searches this database for the most relevant chunks, retrieves them, and feeds them to AI alongside your question: “Here is relevant context. Now answer using it.” Retrieve relevant material, feed it to AI, generate an answer: RAG.
当你上传文档时,系统不会把整份文档都塞进 AI 的“大脑”。它会把文档切成许多片段,储存在一种理解语义而不只匹配关键词的数据库中——向量数据库。你提问时,系统先在这个数据库里找到最相关的片段,把它们取回来,再连同问题一起交给 AI:“这里有相关上下文,请基于它回答。”检索相关内容、交给 AI、生成答案,这就是 RAG。
RAG is the backbone of almost every useful AI product built in the past two years: customer-support bots that know company policies, assistants that answer questions from legal documents, and tools that summarize research papers. When an AI knows your documents, it has not necessarily learned anything new. It is performing a smart search and changing the context given to the same language model.
过去两年里,几乎所有真正有用的 AI 产品背后都有 RAG:了解公司政策的客服机器人、能回答法律文档问题的助手、总结研究论文的工具。当一个 AI 看似“知道”你的文档时,它不一定真的学到了新知识;它更可能是在进行一次聪明的搜索,并为同一个语言模型换上新的上下文。
So why does this matter? AI is not going away. The gap between people who vaguely use AI and people who understand even its basic workings will matter more and more. You do not need to be an engineer or write code. But understanding tokens helps you write better prompts; understanding context windows explains why an assistant gets confused; understanding temperature helps you choose settings; understanding hallucination keeps you from blindly trusting answers; and understanding RAG tells you what is really happening when a product claims to know your data. Five terms, real understanding—and that puts you ahead of most people using AI without knowing what is happening inside.
为什么这些重要?AI 不会消失。未来几年,模糊地使用 AI 的人和真正理解其基本运作方式的人之间,差距会越来越重要。你不需要成为工程师,也不需要会写代码。但理解 Token 能帮你写出更好的提示词;理解上下文窗口能解释助手为什么突然变糊涂;理解温度能帮你为不同任务选择设置;理解幻觉能避免你盲信答案;理解 RAG 则能让你知道产品声称“了解你的数据”时,背后究竟发生了什么。五个术语,真正的理解——这就足以让你领先大多数只会模糊使用 AI、却不理解内部机制的人。
夜雨聆风