Skip to content

A reactive notebook for Python — run reproducible experiments, query with SQL, execute as a script, deploy as an app, and version with git. Stored as pure Python. All in a modern, AI-native editor.

docs (ai completion): add instructions for Ollama (#5212)

Tobias Schweizer0f7fab9b3262
diff --git a/docs/guides/editor_features/ai_completion.md b/docs/guides/editor_features/ai_completion.md
index eb3205e50f..1b6b9834ce 100644
--- a/docs/guides/editor_features/ai_completion.md
+++ b/docs/guides/editor_features/ai_completion.md
@@ -264,13 +264,15 @@ Ollama allows you to run open-source LLMs on your local machine. To integrate Ol
!!! note "Port already in use"
If you get a "port already in use" error, you may need to close an existing Ollama instance. On Windows, click the up arrow in the taskbar, find the Ollama icon, and select "Quit". This is a known issue (see [Ollama Issue #3575](https://github.com/ollama/ollama/issues/3575)). Once you've closed the existing Ollama instance, you should be able to run `ollama serve` successfully.
-5. Open a new terminal and start marimo:
+5. Open a new terminal and install the openai client (e.g. `pip install openai`, `uv add openai`)
+
+6. Start marimo:
```bash
marimo edit notebook.py
```
-6. Add the following to your `marimo.toml` (or configure in the UI settings in the editor):
+7. Add the following to your `marimo.toml` (or configure in the UI settings in the editor):
```toml title="marimo.toml"
[ai.open_ai]