跳到正文
Skillpedia
智能体5.2k · #15023

permissions-debug

它能做什么

它说明如何检查 Kode 已批准的工具和命令限制,然后只做必要的最小权限改动。适合工具被意外阻止的 Kode 用户。

适用场景

  • ✓当 Kode 阻止了你以为应该可以运行的工具时。
  • ✓当 Kode 反复对同一权限发出询问时。
  • ✓当辅助智能体的表现与主 Kode 智能体不同时。

技能链接

https://github.com/shareAI-lab/Kode-CLI/blob/main/packages/builtin-skills/skills/permissions-debug/SKILL.md

复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。

使用方法

最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。

可直接粘贴的消息

请用这个技能帮我:https://github.com/shareAI-lab/Kode-CLI/blob/main/packages/builtin-skills/skills/permissions-debug/SKILL.md 阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
想让你的 AI 自己找到这样的技能吗?安装免费的 Skillpedia MCP:只需一行,每次任务前它都会在 15,000+ 个技能中搜索。1 分钟完成安装 →

可以这样问 AI

“我已经批准了文件搜索工具,但 Kode 还是阻止它。为什么?该怎么修?”

每周 5 个新技能,1 分钟读完。

工作原理

智能体会检查被阻止的具体操作,列出已批准的工具,并查找命令限制。它会做出最小、可撤销的改动,然后重复该操作来测试效果。

技术内容(原始 SKILL.md)

作者在 GitHub 上的英文原文。

Permissions Debug (Kode-first, fail-closed)

Non-negotiables

  • Do not auto-escalate permissions. If an action would normally require user approval, keep it interactive and explain why.
  • Prefer minimal, reversible permission changes and verify immediately.
  • In dontAsk contexts, treat “would prompt” as deny (fail-closed). Do not try to bypass.

Fast triage (what to check first)

  1. Confirm what is blocked

    • Look for the exact tool name and the rejection message.
    • If the failure is from a subagent, confirm whether the parent context was more restricted.
  2. Inspect approved tools / project allowlist

    • Use SlashCommand to run /approved-tools list and confirm whether the tool (or its rule category) is present.
    • If the list is unexpectedly long or contains stale entries, remove only the minimum needed with /approved-tools remove <tool>.
  3. Check per-command constraints

    • Some flows apply commandAllowedTools constraints (slash command / skill execution contexts). Confirm the command’s allowed-tools frontmatter and whether it should be restrictive.

Verification loop (keep it tight)

  • Re-run the exact action that was blocked and confirm:
    • whether the prompt appears (interactive modes), or
    • whether the tool is allowed/denied deterministically (headless / dontAsk).

Forensics (when “it should have worked”)

  • Inspect the latest session artifacts under ~/.kode/ (messages + errors) to confirm what tool call was attempted and why it was denied.
  • If a background shell was involved, cross-check task output files in ~/.kode/**/tasks/ for the corresponding bashId.
常见问题

智能体会自动开启权限吗?

不会。该技能不会自动批准那些通常需要你同意的操作。

在不显示提示的运行中会发生什么?

任何需要提示的操作都会被视为拒绝,以确保安全。

智能体如何确认修复有效?

它会重复被阻止的操作,看看现在是允许还是仍然被拒绝。

详情

作者的原始描述

Troubleshoot Kode permission prompts/denials (tool allowlists, commandAllowedTools, dontAsk fail-closed, subagent inheritance). Use when tools are unexpectedly blocked, permission prompts repeat, or behavior differs between main agent and subagents.

repo: shareAI-lab/Kode-CLI

热度

GitHub 星标
5.2k
排名
#15023
许可证
Apache-2.0
更新时间
2026/11/2

这个技能有用吗?

0

登录 后即可投票。

评论

  • …

同一仓库的更多技能

相似技能