Skip to content

Commit 714e283

Browse files
committed
refactor: Validate lengths match
1 parent 48c4ea4 commit 714e283

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

vllm/model_executor/models/jina_embeddings_v4.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -326,8 +326,9 @@ def pooler(
326326

327327
# Validate lengths match
328328
if len(token_ids_list) != len(prompt_lens):
329-
logger.error(f"Mismatch: {len(token_ids_list)} sequences vs {len(prompt_lens)} lengths")
330-
return self._base_pooler(hidden_states, pooling_metadata)
329+
raise AssertionError(
330+
f"Mismatch: {len(token_ids_list)} sequences vs {len(prompt_lens)} lengths"
331+
)
331332

332333
# Apply pooling based on configured backend
333334
if self.pooling_backend == "triton":

0 commit comments

Comments
 (0)