@@ -288,24 +288,17 @@ describe("QwenWebExecutor (v2 migration)", () => {
288288 "registry must use v2 endpoint"
289289 ) ;
290290 const ids = provider . models . map ( ( m : any ) => m . id ) ;
291- assert . deepEqual ( ids . sort ( ) , [
292- "qwen3.6-plus" ,
293- "qwen3.7-max" ,
294- "qwen3.7-plus" ,
295- "qwen3.8-max-preview" ,
296- ] ) ;
297-
298- const qwen38 = provider . models . find (
299- ( model : RegistryModel ) => model . id === "qwen3.8-max-preview"
300- ) ;
291+ assert . deepEqual ( ids . sort ( ) , [ "qwen3.6-plus" , "qwen3.7-max" , "qwen3.7-plus" , "qwen3.8-max" ] ) ;
292+
293+ const qwen38 = provider . models . find ( ( model : RegistryModel ) => model . id === "qwen3.8-max" ) ;
301294 assert . deepEqual ( qwen38 , {
302- id : "qwen3.8-max-preview " ,
303- name : "Qwen3.8 Max Preview " ,
295+ id : "qwen3.8-max" ,
296+ name : "Qwen3.8 Max" ,
304297 toolCalling : false ,
305298 supportsReasoning : true ,
306299 supportsVision : true ,
307300 contextLength : 1_000_000 ,
308- maxOutputTokens : 65_536 ,
301+ maxOutputTokens : 131_072 ,
309302 } ) ;
310303
311304 const qwen37Max = provider . models . find ( ( model : RegistryModel ) => model . id === "qwen3.7-max" ) ;
@@ -315,7 +308,7 @@ describe("QwenWebExecutor (v2 migration)", () => {
315308 it ( "free-model catalog lists the current qwen-web ids (not the retired ones)" , ( ) => {
316309 const qwenModels = ( FREE_MODEL_BUDGETS as any [ ] ) . filter ( ( m ) => m . provider === "qwen-web" ) ;
317310 const ids = qwenModels . map ( ( m ) => m . modelId ) ;
318- assert . ok ( ids . includes ( "qwen3.8-max-preview " ) , "catalog must list qwen3.8-max-preview " ) ;
311+ assert . ok ( ids . includes ( "qwen3.8-max" ) , "catalog must list qwen3.8-max" ) ;
319312 assert . ok ( ids . includes ( "qwen3.7-max" ) , "catalog must list qwen3.7-max" ) ;
320313 assert . ok ( ! ids . includes ( "qwen-plus" ) , "retired qwen-plus must be gone" ) ;
321314 assert . ok (
@@ -324,7 +317,7 @@ describe("QwenWebExecutor (v2 migration)", () => {
324317 ) ;
325318 } ) ;
326319
327- it ( "passes qwen3.8-max- preview through unchanged " , async ( ) => {
320+ it ( "uses qwen3.8-max and maps its preview id for compatibility " , async ( ) => {
328321 globalThis . fetch = ( async ( url : string | URL | Request , init : RequestInit = { } ) => {
329322 calls . push ( { url : String ( url ) , init } ) ;
330323 if ( String ( url ) . includes ( "/api/v2/chats/new" ) ) return chatCreatedResponse ( ) ;
@@ -347,8 +340,8 @@ describe("QwenWebExecutor (v2 migration)", () => {
347340
348341 const newBody = JSON . parse ( calls [ 0 ] . init . body ) ;
349342 const completionBody = JSON . parse ( calls [ 1 ] . init . body ) ;
350- assert . deepEqual ( newBody . models , [ "qwen3.8-max-preview " ] ) ;
351- assert . equal ( completionBody . model , "qwen3.8-max-preview " ) ;
343+ assert . deepEqual ( newBody . models , [ "qwen3.8-max" ] ) ;
344+ assert . equal ( completionBody . model , "qwen3.8-max" ) ;
352345 assert . equal ( completionBody . messages [ 0 ] . feature_config . thinking_enabled , true ) ;
353346 assert . equal ( completionBody . messages [ 0 ] . feature_config . auto_thinking , true ) ;
354347 } ) ;
0 commit comments