fix(llm): reject unsupported RL fields for responses - #11253
Conversation
Signed-off-by: jthomson04 <jwillthomson19@gmail.com>
|
changes lgtm |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (1)
WalkthroughAdds a validation guard in ChangesResponses API nvext Validation
Estimated code review effort: 2 (Simple) | ~10 minutes Related Issues: None mentioned in the provided context. Related PRs: None mentioned in the provided context. Suggested labels: area/http-service, testing Suggested reviewers: None specified in the provided context. 🐰 A field slips in where it shouldn't be, 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Comment |
Summary
completion_token_idsandprompt_logprobswhen requested throughnvext.extra_fieldson/v1/responsesnvextfields unchangedRoot cause
Responses requests are converted to the Chat Completions protocol internally. The non-streaming conversion copied the resulting chat response
nvextverbatim, while the Responses streaming converter did not expose those fields. This unintentionally made the RL fields available only on the non-streaming Responses path.Linear: https://linear.app/nvidia/issue/DYN-3392
Validation
cargo fmt --all -- --checkcargo test -p dynamo-llm test_validate_unsupported_fields --lib(8 passed)cargo test -p dynamo-llm protocols::openai --lib(207 passed)cargo clippy -p dynamo-llm --lib -- -D warningsSummary by CodeRabbit
501 Not Implementederror when unsupportednvext.extra_fieldsvalues are included.completion_token_idsorprompt_logprobsare now consistently rejected, while supportednvextfields continue to work as expected.