Skip to content

Return log probabilities for tokens #238

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
yunfeng-scale opened this issue Nov 1, 2023 · 2 comments
Closed

Return log probabilities for tokens #238

yunfeng-scale opened this issue Nov 1, 2023 · 2 comments
Assignees
Labels
feature request New feature or request

Comments

@yunfeng-scale
Copy link

Hi, we'd like to have log probabilities for tokens returned from the model, in addition to the token ids. Can you help with this feature request?

@byshiue
Copy link
Collaborator

byshiue commented Nov 2, 2023

Here is a flag to output log probs of generated tokens https://github.com/NVIDIA/TensorRT-LLM/blob/main/tensorrt_llm/runtime/generation.py#L280. The log probs of input tokens are not supported now, it will be supported in near future.

@yunfeng-scale
Copy link
Author

yunfeng-scale commented Nov 2, 2023

@byshiue thanks. Possible to include in the C++ implementation too? https://github.com/NVIDIA/TensorRT-LLM/blob/main/cpp/include/tensorrt_llm/batch_manager/callbacks.h#L32 currently inflight batching is supported through C++ runtime

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
feature request New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants