Added mcphub
This commit is contained in:
@@ -12,6 +12,7 @@ return {
|
||||
"nvim-telescope/telescope.nvim",
|
||||
"nvim-tree/nvim-web-devicons",
|
||||
"zbirenbaum/copilot.lua",
|
||||
"ravitemer/mcphub.nvim",
|
||||
},
|
||||
config = function()
|
||||
require("avante").setup({
|
||||
@@ -23,6 +24,15 @@ return {
|
||||
temperature = 0,
|
||||
max_tokens = 8192,
|
||||
},
|
||||
system_prompt = function()
|
||||
local hub = require("mcphub").get_hub_instance()
|
||||
return hub:get_active_servers_prompt()
|
||||
end,
|
||||
custom_tools = function()
|
||||
return {
|
||||
require("mcphub.extensions.avante").mcp_tool(),
|
||||
}
|
||||
end,
|
||||
})
|
||||
end,
|
||||
}
|
||||
|
||||
27
lua/taken/plugins/mcphub.lua
Normal file
27
lua/taken/plugins/mcphub.lua
Normal file
@@ -0,0 +1,27 @@
|
||||
--- @type LazyPluginSpec
|
||||
return {
|
||||
"ravitemer/mcphub.nvim",
|
||||
dependencies = {
|
||||
"nvim-lua/plenary.nvim",
|
||||
},
|
||||
cmd = "MCPHub",
|
||||
-- build = "npm install -g mcp-hub@latest",
|
||||
build = "bundled_build.lua",
|
||||
init = function()
|
||||
local mcphublocation = vim.fn.expand("~/.config/mcphub")
|
||||
|
||||
if vim.fn.isdirectory(mcphublocation) == 0 then
|
||||
vim.fn.system("mkdir -p " .. mcphublocation)
|
||||
end
|
||||
end,
|
||||
config = function()
|
||||
require("mcphub").setup({
|
||||
extensions = {
|
||||
avante = {
|
||||
make_slash_commands = true,
|
||||
},
|
||||
},
|
||||
use_bundled_binary = true,
|
||||
})
|
||||
end,
|
||||
}
|
||||
Reference in New Issue
Block a user