fix: allow HTTP query rerank control

This commit is contained in:
Tobi Lütke 2026-05-09 19:03:17 +00:00
parent 669e234d1e
commit e36ab96567
No known key found for this signature in database
2 changed files with 2 additions and 1 deletions

View File

@ -693,6 +693,7 @@ export async function startMcpHttpServer(
limit: params.limit ?? 10,
minScore: params.minScore ?? 0,
intent: params.intent,
rerank: params.rerank,
});
// Use first lex or vec query for snippet extraction

View File

@ -1567,7 +1567,7 @@ describe("mcp http daemon", () => {
const res = await fetch(`http://localhost:${port}/query`, {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({ searches: [{ type: "lex", query: "authentication" }], limit: 5 }),
body: JSON.stringify({ searches: [{ type: "lex", query: "authentication" }], limit: 5, rerank: false }),
});
expect(res.status).toBe(200);
const body = await res.json();