File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -176,9 +176,9 @@ def sample_sonnet_requests(
176176 # Sample the rest of lines per request.
177177 sampled_requests : List [Tuple [str , int , int ]] = []
178178 for _ in range (num_requests ):
179- sampled_lines = "" . join (
180- prefix_lines +
181- random .sample (poem_lines , num_input_lines - num_prefix_lines ))
179+ num_lines_needed = num_input_lines - num_prefix_lines
180+ sampled_lines = "" . join ( prefix_lines +
181+ random .choices (poem_lines , k = num_lines_needed ))
182182
183183 prompt = f"{ base_prompt } { sampled_lines } "
184184 message = [
@@ -536,7 +536,7 @@ def process_one_metric(
536536 # E.g., "Time to First Token"
537537 metric_header : str ,
538538 ):
539- # This function print and add statistics of the specified
539+ # This function prints and adds statistics of the specified
540540 # metric.
541541 if metric_attribute_name not in selected_percentile_metrics :
542542 return
You can’t perform that action at this time.
0 commit comments