AI English Shift · Lessons / F09
Tools, calls and execution
工具、调用与执行
Open the interactive lesson · 打开互动课程A language model can generate a description of an action without performing that action.
语言模型可以生成对某个操作的描述,而并未真正执行这个操作。
言語モデルは、実際に行動しなくても、その行動の説明を生成できます。
Tool use connects generated requests to application functions that read information or change an environment.
工具使用将生成的请求连接到应用函数,由这些函数读取信息或改变环境。
ツール利用は、生成したリクエストを、情報を読んだり環境を変更したりするアプリの関数につなぎます。
A tool description usually identifies the operation, its purpose, and the arguments that the system accepts.
工具说明通常会明确操作是什么、用途是什么,以及系统接受哪些参数。
ツールの説明では通常、操作、目的、システムが受け付ける引数を示します。
The model can propose a tool call, but the surrounding application must validate and execute it according to its own controls.
模型可以提出工具调用,但外围应用必须依据自身的控制规则,对调用进行校验和执行。
モデルはツール呼び出しを提案できますが、周囲のアプリが自らの制御に従って検証し実行する必要があります。
For a meeting assistant, a proposal to create an event might include a title, start time, participants, and calendar identifier.
对于会议助手,创建日程的提议可能包含标题、开始时间、参与者和日历标识符。
会議アシスタントが予定を作る提案には、件名、開始時刻、参加者、カレンダーの識別子などが含まれます。
The application needs to check that the arguments are valid and that the user is authorized to change that calendar.
应用需要检查参数是否有效,以及用户是否有权修改该日历。
アプリは、引数が有効か、利用者にそのカレンダーを変更する権限があるかを確認する必要があります。
A syntactically valid request does not establish that the intended calendar, date, or people are correct.
请求在语法上有效,并不能证明其中指定的日历、日期或人员就是正确的。
構文上有効なリクエストでも、意図したカレンダー、日付、相手が正しいとは限りません。
After execution, a tool result can report success, failure, partial completion, or an unresolved status.
执行之后,工具结果可以报告成功、失败、部分完成,或状态仍未确定。
実行後のツール結果は、成功、失敗、一部完了、状態未確定などを報告できます。
The assistant's final answer should reflect that result rather than turn the requested action into an unsupported success claim.
助手的最终回复应如实反映该结果,而不是把用户请求的操作直接说成已经成功完成。
最終回答はその結果を反映し、依頼された行動を根拠なく成功したことにしてはいけません。
Suppose a calendar service accepts an event but the network connection fails before the application receives the confirmation.
假设日历服务已接受一个日程,但应用尚未收到确认,网络连接就中断了。
カレンダーサービスが予定を受け付けたものの、アプリが確認を受け取る前に通信が失敗したとします。
The event may have already been created, so immediately repeating the operation could create a duplicate.
该日程可能已经创建,因此立即重复操作可能会创建重复日程。
予定はすでに作成されているかもしれず、すぐ同じ操作を繰り返すと重複が発生する可能性があります。
An idempotency mechanism lets repeated attempts represent the same logical operation rather than independent new events.
幂等机制使多次尝试能够代表同一个逻辑操作,而不是各自创建独立的新日程。
冪等性の仕組みを使うと、繰り返した試行を別々の新しい予定ではなく、同じ論理的操作として扱えます。
When the service lacks that mechanism, the application may need to inspect the current state or escalate an ambiguous outcome.
如果服务没有这种机制,应用可能需要检查当前状态,或将结果不明的情况交由进一步处理。
その仕組みがないサービスでは、現在の状態を確認したり、結果が不明なことを担当者に引き継いだりする必要があります。
Read-only tools generally have different operational consequences from tools that send messages, delete records, or spend money.
只读工具的实际操作后果,通常不同于发送消息、删除记录或花钱的工具。
読み取り専用ツールと、メッセージ送信、記録削除、支払いを行うツールでは、通常、運用上の影響が異なります。
Permissions and sandbox boundaries should therefore reflect the actual operation, not merely the assistant's polite description of it.
因此,权限和沙箱边界应根据实际操作来设置,而不应只看助手如何礼貌地描述该操作。
そのため権限やサンドボックスの境界は、アシスタントの丁寧な説明ではなく、実際の操作を反映すべきです。
MCP provides a protocol architecture for connecting applications with external capabilities, but business authorization remains a separate design responsibility.
MCP 提供了一种协议架构,用于将应用与外部能力连接起来,但业务授权仍是另一项需要单独设计的责任。
MCPはアプリと外部機能を接続するためのプロトコル構造を提供しますが、業務上の認可は別途設計する責任として残ります。
To understand a tool-using system, trace the proposal, validation, execution, returned evidence, and final communication separately.
要理解一个使用工具的系统,应分别追踪操作提议、校验、执行、返回的证据和最终沟通。
ツールを使うシステムを理解するには、提案、検証、実行、返された証拠、最終的な伝達を分けて追跡します。
Key terms
- Harness: The surrounding software that manages model calls, tools, context and execution controls.
- Tool: A capability exposed through an interface for a model-driven system to request information or actions.
- Tool call: A structured proposal or invocation identifying a tool and its arguments, depending on the trace convention.
- Tool result: Information returned from executing a tool, including outputs, errors or uncertain status.
- Model Context Protocol: A protocol architecture for connecting host applications and clients with servers exposing tools, resources and related capabilities.
- Permission request: A request for a human or policy authority to approve a specific action or access.
- Sandbox: A constrained execution environment intended to limit access or the effects of actions.
- Idempotency: A property or mechanism under which repeating an operation preserves the intended single logical effect.