Add "Ask Duck.ai" action when selecting text - #9740
Open
joshliebe wants to merge 70 commits into
Open
Conversation
Contributor
Author
This stack of pull requests is managed by Graphite. Learn more about stacking. |
joshliebe
force-pushed
the
feature/josh/ask-duck-ai
branch
from
September 8, 2026 00:12
fc325f9 to
384f004
Compare
joshliebe
force-pushed
the
feature/josh/ask-duck-ai
branch
from
September 9, 2026 19:10
dc7f5f2 to
765c20b
Compare
Contributor
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 765c20b. Configure here.
This was referenced Sep 9, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Task/Issue URL: https://app.asana.com/1/137249556945/project/1200204095367872/task/1218242278110771?focus=true
Tech Design URL (if applicable): https://app.asana.com/1/137249556945/project/1200204095367872/task/1218282058361623
API Proposals URL(s) (if applicable): https://app.asana.com/1/137249556945/project/1200204095367872/task/1218270501055399
https://app.asana.com/1/137249556945/project/1200204095367872/task/1218282058361632
Description
PROCESS_TEXT.Steps to test this PR
From DDG
Summarize
Translation
Multiple selections
Duck.ai
From External (Firefox, Opera)
Disabled
UI changes
DuckDuckGo
Firefox
Attached
Note
Medium Risk
Touches browser launch intents, WebView action mode, and Duck.ai prompt payloads; gated behind remote feature flags but spans app and duckchat modules.
Overview
Adds "Ask Duck.ai" to the system text-selection flow so users can send highlighted text into Duck.ai from the browser and other apps via
PROCESS_TEXT.In-app WebView:
DuckDuckGoWebViewwraps the selection action mode so Ask Duck.ai appears as a primary action (hidden on Duck.ai pages). A feature-flaggedSelectedTextDuckAiActivityandTextSelectionTogglerregister or disable that handler.Navigation:
BrowserNav.openDuckChatandBrowserActivityintents now carry contextual vs full-tab Duck.ai plus optional text selection; contextual opens calllaunchContextualDuckAi, otherwise selections are stashed and passed into native Duck.ai input when the tab loads.Composer & chat: Per-tab
TextSelectionRepository(cap of 5) backs attachment chips in native input; submissions include aselectionsJSON array onsubmitAIChatNativePrompt. Contextual entry skips auto page-context when selections are present, shows selection-specific quick prompts, and hands selections through to the contextual sheet/webview.Reviewed by Cursor Bugbot for commit 99f7022. Bugbot is set up for automated code reviews on this repo. Configure here.