68 lines
2.5 KiB
Lua
68 lines
2.5 KiB
Lua
return {
|
|
'olimorris/codecompanion.nvim',
|
|
dependencies = {
|
|
'nvim-lua/plenary.nvim',
|
|
'nvim-treesitter/nvim-treesitter',
|
|
},
|
|
config = {
|
|
prompt_library = {
|
|
['prompt2prompt'] = {
|
|
strategy = 'chat',
|
|
description = 'a prompt to get the LLM to help you create a prompt',
|
|
prompts = {
|
|
{
|
|
role = 'system',
|
|
content = 'You are a prompt engineer that knows exactly how to prompt LLMs for them to be most effective and helpful',
|
|
},
|
|
{
|
|
role = 'user',
|
|
content = ' I would like you to help me craft the best possible to achieve my goal. The prompt will be used by you, the LLM. You will follow the following process: 1. Your first response will be to ask me what the prompt should be about. I will provide my answer, but we will need to improve it through continual iterations by going through the next steps. 2. Based on my input, you will generate 2 sections, a) Revised prompt (provide your rewritten prompt, it should be clear, concise, and easily understood by you), b) Questions (ask any relevant questions pertaining to what additional information is needed from me to improve the prompt). 3. We will continue this iterative process with me providing additional information to you and you updating the prompt in the Revised prompt section until I say we are done.',
|
|
},
|
|
},
|
|
},
|
|
},
|
|
adapters = {
|
|
llama3 = function()
|
|
return require('codecompanion.adapters').extend('ollama', {
|
|
name = 'llama3', -- Give this adapter a different name to differentiate it from the default ollama adapter
|
|
schema = {
|
|
model = {
|
|
default = 'llama3.1',
|
|
},
|
|
-- num_ctx = {
|
|
-- default = 16384,
|
|
-- },
|
|
-- num_predict = {
|
|
-- default = -1,
|
|
-- },
|
|
},
|
|
})
|
|
end,
|
|
deepseekr1 = function()
|
|
return require('codecompanion.adapters').extend('ollama', {
|
|
name = 'deepseekr1', -- Give this adapter a different name to differentiate it from the default ollama adapter
|
|
schema = {
|
|
model = {
|
|
default = 'deepseek-r1',
|
|
},
|
|
-- num_ctx = {
|
|
-- default = 16384,
|
|
-- },
|
|
-- num_predict = {
|
|
-- default = -1,
|
|
-- },
|
|
},
|
|
})
|
|
end,
|
|
},
|
|
strategies = {
|
|
chat = {
|
|
adapter = 'deepseekr1',
|
|
},
|
|
inline = {
|
|
adapter = 'deepseekr1',
|
|
},
|
|
},
|
|
},
|
|
}
|