Ipyai banner
AnswerDotAI AnswerDotAI

Ipyai

Development community

Description

A terminal IPython extension that adds Claude and Codex powered prompting

Installation

This entry records only its repository, not the path inside it, so there is no exact command to give. Open the source below and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

README

ipyai

`ipyai` is terminal IPython with an AI assistant on the same transcript. It is built on [teleprint](https://github.com/answerdotai/teleprint): code cells, outputs, AI replies, and images all print through to the terminal's own scrollback, with a status bar and input line repainted at the bottom. History stays native: scroll, search, and copy with your terminal or tmux as usual.

Install

pip install -e .

ipyai is a [rustygate](https://github.com/answerdotai/rustygate) client: a running local rustygate serves the kernels, like any Jupyter client setup. A plain launch creates a fresh kernel and shuts it down on exit; `ipyai -k PREFIX` attaches to an existing gateway kernel instead, taken as found and left running on exit.

Models

Models live in one flat namespace: a vendor-prefixed string such as `codex/gpt-5.6-terra` (the default), `anthropic/claude-sonnet-4-6`, or `claude_code/claude-sonnet-4-6`. The prefix carries the transport as well as the vendor: `claude_code/` drives your Claude Code subscription while `anthropic/` uses an API key, for the same model name. Switch mid-session with `%ipyai model NAME`.

Modes

ipyai has three modes, one per interpreter: `code` (the IPython kernel, the default), `prompt` (the AI), and `shell` (a persistent shell). `alt-c`/`alt-p`/`alt-s` pick a mode directly, and clicking the `[mode]` segment in the status bar cycles them. The composer mark shows where you are (`»»» `, `››› `, `$$$ `), and an empty input hints the keys for the other two modes. Start in prompt mode with `ipyai -p` or `"prompt_mode": true` in config.

A prefix overrides the mode for one submission, from anywhere: `.` sends a prompt, `;` runs code, a leading `!` runs shell. So in code mode:

.explain what this dataframe transform is doing

Each AI turn sends the session so far: executed cells with their outputs, notes, shell commands, and earlier prompts and replies. Inside a prompt, `` $`name` `` includes a live variabl