Skip to main content

Terminal in natural language. Just say what you want.

Project description

pls

Just say what you want. In your terminal.

InstallUsageProvidersConfig

PyPI Python License

pls demo

$ pls "compress all PNGs in this folder"

╭──────────────────────────────────────────────────╮
│ find . -name "*.png" -exec pngquant --quality=65-80 {} \; │
╰──────────────────────────────────────────────────╯

 Run it? (Y/n)

✓ Done.

Install

pip install pls-sh

That's it. The command is pls.

Usage

pls "find files bigger than 100MB"
pls "kill whatever is using port 3000"
pls "convert video.mp4 to gif"
pls "show disk usage sorted by size"
pls "rename all .jpeg files to .jpg"

Works offline by default with Ollama. No API key, no internet, no telemetry.

Flags

pls "do something" --explain    # also explains what the command does
pls "do something" --yes        # skip confirmation, just run it
pls "do something" --provider openai  # use a different LLM
pls "do something" --model gpt-4o    # pick a specific model

Safety

pls flags dangerous commands before running them. Stuff like rm -rf, chmod 777, dd, piping random scripts into bash — all gets highlighted in red with a warning. Dangerous commands flip the confirmation to opt-in (y/N instead of Y/n).

Providers

Ollama is the default. Runs locally, no account needed.

# make sure ollama is running
ollama serve
ollama pull llama3.2

pls "list all docker containers"
# just works

OpenAI and Anthropic if you want cloud models:

# either set env vars
export OPENAI_API_KEY=sk-...
export ANTHROPIC_API_KEY=sk-ant-...

# or save them in config
pls config set openai api_key sk-...
pls config set anthropic api_key sk-ant-...

# then use them
pls "do something" --provider openai
pls "do something" --provider anthropic

# or set a default
pls config set default provider anthropic

Config

Config lives in ~/.config/pls/config.toml.

pls config show          # see current config
pls config set ...       # change a value
pls config reset         # back to defaults

How it works

  1. You type what you want in plain English (or any language, really)
  2. pls grabs context — your OS, shell, what's in the current directory
  3. Sends that + your request to the LLM
  4. Shows you the command, asks for confirmation
  5. Runs it

No history stored, no data sent anywhere (unless you use OpenAI/Anthropic).

License

MIT

Project details


Download files

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

Source Distribution

pls_sh-0.1.0.tar.gz (209.9 kB view details)

Uploaded Source

Built Distribution

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

pls_sh-0.1.0-py3-none-any.whl (14.6 kB view details)

Uploaded Python 3

File details

Details for the file pls_sh-0.1.0.tar.gz.

File metadata

  • Download URL: pls_sh-0.1.0.tar.gz
  • Upload date:
  • Size: 209.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.13

File hashes

Hashes for pls_sh-0.1.0.tar.gz
Algorithm Hash digest
SHA256 49f438f8af8a05b25079cb47200748c4b9069a779236755e4518ba38150df119
MD5 78945a4b7d041ccfda5535c1c5ef4395
BLAKE2b-256 a77ef30aadc18788576a80f5852361be9d300a9276d7a7851f6fb1722d5fa5bc

See more details on using hashes here.

File details

Details for the file pls_sh-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: pls_sh-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 14.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.13

File hashes

Hashes for pls_sh-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ce68f396114f1c9c30cf7e5ae34d293ffd12adce37d1dc55d6c41831fc5327c5
MD5 bfaefbdc52f0d46f3ccb0cc9456080fc
BLAKE2b-256 860e7cbc354fbe179836431387eb2387fdc2713c4fc98fd8766161f4a47cd056

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 Pingdom Monitoring Sentry Error logging StatusPage Status page