Skip to content
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

Add repetition_penalty and kwargs parameters to SamplingParams #174

Merged
merged 4 commits into from
Sep 11, 2024

Conversation

movchan74
Copy link
Contributor

@movchan74 movchan74 commented Sep 10, 2024

Summary:
This update introduces new parameters to the SamplingParams class, allowing for more flexible and customizable behavior when using vLLM and Hugging Face (HF) transformers based text generation deployments.

Key Changes:

  1. repetition_penalty Parameter: Added a new parameter, repetition_penalty that is supported by both vLLM and HF transformers.
  2. kwargs Parameter: Introduced kwargs to pass extra parameters that are not directly implemented in SamplingParams. These will be forwarded to the SamplingParams of vLLM and the generation parameters of HF transformers, enhancing flexibility.

Closes: #171

@movchan74 movchan74 self-assigned this Sep 10, 2024
@movchan74 movchan74 marked this pull request as ready for review September 10, 2024 14:16
Copy link
Contributor

@appoose appoose left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Checked it, this is good to go.

@movchan74 movchan74 merged commit 8cb6ac0 into main Sep 11, 2024
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

VLLM Sampling params
2 participants