AI completion#
marimo comes with GitHub Copilot, a tool that helps you write code faster by suggesting in-line code suggestions based on the context of your current code.
marimo also comes with the ability to use AI for refactoring a cell, finishing writing a cell, or writing a full cell from scratch. This feature is currently experimental and is not enabled by default.
GitHub Copilot#
The marimo editor natively supports GitHub Copilot, an AI pair programmer, similar to VS Code.
Get started with Copilot:
Install Node.js.
Enable Copilot via the settings menu in the marimo editor.
Note: Copilot is not yet available in our conda distribution; please install
marimo using pip
if you need Copilot.
Using AI to modify cells#
This feature is currently experimental and is not enabled by default. To enable it:
You need add the following to your
~/.marimo.toml
:
[experimental]
ai = true
Add your OpenAI API key to your environment:
export OPENAI_API_KEY=your-api-key
Once enabled, you can use AI completion by pressing Ctrl/Cmd-Shift-e
in a cell. This will open an input to modify the cell using AI.