Skip to content

Conversation

@yujonglee
Copy link
Contributor

No description provided.

@yujonglee
Copy link
Contributor Author

@coderabbitai ignore

@coderabbitai
Copy link

coderabbitai bot commented Oct 24, 2025

Note

Reviews paused

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.
📝 Walkthrough

Walkthrough

This PR introduces AI-powered content enhancement for session notes with streaming support. It adds a new Zustand-based AI task store, integrates OpenRouter and OpenAI language model providers, refactors the EnhancedEditor component into a modular structure with streaming and error-handling views, implements an agent-based meeting summary system with structured Markdown output, and updates the Tiptap editor to operate in Markdown mode.

Changes

Cohort / File(s) Change Summary
Package Manager and Dependencies
.github/actions/pnpm_install/action.yaml, package.json, apps/desktop/package.json, packages/tiptap/package.json
Updated pnpm version from 10.18.3 to 10.19.0; added @openrouter/ai-sdk-provider dependency to apps/desktop; added @tiptap/markdown extension to packages/tiptap
AI Task Store and Context
apps/desktop/src/store/zustand/ai-task/index.ts, apps/desktop/src/store/zustand/ai-task/tasks.ts, apps/desktop/src/contexts/ai-task/index.tsx
Introduced new Zustand store for managing AI task lifecycle (idle, generating, success, error); created AITaskProvider context with useAITask hook; implemented task slice with streaming text collection, agent selection, abort support, and error handling
Language Model and Agent Creation
apps/desktop/src/hooks/useLLMConnection.ts, apps/desktop/src/contexts/ai-task/enhancing.ts
Extended useLanguageModel to support OpenRouter and OpenAI providers alongside existing Anthropic; created createEnhancingAgent factory that constructs an Experimental_Agent for structured meeting summaries with tool-based section analysis
UI Layout and Floating Button
apps/desktop/src/components/main/body/index.tsx, apps/desktop/src/components/main/body/sessions/index.tsx, apps/desktop/src/components/main/body/sessions/floating/index.tsx
Added floatingButton prop to StandardTabWrapper; refactored session container to flex-column layout with header flex-shrink-0 and flexible note input; wired GenerateButton to receive sessionId from tab context
Enhanced Editor Refactoring and Streaming
apps/desktop/src/components/main/body/sessions/note-input/enhanced/editor.tsx, apps/desktop/src/components/main/body/sessions/note-input/enhanced/index.tsx, apps/desktop/src/components/main/body/sessions/note-input/enhanced/streaming.tsx, apps/desktop/src/components/main/body/sessions/note-input/enhanced.tsx
Relocated EnhancedEditor logic to subdirectory structure; created Enhanced wrapper that conditionally renders StreamingView during generation or error states; added StreamingView component with auto-scroll and animated loading indicator
Generate Button Task Integration
apps/desktop/src/components/main/body/sessions/floating/generate.tsx
Enhanced GenerateButton to accept sessionId prop, derive unique taskId, integrate with useLanguageModel and useAITask hooks, execute async generate workflow with prompt construction and completion callback, show Loader2 spinner during generation, and toggle between "Regenerate" and "Cancel" actions
Note Input Tab Management
apps/desktop/src/components/main/body/sessions/note-input/index.tsx
Replaced EnhancedEditor import with Enhanced; added useAITask integration to track per-note enhancement tasks; implemented auto-switch to "enhanced" tab when taskStatus is "generating"; updated tab ordering to prioritize "enhanced" when transcript is present
Tiptap Editor Markdown Support
packages/tiptap/src/editor/index.tsx
Added Markdown extension to editor extensions; changed content initialization from HTML placeholder to empty string; set contentType to "markdown"; disabled autocapitalize
Type and Context Updates
apps/desktop/src/types/index.ts, apps/desktop/src/main.tsx, apps/desktop/src/routes/app/main/_layout.tsx
Extended Context type to include aiTaskStore; instantiated aiTaskStore in main.tsx and injected into router context; wrapped ToolRegistration and Outlet in AITaskProvider within layout route

Sequence Diagram

sequenceDiagram
    participant User
    participant UI as GenerateButton UI
    participant Task as AI Task Store
    participant Agent as Language Model Agent
    participant Editor as Enhanced Editor
    participant View as StreamingView

    User->>UI: Click "Regenerate"
    UI->>Task: generate(taskId, prompt, onComplete)
    Task->>Task: Create AbortController, set status="generating"
    Task->>Agent: agent.stream(messages)
    Agent->>Task: Stream text chunks
    Task->>Task: Accumulate streamedText, collect steps
    Task->>Editor: Re-render with isGenerating=true
    Editor->>View: Render StreamingView(streamedText)
    View->>View: Auto-scroll to bottom
    Agent-->>Task: Finish streaming
    Task->>Task: onComplete(streamedText)
    Task->>Editor: Update enhanced_md via partial row setter
    Task->>Task: Set status="success"
    
    User->>UI: Click "Cancel" (during generation)
    UI->>Task: cancel(taskId)
    Task->>Agent: Abort streaming
    Agent-->>Task: AbortError
    Task->>Task: Reset state to idle
    Task->>Editor: Re-render, status=idle
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~50 minutes

The changes span multiple concerns with varied patterns: new Zustand store architecture with complex streaming and agent logic; substantial component refactoring across the editor hierarchy; provider integration requiring conditional branching; and layout restructuring affecting focus and scroll behavior. While individual files have clear intent, the interconnected task state, streaming mechanics, and agent scheduling introduce moderate logic density warranting careful cross-file review.

Possibly related PRs

Pre-merge checks and finishing touches

❌ Failed checks (1 warning, 1 inconclusive)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
Description Check ❓ Inconclusive No pull request description was provided by the author. Since there is no description content to evaluate, it is impossible to assess whether a description relates to, partially describes, or is unrelated to the changeset. The absence of information prevents a definitive determination. Add a pull request description that explains the objectives and scope of the enhancing feature implementation, including the AI task infrastructure, provider support, and UI components being introduced.
✅ Passed checks (1 passed)
Check name Status Explanation
Title Check ✅ Passed The title "Got enhancing working in desktop2" refers to implementing an AI enhancing (summarization) feature. The changeset demonstrates this through multiple coordinated additions: a new AI task management infrastructure with Zustand store, a createEnhancingAgent function, UI components (GenerateButton, FloatingActionButton, Enhanced, StreamingView) to trigger and display the enhancement workflow, support for new AI providers, and modifications to the editor to support Markdown-based content. While the phrasing is somewhat casual, the title clearly captures the primary objective—implementing the enhancing feature—and a teammate reviewing history would understand this core change.

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

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@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: 4

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
apps/desktop/src/components/main/body/sessions/note-input/index.tsx (1)

87-100: Users can’t trigger “Enhanced” without a transcript

Enhanced tab appears only if hasTranscript, but generation is only reachable on the Enhanced tab. This blocks enhancement for sessions with only raw notes.

Expose Enhanced when generating or when enhanced content exists (and optionally even when raw notes exist). Example:

 function useEditorTabs({ sessionId }: { sessionId: string }): EditorView[] {
   const status = useListener((state) => state.status);
   const hasTranscript = useHasTranscript(sessionId);
+  const taskStatus = useAITask((state) =>
+    state.tasks.get(`${sessionId}-enhance`)?.status ?? "idle",
+  );
+  const hasEnhanced = !!persisted.UI.useCell(
+    "sessions",
+    sessionId,
+    "enhanced_md",
+    persisted.STORE_ID,
+  );

   if (status === "running_active") {
     return ["raw", "transcript"];
   }

-  if (hasTranscript) {
-    return ["enhanced", "raw", "transcript"];
-  }
+  if (hasTranscript || taskStatus === "generating" || hasEnhanced) {
+    return ["enhanced", "raw", ...(hasTranscript ? ["transcript"] : [])];
+  }

   return ["raw"];
 }

This aligns with the UX flow and avoids dead-ends. As per coding guidelines.

🧹 Nitpick comments (1)
apps/desktop/src/store/zustand/ai-task/tasks.ts (1)

173-186: Success path looks fine; consider storing trimmed text consistently

You store fullText on success but trimmed text during streaming. Optional: also store trimmed on success for consistency, while onComplete receives fullText to persist.

📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7a6a9aa and 5546951.

⛔ Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (23)
  • .github/actions/pnpm_install/action.yaml (1 hunks)
  • apps/desktop/package.json (1 hunks)
  • apps/desktop/src/components/main/body/index.tsx (1 hunks)
  • apps/desktop/src/components/main/body/sessions/floating/generate.tsx (1 hunks)
  • apps/desktop/src/components/main/body/sessions/floating/index.tsx (1 hunks)
  • apps/desktop/src/components/main/body/sessions/index.tsx (1 hunks)
  • apps/desktop/src/components/main/body/sessions/note-input/enhanced.tsx (0 hunks)
  • apps/desktop/src/components/main/body/sessions/note-input/enhanced/editor.tsx (1 hunks)
  • apps/desktop/src/components/main/body/sessions/note-input/enhanced/index.tsx (1 hunks)
  • apps/desktop/src/components/main/body/sessions/note-input/enhanced/streaming.tsx (1 hunks)
  • apps/desktop/src/components/main/body/sessions/note-input/index.tsx (4 hunks)
  • apps/desktop/src/components/settings/ai/shared/model-combobox.tsx (2 hunks)
  • apps/desktop/src/contexts/ai-task/enhancing.ts (1 hunks)
  • apps/desktop/src/contexts/ai-task/index.tsx (1 hunks)
  • apps/desktop/src/hooks/useLLMConnection.ts (2 hunks)
  • apps/desktop/src/main.tsx (2 hunks)
  • apps/desktop/src/routes/app/main/_layout.tsx (3 hunks)
  • apps/desktop/src/store/zustand/ai-task/index.ts (1 hunks)
  • apps/desktop/src/store/zustand/ai-task/tasks.ts (1 hunks)
  • apps/desktop/src/types/index.ts (1 hunks)
  • package.json (1 hunks)
  • packages/tiptap/package.json (1 hunks)
  • packages/tiptap/src/editor/index.tsx (2 hunks)
💤 Files with no reviewable changes (1)
  • apps/desktop/src/components/main/body/sessions/note-input/enhanced.tsx
🧰 Additional context used
📓 Path-based instructions (1)
apps/desktop/**/*.{tsx,jsx}

📄 CodeRabbit inference engine (apps/desktop/.cursor/rules/style.mdc)

apps/desktop/**/*.{tsx,jsx}: When there are many Tailwind classNames with conditional logic, use the utility cn imported as import { cn } from "@hypr/utils"
When using cn for Tailwind classNames, always pass an array
Group Tailwind classNames by logical sections when using cn (split array items by grouping)

Files:

  • apps/desktop/src/components/main/body/sessions/note-input/enhanced/streaming.tsx
  • apps/desktop/src/components/main/body/sessions/note-input/enhanced/editor.tsx
  • apps/desktop/src/components/main/body/index.tsx
  • apps/desktop/src/components/main/body/sessions/floating/generate.tsx
  • apps/desktop/src/components/settings/ai/shared/model-combobox.tsx
  • apps/desktop/src/components/main/body/sessions/floating/index.tsx
  • apps/desktop/src/routes/app/main/_layout.tsx
  • apps/desktop/src/contexts/ai-task/index.tsx
  • apps/desktop/src/components/main/body/sessions/note-input/enhanced/index.tsx
  • apps/desktop/src/components/main/body/sessions/index.tsx
  • apps/desktop/src/main.tsx
  • apps/desktop/src/components/main/body/sessions/note-input/index.tsx
🧬 Code graph analysis (13)
apps/desktop/src/components/main/body/sessions/note-input/enhanced/streaming.tsx (1)
packages/utils/src/cn.ts (1)
  • cn (20-22)
apps/desktop/src/components/main/body/sessions/note-input/enhanced/editor.tsx (1)
packages/tiptap/src/editor/index.tsx (1)
  • TiptapEditor (12-12)
apps/desktop/src/components/main/body/sessions/floating/generate.tsx (4)
apps/desktop/src/hooks/useLLMConnection.ts (1)
  • useLanguageModel (11-51)
apps/desktop/src/contexts/ai-task/index.tsx (1)
  • useAITask (28-42)
packages/utils/src/cn.ts (1)
  • cn (20-22)
apps/desktop/src/components/main/body/sessions/floating/shared.tsx (1)
  • FloatingButton (5-29)
apps/desktop/src/components/main/body/sessions/floating/index.tsx (1)
apps/desktop/src/components/main/body/sessions/floating/generate.tsx (1)
  • GenerateButton (11-111)
apps/desktop/src/types/index.ts (2)
apps/desktop/src/store/zustand/listener/index.ts (1)
  • ListenerStore (10-10)
