ollama settings

This commit is contained in:
m3tam3re 2024-06-04 12:41:36 +02:00
parent 9c79f4672b
commit d581be532d

View File

@ -850,6 +850,20 @@ require('lazy').setup({
-- list_models = '<omitted lua function>', -- Retrieves a list of model names -- list_models = '<omitted lua function>', -- Retrieves a list of model names
debug = false, -- Prints errors and the command which is run. debug = false, -- Prints errors and the command which is run.
}, },
config = function()
require('gen').prompts['Fix_Code'] = {
prompt = 'Fix the following code. Only ouput the result in format ```$filetype\n...\n```:\n```$filetype\n$text\n```',
replace = true,
extract = '```$filetype\n(.-)```',
model = 'codellama:latest',
}
require('gen').prompts['Enhance_Code'] = {
prompt = 'Fix the following code. Only ouput the result in format ```$filetype\n...\n```:\n```$filetype\n$text\n```',
replace = true,
extract = '```$filetype\n(.-)```',
model = 'codellama:latest',
}
end,
vim.keymap.set('n', '<leader>lo', vim.cmd.Gen, { desc = '[O]llama AI' }), vim.keymap.set('n', '<leader>lo', vim.cmd.Gen, { desc = '[O]llama AI' }),
}, },
{ {