-
Notifications
You must be signed in to change notification settings - Fork 728
feat: Add logprobs support to TRTLLM backend #4759
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
👋 Hi esoba! Thank you for contributing to ai-dynamo/dynamo. Just a reminder: The 🚀 |
WalkthroughThe changes implement log-probability support across TRTLLM request handlers and test utilities. A new static helper method extracts logprob information from generated tokens, request option handling propagates logprobs configuration into sampling parameters, and test utilities add payload types and builders to validate logprobs in responses. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes
Poem
Pre-merge checks❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
/ok to test 111d0e8 |
|
@esoba please fix the failing precommit check: https://github.com/ai-dynamo/dynamo/actions/runs/19946850289/job/57198198828?pr=4759 - just some linting |
|
The code changes look good to me. But there are still some code formatting errors showing up pre-commit runs. |
|
Can you fix the conflict in |
724b973 to
19162c1
Compare
Signed-off-by: Elijah Soba <[email protected]>
19162c1 to
430f554
Compare
Overview:
Add logprobs extraction and propagation for TRTLLM backend
Details:
_extract_logprobs()method to extract and format logprobs from TRTLLM engine outputlog_probsandtop_logprobsto Dynamo's response formattop_logprobs=0edge case usingmax(1, logprobs)ChatPayloadWithLogprobsandCompletionPayloadWithLogprobstest utilitiesWhere should the reviewer start?
components/src/dynamo/trtllm/request_handlers/handler_base.py- main logprobs extraction logictests/serve/test_trtllm.py- new test configurationsRelated Issues: (use one of the action keywords Closes / Fixes / Resolves / Relates to)
Summary by CodeRabbit
New Features
Tests
✏️ Tip: You can customize this high-level summary in your review settings.