codecompanion.nvim
Neovim (codecompanion)
The AI coding companion for Neovim. Add an openai_compatible adapter.
Step by step
01
Install codecompanion
Add 'olimorris/codecompanion.nvim' with your plugin manager.
02
Add the adapter
Put the Lua block below in your codecompanion setup.
03
Use it
:CodeCompanionChat and pick the LuxeChain adapter.
Copy this
neovim
-- codecompanion.nvim setup
require("codecompanion").setup({
adapters = {
luxechain = function()
return require("codecompanion.adapters").extend("openai_compatible", {
env = { api_key = "lxc_live_YOUR_KEY" },
schema = {
model = { default = "YOUR_MODEL_ID" }, -- any id from /models
url = { default = "https://api.luxechain.si/v1/chat/completions" },
},
})
end,
},
})
The adapter's url is the FULL chat-completions path, so it ends in /v1/chat/completions.