apps/desktop/src/store/zustand/ai-task/index.ts (1)
  • AITaskStore (9-9)
apps/desktop/src/routes/app/main/_layout.tsx (1)
apps/desktop/src/contexts/ai-task/index.tsx (1)
  • AITaskProvider (9-26)
apps/desktop/src/store/zustand/ai-task/index.ts (1)
apps/desktop/src/store/zustand/ai-task/tasks.ts (3)
  • TasksState (26-28)
  • TasksActions (30-47)
  • createTasksSlice (64-218)
apps/desktop/src/contexts/ai-task/index.tsx (1)
apps/desktop/src/store/zustand/ai-task/index.ts (2)
  • AITaskStore (9-9)
  • createAITaskStore (11-15)
apps/desktop/src/components/main/body/sessions/note-input/enhanced/index.tsx (4)
packages/tiptap/src/editor/index.tsx (1)
  • TiptapEditor (12-12)
apps/desktop/src/contexts/ai-task/index.tsx (1)
  • useAITask (28-42)
apps/desktop/src/components/main/body/sessions/note-input/enhanced/streaming.tsx (1)
  • StreamingView (8-57)
apps/desktop/src/components/main/body/sessions/note-input/enhanced/editor.tsx (1)
  • EnhancedEditor (7-36)
apps/desktop/src/components/main/body/sessions/index.tsx (5)
apps/desktop/src/components/main/body/index.tsx (1)
  • StandardTabWrapper (272-293)
apps/desktop/src/components/main/body/sessions/floating/index.tsx (1)
  • FloatingActionButton (10-32)
apps/desktop/src/components/main/body/sessions/outer-header/index.tsx (1)
  • OuterHeader (6-18)
apps/desktop/src/components/main/body/sessions/title-input.tsx (1)
  • TitleInput (6-32)
apps/desktop/src/components/main/body/sessions/note-input/index.tsx (1)
  • NoteInput (14-50)
apps/desktop/src/store/zustand/ai-task/tasks.ts (1)
apps/desktop/src/contexts/ai-task/enhancing.ts (1)
  • createEnhancingAgent (4-75)
apps/desktop/src/main.tsx (2)
apps/desktop/src/store/zustand/listener/index.ts (1)
  • createListenerStore (12-17)
apps/desktop/src/store/zustand/ai-task/index.ts (1)
  • createAITaskStore (11-15)
apps/desktop/src/components/main/body/sessions/note-input/index.tsx (2)
apps/desktop/src/contexts/ai-task/index.tsx (1)
  • useAITask (28-42)
apps/desktop/src/components/main/body/sessions/note-input/enhanced/index.tsx (1)
  • Enhanced (8-32)
⏰ 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: zizmor
  • GitHub Check: ci (macos, macos-14)
🔇 Additional comments (31)
.github/actions/pnpm_install/action.yaml (1)

6-6: LGTM! Version bump aligns with root package.json.

The pnpm version update to 10.19.0 is consistent with the packageManager field in the root package.json.

apps/desktop/package.json (1)

39-39: LGTM! New dependency supports OpenRouter integration.

The addition of @openrouter/ai-sdk-provider enables the OpenRouter LLM provider functionality implemented in useLLMConnection.ts.

package.json (2)

2-2: LGTM! Package manager version bump is consistent.

The pnpm version update aligns with the GitHub Actions configuration change.


4-5: LGTM! Cosmetic reordering.

The swap in devDependencies order has no functional impact.

apps/desktop/src/components/settings/ai/shared/model-combobox.tsx (2)

195-195: Verify the keyword filter for potential false positives.

The filter excludes models containing "audio", "image", or "code" as substrings. While this likely achieves the intended goal, it could theoretically match unintended model IDs (e.g., a model named "advanced-coder" would be excluded).

Consider whether the filtering logic should be more specific (e.g., matching specific model families or checking against a known list) or if the current substring approach is sufficient for the OpenRouter/OpenAI model naming conventions.


208-208: Stricter tool parameter requirements.

The filter now requires both "tools" AND "tool_choice" in supported_parameters. This is more restrictive than the previous logic which only checked for "tools".

Ensure that this stricter requirement aligns with how the application invokes tool-enabled models. If the application always uses tool_choice, this change is appropriate. If tool_choice is optional, this may filter out valid models.

