@@ -286,9 +286,9 @@ class Requests(BaseModel):
286286 @model_validator (mode = 'after' )
287287 def check_units (self ):
288288 if self .input_length .units not in units_quantity :
289- raise ValueError (f'Invalid units "{ self .input_length .units } ", must be one of: { ' ' .join (units_quantity )} ' )
289+ raise ValueError (f'Invalid units "{ self .input_length .units } ", must be one of: { " " .join (units_quantity )} ' )
290290 if self .output_length .units not in units_quantity :
291- raise ValueError (f'Invalid units "{ self .output_length .units } ", must be one of: { ' ' .join (units_quantity )} ' )
291+ raise ValueError (f'Invalid units "{ self .output_length .units } ", must be one of: { " " .join (units_quantity )} ' )
292292 return self
293293
294294
@@ -324,15 +324,15 @@ class Latency(BaseModel):
324324 @model_validator (mode = 'after' )
325325 def check_units (self ):
326326 if self .time_to_first_token .units not in units_time :
327- raise ValueError (f'Invalid units "{ self .time_to_first_token .units } ", must be one of: { ' ' .join (units_time )} ' )
327+ raise ValueError (f'Invalid units "{ self .time_to_first_token .units } ", must be one of: { " " .join (units_time )} ' )
328328 if self .normalized_time_per_output_token and self .normalized_time_per_output_token .units not in units_gen_latency :
329- raise ValueError (f'Invalid units "{ self .normalized_time_per_output_token .units } ", must be one of: { ' ' .join (units_gen_latency )} ' )
329+ raise ValueError (f'Invalid units "{ self .normalized_time_per_output_token .units } ", must be one of: { " " .join (units_gen_latency )} ' )
330330 if self .time_per_output_token and self .time_per_output_token .units not in units_gen_latency :
331- raise ValueError (f'Invalid units "{ self .time_per_output_token .units } ", must be one of: { ' ' .join (units_gen_latency )} ' )
331+ raise ValueError (f'Invalid units "{ self .time_per_output_token .units } ", must be one of: { " " .join (units_gen_latency )} ' )
332332 if self .inter_token_latency and self .inter_token_latency .units not in units_gen_latency :
333- raise ValueError (f'Invalid units "{ self .inter_token_latency .units } ", must be one of: { ' ' .join (units_gen_latency )} ' )
333+ raise ValueError (f'Invalid units "{ self .inter_token_latency .units } ", must be one of: { " " .join (units_gen_latency )} ' )
334334 if self .request_latency and self .request_latency .units not in units_time :
335- raise ValueError (f'Invalid units "{ self .request_latency .units } ", must be one of: { ' ' .join (units_time )} ' )
335+ raise ValueError (f'Invalid units "{ self .request_latency .units } ", must be one of: { " " .join (units_time )} ' )
336336 return self
337337
338338
@@ -355,11 +355,11 @@ class Service(BaseModel):
355355 @model_validator (mode = 'after' )
356356 def check_units (self ):
357357 if self .batch_size and self .batch_size .units not in units_quantity :
358- raise ValueError (f'Invalid units "{ self .batch_size .units } ", must be one of: { ' ' .join (units_quantity )} ' )
358+ raise ValueError (f'Invalid units "{ self .batch_size .units } ", must be one of: { " " .join (units_quantity )} ' )
359359 if self .queue_size and self .queue_size .units not in units_quantity :
360- raise ValueError (f'Invalid units "{ self .queue_size .units } ", must be one of: { ' ' .join (units_quantity )} ' )
360+ raise ValueError (f'Invalid units "{ self .queue_size .units } ", must be one of: { " " .join (units_quantity )} ' )
361361 if self .kv_cache_size and self .kv_cache_size .units not in units_quantity :
362- raise ValueError (f'Invalid units "{ self .kv_cache_size .units } ", must be one of: { ' ' .join (units_quantity )} ' )
362+ raise ValueError (f'Invalid units "{ self .kv_cache_size .units } ", must be one of: { " " .join (units_quantity )} ' )
363363 return self
364364
365365
@@ -373,11 +373,11 @@ class MemoryMetrics(BaseModel):
373373 @model_validator (mode = 'after' )
374374 def check_units (self ):
375375 if self .consumption and self .consumption .units not in units_memory :
376- raise ValueError (f'Invalid units "{ self .consumption .units } ", must be one of: { ' ' .join (units_memory )} ' )
376+ raise ValueError (f'Invalid units "{ self .consumption .units } ", must be one of: { " " .join (units_memory )} ' )
377377 if self .utilization and self .utilization .units not in units_portion :
378- raise ValueError (f'Invalid units "{ self .utilization .units } ", must be one of: { ' ' .join (units_portion )} ' )
378+ raise ValueError (f'Invalid units "{ self .utilization .units } ", must be one of: { " " .join (units_portion )} ' )
379379 if self .bandwidth and self .bandwidth .units not in units_bandwidth :
380- raise ValueError (f'Invalid units "{ self .bandwidth .units } ", must be one of: { ' ' .join (units_bandwidth )} ' )
380+ raise ValueError (f'Invalid units "{ self .bandwidth .units } ", must be one of: { " " .join (units_bandwidth )} ' )
381381 return self
382382
383383
@@ -389,7 +389,7 @@ class ComputeMetrics(BaseModel):
389389 @model_validator (mode = 'after' )
390390 def check_units (self ):
391391 if self .utilization .units not in units_portion :
392- raise ValueError (f'Invalid units "{ self .utilization .units } ", must be one of: { ' ' .join (units_portion )} ' )
392+ raise ValueError (f'Invalid units "{ self .utilization .units } ", must be one of: { " " .join (units_portion )} ' )
393393 return self
394394
395395
@@ -403,7 +403,7 @@ class AcceleratorMetrics(BaseModel):
403403 @model_validator (mode = 'after' )
404404 def check_units (self ):
405405 if self .power and self .power .units not in units_power :
406- raise ValueError (f'Invalid units "{ self .power .units } ", must be one of: { ' ' .join (units_power )} ' )
406+ raise ValueError (f'Invalid units "{ self .power .units } ", must be one of: { " " .join (units_power )} ' )
407407 return self
408408
409409
0 commit comments