-
Notifications
You must be signed in to change notification settings - Fork 526
feat: Interactive Planning Mode with Clarification Questions #543
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Interactive Planning Mode with Clarification Questions #543
Conversation
Add font selectors that allow per-project font customization for both sans and mono fonts, independent of theme selection. Uses system fonts. - Add fontFamilySans and fontFamilyMono to ProjectSettings and Project types - Create ui-font-options.ts config with system font options - Add store actions: setProjectFontSans, setProjectFontMono, getEffectiveFontSans, getEffectiveFontMono - Apply font CSS variables in root component - Add font selector UI in project-theme-section (Project Settings → Theme)
Radix UI Select doesn't allow empty string values, so use 'default' as a sentinel value instead.
- Add fontFamilySans and fontFamilyMono to GlobalSettings type - Add global font state and actions to app store - Update getEffectiveFontSans/Mono to fall back to global settings - Add font selectors to global Settings → Appearance - Add "Use Global Font" checkboxes in Project Settings → Theme - Add fonts to settings sync and migration - Include fonts in import/export JSON
New themes added: - Dark: Ayu Dark, Ayu Mirage, Ember, Matcha - Light: Ayu Light, One Light, Bluloco, Feather Other changes: - Bundle Zed Sans and Zed Mono fonts from zed-industries/zed-fonts - Sort font options alphabetically (default first) - Sort theme options alphabetically (Dark/Light first) - Improve Ayu Dark text contrast for better readability - Fix Matcha theme to have green undertone instead of blue
- Fix git+ssh URL to git+https for @electron/node-gyp (build compatibility) - Remove duplicate @fontsource packages from root package.json - Refactor font state initialization to reduce code duplication
- Terminal font dropdown now uses mono fonts from UI font options - Unified font list between appearance section and terminal settings - Terminal font persisted to GlobalSettings for import/export support - Aligned global terminal settings popover with per-terminal popover: - Same settings in same order (Font Size, Run on New Terminal, Font Family, Scrollback, Line Height, Screen Reader) - Consistent styling (Radix Select instead of native select) - Added terminal padding (12px vertical, 16px horizontal) for readability
Allow AI agents to ask clarification questions during the planning phase when "Require approval" is enabled. This helps gather requirements before generating a spec, resulting in better-targeted implementations. Key changes: - Add AskUserQuestion tool to Auto Mode when requirePlanApproval is true - Detect tool invocation in message stream and pause for user response - Add ClarificationQuestionsDialog UI component with radio/checkbox options - Add clarificationInstructions prompt customization (Settings > Prompts) - Create notification when clarification is needed - Add WebSocket events for clarification request/response flow Activation conditions: - Feature uses Claude model (haiku, sonnet, opus) - "Require approval" is enabled on the feature - Planning mode is lite, spec, or full The clarification instructions prompt can be customized in Settings under Prompt Customization > Auto Mode > Interactive Planning section.
- Add `enableInteractivePlanning` global setting (default: true) - Make clarification prompt more assertive (Required vs Optional) - Add checkbox in Feature Defaults to enable/disable the feature - Setting is always visible with explanation of when it activates - Update prompt customization descriptions to reference Feature Defaults - Properly sync setting with server and include in import/export
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the Note Other AI code review bot(s) detectedCodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary of ChangesHello @stefandevo, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request significantly enhances the AI planning process by introducing an interactive mode that allows the AI to solicit user input through clarification questions. This ensures that the generated implementation plans are more aligned with user expectations and requirements. Additionally, it expands the application's customization capabilities by offering extensive UI and code font options, both globally and on a per-project basis, along with a variety of new visual themes. Highlights
🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console. Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request introduces a great new feature: Interactive Planning Mode, which allows the AI to ask for clarification. The implementation is comprehensive, touching both the backend service and the frontend UI to support this new flow. Additionally, there are significant enhancements to UI customization with new themes and font selection options. My review focuses on improving type safety and code clarity in the new interactive planning logic, particularly around handling data from API requests and AI model outputs. Overall, this is a solid contribution that will improve the user experience.
apps/server/src/routes/auto-mode/routes/clarification-response.ts
Outdated
Show resolved
Hide resolved
apps/server/src/routes/auto-mode/routes/clarification-response.ts
Outdated
Show resolved
Hide resolved
apps/ui/src/components/views/board-view/dialogs/clarification-questions-dialog.tsx
Outdated
Show resolved
Hide resolved
- Replace `as` type assertion with proper runtime validation function for req.body in clarification-response.ts - Consolidate repetitive validation into a loop-based approach - Add parseClarificationQuestions() type guard for validating tool output instead of using `as any[]` cast - Remove unnecessary `as any` casts from event type strings - Extract '__other__' magic string to OTHER_OPTION_VALUE constant Addresses review feedback from gemini-code-assist on PR AutoMaker-Org#543
Add data-testid with sanitized project name for E2E test assertions.
The testid format is 'project-switcher-project-{name}' where name is
the lowercased project name with spaces replaced by hyphens.
This fixes E2E tests that expect to find projects by name in the
project switcher.
- Replace `as` type assertion with proper runtime validation function for req.body in clarification-response.ts - Consolidate repetitive validation into a loop-based approach - Add parseClarificationQuestions() type guard for validating tool output instead of using `as any[]` cast - Remove unnecessary `as any` casts from event type strings - Extract '__other__' magic string to OTHER_OPTION_VALUE constant Addresses review feedback from gemini-code-assist on PR AutoMaker-Org#543
Summary
This PR introduces Interactive Planning Mode, a feature that allows the AI to ask clarification questions before generating an implementation plan. This helps gather requirements and preferences upfront, leading to better implementation plans that match user expectations.
Key Features
enableInteractivePlanningsetting in Feature Defaults (default:true)Configuration
Where to Enable/Disable
Settings → Feature Defaults → Enable interactive planning
The setting is always visible and explains when it activates:
When It Activates
The AI will ask clarification questions when all of these conditions are met:
enableInteractivePlanningis enabled (in Feature Defaults)Require plan approvalcheckedWhat Happens
Customizing the Prompt
Settings → Prompts → Auto Mode → Interactive Planning (Claude Code CLI Only)
You can customize the instructions that guide the AI on:
Changes
New Setting
enableInteractivePlanning: booleanin GlobalSettings (default:true)Files Modified
libs/types/src/settings.ts- Added setting type and defaultlibs/prompts/src/defaults.ts- Made clarification prompt more assertiveapps/server/src/services/auto-mode-service.ts- Check setting before enabling featureapps/ui/src/components/views/settings-view/feature-defaults/- Added checkboxapps/ui/src/components/views/settings-view/prompts/tab-configs.ts- Updated descriptionsapps/ui/src/store/app-store.ts- Added state and setterapps/ui/src/hooks/use-settings-sync.ts- Sync with serverapps/ui/src/hooks/use-settings-migration.ts- Migration supportTest Plan
enableInteractivePlanning: true→ AI should ask questionsenableInteractivePlanning: false→ AI should skip questions