refactor: add openai to avante

This commit is contained in:
Dinesh Salunke 2025-04-20 13:26:37 +05:30
parent 6184d4d42d
commit d0b0d60d6f

View File

@ -3,10 +3,18 @@ return {
"yetone/avante.nvim",
event = "VeryLazy",
version = false, -- Never set this value to "*"! Never!
enabled = true,
opts = {
-- add any opts here
-- for example
provider = "deepseek",
provider = "openai",
openai = {
endpoint = "https://api.openai.com/v1",
model = "gpt-4o-mini", -- your desired model (or use gpt-4o, etc.)
timeout = 30000, -- Timeout in milliseconds, increase this for reasoning models
temperature = 0,
max_completion_tokens = 8192, -- Increase this to include reasoning tokens (for reasoning models)
--reasoning_effort = "medium", -- low|medium|high, only used for reasoning models
},
ollama = {
model = "codellama",
endpoint = "http://127.0.0.1:11434",
@ -23,6 +31,14 @@ return {
endpoint = "https://agent-mql2w66kzgoopio7n6mt5n4x-h8fzy.ondigitalocean.app/api/v1/",
api_key_name = "DO_GEN_AI_API_KEY",
model = "deepseek-r1-distill-llama-70b",
temperature = 0.5,
},
llama31 = {
__inherited_from = "openai",
endpoint = "https://agent-mql2w66kzgoopio7n6mt5n4x-h8fzy.ondigitalocean.app/api/v1/",
api_key_name = "DO_GEN_AI_API_KEY",
model = "llama3.3-instruct",
temperature = 0.5,
},
},
mappings = {