Skip to content

feat: Add search_type support to issue search - #4414

Open
kelsey-myers wants to merge 1 commit into
google:masterfrom
kelsey-myers:km/search-type-issue-search
Open

feat: Add search_type support to issue search#4414
kelsey-myers wants to merge 1 commit into
google:masterfrom
kelsey-myers:km/search-type-issue-search

Conversation

@kelsey-myers

@kelsey-myers kelsey-myers commented Jul 27, 2026

Copy link
Copy Markdown

Fixes #4415

The search issues and pull requests endpoint supports a search_type query parameter (semantic or hybrid, defaulting to lexical), and returns the type that actually ran in the response body. Neither is currently exposed, so Search.Issues can only do lexical search, and callers can't tell when the API has fallen back to lexical for an ineligible query.

Adds SearchType to SearchOptions (mirroring AdvancedSearch) and to IssuesSearchResult.

I'm updating the GitHub MCP server's search_issues tool to support semantic search, and we'd like to use these rather than wrapping the HTTP transport to rewrite the query string and re-parse the response body.

@kelsey-myers
kelsey-myers marked this pull request as ready for review July 27, 2026 20:57
@gmlewis gmlewis added the NeedsReview PR is awaiting a review before merging. label Jul 27, 2026
@gmlewis gmlewis changed the title feat: Add search_type support to issue search feat: Add search_type support to issue search Jul 27, 2026
@codecov

codecov Bot commented Jul 27, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.54%. Comparing base (0eab779) to head (7bdbd06).

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #4414   +/-   ##
=======================================
  Coverage   97.54%   97.54%           
=======================================
  Files         194      194           
  Lines       19765    19765           
=======================================
  Hits        19279    19279           
  Misses        268      268           
  Partials      218      218           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@gmlewis gmlewis left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thank you, @kelsey-myers!
LGTM.
Awaiting second LGTM+Approval from any other contributor to this repo before merging.

cc: @stevehipwell - @alexandear - @Not-Dhananjay-Mishra

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

NeedsReview PR is awaiting a review before merging.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add search_type support to issue search

2 participants