return { "Lommix/ollamachad.nvim", enabled = false, config = function() --- this is the default, you do not need to call setup if you use the default endpoints require("ollamachad").setup({ generate_api_url = "https://box.ache.one:1080/ollama/api/generate", chat_api_url = "https://box.ache.one:1080/ollama/api/chat", keymap = { -- send prompt prompt = "", -- close chat close = "", -- clear chat clear = "", -- tab between prompt and chat tab = "", }, }) -- local chat = require("ollamachad.chat") local gen = require("ollamachad.generate") local util = require("ollamachad.util") -- rewrite selected text in visual mode vim.keymap.set("v", "cr", function() local instruction = "Improove the following text in its original language: " local request = { model = "mistral", prompt = instruction .. util.read_visiual_lines(), } gen.prompt(request) end, { silent = true, desc = "Rewrite the selected text" }) end, }