apps/desktop/src/hooks/useLLMConnection.ts (2)

2-4: LGTM! Provider imports added.

The new imports for OpenAI and OpenRouter providers are correctly added.


27-41: LGTM! Provider integrations follow consistent patterns.

The OpenRouter and OpenAI provider branches follow the same pattern as the existing Anthropic integration. Each creates a provider with the API key and returns a language model instance.

packages/tiptap/package.json (1)

39-39: LGTM! Markdown support added with consistent versioning.

The @tiptap/markdown dependency version ^3.7.2 matches all other TipTap extension versions in the package, ensuring compatibility.

apps/desktop/src/types/index.ts (2)

4-4: LGTM! Type import for AI task store.

The AITaskStore type import is correctly added to support the context extension.


11-11: LGTM! Context extended with AI task store.

The aiTaskStore field is added to the Context type, following the same pattern as the existing listenerStore field.

apps/desktop/src/main.tsx (3)

21-21: LGTM! AI task store factory imported.

The createAITaskStore import enables instantiation of the AI task store.


25-25: LGTM! AI task store instantiated.

The aiTaskStore is created following the same pattern as the listenerStore on line 24.


53-53: LGTM! AI task store wired into router context.

The aiTaskStore is correctly injected into the router context, completing the integration and making it available to all routes via the Context type.

apps/desktop/src/routes/app/main/_layout.tsx (1)

5-5: LGTM! Clean integration of AI task provider.

The null guard for aiTaskStore ensures safe rendering, and the provider correctly scopes AI task state within this layout.

Also applies to: 20-20, 56-68

apps/desktop/src/components/main/body/sessions/floating/index.tsx (1)

22-22: LGTM! Correct prop passing.

The sessionId prop correctly ties the generate action to the specific session, aligning with the updated GenerateButton signature.

packages/tiptap/src/editor/index.tsx (2)

55-57: Good UX improvement.

Adding autocapitalize="off" improves the editing experience by preventing unwanted auto-capitalization in note-taking contexts.


42-42: Clarify markdown content retrieval inconsistency.

The contentType: 'markdown' configuration controls how input is parsed, not what getHTML() returns—getHTML() always returns HTML. Lines 42, 49, and 52 show a potential inconsistency:

  • Editor is configured for markdown input with the Markdown extension
  • handleChange calls editor.getHTML(), which returns HTML

If markdown content retrieval is intended, use editor.getMarkdown() or editor.markdown.serialize() instead. If HTML output is intentional despite markdown mode, document this design decision and confirm the HTMLContent type signature aligns with the actual output format.

apps/desktop/src/contexts/ai-task/index.tsx (1)

1-42: LGTM! Well-implemented context pattern.

The provider correctly memoizes the store via useRef, and the useAITask hook properly applies shallow comparison for selector optimization. Clear error message enforces proper usage within the provider boundary.

apps/desktop/src/store/zustand/ai-task/index.ts (1)

1-15: LGTM! Clean store factory pattern.

The store composition is straightforward, correctly spreads the tasks slice, and type definitions are clear.

apps/desktop/src/components/main/body/sessions/note-input/enhanced/streaming.tsx (3)

59-82: LGTM! Well-implemented auto-scroll behavior.

The hook correctly identifies the scrollable parent and only auto-scrolls when the user is near the bottom (within 100px), preserving user control when they've scrolled up.


29-32: Follow coding guidelines for cn() usage.

The cn() call should receive an array per coding guidelines: "When using cn for Tailwind classNames, always pass an array."

As per coding guidelines.

Apply this diff:

-        className={cn([
-          "text-sm leading-relaxed",
-          "whitespace-pre-wrap break-words",
-        ])}
+        className={cn([
+          ["text-sm leading-relaxed"],
+          ["whitespace-pre-wrap break-words"],
+        ])}
⛔ Skipped due to learnings
Learnt from: CR
PR: fastrepl/hyprnote#0
File: apps/desktop/.cursor/rules/style.mdc:0-0
Timestamp: 2025-10-21T03:03:20.070Z
Learning: Applies to apps/desktop/**/*.{tsx,jsx} : When using `cn` for Tailwind classNames, always pass an array
Learnt from: CR
PR: fastrepl/hyprnote#0
File: apps/desktop/.cursor/rules/style.mdc:0-0
Timestamp: 2025-10-21T03:03:20.070Z
Learning: Applies to apps/desktop/**/*.{tsx,jsx} : When there are many Tailwind classNames with conditional logic, use the utility `cn` imported as `import { cn } from "hypr/utils"`
Learnt from: CR
PR: fastrepl/hyprnote#0
File: apps/desktop/.cursor/rules/style.mdc:0-0
Timestamp: 2025-10-21T03:03:20.070Z
Learning: Applies to apps/desktop/**/*.{tsx,jsx} : Group Tailwind classNames by logical sections when using `cn` (split array items by grouping)

