fix: provider inherited_from (#857)
This commit is contained in:
parent
dfc51b3247
commit
4acdcb6e8b
@ -273,7 +273,7 @@ M = setmetatable(M, {
|
||||
local ok, module = pcall(require, "avante.providers." .. Opts.__inherited_from)
|
||||
if not ok then error("Failed to load provider: " .. Opts.__inherited_from) end
|
||||
Opts._shellenv = module.api_key_name ~= M.AVANTE_INTERNAL_KEY and module.api_key_name or nil
|
||||
t[k] = vim.tbl_deep_extend("keep", BaseOpts, Opts, module)
|
||||
t[k] = vim.tbl_deep_extend("keep", Opts, BaseOpts, module)
|
||||
else
|
||||
t[k] = Opts
|
||||
end
|
||||
|
@ -135,6 +135,9 @@ M.parse_curl_args = function(provider, code_opts)
|
||||
body_opts.temperature = 1
|
||||
end
|
||||
|
||||
Utils.debug("endpoint", base.endpoint)
|
||||
Utils.debug("model", base.model)
|
||||
|
||||
return {
|
||||
url = Utils.url_join(base.endpoint, "/chat/completions"),
|
||||
proxy = base.proxy,
|
||||
|
Loading…
x
Reference in New Issue
Block a user