Agent · 模型只是其中一块AI Agent · The Model Is Only One Part
goal → model + state + tools + environment → updated progress
Agent 是围绕目标反复感知状态、选择动作、调用工具并更新进度的系统。它不是更长的聊天,而是模型与外部执行环境的组合。An AI Agent repeatedly senses state, chooses actions, calls tools, and updates progress toward a goal. It is not a longer chat; it combines a model with an execution environment.
01 · 会回答,等于会办事吗01 · Is answering the same as doing?
让聊天模型说“我查过库存了”,和系统真的查库、读回结果、更新任务,有什么不同?What separates a model saying “I checked inventory” from a system that actually queries, reads the result, and updates the task?
◎
02Agent 组件台:一次点亮一条真实消息流Agent Workbench: Light One Real Message Flow at a Time
四块组合four-part system
消息进度Message progress
0/6
等待目标waiting for goal
真实工具调用Real tool call
0
read_inventory
任务状态Task state
NEW
external state
03Agent 不是一个气泡,而是 4 块系统An Agent Is Four System Parts, Not One Bubble
职责分离separation of duties
MODEL
模型选择下一步Model chooses next step
根据目标与当前状态提出动作,但不直接冒充外部执行结果。Proposes an action from goal and state, but does not impersonate an external result.
STATE
状态记录进度State records progress
保存已知事实、当前步骤与待完成项,让任务不靠模型“似乎记得”。Stores known facts, current step, and remaining work instead of relying on what the model seems to remember.
TOOL
工具执行动作Tool executes action
按结构化请求读取信息或改变状态,必须受权限、参数与确认门控制。Reads or changes state through structured calls governed by permission, parameter, and confirmation gates.
ENVIRONMENT
环境交回事实Environment returns facts
库存、订单、文件等真实系统返回结果;它可能与模型预期不同。The real inventory, order, or file system returns results that may differ from the model’s expectation.
04最小机制:动作之后必须读回环境Minimal Mechanism: Read the Environment After Acting
statet+1 = update(result)
st+1 = update(st, resulttool)
只有工具真实结果进入 update,任务状态才从 NEW 变为 VERIFIED;模型说“完成”不触发状态更新。Only a real tool result moves task state from NEW to VERIFIED. A model merely saying “done” does not update state.
状态更新进度State updates progressVERIFIED · 可发货VERIFIED · can ship
05边界实验:只留下会说话的模型Boundary Test: Leave Only the Talking Model
主动制造失败Create a failure
跳过工具与环境,直接写“已发货”Skip tool and environment, then write “shipped”
模型能生成听起来完成的句子,但没有真实调用、结果或状态更新。这是一次回答,不是完成任务的 Agent。The model can generate a completion-sounding sentence, but no call, result, or state update exists. That is an answer, not an Agent completing work.
尚未执行。任务仍等待真实消息流。Not run yet. The task still awaits the real message flow.
✗ 回复很长,所以它是 Agent。A long reply makes it an Agent. → ✓ Agent 需要目标、状态、工具与环境反馈。An Agent needs goal, state, tools, and environmental feedback.
✗ 模型说“调用成功”就算工具结果。The model saying “call succeeded” counts as a tool result. → ✓ 真实返回必须由执行环境送回。The execution environment must return the actual result.
✗ 有模型和工具就足够,不必记状态。A model and tools are enough; state is optional. → ✓ 状态让进度、事实和未完成项可核验。State makes progress, facts, and remaining work verifiable.
06 · 一句话带走06 · One line to keep
Agent 是模型、状态、工具和环境围绕目标组成的行动系统;本页看清这四块,下一页再看它们怎样重复成循环并可靠停下。An AI Agent combines model, state, tools, and environment around a goal. This lesson identifies the parts; the next shows how they repeat as a loop and stop reliably.