local M = {} M.opts = { api_url = "https://api.anthropic.com/v1/messages", border_style = "single", layout = { relative = "editor", position = { row = "50%", col = "50%", }, size = { width = "80%", height = "90%", }, }, token = nil, nerdfonts = false, } M.resources = { icons = { user = "User:", assistant = "Assistant:", }, spinner = { fps = 12, parts = { "⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏" }, }, } function M.setup(opts) M.opts = vim.tbl_deep_extend("force", M.opts, opts) if M.opts.nerdfonts then M.resources = { icons = { user = "", assistant = "󰚩", }, spinner = { fps = 25, parts = { "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", }, }, } end end return M