User config precedence over GGUF metadata
This commit is contained in:
parent
8250d0149d
commit
3d1c0f173d
2 changed files with 13 additions and 11 deletions
|
@ -259,10 +259,8 @@ with Path(f'{args.model_dir}/config.yaml') as p:
|
|||
with Path(f'{args.model_dir}/config-user.yaml') as p:
|
||||
if p.exists():
|
||||
user_config = yaml.safe_load(open(p, 'r').read())
|
||||
for k in user_config:
|
||||
if k in model_config:
|
||||
model_config[k].update(user_config[k])
|
||||
else:
|
||||
model_config[k] = user_config[k]
|
||||
else:
|
||||
user_config = {}
|
||||
|
||||
model_config = OrderedDict(model_config)
|
||||
user_config = OrderedDict(user_config)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue