Tiny fix eos handling for PD disaggregation (#12334)
Signed-off-by: Shangming Cai <csmthu@gmail.com>
This commit is contained in:
@@ -776,7 +776,7 @@ class DecodeTransferQueue:
|
|||||||
# special handling for corner cases
|
# special handling for corner cases
|
||||||
should_finish = (
|
should_finish = (
|
||||||
decode_req.req.sampling_params.max_new_tokens == 1
|
decode_req.req.sampling_params.max_new_tokens == 1
|
||||||
or output_id in decode_req.req.eos_token_ids
|
or decode_req.req.output_ids[-1] in decode_req.req.eos_token_ids
|
||||||
)
|
)
|
||||||
if should_finish:
|
if should_finish:
|
||||||
# finish immediately
|
# finish immediately
|
||||||
|
|||||||
Reference in New Issue
Block a user