sglang
sglang copied to clipboard
Max Length.
Is there anyway to truncate text based on tokens? I really like that as a user I don't need to think about tokens. But to save memory I would like something like
s += left_trunc(inp, 500) that keeps it reasonably sized.
After this line s += left_trunc(inp, 500), do you mean inp <= 500 or s + inp <= 500?
Either one should be easy to implement!
I was thinking inp <=500 tokens.
This issue has been automatically closed due to inactivity. Please feel free to reopen it if needed.