feat: specific provider for auto-suggestions (#569)

This commit is contained in:
yetone
2024-09-12 14:23:00 +08:00
committed by GitHub
parent 8184275770
commit 0642905c80
4 changed files with 9 additions and 3 deletions

View File

@@ -33,6 +33,7 @@ local group = api.nvim_create_augroup("avante_llm", { clear = true })
---@field bufnr integer
---@field instructions string
---@field mode LlmMode
---@field provider AvanteProviderFunctor | nil
---@field on_chunk AvanteChunkParser
---@field on_complete AvanteCompleteParser
@@ -40,7 +41,7 @@ local group = api.nvim_create_augroup("avante_llm", { clear = true })
M.stream = function(opts)
local mode = opts.mode or "planning"
---@type AvanteProviderFunctor
local Provider = P[Config.provider]
local Provider = opts.provider or P[Config.provider]
-- Check if the instructions contains an image path
local image_paths = {}