@@ -112,6 +112,13 @@ class TestSettings(BaseModel):
112112 ),
113113 ] = timedelta (seconds = 5 )
114114
115+ use_token_latencies : Annotated [
116+ bool ,
117+ Field (
118+ description = "When set to True, LoadGen will track TTFT and TPOT." ,
119+ ),
120+ ] = True
121+
115122 @field_validator ("min_duration" , mode = "before" )
116123 @classmethod
117124 def parse_min_duration (cls , value : timedelta | float | str ) -> timedelta | str :
@@ -136,9 +143,8 @@ def to_lgtype(self) -> lg.TestSettings:
136143 settings .scenario = self .scenario .to_lgtype ()
137144 settings .mode = self .mode .to_lgtype ()
138145 settings .offline_expected_qps = self .offline_expected_qps
139- settings .min_duration_ms = round (
140- self .min_duration .total_seconds () * 1000 )
141- settings .use_token_latencies = True
146+ settings .min_duration_ms = round (self .min_duration .total_seconds () * 1000 )
147+ settings .use_token_latencies = self .use_token_latencies
142148 return settings
143149
144150
@@ -222,9 +228,7 @@ def main(
222228 logger .info ("Running VL2L benchmark with settings: {}" , settings )
223229 logger .info ("Running VL2L benchmark with model: {}" , model )
224230 logger .info ("Running VL2L benchmark with dataset: {}" , dataset )
225- logger .info (
226- "Running VL2L benchmark with OpenAI API endpoint: {}" ,
227- endpoint )
231+ logger .info ("Running VL2L benchmark with OpenAI API endpoint: {}" , endpoint )
228232 logger .info ("Running VL2L benchmark with random seed: {}" , random_seed )
229233 lg_settings = settings .to_lgtype ()
230234 task = ShopifyGlobalCatalogue (
0 commit comments