-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Description
Overview
Add always-visible quick prompt suggestions below the chat input field, allowing users to select common prompts without typing commands.
User Experience
When input is empty, display selectable prompt chips:
You: _____________________
[Explain code] [Debug error] [Write tests] [Summarize]
[Code review] [Refactor] [Add docs] [More...]
Interaction:
- Arrow keys or number keys to select
- Enter to insert selected prompt into input
- Start typing to hide suggestions and use regular input
- Suggestions reappear when input is cleared
Implementation Approach
Using prompt_toolkit layout features:
- Create a floating panel or bottom section showing prompt chips
- Conditionally display when input buffer is empty
- Add key bindings for navigation (arrows, numbers)
- Insert selected prompt text into input buffer
Prompt Categories (example)
- Code: Explain, Debug, Refactor, Review, Write tests, Add docs
- Analysis: Summarize, Compare, Find issues, Suggest improvements
- Creative: Brainstorm, Generate ideas, Write copy
Configuration
- Prompts could be loaded from a config file (YAML/JSON)
- User-customizable prompt library
- Conditional prompts based on context (e.g., RAG-specific prompts when RAG is enabled)
Files to Modify
app/cli/ai.py- Modify PromptSession layoutapp/cli/chat_completer.py- May need prompt navigation logic- New:
app/cli/quick_prompts.py- Prompt definitions and UI component
Reference
- prompt_toolkit layouts: https://python-prompt-toolkit.readthedocs.io/en/master/pages/advanced_topics/rendering_flow.html
- Current chat implementation:
app/cli/ai.pylines 1005-1320
Metadata
Metadata
Assignees
Labels
No labels