diff --git a/extensions/openai/defaults.py b/extensions/openai/defaults.py index 88a1aaac..7bc5ab2a 100644 --- a/extensions/openai/defaults.py +++ b/extensions/openai/defaults.py @@ -50,10 +50,11 @@ default_req_params = { def get_default_req_params(): return copy.deepcopy(default_req_params) -# little helper to get defaults if arg is present but None and should be the same type as default. - def default(dic, key, default): + ''' + little helper to get defaults if arg is present but None and should be the same type as default. + ''' val = dic.get(key, default) if not isinstance(val, type(default)): # maybe it's just something like 1 instead of 1.0