Skip to content

fix(cli): clarify permission mode approval behavior#1877

Open
whatevertogo wants to merge 3 commits into
MoonshotAI:mainfrom
whatevertogo:whatevertogo/clarify-permission-mode-copy
Open

fix(cli): clarify permission mode approval behavior#1877
whatevertogo wants to merge 3 commits into
MoonshotAI:mainfrom
whatevertogo:whatevertogo/clarify-permission-mode-copy

Conversation

@whatevertogo

@whatevertogo whatevertogo commented Jul 18, 2026

Copy link
Copy Markdown

Related Issue

Closes #1866
Closes #1874
Addresses #1859 — clarifies the semantics without renaming the shipped modes.

Problem

The permission engines implement an increasing autonomy order of manual < yolo < auto:

  • Manual reviews actions that require approval.
  • YOLO auto-approves regular tools, while sensitive actions may still need approval and the agent may still ask questions.
  • Auto is the unattended mode: permission prompts are approved automatically and the agent does not ask questions.

The copy shipped across the CLI and TUI used absolute or incomplete descriptions such as "Approve every action yourself", "Tool actions auto-approved", and "All actions auto-approved". That made the distinction unclear and contributed to the confusion reported in #1859, #1866, and #1874.

Issue #1859 suggests swapping or renaming the modes. This PR takes the compatibility-preserving approach instead: it keeps the shipped names, command semantics, persisted values, and permission-engine behavior unchanged, while making the user-facing contract explicit.

This is a follow-up to #1867, which first aligned the broad permission-mode descriptions.

What changed

  • Clarified the permission descriptions shown by CLI help, the /permission selector, slash-command autocomplete, /auto and /yolo notices, and session replay.
  • Kept the selector ordered as Manual → YOLO → Auto to match increasing autonomy.
  • Added a patch changeset for @moonshot-ai/kimi-code, as required for this user-visible CLI/TUI change.
  • Preserved the existing local source layout instead of applying unrelated whole-file formatting.
  • Did not add copy-specific assertions: the existing behavior-level tests already cover these surfaces, and duplicating static strings would make the suite brittle.

File change summary

  • Added: 1 file
  • Modified: 5 files
  • Deleted: 0 files
Area Files Purpose
Release .changeset/clarify-permission-mode-copy.md Record the user-visible patch
CLI/TUI copy apps/kimi-code/src/cli/commands.ts, src/tui/commands/config.ts, src/tui/commands/registry.ts Align help, notices, and command descriptions
Selector/replay src/tui/components/dialogs/permission-selector.ts, src/tui/controllers/session-replay.ts Clarify visible mode behavior

Verification

  • Existing targeted Vitest suite: 4 files, 199 tests passed.
  • apps/kimi-code TypeScript typecheck passed.
  • Oxlint passed with 0 warnings and 0 errors on the changed source files.
  • git diff --check origin/main...HEAD passed.
  • Read-only public-text audit found no context-specific internal identifiers or agent attribution.

Checklist

  • I have read the CONTRIBUTING document.
  • I have linked a related issue, or explained the problem above.
  • I have added tests that prove my feature works. Not applicable: this is a copy-only change, and the existing behavior-level tests pass.
  • Ran gen-changesets skill, or this PR needs no changeset.
  • Ran gen-docs skill, or this PR needs no doc update. The current docs already describe the engine semantics correctly; this PR only makes existing CLI/TUI copy more precise.

Distinguish YOLO regular-tool approvals from exceptional prompts and describe Auto as unattended across command help, selectors, notices, and replay. Add regression coverage for the permission order and user-visible copy.

Refs MoonshotAI#1859, MoonshotAI#1866, MoonshotAI#1874
Keep the updated permission descriptions in the existing one-line call and property layout without applying unrelated whole-file formatting.
@changeset-bot

changeset-bot Bot commented Jul 18, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 0b56643

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@moonshot-ai/kimi-code Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Keep the existing behavior-level coverage without pinning user-facing permission descriptions verbatim in multiple test suites.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant