added ollama integration
This commit is contained in:
parent
5d5dcabad7
commit
96add0cf96
4 changed files with 47 additions and 24 deletions
32
lua/custom/plugins/ollama.lua
Normal file
32
lua/custom/plugins/ollama.lua
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
return {
|
||||
'nomnivore/ollama.nvim',
|
||||
dependencies = {
|
||||
'nvim-lua/plenary.nvim',
|
||||
},
|
||||
|
||||
-- All the user commands added by the plugin
|
||||
cmd = { 'Ollama', 'OllamaModel', 'OllamaServe', 'OllamaServeStop' },
|
||||
|
||||
keys = {
|
||||
-- Sample keybind for prompt menu. Note that the <c-u> is important for selections to work properly.
|
||||
{
|
||||
'<leader>oo',
|
||||
":<c-u>lua require('ollama').prompt()<cr>",
|
||||
desc = 'ollama prompt',
|
||||
mode = { 'n', 'v' },
|
||||
},
|
||||
|
||||
-- Sample keybind for direct prompting. Note that the <c-u> is important for selections to work properly.
|
||||
{
|
||||
'<leader>oG',
|
||||
":<c-u>lua require('ollama').prompt('Generate_Code')<cr>",
|
||||
desc = 'ollama Generate Code',
|
||||
mode = { 'n', 'v' },
|
||||
},
|
||||
},
|
||||
|
||||
---@type Ollama.Config
|
||||
opts = {
|
||||
-- your configuration overrides
|
||||
},
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue