From f56abeaf5b7ba780ab238b175d98ca297340ca7f Mon Sep 17 00:00:00 2001 From: Taken Date: Wed, 6 Mar 2024 12:45:03 +0100 Subject: [PATCH] Added gen.nvim Signed-off-by: Taken --- lua/taken/plugins/gen.lua | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 lua/taken/plugins/gen.lua diff --git a/lua/taken/plugins/gen.lua b/lua/taken/plugins/gen.lua new file mode 100644 index 0000000..c1e0ade --- /dev/null +++ b/lua/taken/plugins/gen.lua @@ -0,0 +1,23 @@ +return { + "David-Kunz/gen.nvim", + cmd = "Gen", + opts = { + model = "llama2", + host = "localhost", + port = "11434", + display_mode = "float", + show_prompt = false, + show_model = true, + no_auto_close = false, + init = function(options) + pcall(io.popen, "ollama serve") + end, + command = function(options) + return "curl --silent --no-buffer -X POST http://" + .. options.host + .. ":" + .. options.port + .. "/api/chat -d $body" + end, + }, +}