Commands

Interactive

pawan

Default TUI mode with ratatui-powered interface.

Features: welcome screen, command palette (Ctrl+P), F1 help overlay, framed full-width chat with inline tool activity, streaming markdown, readable dark-mode theme tokens, bottom status bar with separated model/token/context/clock fields, readable themed input placeholder, inline slash command popup that submits argument-bearing commands correctly, vim-like navigation (j/k, g/G, Ctrl+U/D, PageUp/PageDown, /search, n/N), mouse wheel scroll support, expand/collapse tool results (e), message timestamps, scroll position indicator, session tags (green), fuzzy session search ([FUZZY] indicator), session stats, conversation export.

TUI Slash Commands

CommandShorthandDescription
/model [name]/mShow or switch LLM model
/modelsBrowse NVIDIA NIM model catalog
/theme [name]List available themes or switch theme (e.g., /theme nord)
/search <query>/sWeb search via Daedra MCP
/ss <query>Search saved sessions by content
/prune [args]Prune old sessions (e.g., 30d, 100s)
/tag <cmd>Manage session tags (add/rm/list/clear)
/tools/tList available tools by tier
/heal/hAuto-fix build errors
/forkClone current session to a new one
/dumpCopy conversation to clipboard
/shareExport session and print shareable path
/diff [--cached]/dShow git diff of working directory (use --cached for staged changes)
/compact [strategy]Compact session messages (strategies: default, aggressive, conservative)
/handoffGenerate focused context for new session
/export [path]/eExport conversation to markdown
/import <path>Import session from JSON file
/saveSave current session
/loadLoad a saved session (opens browser if no arg)
/resumeResume a saved session (opens browser if no arg)
/newStart new session
/clearClear chat history
/quit/qExit pawan
/help/?Show help

/compact - Session Compaction

The /compact command efficiently reduces conversation history by applying intelligent filtering strategies. This helps manage context length and token usage while preserving important information.

Usage:

/compact [strategy]

Strategies:

Examples:

/compact              # Use default balanced strategy
/compact aggressive   # Maximum reduction
/compact conservative # Minimal reduction

Output: After compaction, the status bar shows:

Compacted: 150 → 45 messages (70% reduction, ~420 tokens saved)

Keyboard Shortcuts

KeyContextAction
Ctrl+PAnyToggle command palette
F1AnyToggle keyboard shortcuts overlay
Ctrl+LAnyClear messages
Ctrl+CAnyQuit
TabAnySwitch focus (Input/Messages)
j/kMessagesScroll up/down
g/GMessagesJump to top/bottom
Ctrl+U/DMessagesHalf-page scroll
PageUp/PageDownMessagesPage scroll
/MessagesEnter search mode
n/NMessagesNext/previous search match
eMessagesExpand/collapse nearest tool call result
iMessagesReturn to input
/InputOpen inline slash command popup
Up/DownPopupsNavigate items
PageUp/PageDownPopupsBulk scroll
g/GPopupsJump to top/bottom
EnterPopupsSelect item
EscPopupsClose popup
Mouse wheelAnyScroll (respects active popup)

pawan chat --resume <ID>

Resume a previously saved session by ID. List sessions with pawan sessions.

Code Actions

pawan heal

Auto-fix compilation errors, clippy warnings, and failing tests.

pawan heal              # fix everything
pawan heal --errors-only    # only compilation errors
pawan heal --warnings-only  # only clippy warnings
pawan heal --commit         # auto-commit fixes

pawan task "<description>"

Execute a coding task with full tool access.

pawan task "add input validation to CreateUserRequest"

pawan commit

AI-powered commit workflow. Aliases: pawan ai-commit

pawan commit          # interactive file selection + message generation
pawan commit -a       # stage all files
pawan commit --dry-run  # preview message only
pawan commit -a -y    # stage all, skip confirmation

pawan improve <target>

Improve code quality. Targets: docs, refactor, tests, all

pawan improve docs
pawan improve refactor -f src/config.rs

pawan test

Run tests and AI-analyze failures.

pawan test              # run all tests, report failures
pawan test --fix        # auto-fix failing tests
pawan test -f "config"  # filter by test name

pawan review

AI code review with severity levels.

pawan review            # review all changes
pawan review --staged   # staged changes only
pawan review -f src/lib.rs  # specific file

pawan explain <query>

AI explanation of files, functions, or concepts.

pawan explain src/main.rs
pawan explain "how does the agent loop work"

Automation

pawan run

Headless single-prompt execution for scripting.

pawan run "fix the compilation errors"
pawan run -f prompt.md --output json --timeout 300
pawan run "..." --save  # save session after completion

pawan watch

Continuous monitoring with auto-heal.

pawan watch                    # check every 10s
pawan watch --interval 30      # check every 30s
pawan watch --commit           # auto-commit fixes

Project

pawan init

Scaffold pawan in a project (creates PAWAN.md, pawan.toml, .pawan/).

pawan doctor

Diagnose setup: API keys, model connectivity, config files, git, tools, MCP servers.

pawan status

Show project health (cargo check, clippy, test results).

pawan sessions

List saved conversation sessions.

pawan distill

Distill a completed session into a reusable SKILL.md file via thulpoff.

pawan distill                          # distill latest session
pawan distill -s abc123                # distill specific session
pawan distill -o ./skills              # custom output directory
pawan distill --eval                   # distill then evaluate against primary model
pawan distill --refine                 # full distill → eval → refine → eval loop
pawan distill --refine --student-model mistral-small-24b

The distilled skill can be loaded back by pawan (or any thulp-compatible agent) to reuse learned patterns.

With --eval, pawan runs each test case from the distilled skill through the configured model (or --student-model) and reports a pass rate.

With --refine, pawan automatically improves the skill content based on failing test cases using thulpoff's RefinementEngine, then re-evaluates and reports the improvement delta.

pawan bench

Run model latency benchmarks via nimakai.

pawan notify

Send notifications via relay service.

pawan notify "build failed" --channel whatsapp
pawan notify "deploy done" --channel telegram

pawan fmt

Format code with cargo fmt and cargo clippy --fix.

pawan fmt          # format and fix
pawan fmt --check  # check only, no changes

pawan tasks

Beads-style task tracking (SQLite at ~/.pawan/beads.db) with dependencies, memory decay, and ready detection.

pawan tasks list                       # list all tasks
pawan tasks list --status open --priority 1  # filter by status + priority
pawan tasks create "description"       # create a new bead
pawan tasks update <id> --status in_progress
pawan tasks close <id> --reason "done" # close a bead with a reason
pawan tasks ready                      # show beads whose deps are closed
pawan tasks dep add <bead> <depends_on>    # add dependency
pawan tasks dep rm <bead> <depends_on>     # remove dependency
pawan tasks decay --max-age-days 30    # archive closed beads older than N days

Configuration

pawan config show

Display the fully resolved configuration.

pawan config init

Generate a pawan.toml template.

pawan mcp list

List connected MCP servers and their discovered tools.

pawan completions <shell>

Generate shell completions for bash, zsh, fish, etc.