feat(llm): copilot (closes #68) (#116)

Signed-off-by: Aaron Pham <contact@aarnphm.xyz>
This commit is contained in:
Aaron Pham
2024-08-20 14:24:33 -04:00
committed by GitHub
parent 7c7fd6e315
commit 175eff5cac
4 changed files with 271 additions and 13 deletions

View File

@@ -9,7 +9,7 @@ M.defaults = {
debug = false,
---Currently, default supported providers include "claude", "openai", "azure", "deepseek", "groq"
---For custom provider, see README.md
---@alias Provider "openai" | "claude" | "azure" | "deepseek" | "groq" | string
---@alias Provider "openai" | "claude" | "azure" | "deepseek" | "groq" | "copilot" | string
provider = "claude",
---@type AvanteSupportedProvider
openai = {
@@ -19,6 +19,16 @@ M.defaults = {
max_tokens = 4096,
["local"] = false,
},
---@type AvanteCopilotProvider
copilot = {
endpoint = "https://api.githubcopilot.com",
model = "gpt-4o-2024-05-13",
proxy = nil, -- [protocol://]host[:port] Use this proxy
allow_insecure = false, -- Allow insecure server connections
timeout = 30000, -- Timeout in milliseconds
temperature = 0,
max_tokens = 8192,
},
---@type AvanteAzureProvider
azure = {
endpoint = "", -- example: "https://<your-resource-name>.openai.azure.com"