-
Notifications
You must be signed in to change notification settings - Fork 0
Enable Smart Mode by default for immediate chat-driven ChartSpec generation #11
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
base: main
Are you sure you want to change the base?
Conversation
Co-authored-by: evcatalyst <[email protected]>
Co-authored-by: evcatalyst <[email protected]>
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.
Pull request overview
This pull request enables Smart Mode by default, allowing users to create charts using natural language commands without requiring an API key. The change shifts the application's focus from requiring manual ChartSpec JSON or API-key-based LLM interactions to providing immediate, API-less chart generation for new users.
Key Changes:
- Smart Mode is now enabled by default in application state (smartMode: true)
- Enhanced loadSettings() to properly handle first-time users with the new default
- Added a welcome message system that guides users based on their active mode
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| chartspec/main.js | Sets smartMode to true as default, adds logic to handle first-time user settings properly, implements showWelcomeMessage() to provide contextual onboarding |
| README.md | Reorganizes documentation to emphasize Smart Mode as default, updates getting started instructions to highlight immediate usability without setup |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <[email protected]>
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.
Pull request overview
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| * Show welcome message for first-time users | ||
| */ | ||
| function showWelcomeMessage() { | ||
| // Check if this is a first-time user (no saved chat history) |
Copilot
AI
Dec 13, 2025
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.
The comment on line 846 is misleading. It states "Check if this is a first-time user (no saved chat history)" but the code actually checks localStorage.getItem('chartspec_welcome_shown'), which is a dedicated flag for the welcome message, not chat history. The comment should be updated to accurately reflect what the code does, e.g., "Check if the welcome message has been shown before".
| // Check if this is a first-time user (no saved chat history) | |
| // Check if the welcome message has been shown before |
Users previously needed to manually write ChartSpec JSON or configure API keys before creating charts. The application now enables Smart Mode by default, allowing immediate natural language chart generation without setup.
Changes
State initialization (
chartspec/main.js)smartMode: trueas default instead offalseSettings persistence (
chartspec/main.js)loadSettings()to distinguish between no preference (default to Smart Mode) and explicit user choice'true'(keep enabled),'false'(user disabled),null(use default)Onboarding (
chartspec/main.js)showWelcomeMessage()to explain active mode on first launchDocumentation (
README.md)User flow
Backward compatibility
Existing user preferences respected via localStorage:
Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.