File tree 1 file changed +6
-3
lines changed
1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -1201,13 +1201,16 @@ def _pull_args_from_config(args: List[str]) -> List[str]:
1201
1201
config_args = FlexibleArgumentParser ._load_config_file (file_path )
1202
1202
1203
1203
# 0th index is for {serve,chat,complete}
1204
- # followed by model_tag
1204
+ # followed by model_tag (only for serve)
1205
1205
# followed by config args
1206
1206
# followed by rest of cli args.
1207
1207
# maintaining this order will enforce the precedence
1208
1208
# of cli > config > defaults
1209
- args = [args [0 ]] + [args [1 ]] + config_args + \
1210
- args [2 :index ] + args [index + 2 :]
1209
+ if args [0 ] == "serve" :
1210
+ args = [args [0 ]] + [args [1 ]
1211
+ ] + config_args + args [2 :index ] + args [index + 2 :]
1212
+ else :
1213
+ args = [args [0 ]] + config_args + args [1 :index ] + args [index + 2 :]
1211
1214
1212
1215
return args
1213
1216
You can’t perform that action at this time.
0 commit comments