feat: add Tavily as configurable web search provider in extension#23
Open
tavily-integrations wants to merge 1 commit intoOpenBrowserAI:mainfrom
Open
Conversation
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.
Summary
Adds Tavily as a configurable web search provider alongside the existing Exa AI option in the Chrome extension's Options UI and background chat service.
What changed and why
packages/core/src/service/tavily-search.ts): A static service class that calls the Tavily Search REST API viafetch, following the same pattern asExaSearchService. Returns formatted search results optimized for LLM consumption.chromium-extension/src/options/index.tsx): Added a provider radio group (Exa AI / Tavily) shown when web search is enabled. Selecting Tavily shows a required Tavily API Key input; selecting Exa shows the existing optional Exa API Key input. ThewebSearchConfigChrome storage schema now includesproviderandtavilyApiKeyfields.chromium-extension/src/background/agent/chat-service.ts):SimpleChatServicenow reads theproviderandtavilyApiKeyfields fromwebSearchConfigand routeswebsearchImpl()toTavilySearchServicewhen provider is'tavily', falling back toExaSearchServicefor'exa'or when provider is unset (backwards-compatible default).packages/core/src/service/index.ts,packages/core/src/index.ts):TavilySearchServiceis exported from@openbrowser-ai/core.Files changed
packages/core/src/service/tavily-search.ts(new)packages/core/src/service/index.tspackages/core/src/index.tschromium-extension/src/options/index.tsxchromium-extension/src/background/agent/chat-service.tsDependency / env changes
fetchAPI directly (same as ExaSearchService)tavilyApiKeyandproviderfields added to thewebSearchConfigChrome storage object (user-entered via Options UI)Notes for reviewers
'exa'when absent in storage, preserving backwards compatibilityAutomated Review