peri-peri-cli
v1.1.0
Published
Interactive coding CLI for Lyzr-backed providers
Maintainers
Readme
Peri Peri CLI
Peri Peri is a terminal-native coding assistant for Lyzr-backed providers. It supports interactive chat, model/provider selection, persistent file context, repo maps, deterministic file edits, local tool execution, approval controls, undo snapshots, git/diff helpers, validation commands, timeline output, and raw response panels.
Quick start
npm install -g peri-peri-cli
periperiConfigure credentials with environment variables:
export PERI_PERI_API_KEY="..."
export PERI_PERI_USER_ID="[email protected]"
export PERI_PERI_PROVIDER="Aws-Bedrock"
export PERI_PERI_MODEL="anthropic.claude-sonnet-4-6"
export PERI_PERI_UI="react"
periperiPeri Peri also supports the existing local .env endpoint object used during development.
You can also create .peri-peri/config.json or .periperi.json:
{
"provider": "Aws-Bedrock",
"model": "anthropic.claude-sonnet-4-6",
"apiKeyEnv": "PERI_PERI_API_KEY",
"userId": "[email protected]",
"approvalMode": "ask",
"timeline": true,
"uiMode": "react"
}uiMode supports:
react- default behavior; prefer the React TUI and fall back to the classic shell if the terminal is not interactiveauto- use the React TUI for interactive terminals and fall back to the classic shell otherwiseclassic- always use the existing line-oriented shell
Useful commands
/help
/model anthropic.claude-sonnet-4-6
/provider Aws-Bedrock
/add src/index.js
/files
/read package.json
/drop src/index.js
/map
/git
/diff
/commit "update app"
/test
/lint
/undo
/status
/logs
/doctor
/approval ask
/allow-all
/timeline on
/raw onUse @path/to/file to attach file context, and ! command to run a local shell command directly.
Local tools
Models can request host-executed tools using Peri Peri's XML protocol:
read_filewrite_fileappend_filereplace_in_fileapply_patchdelete_filemkdirlist_dirrun_shellrepo_map
replace_in_file uses deterministic search/replace matching with exact, normalized line-ending, and whitespace-tolerant fallback strategies. apply_patch accepts standard unified diff patches for larger or multi-file edits. Before mutating file actions, Peri Peri stores undo snapshots that can be restored with /undo.
If an edit fails, Peri Peri feeds only the failed edit diagnostics back into the model so it can repair the broken action without repeating successful actions.
Release checklist
Before publishing:
npm test
npm pack --dry-runInspect the dry-run output and verify it only includes package source files. .env, .peri-peri/, logs, generated HTML, node_modules, and tarballs must not be included.
Local state
Peri Peri stores local runtime state under .peri-peri/. Do not commit or publish this directory. Structured event logs are written to .peri-peri/logs/events.jsonl.