46-50: Follow coding guidelines for cn() usage.

The cn() call should receive an array per coding guidelines, with logical grouping of className sections.

As per coding guidelines.

Apply this diff:

-        className={cn([
-          "flex items-center justify-center w-[calc(100%-24px)] gap-3",
-          "border border-neutral-200",
-          "bg-neutral-800 rounded-lg py-3",
-        ])}
+        className={cn([
+          ["flex items-center justify-center w-[calc(100%-24px)] gap-3"],
+          ["border border-neutral-200"],
+          ["bg-neutral-800 rounded-lg py-3"],
+        ])}
⛔ Skipped due to learnings
Learnt from: CR
PR: fastrepl/hyprnote#0
File: apps/desktop/.cursor/rules/style.mdc:0-0
Timestamp: 2025-10-21T03:03:20.070Z
Learning: Applies to apps/desktop/**/*.{tsx,jsx} : Group Tailwind classNames by logical sections when using `cn` (split array items by grouping)
Learnt from: CR
PR: fastrepl/hyprnote#0
File: apps/desktop/.cursor/rules/style.mdc:0-0
Timestamp: 2025-10-21T03:03:20.070Z
Learning: Applies to apps/desktop/**/*.{tsx,jsx} : When using `cn` for Tailwind classNames, always pass an array
Learnt from: CR
PR: fastrepl/hyprnote#0
File: apps/desktop/.cursor/rules/style.mdc:0-0
Timestamp: 2025-10-21T03:03:20.070Z
Learning: Applies to apps/desktop/**/*.{tsx,jsx} : When there are many Tailwind classNames with conditional logic, use the utility `cn` imported as `import { cn } from "hypr/utils"`
apps/desktop/src/components/main/body/sessions/note-input/enhanced/editor.tsx (1)

1-36: LGTM! Clean enhanced editor implementation.

The component correctly reads from and writes to the persisted store, properly forwards the editor ref, and includes a minimal but valid mention configuration.

apps/desktop/src/components/main/body/index.tsx (1)

272-293: LGTM! Clean API extension.

The floatingButton prop is properly typed and positioned, enabling session-specific floating actions while maintaining the existing TabChatButton behavior.

apps/desktop/src/components/main/body/sessions/note-input/enhanced/index.tsx (2)

14-21: Selector reads look solid

Derived object avoids Map identity pitfalls; good use of a narrow selector.


27-31: Streaming branch is appropriate

Clean separation: stream view while generating, editor otherwise.

apps/desktop/src/components/main/body/sessions/index.tsx (1)

56-67: Wrapper integration LGTM

floatingButton placement and flex layout changes look correct; no conditional className complexity here.

apps/desktop/src/contexts/ai-task/enhancing.ts (1)

1-75: Agent setup is coherent

Prompt, tool schema, and step orchestration look consistent. Biggest risk now is upstream callers not supplying the raw content (addressed in GenerateButton review).

If you want, I can add a quick unit harness to simulate a tool-invocation step with sample content to ensure sections are produced.

apps/desktop/src/components/main/body/sessions/note-input/index.tsx (1)

31-35: Auto-switch-on-generate is good

Ensures users see streaming when a task starts.

apps/desktop/src/components/main/body/sessions/floating/generate.tsx (1)

49-49: Expose generating state clearly

isGenerating derivation is correct and keeps template UI gated while running.

@coderabbitai
Copy link

coderabbitai bot commented Oct 24, 2025

✅ Actions performed

Reviews paused.

@yujonglee yujonglee merged commit 59a6eed into main Oct 24, 2025
5 checks passed
@yujonglee yujonglee deleted the got-enhancing-working-in-desktop2 branch October 24, 2025 08:10
@coderabbitai coderabbitai bot mentioned this pull request Oct 27, 2025
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.

2 participants