copilotchat.lua (934B)
1 ---@diagnostic disable: undefined-global 2 return { 3 "CopilotC-Nvim/CopilotChat.nvim", 4 dependencies = { 5 "zbirenbaum/copilot.lua", 6 "nvim-lua/plenary.nvim", 7 }, 8 event = "VeryLazy", 9 build = "make tiktoken", 10 opts = { 11 model = "gpt-5.2", 12 window = { 13 layout = "horizontal", 14 width = 1, 15 height = 0.3, 16 title = "🤖 AI Assistant", 17 }, 18 headers = { 19 user = "👤 You", 20 assistant = "🤖 Copilot", 21 tool = "🔧 Tool", 22 }, 23 suggestion = { enabled = true }, 24 separator = "━━", 25 auto_fold = true, 26 }, 27 config = function(_, opts) 28 require("CopilotChat").setup(opts) 29 end, 30 keys = { 31 { 32 "<leader>ao", 33 function() 34 vim.cmd("CopilotChatOpen") 35 end, 36 desc = "CopilotChat - Activate", 37 }, 38 { 39 "<leader>ar", 40 function() 41 vim.cmd("CopilotChatReset") 42 end, 43 desc = "CopilotChat - Reset", 44 }, 45 }, 46 }