Skip to main content

Argo

Terminal assistant that translates natural language requests into Linux commands.

What it is

Argo is a CLI tool that:

  • interprets natural language requests (Italian, English, etc.)
  • generates appropriate shell commands via LLM (Ollama)
  • classifies commands by risk level (🟢 read-only, 🟡 write, 🔴 destructive)
  • allows preview, edit, explain and execution time estimation before running
  • learns from your choices and improves suggestions over time

Installation

# Quick install script
./install.sh
# or without sudo (installs to ~/.local)
./install.sh --user

# Manual
pip install -e .
# or run from source without installing
./run.sh --version

Requirements

  • Python 3.10+
  • Ollama running
    • ollama serve — start the server
    • ollama pull llama3.2 — download a model

Basic usage

# Interactive mode (REPL)
argo

# Single query
argo find files larger than 1gb
argo find files modified today
argo search for "error" in logs

After generation you'll see a list of commands: use arrow keys to select, Enter to run. Keys: p preview, e edit, t estimate, x explain, q exit.

Examples

Single commands

# Preview (what the command would do)
argo preview "rm *.log"

# Step-by-step explanation
argo explain "grep -r error logs/"

# Execution time estimate
argo estimate ls -la
argo estimate find . -name "*.log"

Learning and memory

# Save a preferred command
argo learn grep -r error logs/

# List learned commands
argo memory

# Remove one
argo forget 1

# Optimize knowledge (deduplicate, learn from history)
argo optimize
argo optimize --dry-run

Configuration

argo config set llm.model llama3.2
argo config set language.output it
argo config get language.output
argo config list

# Verify environment
argo check
argo check --fix   # create missing config files

Custom risk rules

argo risk add command mytool danger
argo risk add pattern "curl.*\|.*sh" critical
argo risk protect /etc
argo risk list
argo risk remove command mytool

Auto-execute

argo -y find .log files          # auto if read-only
argo -y2 copy files to backup/   # auto if read-only or write
argo -y3 any command            # use with caution!

Session options

argo --lang it      # session in Italian
argo --auto         # same as -y for REPL
argo --no-color     # disable colors

Remote LLM (OpenAI, OpenRouter, etc.)

Argo can use remote APIs instead of local Ollama. API keys are read from environment variables (never stored in config).

OpenAI / compatible APIs:

# Set your API key (never commit this!)
export OPENAI_API_KEY="sk-..."

# Enable remote in config
argo config set llm.remote.enabled true
argo config set llm.remote.model gpt-4

OpenRouter (access to many models with one key):

export OPENAI_API_KEY="sk-or-..."
argo config set llm.remote.enabled true
argo config set llm.remote.base_url "https://openrouter.ai/api/v1"
argo config set llm.remote.model "anthropic/claude-3-haiku"

Custom env var name:

export MY_API_KEY="sk-..."
argo config set llm.remote.api_key_env MY_API_KEY

If remote fails or the openai package is missing, Argo falls back to local Ollama.

Configuration

Files in ~/.config/argo/:

  • config.json — LLM, language, colors
  • knowledge.json — learned commands
  • history.json — choice history
  • risk-rules.json — custom risk rules
  • perf.json — performance estimate cache

License

MIT — see LICENSE

Metadata

Release files for argo-shell-assistant 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for argo-shell-assistant 0.1.0
File Size Uploaded Provenance
argo_shell_assistant-0.1.0.tar.gz 29.1 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for argo-shell-assistant 0.1.0
File Interpreter ABI Platform
argo_shell_assistant-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 67.3 kB

Release files / argo_shell_assistant-0.1.0.tar.gz

Download URL argo_shell_assistant-0.1.0.tar.gz
Size 29.1 kB
Tags Source
SHA-256 checksum
How to use checksums
9161c90149b9654e48e5b461e89f6532c8474acb83ee0c70a906fe73d1219a4e
BLAKE2b-256 checksum
How to use checksums
f29b5f1d845a0453a291bad2f2aefea5c50350e6706685752c0ffc296f7f21dc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.10.12

Release files / argo_shell_assistant-0.1.0-py3-none-any.whl

Download URL argo_shell_assistant-0.1.0-py3-none-any.whl
Size 38.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
42f69269af3783b30d085b681af79e49562477a213b583bd1df11e19c43eeb8f
BLAKE2b-256 checksum
How to use checksums
97ee9a9bfe2a91c75740b6aca1953ac2efa35f90a46dd585ad9d14defc763e75
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.10.12

Security for argo-shell-assistant 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page