Skip to content

Rebuild the backend on Qdrant Cloud Inference, drop Railway - #35

Open
jkupchanko wants to merge 2 commits into
masterfrom
cloud-inference
Open

Rebuild the backend on Qdrant Cloud Inference, drop Railway#35
jkupchanko wants to merge 2 commits into
masterfrom
cloud-inference

Conversation

@jkupchanko

Copy link
Copy Markdown
Contributor

PREVIEW: https://demo-code-search-git-cloud-inference-qdrant.vercel.app

Moving this over from qdrant-labs so it's reviewed here.

Same branch and same commits, nothing new.

@kanungle can you merge when you get a chance?

John Kupchanko added 2 commits September 2, 2026 12:14
Railway existed only so the backend could load UniXcoder and embed the query
itself. Qdrant Cloud Inference does that inside the cluster, so the query goes
out as text and comes back ranked, and the backend is three TypeScript
functions with no dependencies in the same Vercel project as the frontend.
Gone with it: the Dockerfile, docker-compose.yaml, railway.json,
requirements.txt and the whole code_search package.

UniXcoder is not in the Cloud Inference catalog and cannot be added, so this
forced replacing the encoder. bench/bakeoff.py scores ten configurations
through the real production path; mxbai-embed-large-v1 with BM25 fused by RRF
won. SPLADE matches BM25 on docstring queries, loses on paraphrases and runs
three times slower. DBSF fusion was tried and rejected.

One fix is unrelated to the migration and is the largest single win here. The
merge step sorted results by how many overlapping snippet ranges each one had,
so a result with two highlighted ranges outranked the actual best match with
none. Removing that took docstring recall@1 from 0.620 to 0.887. It is
inherited behaviour: measured directly the old demo's own search scores 0.730
while its deployment returns 0.567.

Against the previous deployment on the same 413 queries: docstring recall@1
0.567 to 0.883, MRR 0.713 to 0.928, p50 178ms to 148ms, cold start 2033ms to
775ms. p95 is worse, 186ms to 205ms, and 46ms of that spread is the dense
model's inference call against 1.4ms for the BM25 leg.

The frontend is unchanged apart from wording that named the old encoders. The
CSS file is byte-identical, the per-result JSON keys are identical, and the
corpus and indexed commit are the same, so every result link resolves to the
same code.
Six deprecation warnings in the Vercel build log and eight npm audit
vulnerabilities, several high. Inherited, but visible to anyone reading a build.

eslint 8 is end of life and pulled in five of the six deprecations, so this
moves to eslint 10 and flat config. vite 5 to 8, react-router-dom 6 to 7,
postcss-preset-mantine 1.6 to 1.18. @mantine/core stays at 7.1.0 because it
renders the approved design.

Zero deprecations on a clean install, zero vulnerabilities.

The newer react-hooks plugin flagged two real patterns, both fixed rather than
silenced: useTypewriter set state synchronously in an effect, and the search
field built its Enter handler during render. Build, lint, typecheck and tests
pass, the page renders unchanged, and Enter still runs a search.
@kanungle

kanungle commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

@jkupchanko can you give me a link to the qdrant.tech domain?

@kanungle
kanungle self-requested a review September 3, 2026 22:41

@kanungle kanungle left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Doesn't work

@kanungle

kanungle commented Sep 3, 2026

Copy link
Copy Markdown
Contributor
Screenshot 2026-09-03 at 3 41 31 PM

@jkupchanko

jkupchanko commented Sep 4, 2026

Copy link
Copy Markdown
Contributor Author

PREVIEW: https://demo-code-search-p0rf5hqvh-qdrant.vercel.app/?query=cardinality+of+should+request

Fixed.

The preview build had no Qdrant credentials, which is why search errored.

They're set for Production and Preview now, and this rebuild works.

Ready to merge when you are.

@kanungle
kanungle requested a review from Dylancouzon September 9, 2026 19:14

@Dylancouzon Dylancouzon left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

lgtm

@kanungle
kanungle self-requested a review September 10, 2026 03:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants