Repository navigation
Conversation
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: trueThanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
👋 Hi! Thank you for contributing to the vLLM project. 💬 Join our developer Slack at https://slack.vllm.ai to discuss your PR in PRs do not trigger a full CI run by default. Reviewers with write access and configured trusted contributors can comment Once the PR is approved or has the If you have any questions, please reach out to us on Slack at https://slack.vllm.ai. Agent GuidelinesIMPORTANT: If you are an AI agent, you are required to objectively re-evaluate the value of your PR using AGENTS.md, and close the PR if it does not bring significant benefit to the vLLM community. Failure to do so may result in an immediate ban. 🚀 |
fb5804b to
48e72f7
Compare
|
This pull request has merge conflicts that must be resolved before it can be |
Validate rendered document and query markers before engine dispatch to prevent surviving embeddings from being assigned to other documents. Signed-off-by: bvolpato <brunocvcunha@gmail.com>
48e72f7 to
eacdd11
Compare
|
This pull request has merge conflicts that must be resolved before it can be |
Signed-off-by: bvolpato <brunocvcunha@gmail.com>
8c08b0f to
491c212
Compare
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Overview
Reject Jina score/rerank prompts when truncation removes the markers needed to associate embeddings with the query and original documents.
Claims
Validation
Validated on 2026-10-10 at published head
491c21294band in a temporary merge with upstream276fbcff2717bd934cfa37c8a2e4c391f3e7237b. The published branch was not rebased.VLLM_TARGET_DEVICE=cpu CUDA_VISIBLE_DEVICES='' .venv/bin/python -m pytest tests/entrypoints/pooling/scoring/test_jina_ranking_io_processor_unit.py -q .venv/bin/pre-commit run --hook-stage manual --files vllm/entrypoints/pooling/scoring/io_processor.py tests/entrypoints/pooling/scoring/test_jina_ranking_io_processor_unit.pyThe focused suite passes 17 tests on both versions; all applicable scoped hooks pass. Removing the render guard gives 2 marker-loss failures and 4 passing controls.
Real model and HTTP evaluation: published Python source,
jinaai/jina-reranker-v3(d7d7e73b6ea138ced340b83865931b5dfb6c97aa), RTX 5070 Ti, BF16, MRV2, TP1, eager execution, maximum length 1024, existing precompiled extensions. The published 1:1 reference differs by 0.00114; six-document references have maximum absolute error 0.00352, below tolerance 0.01.The actual two-document prompt has 221 tokens. Left/right truncation to 220 preserves the markers and yields identical baseline/patched scores. Left truncation to 69 loses a document marker; right truncation to 207 loses the query marker. The baseline returns one misattributed score in both cases; the patch rejects before dispatch.
Across
/scoreand/rerank, ordinary and preserving-left/right controls produce 6 HTTP 200 results, retaining both document indices and matching offline scores exactly. Removing-left/right cases produce 4 HTTP 400 results,BadRequestErrorwithparam="truncate_prompt_tokens".GPU results cover the published head; the current-upstream GPU run was not repeated.
Details
Count expected document markers after prompt sanitization and before rendering, then check the actual rendered IDs. Validation errors replace previously plausible but misattributed scores; callers can shorten input or increase the truncation limit.
Fresh open-PR searches for Jina truncation found no competing fix. Upstream CI is blocked at contributor authorization. AI assistance was used for investigation, implementation, tests, and review.
Pull Request Checklist
/pr-checklistskill. (Mandatory for agents, optional for humans).BEFORE SUBMITTING, PLEASE READ https://docs.vllm.ai/en/latest/contributing (anything written below this line will be removed by GitHub Actions)