Skip to main content

Paimon

Paimon

English | 简体中文

Paimon is a coding agent that lives in your terminal. It reads and edits files in the current directory and runs commands, asking before it touches anything. It also runs headless, so a stronger agent can drive it as a worker.

Install

uv tool install paimon   # or: pip install paimon

Getting started

paimon

Or run it without installing anything:

uvx paimon

The first launch asks for a provider, model, API base and key, and saves them to ~/.config/paimon/default/config.json. Then just type what you want done.

While it runs: Shift+Tab switches how much the agent may do on its own (read: ask before writing files or running commands, except clearly read-only ones like ls or git status, which run without asking, edit: edits inside the working directory go through, yolo: never ask; the default), Esc interrupts the current turn, Ctrl+P opens the command palette (switch provider or profile, new, fork or resume session, show the model's thinking, compact the context), Ctrl+C quits.

Ctrl+T opens another session in a pane of its own, Ctrl+W closes one, Ctrl+PageUp and Ctrl+PageDown move between them, and Ctrl+G jumps to a pane waiting for permission.

Paimon can open panes itself: ask for two independent things and it starts a second agent in its own tab, with the same tools, working directory and permission mode. Its permission prompts appear in that tab, so Ctrl+G is how you unblock it. Those sessions belong to the one that started them, so they stay out of paimon sessions and end when it does.

It can also leave a command running in a tab of its own, for a dev server, a watcher or a long build that would otherwise hold up a turn. It asks first, every time, whatever the mode says about read-only commands. The tab streams the output and stops the command when you close it or quit. Programs that buffer their output when it is not going to a terminal print in blocks there rather than line by line; that is what a pipe costs, and Paimon does not emulate a terminal.

Write @path/to/file in a prompt to hand a file to the agent.

Using Paimon as a subagent

Frontier models are good at planning and reviewing; the steps in between are often mechanical. Point Paimon at a cheaper model, let Claude Code or Codex write the plan and check the result, and pay frontier prices only for the parts that need them. A profile keeps that model's account separate:

paimon login --profile glm --model zai:glm-4.7 --api-key-env ZAI_API_KEY
paimon --profile glm -p "apply the plan in PLAN.md" --mode edit --output-format result

The bundled skill teaches the calling agent this workflow (check paimon status --json, run one-shot, read the single result object, resume its session_id, inspect what a run did with paimon log):

paimon install-skill                  # into Claude Code (~/.claude/skills/paimon)
paimon install-skill --target codex   # into Codex; --dest DIR for anywhere else
npx skills add aisk/paimon            # the same skill, via skills.sh

Sessions

Every conversation is saved. Paimon prints the command that brings one back when you leave:

paimon -r            # choose a session started in this directory
paimon -r a1b2c3     # resume one by id
paimon -c            # resume the most recent one
paimon sessions      # list them (--json for machines)
paimon log a1b2c3    # what a session did, one line per event

paimon log prefixes every line with a stable seq number; --after SEQ, --turns N and --tail N narrow the window, --json and --full give the raw records.

Other ways to run it

paimon --mode read                  # start in a more cautious permission mode (yolo is the default)
paimon --strict                     # ask before every command, even read-only ones
paimon --web                        # the same UI in a browser (--port, default 8000)
paimon -p "what does cli.py do?"    # one answer on stdout, no UI
cat log.txt | paimon -p "summarize this"
paimon --model zai:glm-4.7          # this model for this run only
paimon --profile work               # a separately configured account

-p never stops to ask, and the default mode is yolo, so it can already write files and run commands; pass --mode read or --mode edit to keep the guardrails, in which case anything the mode would prompt for is refused instead (recognized read-only commands still run in read mode). Add --output-format result for a single JSON object with the outcome (or json for one event per line), and --timeout/--max-tool-calls to bound an unattended run.

Configuration

~/.config/paimon/<name>/config.json holds each profile's model settings (default unless --profile says otherwise). Two optional keys change how it behaves: auto-allowing read-only commands, and summarizing long conversations in place near the context limit.

{
  "safe_commands": false,
  "compaction": {
    "enabled": true,
    "context_window": 128000,
    "reserve_tokens": 16384,
    "keep_recent_tokens": 20000
  }
}

safe_commands (default true) lets read and edit modes run a small fixed set of clearly read-only commands (ls, cat, git status, …) without asking; --strict turns it off for one run. Recognized commands may be chained with &&, ; or pipes, including cd dir && … when the directory stays inside the working directory and every link in the chain is &&. Redirects, $()/backtick substitution and background & still ask.

This is a guardrail against agent mistakes, not a security boundary. Recognized commands are still resolved through PATH and can still follow symlinks out of the working directory, and even a pure read pulls file contents into the model's context, so read-only is not confidentiality-safe. For real isolation, run Paimon inside a container or VM.

Sessions live in ~/.local/share/paimon/sessions/ (PAIMON_DATA_HOME overrides). File changes render nicer if delta is installed.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

paimon-0.2.2.tar.gz (123.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

paimon-0.2.2-py3-none-any.whl (127.4 kB view details)

Uploaded Python 3

File details

Details for the file paimon-0.2.2.tar.gz.

File metadata

  • Download URL: paimon-0.2.2.tar.gz
  • Upload date:
  • Size: 123.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for paimon-0.2.2.tar.gz
Algorithm Hash digest
SHA256 fd9c30b22bf1dd10f5dd45a6b182b34a4c220bd242bf5740b86960e895b32164
MD5 953c02fd24c9d8d13cc0aa8f851495eb
BLAKE2b-256 e3dfe2abcd83feba61914d7971d6f9627b0b4d1a976b0d5b3bad2639066b2dbe

See more details on using hashes here.

Provenance

The following attestation bundles were made for paimon-0.2.2.tar.gz:

Publisher: release.yml on aisk/paimon

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file paimon-0.2.2-py3-none-any.whl.

File metadata

  • Download URL: paimon-0.2.2-py3-none-any.whl
  • Upload date:
  • Size: 127.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for paimon-0.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 50c6536cb48744d5c873abb9ee4758b5a90b6a777e34af726eb80d2ee79aa49f
MD5 0b16b8b439c4f0b56b1c068dd7cb73fe
BLAKE2b-256 a1d2bc3b6345370c2fccfc62766b1a545d79c634a790bb8542c266a3a78b3406

See more details on using hashes here.

Provenance

The following attestation bundles were made for paimon-0.2.2-py3-none-any.whl:

Publisher: release.yml on aisk/paimon

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.2.5

2 files

0.2.4

2 files

0.2.3

2 files

This release

0.2.2 This release

2 files

0.2.1

2 files

0.2.0

2 files

0.1.2

2 files

0.1.1

2 files

0.1.0

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page