Skip to main content

ShellPa command-line logo

ShellPa

A safety-conscious, cross-platform terminal assistant. Describe the outcome; review the native command; stay in control.

CI Version 0.3.0 Python 3.10+ Windows, Linux, and macOS MIT License

ShellPa translates natural-language intent into a command for the active operating system and shell. Before anything runs, ShellPa applies a deterministic local safety policy and presents the proposal for review.

User intent
    -> structured command proposal
    -> deterministic safety assessment
    -> permission decision
    -> observable execution
    -> redacted recovery when needed

Why ShellPa

  • Cross-platform commands — supports PowerShell, CMD, Bash, and Zsh.
  • Deterministic safety — the model proposes; ShellPa decides whether a command may execute.
  • Interactive terminal UX — themes, motion settings, history, completion, activity states, and keyboard navigation.
  • Workspace awareness — detects bounded project, Git, tool, and Python environment metadata without reading source contents.
  • Provider choice — supports OpenRouter, OpenAI API, Gemini, Anthropic, and eligible ChatGPT subscriptions through the optional Codex provider.
  • Private by design — diagnostics and recovery exclude credentials, environment values, command output, and arbitrary Git filenames.

Installation

ShellPa requires Python 3.10 or newer. For a standalone command-line application, pipx is recommended because it creates an isolated environment while making shellpa available from any terminal.

pipx install shellpa

For ChatGPT subscription access through the embedded Codex provider:

pipx install "shellpa[codex]"

The configuration wizard can also install the optional Codex provider after explicit approval. A separate Codex CLI installation is not required.

Quick start

Configure a provider:

shellpa config

Run a natural-language request:

shellpa "show the five largest files in this directory"

Preview without execution:

shellpa "show the five largest files in this directory" --dry-run

Open the interactive session:

shellpa

Inside the session, use /help to see all interactive controls.

Providers

Provider Authentication API billing
OpenRouter API key Provider account
OpenAI OpenAI Platform API key OpenAI API account
Google Gemini API key Provider account
Anthropic API key Provider account
OpenAI Codex Eligible ChatGPT account ChatGPT plan limits

The Codex path delegates sign-in and session storage to the official embedded Codex runtime. ShellPa does not read or store Codex credentials. Existing sessions are preserved by default, and logout requires explicit confirmation.

shellpa login
shellpa login --device-code
shellpa logout

Safety model

ShellPa assesses every proposed command locally:

Level Typical behavior
Read-only May run automatically only in Trusted mode
Normal Requires approval unless safely permitted by explicit --force
High risk Requires typed confirmation
Critical Manual-only; ShellPa will not execute it
Unknown Requires review and cannot be silently trusted

Permission modes:

  • Ask — review commands before execution.
  • Plan — display proposals without execution.
  • Trusted — automatically runs only commands proven read-only.

--force does not bypass critical-policy boundaries.

Workspace transparency

ShellPa detects only bounded workspace facts:

  • workspace boundary and allowlisted project markers;
  • project types and known executable availability;
  • Git branch, detached/unborn state, and change counts;
  • active Python environment type.

It does not read source contents, .env contents, credential files, or arbitrary Git filenames to create the provider-safe summary.

shellpa context

The context view clearly separates local-only paths from the smaller summary that may influence a provider request.

Useful commands

Command Purpose
shellpa Open the interactive terminal
shellpa "<request>" Generate, review, and process a command
shellpa config Configure the provider and model
shellpa context Inspect workspace facts and provider-safe context
shellpa doctor Diagnose the local installation without exposing secrets
shellpa about Open the ShellPa identity and project hub
shellpa version Show the installed version

See the complete command reference and v0.3 migration guide.

Development

Clone the repository and create a project environment:

git clone https://github.com/AMR-M-ALSHAMEERI/ShellPa.git
cd ShellPa
python -m venv venv

Activate it:

# Windows PowerShell
.\venv\Scripts\Activate.ps1

# macOS / Linux
source venv/bin/activate

Install the development and Codex extras:

python -m pip install -e ".[dev,codex]"

Run the quality suite:

python -m pytest
python -m ruff format --check .
python -m ruff check .
python -m mypy
python -m build
python scripts/verify_package_contents.py dist

See CONTRIBUTING.md before proposing a change. Report suspected vulnerabilities through the security policy, not through a public issue.

License

ShellPa is available under the MIT License.

Release status

Version 0.3.0 passed its TestPyPI publication and clean-install rehearsal. Production PyPI publication is handled through the protected release workflow rather than normal CI.

Download files

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

Source Distribution

shellpa-0.3.0.tar.gz (105.9 kB view details)

Uploaded Source

Built Distribution

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

shellpa-0.3.0-py3-none-any.whl (61.8 kB view details)

Uploaded Python 3

File details

Details for the file shellpa-0.3.0.tar.gz.

File metadata

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

File hashes

Hashes for shellpa-0.3.0.tar.gz
Algorithm Hash digest
SHA256 1b69947c8940645d146bd291cbecd7b2f8ad13af8a62fb57a6e69d4eb6fd1497
MD5 d8505891e2075da17b10ed21b862263c
BLAKE2b-256 101d37c6c85686cb2bca7173baabeee5be2a8c82e28f749d9aff5e8ddf0cf00c

See more details on using hashes here.

Provenance

The following attestation bundles were made for shellpa-0.3.0.tar.gz:

Publisher: release.yml on AMR-M-ALSHAMEERI/ShellPa

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

File details

Details for the file shellpa-0.3.0-py3-none-any.whl.

File metadata

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

File hashes

Hashes for shellpa-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 fec4d91ab504f46a1ca0eaf1466b211bc1b68ca2b34e0726e0a1bae4e19a3e4f
MD5 8204b3233f49b979e556768f6bc275a9
BLAKE2b-256 bfb23543e3c83a26456c58f11ba0544f64dfeb6964158d43d98118844a7d9ffb

See more details on using hashes here.

Provenance

The following attestation bundles were made for shellpa-0.3.0-py3-none-any.whl:

Publisher: release.yml on AMR-M-ALSHAMEERI/ShellPa

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

Supported by

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