feat: Implement Plan Mode for Safe Code Planning (#658)
Some checks are pending
Qwen Code CI / Lint (GitHub Actions) (push) Waiting to run
Qwen Code CI / Lint (Javascript) (push) Waiting to run
Qwen Code CI / Lint (Shell) (push) Waiting to run
Qwen Code CI / Lint (YAML) (push) Waiting to run
Qwen Code CI / Lint (push) Blocked by required conditions
Qwen Code CI / Test (push) Blocked by required conditions
Qwen Code CI / Test-1 (push) Blocked by required conditions
Qwen Code CI / Test-2 (push) Blocked by required conditions
Qwen Code CI / Test-3 (push) Blocked by required conditions
Qwen Code CI / Test-4 (push) Blocked by required conditions
Qwen Code CI / Test-5 (push) Blocked by required conditions
Qwen Code CI / Test-6 (push) Blocked by required conditions
Qwen Code CI / Test-7 (push) Blocked by required conditions
Qwen Code CI / Test-8 (push) Blocked by required conditions
Qwen Code CI / Post Coverage Comment (push) Blocked by required conditions
Qwen Code CI / CodeQL (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:docker (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:none (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:docker-1 (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:none-1 (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:docker-2 (push) Waiting to run
E2E Tests / E2E Test (Linux) - sandbox:none-2 (push) Waiting to run
E2E Tests / E2E Test - macOS (push) Waiting to run

This commit is contained in:
tanzhenxin 2025-09-24 14:26:17 +08:00 committed by GitHub
parent 8379bc4d81
commit 4e7a7e2656
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
43 changed files with 2895 additions and 281 deletions

View file

@ -464,6 +464,7 @@ export type ToolResultDisplay =
| string
| FileDiff
| TodoResultDisplay
| PlanResultDisplay
| TaskResultDisplay;
export interface FileDiff {
@ -490,6 +491,12 @@ export interface TodoResultDisplay {
}>;
}
export interface PlanResultDisplay {
type: 'plan_summary';
message: string;
plan: string;
}
export interface ToolEditConfirmationDetails {
type: 'edit';
title: string;
@ -541,7 +548,15 @@ export type ToolCallConfirmationDetails =
| ToolEditConfirmationDetails
| ToolExecuteConfirmationDetails
| ToolMcpConfirmationDetails
| ToolInfoConfirmationDetails;
| ToolInfoConfirmationDetails
| ToolPlanConfirmationDetails;
export interface ToolPlanConfirmationDetails {
type: 'plan';
title: string;
plan: string;
onConfirm: (outcome: ToolConfirmationOutcome) => Promise<void>;
}
export enum ToolConfirmationOutcome {
ProceedOnce = 'proceed_once',