Skip to content

Add search_type support to issue search #4415

Description

@kelsey-myers

The search issues and pull requests endpoint documents a search_type query parameter:

The type of search to perform on issues. When not specified, the default is lexical search. semantic performs a pure semantic (vector) search using embedding-based understanding. hybrid combines semantic search with lexical search for best results. Only applies to issue searches (/search/issues). Can be one of: semantic, hybrid.

SearchOptions has no field for it, so Search.Issues can only do lexical search. The response for these searches also carries a top-level search_type, which IssuesSearchResult doesn't expose, so callers can't tell which engine actually ran (the API falls back to lexical when a query isn't eligible for semantic).

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

Opened #4414 with the change.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions