Lots of work still needed to be able to use the llm effectively. But its
a start
This commit is contained in:
parent
b17eac308a
commit
ba187eae92
30
after/plugin/llm.lua
Normal file
30
after/plugin/llm.lua
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
require("codecompanion").setup({
|
||||||
|
adapters = {
|
||||||
|
llama3_2 = function()
|
||||||
|
return require("codecompanion.adapters").extend("ollama", {
|
||||||
|
name = "llama3_2", -- Give this adapter a different name to differentiate it from the default ollama adapter
|
||||||
|
schema = {
|
||||||
|
model = {
|
||||||
|
default = "llama3.2:latest",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
})
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
strategies = {
|
||||||
|
chat = {
|
||||||
|
adapter= "llama3_2",
|
||||||
|
},
|
||||||
|
inline = {
|
||||||
|
adapter="llama3_2",
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
vim.api.nvim_set_keymap("v", "<leader>ce", "", {
|
||||||
|
callback = function()
|
||||||
|
require("codecompanion").prompt("explain")
|
||||||
|
end,
|
||||||
|
noremap = true,
|
||||||
|
silent = true,
|
||||||
|
})
|
@ -27,6 +27,7 @@ require("lazy").setup({
|
|||||||
},
|
},
|
||||||
{ "catppuccin/nvim", name = "catppuccin", priority = 1000 },
|
{ "catppuccin/nvim", name = "catppuccin", priority = 1000 },
|
||||||
{ "olimorris/onedarkpro.nvim", priority = 1000}, -- Ensure it loads first
|
{ "olimorris/onedarkpro.nvim", priority = 1000}, -- Ensure it loads first
|
||||||
|
{"olimorris/codecompanion.nvim"},
|
||||||
{ "zootedb0t/citruszest.nvim", lazy = false, priority = 1000, },
|
{ "zootedb0t/citruszest.nvim", lazy = false, priority = 1000, },
|
||||||
{'norcalli/nvim-colorizer.lua'},
|
{'norcalli/nvim-colorizer.lua'},
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user