Skip to content

Instantly share code, notes, and snippets.

@up1
Created September 7, 2025 06:42
Show Gist options
  • Save up1/c58f268482e7b2732d97ad0d7ccafadc to your computer and use it in GitHub Desktop.
Save up1/c58f268482e7b2732d97ad0d7ccafadc to your computer and use it in GitHub Desktop.
Elasticsearch :: Hybrid search
# Hybrid search
GET rag-langchain/_search
{
"retriever": {
"rrf": {
"retrievers": [
{
"standard": {
"query": {
"semantic": {
"field": "semantic_field",
"query": "Who won the Nobel Prize in Physics 2024?"
}
}
}
},
{
"standard": {
"query": {
"multi_match": {
"query": "Who won the Nobel Prize in Physics 2024?",
"fields": [
"text"
]
}
}
}
}
],
"rank_window_size": 50,
"rank_constant": 20
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment