refactor(lite-plan): enhance argument hints and clarify exploration flags in documentation

This commit is contained in:
catlog22
2025-11-15 17:39:28 +08:00
parent 9d4c9ef212
commit b8dc3018d4

View File

@@ -1,7 +1,7 @@
--- ---
name: lite-plan name: lite-plan
description: Lightweight interactive planning and execution workflow with in-memory planning, code exploration, and immediate execution after user confirmation description: Lightweight interactive planning and execution workflow with in-memory planning, code exploration, and immediate execution after user confirmation
argument-hint: "[--tool claude|gemini|qwen|codex] [--quick] \"task description\"|file.md" argument-hint: "[--tool claude|gemini|qwen|codex] [-e|--explore] \"task description\"|file.md"
allowed-tools: TodoWrite(*), Task(*), Bash(*), AskUserQuestion(*) allowed-tools: TodoWrite(*), Task(*), Bash(*), AskUserQuestion(*)
timeout: 180000 timeout: 180000
color: cyan color: cyan
@@ -34,7 +34,7 @@ Intelligent lightweight planning and execution command with dynamic workflow ada
# Flags # Flags
--tool <tool-name> Preset CLI tool (claude|gemini|qwen|codex); if not provided, user selects during confirmation --tool <tool-name> Preset CLI tool (claude|gemini|qwen|codex); if not provided, user selects during confirmation
--quick Skip code exploration phase (fast mode, completes within 60 seconds) -e, --explore Force code exploration phase (overrides auto-detection logic)
# Arguments # Arguments
<task-description> Task description or path to .md file (required) <task-description> Task description or path to .md file (required)
@@ -51,7 +51,7 @@ User Input ("/workflow:lite-plan \"task\"")
v v
[Phase 1] Task Analysis & Exploration Decision (10-20 seconds) [Phase 1] Task Analysis & Exploration Decision (10-20 seconds)
-> Analyze task description -> Analyze task description
-> Decision: Need exploration? (Yes/No/--quick override) -> Decision: Need exploration? (Yes/No)
-> If Yes: Launch cli-explore-agent -> If Yes: Launch cli-explore-agent
-> Output: exploration findings (if performed) -> Output: exploration findings (if performed)
| |
@@ -107,17 +107,21 @@ Execution Complete
- Decision logic: - Decision logic:
```javascript ```javascript
needsExploration = ( needsExploration = (
task.mentions_specific_files || flags.includes('--explore') || flags.includes('-e') || // Force exploration if flag present
task.requires_codebase_context || (
task.needs_architecture_understanding || task.mentions_specific_files ||
task.modifies_existing_code task.requires_codebase_context ||
) && !flags.includes('--quick') task.needs_architecture_understanding ||
task.modifies_existing_code
)
)
``` ```
**Decision Criteria**: **Decision Criteria**:
| Task Type | Needs Exploration | Reason | | Task Type | Needs Exploration | Reason |
|-----------|-------------------|--------| |-----------|-------------------|--------|
| Any task with `-e` or `--explore` flag | **Yes (forced)** | **Flag overrides auto-detection logic** |
| "Implement new feature X" | Maybe | Depends on integration with existing code | | "Implement new feature X" | Maybe | Depends on integration with existing code |
| "Refactor module Y" | Yes | Needs understanding of current implementation | | "Refactor module Y" | Yes | Needs understanding of current implementation |
| "Add tests for Z" | Yes | Needs to understand code structure | | "Add tests for Z" | Yes | Needs to understand code structure |
@@ -800,6 +804,11 @@ TodoWrite({
- Adaptive planning: Simple tasks get direct planning, complex tasks use specialized agent - Adaptive planning: Simple tasks get direct planning, complex tasks use specialized agent
- Context-aware clarification: Only asks questions when truly needed - Context-aware clarification: Only asks questions when truly needed
- Reduces unnecessary steps while maintaining thoroughness - Reduces unnecessary steps while maintaining thoroughness
- **Flag-Based Control**:
- Use `-e` or `--explore` to force exploration when:
- Task appears simple but you know it requires codebase context
- Auto-detection might miss subtle integration points
- You want comprehensive code understanding before planning
2. **Progressive Clarification**: Gather information at the right time 2. **Progressive Clarification**: Gather information at the right time
- Phase 1: Explore codebase to understand current state - Phase 1: Explore codebase to understand current state
@@ -893,7 +902,7 @@ TodoWrite({
- "Add unit tests for authentication service" - "Add unit tests for authentication service"
- Flags (optional): - Flags (optional):
- `--tool <name>`: Preset execution tool (claude|gemini|codex|qwen) - `--tool <name>`: Preset execution tool (claude|gemini|codex|qwen)
- `--quick`: Skip code exploration phase - `-e` or `--explore`: Force code exploration phase (overrides auto-detection)
### Output Format ### Output Format