Using completions

Augment’s code completions integrates with Vim and Neovim to give you autocomplete-like suggestions as you type. Completions are enable by default and you can use Tab to accept a suggestion.

CommandAction
TabAccept the current suggestion
:Augment enableGlobally enable suggestions (on by default)
:Augment disableGlobally disable suggestions

Customizing accepting a suggestion

If you want to use a key other than Tab to accept a suggestion, create a mapping that calls augment#Accept(). The function takes an optional arugment used to specify the fallback text to insert if no suggestion is available.

" Use Ctrl-Y to accept a suggestion
inoremap <c-y> <cmd>call augment#Accept()<cr>

" Use enter to accept a suggestion, falling back to a newline if no suggestion
" is available
inoremap <cr> <cmd>call augment#Accept("\n")<cr>

You can disable the default Tab mapping by setting g:augment_disable_tab_mapping = v:true before the plugin is loaded.

Using chat

Chat is a new way to work with your codebase using natural language. Use Chat to explore your codebase, quickly get up to speed on unfamiliar code, and get help working through a technical problem.

CommandAction
:Augment chat <message>Send a chat message to Augment
:Augment chat-newStart a new chat conversation
:Augment chat-toggleToggle the chat panel visibility

Sending a message

You can send a message to Chat using the :Augment chat command. You can send your message as an optional argument to the command or enter it into the command-line when prompted. Each new message will continue the current conversation which will be used as context for your next message.

Focusing on selected text

If you have text selected in visual mode, Augment will automatically include it in your message. This is useful for asking questions about specific code or requesting changes to the selected code.

Starting a new conversation

You can start a new conversation by using the :Augment chat-new command.

All available commands

CommandAction
:Augment enableGlobally enable suggestions (on by default)
:Augment disableGlobally disable suggestions
:Augment chat <message>Send a chat message to Augment
:Augment chat-newStart a new chat conversation
:Augment chat-toggleToggle the chat panel visibility
:Augment signinStart the sign in flow
:Augment signoutSign out of Augment
:Augment statusView the current status of the plugin
:Augment logView the plugin log