kvcache-ai / ktransformers

A Flexible Framework for Experiencing Cutting-edge LLM Inference Optimizations
Apache License 2.0
741 stars 39 forks source link

Fix: Wrong type of token list returned by prefill_and_generate #77

Closed TKONIY closed 1 month ago

TKONIY commented 2 months ago

Bug Report

The prefill_and_generate returns List[Tensor], which cannot be fed into tokenizer.decode. e.g., [Tensor[1], Tensor[2]]

Fix

Make it returns List[int], e.g., [1, 2]