File tree 1 file changed +5
-1
lines changed
1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -44,7 +44,11 @@ def __init__(self, job):
44
44
self .max_batch_size = job .get ("max_batch_size" )
45
45
self .apply_chat_template = job .get ("apply_chat_template" , False )
46
46
self .use_openai_format = job .get ("use_openai_format" , False )
47
- self .sampling_params = SamplingParams (max_tokens = 100 , ** job .get ("sampling_params" , {}))
47
+ samp_param = job .get ("sampling_params" , {})
48
+ if "max_tokens" not in samp_param :
49
+ samp_param ["max_tokens" ] = 100
50
+ self .sampling_params = SamplingParams (** samp_param )
51
+ # self.sampling_params = SamplingParams(max_tokens=100, **job.get("sampling_params", {}))
48
52
self .request_id = random_uuid ()
49
53
batch_size_growth_factor = job .get ("batch_size_growth_factor" )
50
54
self .batch_size_growth_factor = float (batch_size_growth_factor ) if batch_size_growth_factor else None
You can’t perform that action at this time.
0 commit comments