Kiro:V3 会话中的钩子可改写工具输入并回答权限请求

V3 会话中,PreToolUse 钩子可返回 updatedInput,PermissionRequest 钩子可回答 allow 或 deny。

Kiro
事件类型
功能更新
官方发布
本站整理
本页目录

关键变化

在 V3 会话中,PreToolUse 钩子现在可以返回 updatedInput,在工具运行前替换工具调用的输入。

官方原文

本次变化

共 9 条要点

  1. 在 V3 会话中,PreToolUse 钩子现在可以返回 updatedInput,在工具运行前替换工具调用的输入。

    官方原文 · c1

    In a V3 session, a PreToolUse hook can now return updatedInput to replace a tool call's inputs before the tool runs

    官方原文 · c1
  2. 在 V3 会话中,PreToolUse hook 可以在工具运行前返回 updatedInput,并同时给出 allow、ask 或 deny 决定。

    官方原文 · c2

    In a V3 session, a PreToolUse hook can now return updatedInput to replace a tool call's inputs before the tool runs, alongside its allow , ask , or deny decision.

    官方原文 · c2
  3. 新增的 PermissionRequest 钩子在工具调用将要向你请求权限时运行,可以用 allow 或 deny 作答。

    官方原文 · c3

    A new PermissionRequest hook runs when a tool call would ask you for permission and can answer with allow or deny

    官方原文 · c3
  4. 这样脚本就能批准或拒绝原本要等你处理的调用。

    官方原文 · c4

    so a script grants or refuses a call that would otherwise wait on you

    官方原文 · c4
  5. 任何钩子给出的 deny 都优先于 allow。

    官方原文 · c5

    A deny from any hook wins over an allow

    官方原文 · c5
  6. 钩子给出的权限答复只适用于那一次工具调用。

    官方原文 · c6

    a hook's permission answer applies to that one tool call only

    官方原文 · c6
  7. 请求超出模型上下文窗口时,智能体会恢复,而不是让这一轮失败。

    官方原文 · c7

    The agent recovers when a request exceeds the model's context window instead of failing the turn

    官方原文 · c7
  8. macOS 上的沙盒命令和 MCP 服务器可以使用 POSIX 信号量。

    官方原文 · c8

    Sandboxed commands and MCP servers on macOS can use POSIX semaphores

    官方原文 · c8
  9. 读取文件失败后,不再未经批准就把它当作你主目录中的路径重试。

    官方原文 · c9

    A failed file read no longer retries without approval as a path in your home folder

    官方原文 · c9

变化明细

下表按已审核事实整理,保留原语言;原文见各要点的引用。

编号主体动作对象范围判断
c1PreToolUse hookcan returnupdatedInput to replace a tool call's inputs before the tool runsV3 session
c2PreToolUse hookcan return updatedInput alongsideallow, ask, or deny decisionin a V3 session, before the tool runs
c3PermissionRequest hookruns and can answerallow or deny when a tool call would ask for permission
c4scriptgrants or refusesa call that would otherwise wait on the user
c5deny from any hookwins overallow
c6hook permission answerapplies tothat one tool call only
c7agentrecoverswhen a request exceeds the model's context window instead of failing the turn
c8Sandboxed commands and MCP serverscan usePOSIX semaphoresmacOS
c9failed file readno longer retries without approvalas a path in your home folder否定

版本时间线

同一工具在本站已发布的快讯,按官方发布日期由新到旧。

  1. 标准版指挥模式无需预览开关,LTS 不提供
  2. 当前V3 会话中的钩子可改写工具输入并回答权限请求
  3. CLI 新增超出终端宽度 Mermaid 图的全屏查看器
  4. Kiro企业管理员可在已分配席位用户间共享积分
  5. V3 会话启动时默认自动升级 V2 智能体
  6. 四款模型正式发布并获Kiro完整支持

关于这个工具

Kiro

Kiro 是以规格驱动开发为重点的编程 Agent,将需求转成设计与任务,并辅助实施和检查代码。

分类AI编程工具

查看 Kiro 详情

相关教程

来源与说明

官方原文 · kiro.dev/changelog/cli/3-4

AI 整理说明

本条由 AI 依据官方来源整理并经自动核对;发现错误请 反馈。