From: Stefan Huber <shuber@sthu.org> Date: Sun, 8 Dec 2024 14:29:07 +0000 (+0100) Subject: plugins: Add googleai and gemini to gp X-Git-Url: https://git.sthu.org/?a=commitdiff_plain;h=77ea821e31f22ae13fef3e245ef0c4a5786a57d8;p=vimconf.git plugins: Add googleai and gemini to gp --- diff --git a/plugins-full.vim.example b/plugins-full.vim.example index 3fbb226..40e35a7 100644 --- a/plugins-full.vim.example +++ b/plugins-full.vim.example @@ -189,8 +189,36 @@ function PluginsConfigFull() "-c", "cat ~/.config/github-copilot/apps.json | sed -e 's/.*oauth_token...//;s/\".*//'", }, - } - } + }, + googleai = { + -- disable = true, + endpoint = "https://generativelanguage.googleapis.com/v1beta/models/{{model}}:streamGenerateContent?key={{secret}}", + secret = os.getenv("GOOGLEAI_API_KEY"), + }, + }, + agents = { + { + provider = "copilot", + name = "ChatCopilot", + chat = true, + command = false, + -- string with model name or table with model name and parameters + model = { model = "gpt-4o", temperature = 1.1, top_p = 1 }, + -- system prompt (use this to specify the persona/role of the AI) + system_prompt = require("gp.defaults").chat_system_prompt, + }, + { + provider = "googleai", + name = "ChatGemini", + chat = true, + command = false, + -- string with model name or table with model name and parameters + model = { model = "gemini-pro", temperature = 1.1, top_p = 1 }, + -- system prompt (use this to specify the persona/role of the AI) + system_prompt = require("gp.defaults").chat_system_prompt, + }, + + }, }) vim.api.nvim_create_user_command("Calculate", "lua require(\"calculator\").calculate()",