Skip to content

new onboarding#1314

Merged
duckduckhero merged 1 commit intomainfrom
onboarding-fix-ph
Aug 11, 2025
Merged

new onboarding#1314
duckduckhero merged 1 commit intomainfrom
onboarding-fix-ph

Conversation

@duckduckhero
Copy link
Contributor

@duckduckhero duckduckhero commented Aug 11, 2025

Summary by cubic

Simplified the onboarding flow by removing the manual model selection step and automatically selecting the default model for users.

  • Refactors
    • Users now skip model selection; the 'small' model is chosen automatically after LLM or custom endpoint selection.
    • Cleaned up related code and removed unused translations.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Aug 11, 2025

📝 Walkthrough

Walkthrough

Removes the model-selection onboarding step in WelcomeModal and auto-selects the QuantizedSmall STT model when continuing from LLM or custom endpoint, then navigates directly to download-progress. Simplifies back-navigation and analytics. Updates localization source references for "Back" in English and Korean .po files.

Changes

Cohort / File(s) Summary
Onboarding flow adjustments
apps/desktop/src/components/welcome-modal/index.tsx
Removed ModelSelectionView import/usage and related state/analytics; added auto-selection of QuantizedSmall STT via selectSTTModel.mutateAsync on LLM/custom-endpoint continue; set sessionStorage flag; navigates to download-progress; simplified back button to custom-endpoint only; removed model-selection analytics/useEffect.
Localization metadata updates
apps/desktop/src/locales/en/messages.po, apps/desktop/src/locales/ko/messages.po
Updated source line references for msgid "Back" to new location; message strings unchanged.

Sequence Diagram(s)

sequenceDiagram
  participant U as User
  participant WM as WelcomeModal
  participant STT as selectSTTModel (mutation)
  participant SS as sessionStorage
  participant R as Router
  participant A as Analytics

  U->>WM: Continue from LLM selection
  WM->>A: track("onboarding_reached_llm_selection"/continue)
  WM->>STT: mutateAsync(select QuantizedSmall STT)
  STT-->>WM: success
  WM->>SS: set("model-download-dismiss", "true")
  WM->>R: navigate("download-progress")
Loading
sequenceDiagram
  participant U as User
  participant WM as WelcomeModal
  participant STT as selectSTTModel (mutation)
  participant SS as sessionStorage
  participant R as Router

  U->>WM: Continue from custom-endpoint
  WM->>STT: mutateAsync(select QuantizedSmall STT)
  STT-->>WM: success
  WM->>SS: set("model-download-dismiss", "true")
  WM->>R: navigate("download-progress")
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~15 minutes

Possibly related PRs

✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch onboarding-fix-ph

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.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

‼️ IMPORTANT
Auto-reply has been disabled for this repository in the CodeRabbit settings. The CodeRabbit bot will not respond to your replies unless it is explicitly tagged.

  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai generate unit tests to generate unit tests for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cubic analysis

No issues foundReview in cubic

@duckduckhero duckduckhero merged commit 07e01a1 into main Aug 11, 2025
7 of 8 checks passed
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (6)
apps/desktop/src/components/welcome-modal/index.tsx (6)

75-75: Remove commented-out state

Dead/commented code adds noise. Please delete it.

-  // const [cameFromLlmSelection, setCameFromLlmSelection] = useState(false);

244-251: Delete the commented-out handleModelSelected block

This legacy block is no longer used. Rely on git history instead of keeping commented code.

-  /*
-  const handleModelSelected = (model: WhisperModel) => {
-    selectSTTModel.mutate(model);
-    setSelectedSttModel(model);
-    sessionStorage.setItem("model-download-toast-dismissed", "true");
-    setCurrentStep("download-progress");
-  };
-  */

262-271: DRY the auto-select-small STT flow and add a pending guard

The same sequence appears here and in handleCustomEndpointContinue. Extract to a helper to reduce duplication and avoid double-triggering while the mutation is pending.

-    if (selection === "hyprllm") {
-      // Automatically select the 'small' model and proceed to download
-      const smallModel = "QuantizedSmall" as WhisperModel;
-      await selectSTTModel.mutateAsync(smallModel);
-      setSelectedSttModel(smallModel);
-      sessionStorage.setItem("model-download-toast-dismissed", "true");
-      setCurrentStep("download-progress");
-    } else {
+    if (selection === "hyprllm") {
+      await autoSelectSmallSttAndProceed();
+    } else {
       // setCameFromLlmSelection(false);
       setCurrentStep("custom-endpoint");
     }

Add this helper inside the component (outside of the handlers):

const autoSelectSmallSttAndProceed = async () => {
  if (selectSTTModel.isPending) return;
  const smallModel: WhisperModel = "QuantizedSmall";
  await selectSTTModel.mutateAsync(smallModel);
  setSelectedSttModel(smallModel);
  sessionStorage.setItem("model-download-toast-dismissed", "true");
  setCurrentStep("download-progress");
};

272-274: Remove leftover commented line

Leftover reference to removed state. Safe to delete.

-      // setCameFromLlmSelection(false);

277-284: Reuse the helper to avoid duplication

Apply the same helper here.

-  // Automatically select the 'small' model and proceed to download
-  const smallModel = "QuantizedSmall" as WhisperModel;
-  await selectSTTModel.mutateAsync(smallModel);
-  setSelectedSttModel(smallModel);
-  sessionStorage.setItem("model-download-toast-dismissed", "true");
-  setCurrentStep("download-progress");
+  await autoSelectSmallSttAndProceed();

265-266: Keep comments minimal and about “why”

These comments state “what” the code does. Either remove them (code is self-explanatory) or briefly explain “why” small is auto-selected (e.g., fastest initial setup to minimize time-to-value).

Also applies to: 278-279

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 2c14273 and 2ae345b.

📒 Files selected for processing (3)
  • apps/desktop/src/components/welcome-modal/index.tsx (3 hunks)
  • apps/desktop/src/locales/en/messages.po (1 hunks)
  • apps/desktop/src/locales/ko/messages.po (1 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
**/*.{js,ts,tsx,rs}

⚙️ CodeRabbit Configuration File

**/*.{js,ts,tsx,rs}: 1. No error handling.
2. No unused imports, variables, or functions.
3. For comments, keep it minimal. It should be about "Why", not "What".

Files:

  • apps/desktop/src/components/welcome-modal/index.tsx
🧬 Code Graph Analysis (1)
apps/desktop/src/components/welcome-modal/index.tsx (1)
plugins/local-stt/js/bindings.gen.ts (1)
  • WhisperModel (68-68)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
  • GitHub Check: ci (windows, windows-latest)
  • GitHub Check: ci (macos, macos-latest)
🔇 Additional comments (2)
apps/desktop/src/locales/en/messages.po (1)

446-449: Anchor update looks correct

"Back" now references index.tsx:349, matching the new button location in the simplified flow.

apps/desktop/src/locales/ko/messages.po (1)

446-449: Anchor update looks correct

"Back" now references index.tsx:349, aligned with the updated onboarding flow.

@coderabbitai coderabbitai bot mentioned this pull request Dec 10, 2025
@ComputelessComputer ComputelessComputer deleted the onboarding-fix-ph branch December 14, 2025 15:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant