feat: add Exa AI-powered search tool#3
Open
tgonzalezc5 wants to merge 3 commits into
Open
Conversation
Add ExaSearchBackend as a new search engine alongside BoCha and DuckDuckGo. Exa provides AI-powered web search with content extraction. - Add ExaSearchBackend with web search and news search (via category) - Wire into AISearch auto-fallback chain: BoCha -> Exa -> DuckDuckGo - Support search types (auto, neural, fast, instant, deep variants), content modes (highlights, text, summary), category/domain/text filtering, and date ranges - Set x-exa-integration tracking header for usage attribution - Add exa-py>=2.0.0 to pyproject.toml dependencies
2d39313 to
621944b
Compare
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
ExaSearchBackendas a new search engine option alongside BoCha and DuckDuckGoAISearchauto-fallback chain (BoCha -> Exa -> DuckDuckGo)auto,neural,fast,instant,deepvariants), content modes (highlights,text,summary), category/domain/text filtering, and date rangesx-exa-integration: alphoratracking header for API usage attributionexa-py>=2.0.0topyproject.tomldependenciesUsage
Set
EXA_API_KEYenvironment variable to use Exa without passing the key explicitly.Files Changed
alphora/tools/builtin/web_search.py: AddExaSearchBackendclass, updateSearchEngineenum, wire intoAISearchandWebSearcherpyproject.toml: Addexa-py>=2.0.0dependencyTest Plan
ExaSearchBackend.search_web()returns validSearchResponsewith highlightsExaSearchBackend.search_news()usescategory="news"correctlyengine="exa"routes to_search_exa()inAISearchEXA_API_KEYreturns descriptive error messagex-exa-integration: alphoraheader is set on client