Skip to main content

Planner AI

Terminal UI that asks several models for a plan or answer in parallel, reconciles via a consensus model, and either writes plan.md (Plan mode) or returns a Q&A answer (Ask mode). It plans and answers; it does not execute.

This package is the Python/Textual port. The TypeScript app at the repo root remains available until you cut over fully.

Requirements

  • Python ≥ 3.14
  • uv

Install and run

From this directory (development)

cd planner-ai
uv sync
uv run planner

Or:

uv run python -m planner_ai

Install as a tool (any project)

From PyPI:

uv tool install planner-ai
# or: pip install planner-ai

From this package directory (development):

uv tool install .

Then from any project you want to plan:

cd ~/code/my-app
planner

Both the Bun and Python CLIs expose the same console name planner. If both are on your PATH, whichever comes first wins. Prefer one install at a time, or call the Python app explicitly with uv run --directory /path/to/planner-ai planner.

Auth / tokens

On first run the TUI opens Auth when no real credential is set (set at least one real provider; empty Enter cancels a token editor):

Tokens are saved under the OS user config directory (same path and JSON shape as the TypeScript app):

  • macOS: ~/Library/Application Support/planner-ai/config.json
  • Linux: ~/.config/planner-ai/config.json (or $XDG_CONFIG_HOME/planner-ai)
  • Windows: %APPDATA%\planner-ai\config.json

Never commit tokens or put them in .env. The app does not log credential values.

Providers without a key are omitted; if none are set, mock providers are used. With real keys present, mocks appear only when includeMocks is enabled (press m on Proposers/Consensus).

If a stored key fails auth during a run, the error screen offers r to remove that key from config and re-enter it (or q to quit). To clear all credentials without launching the TUI:

uv run planner --reset-auth
# or, if installed as a tool:
planner --reset-auth

What it does

  • Plans/asks against the folder you launched the CLI in (cwd)
  • Asks several models in parallel (one failure does not cancel the others)
  • Uses a separate consensus model to reconcile
  • Plan mode: writes plan.md in that folder (backs up an existing file as plan.md.bak) and archives the run
  • Ask mode: same multi-proposer + consensus flow with Q&A prompts; does not write cwd plan.md; archives under .planner-ai/ask-…/

TUI

Fullscreen alternate-screen UI with tabs:

Tab Shortcut What it does
Plan Ctrl+1 Plan/Ask toggle, enter a goal or question, watch proposals / consensus, browse the result
Proposers Ctrl+2 Pick proposer models (multi) — Claude / Cursor / Codex / Mock
Consensus Ctrl+3 Pick the consensus model (single)
Auth Ctrl+4 Set or clear Claude OAuth / Cursor / Codex API keys
History Ctrl+5 Browse past successful runs archived under .planner-ai/

You can also click the tab labels. On Models: click a row or use ↑↓ / PgUp/PgDn, Space toggle/choose, / filter, m toggle mocks, c continues to Plan.

Startup opens Auth if no real credential is set, else Proposers if there is no saved selection, else Plan.

How it works

  1. You provide a goal (Plan) or question (Ask) on the Plan tab.
  2. Models inspect the current working directory (read-only) and each propose.
  3. A consensus model reconciles the proposals into one plan or answer.
  4. Plan mode writes plan.md; both modes archive under .planner-ai/.
flowchart LR
  Goal[Goal or question] --> Models[Multi-model proposals]
  Models --> Consensus[Consensus model]
  Consensus --> Plan[plan.md or answer.md archive]

Output

plan.md (Plan mode) is the artifact meant for a later execution step. This tool produces the plan; it does not run it.

Each successful run is archived under .planner-ai/:

.planner-ai/
  plan-2026-08-13T16-48-00/
    anthropic-claude-sonnet-4-5-output.md
    plan.md
  ask-2026-08-13T16-49-00/
    cursor-composer-2.5-output.md
    answer.md
  • Plan runs: plan-{YYYY-MM-DDTHH-MM-SS}/ with per-model *-output.md and consensus plan.md
  • Ask runs: ask-{YYYY-MM-DDTHH-MM-SS}/ with per-model *-output.md and consensus answer.md
  • Collision dirs: plan-{ts}-2, plan-{ts}-3, …
  • History lists both kinds newest-first (by timestamp, not full dirname)

Archives written by the TypeScript app remain readable.

Development

cd planner-ai
uv sync
uv run planner              # TUI (plans cwd)
uv run planner --reset-auth
uv run pytest
uv run ruff check src tests

Plan another folder without installing:

cd ~/code/my-app
uv run --directory /path/to/planner-ai/planner-ai planner

Download files

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

Source Distribution

planner_ai-0.2.0.tar.gz (35.8 kB view details)

Uploaded Source

Built Distribution

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

planner_ai-0.2.0-py3-none-any.whl (52.7 kB view details)

Uploaded Python 3

File details

Details for the file planner_ai-0.2.0.tar.gz.

File metadata

  • Download URL: planner_ai-0.2.0.tar.gz
  • Upload date:
  • Size: 35.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.4 {"installer":{"name":"uv","version":"0.12.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for planner_ai-0.2.0.tar.gz
Algorithm Hash digest
SHA256 c4e9525041162cec6c663b5ecfab32eca12f55a5a008f1d5c398bd94c55a1d8b
MD5 68489c66f24ce49565524931b5b576ca
BLAKE2b-256 9b42a2663c0c9189d38b7dcd8a84b05ab3838c2142e52a96fb242d92eeb9f595

See more details on using hashes here.

File details

Details for the file planner_ai-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: planner_ai-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 52.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.4 {"installer":{"name":"uv","version":"0.12.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for planner_ai-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 89d5d96151614031dd26a3bd82c6389a8ef4a4b75edc4f8277502a3b90fa757f
MD5 ffbb9ca1ed001c28258e6f7239b157c1
BLAKE2b-256 d15d26579490154316593424ec96ba40a6a2a6ac93b4cfd8cc235d725b76a7e2

See more details on using hashes here.

Supported by

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