Skip to main content

Local-first command wrapper for AI coding agents with compressed terminal output and privacy-safe proof metrics.

Project description

SAGE

CI Python License Release

SAGE is a local-first command wrapper for AI coding agents that compresses terminal output, preserves raw logs locally, and proves token savings with privacy-safe metrics.

The public package is CLI-first. The desktop GUI is not included in this public repository yet.

Live Public Proof Dashboard

Live dashboard: https://psyc-god-sage-api.valan-dj.workers.dev/dashboard

SAGE Live Public Proof Dashboard

Current public proof includes:

  • Total commands processed through SAGE
  • Tokens processed, compressed, and saved
  • Estimated savings by AI agent/provider
  • Compression rate and command success rate
  • ML prediction scoring from local command history

Latest verified snapshot:

Metric Value
Commands processed 4,726
Tokens processed 16,870,812
Tokens compressed 1,225,605
Tokens saved 15,645,207
Estimated savings $46.94
Compression rate 92.74%
Success rate 98.03%

These stats reflect the public CLI proof snapshot after the hosted dashboard went live. Raw commands, outputs, file paths, and logs stay local by default. Public proof uses aggregate counters only.

Install From GitHub Until PyPI Is Live

PyPI publishing is prepared but still blocked by the Trusted Publisher project-name mismatch. Until the PyPI project is live, install the public CLI directly from GitHub:

pip install git+https://github.com/PsYcGoD/sage.git
sage --version

After PyPI is live, the install command will be:

pip install psycgod-sage
sage --version

For local development:

git clone https://github.com/PsYcGoD/sage.git
cd sage
pip install -e .
sage --version

The prepared PyPI distribution is psycgod-sage; the installed CLI command is still sage.

Connect Your Account

Most public API-backed commands require GitHub OAuth:

sage connect
sage whoami
sage api status

SAGE stores the API key in the operating system keyring when available. Local command history and raw outputs remain on your machine.

Bind Agent Instructions

Create local SAGE instructions for terminal agents:

sage init

This writes SAGE.md in the current project. Give that file to your local AI coding agent, or bind the same rule into your AGENTS.md / agent instruction file:

Route every shell command through:

sage run -- <command>

Run Commands Through SAGE

sage run -- python -m pytest
sage run -- npm test
sage run -- git status

SAGE stores full raw command output locally, summarizes noisy output for AI context, tracks compression, and sends only allowed aggregate proof metrics to the dashboard.

Useful CLI Commands

sage context stats
sage context report
sage history --limit 10
sage explain
sage suggest
sage fix
sage fix --apply --confidence 0.9
sage savings --agent claude-sonnet
sage firewall status
sage firewall rules list
sage github-bot comment --kind summary
sage mcp install
sage dashboard start --port 8765

Team View Preview

Team Dashboard is not published yet. It will open by invite after SAGE reaches 100 users.

SAGE Team View Preview

The planned Team View will show aggregate workspace proof only: tokens saved, success rate, safety events, and protected secrets. It will not publish raw commands, source code, file paths, .env data, or raw logs.

Screenshots

Command Preview
sage run -- sage run terminal capture
sage context report sage context report terminal capture
sage mcp install sage mcp install terminal capture
Dashboard proof SAGE Live Public Proof Dashboard

Starter demo GIFs:

GUI Status

The desktop GUI is not available in this public repo right now.

sage gui

This command prints the roadmap status instead of launching a desktop app. The GUI will be released later with AI agents and ML workflows after it is stable enough for public use.

Known Limitations

  • The GUI is not public yet and is intentionally absent from the CLI package.
  • GitHub OAuth / a SAGE API key is required for most API-backed commands and public proof sync.
  • Telemetry level 0 is local-only; higher levels are opt-in and constrained by account/key policy.
  • The public dashboard is aggregate-only and does not expose raw commands, raw outputs, file paths, or local logs.
  • Local ML and agent features depend on local history volume and optional provider credentials.

Privacy

  • Raw commands and full outputs stay local by default.
  • Public dashboard data is aggregate proof only.
  • API connection is handled through GitHub OAuth.
  • Higher telemetry is opt-in.
  • API keys are stored in the OS keyring when available.

See PRIVACY.md and SECURITY.md for the detailed data and security model.

Development

python -m pytest -q

The public package is CLI-first. GUI source, GUI tests, and GUI-only dependencies are intentionally not shipped in this repo at this time.

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

psycgod_sage-2.0.1.tar.gz (159.1 kB view details)

Uploaded Source

Built Distribution

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

psycgod_sage-2.0.1-py3-none-any.whl (166.7 kB view details)

Uploaded Python 3

File details

Details for the file psycgod_sage-2.0.1.tar.gz.

File metadata

  • Download URL: psycgod_sage-2.0.1.tar.gz
  • Upload date:
  • Size: 159.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for psycgod_sage-2.0.1.tar.gz
Algorithm Hash digest
SHA256 702ee35beaea421e7c6b5bdca1e93f540486782ee9b6557ffe914ec306a5142f
MD5 8804783574afd5e834b0d25cc69a8099
BLAKE2b-256 de8636f5ef465d11cd1a5749ff29e83840e76e3f8c0049a358693b0526a3ff62

See more details on using hashes here.

Provenance

The following attestation bundles were made for psycgod_sage-2.0.1.tar.gz:

Publisher: pypi-publish.yml on PsYcGoD/sage

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

File details

Details for the file psycgod_sage-2.0.1-py3-none-any.whl.

File metadata

  • Download URL: psycgod_sage-2.0.1-py3-none-any.whl
  • Upload date:
  • Size: 166.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for psycgod_sage-2.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 026b17c16a3b166881e99d1f55e7c7db7221195bcbf2999ac07903222511c88d
MD5 8ba8693cb0a6838344f1fa26fd8d461f
BLAKE2b-256 ce233af5c4cd0b6feb721535a563458d28c1a3000b518c8b8cda684c70405478

See more details on using hashes here.

Provenance

The following attestation bundles were made for psycgod_sage-2.0.1-py3-none-any.whl:

Publisher: pypi-publish.yml on PsYcGoD/sage

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