v0.3.0 · Rust · MIT License

Cli
de

Glide through your CLI — autonomous terminal operations via AI

A Rust-based autonomous agent running on Termux/Android. Send natural language commands from Telegram or Matrix — Clide interprets them with Gemini AI, executes them on your machine or over SSH, and replies with results. Zero dependencies. Single static binary.

✦ Rust 1.75+ ⚡ Gemini AI 📡 Matrix / Telegram 🤖 Android / Termux
📱 Android/Termux 🐧 Linux x64 🐧 Linux ARM64 🍎 macOS 🪟 Windows (WSL2)
clide · matrix-bot · Termux
clide@android:~$ clide bot
✅ Connected as @clidebot:matrix.org
   Authorized: @juanitto:matrix.org
   Model: gemini-2.5-flash
   Polling (long-poll 30s)…

[INFO] Message: "harden this VPS"
→ run_skill vps_hardening vps_host=100.x.x.x
  [3/18] SSH hardened → root login disabled
  [4/18] UFW configured → port 22 open
  [5/18] fail2ban → 3 retries, 1h ban
✅ Lynis score: 71/100

[INFO] Message: "disk usage?"
→ run_command df -h
/dev/sda1  50G  12G  38G  24% /
✅ Root disk at 24%. All good.

clide@android:~$
0
Runtime Deps
18+
Built-in Skills
3
Platforms
20
Agent Steps
What it does

Everything you need to run your infrastructure from a chat window

Clide combines an AI agent, a credential manager, an SSH hub, and a YAML skills engine into a single static binary that compiles for Android ARM64 without OpenSSL.

🤖
Gemini AI Agent

Natural language → shell commands. Multi-step agentic loop with function calling, up to 20 tool-call steps per task. Gemini 2.5 Flash by default.

📡
Matrix + Telegram

Control your machines from Element/Matrix (E2E-encrypted) or Telegram. Run both simultaneously. /stop cancels a running task mid-flight.

📸
Vision Mode

Attach a screenshot to your Telegram message. Clide embeds it as Gemini inline data — the model reads error text, UI elements, and terminal output directly.

⚡
Zero-Dep Binary

Pure-Rust TLS via rustls. No OpenSSL, no Java, no Node.js, no Python. One static binary. Works on Android ARM64 with Termux out of the box.

🔑
Credential Manager

secrets.yaml + optional GNU pass (GPG-encrypted) layer. All values available as ${KEY_NAME} in skills — substituted at execution time, never sent to AI.

📦
Encrypted Vault

age-encrypted backup of secrets and SSH host registry to a private GitHub Gist. One-liner restore on a new device: bash install.sh --restore

🖥️
SSH Hub

Named host registry (hosts.yaml). Reference servers as ${HOST_PROD_IP} in skills — real IPs never appear in chat or AI prompts. Tailscale-ready.

🧠
Persistent Memory

SQLite-backed conversation memory. The last 10 exchanges are injected as context in every agent task, giving Clide continuity across sessions.

🔐
Secret Scrubber

Every string leaving the process — to Gemini, Telegram, Matrix, logs — is scanned and all known secret values are replaced with ***.

How it works

Architecture

Every component compiles into a single binary. The agent loop, credential manager, skill runner, and messaging clients share a unified config with secrets injected at the last possible moment.

Agent Loop
You (Element / Telegram)
↓ encrypted message
Clide Bot
↕ function calling
Gemini AI
interpret
Executor
run cmds
Skills
YAML wf
SSH Client
remote
↓
Your System / Remote Servers
Secrets Priority
1. env var — highest
2. secrets.yaml or pass (GPG)
3. config.yaml
4. built-in default
File Structure
~/.clide/
  config.yaml  ← settings
  secrets.yaml ← API keys
  hosts.yaml   ← SSH hosts
  skills/      ← YAML wf
  memory.db   ← SQLite
Rust Crates
tokio · async runtime
reqwest (rustls) · pure-Rust TLS
rusqlite (bundled) · memory
serde_yaml · config + skills
tracing · structured logs
Automation

Built-in Skills

Skills are YAML workflows the AI invokes by name. They support parameter injection, secret substitution, timeouts, rollback commands, and confirmation gates.

run_skill vps_hardening vps_host=100.x.x.x vps_user=root
Any value from secrets.yaml is available as ${KEY_NAME} in skill commands — substituted after Gemini returns its output, never visible to the model.
🛡️
vps_hardening

Full 18-step VPS hardening over SSH: system update, admin user, sshd, UFW, fail2ban, kernel sysctl, rkhunter, Lynis, Tailscale, rootless Docker, auditd.

🔍
lynis_audit

Install Lynis via git clone and run a full security audit. Reports hardening index, warnings, and suggestions. Supports local and remote SSH mode.

🐳
docker_ai_sandbox

Docker CE install, isolated internal bridge networks, seccomp + AppArmor hardening, Ollama LLM container, resource-capped bot template.

🖥️
vps_manager

Full VPS status dashboard over Tailscale SSH: disk, memory, top processes, UFW, fail2ban, Docker, recent logins, rkhunter, Lynis score.

🤖
aiwb_manager

Drive AIworkbench headlessly. Auto-installs AIWB, injects API keys from secrets, runs make/tweak/debug pipeline, extracts code to ~/clide_exports/.

🔬
debugger

Multi-phase diagnostic for Docker containers, systemd services, or host. Captures logs, processes, resources, network — produces an AI-ready fault report.

📊
system_overview

Comprehensive snapshot: OS identity, hardware, software environment, network state, and a richly annotated file tree. Six modes.

⏰
maintenance_cron

Schedule routine maintenance: temp-file cleanup, log truncation, package-cache pruning, disk reporting. Supports install, remove, list, run.

Get started

One-line install

The installer detects your architecture, downloads the pre-built binary, and walks you through Gemini + messaging setup interactively. All steps skippable.

▶ Termux (Android) · Linux · macOS
$ curl -fsSL https://raw.githubusercontent.com/juanitto-maker/Clide/main/install.sh | bash
The installer will:
1

Download or build

Pre-built aarch64 binary from GitHub Releases. Falls back to cargo build --release if no binary available.

2

Configure interactively

Asks for your Gemini API key, messaging platform, bot token or Matrix credentials. Every step skippable with Enter.

3

Install skills

Copies the bundled skills library to ~/.clide/skills/ with chmod 600. Immediately available as named workflows.

Manual binary (Termux)
$ wget …/releases/latest/download/clide-aarch64
$ chmod +x clide-aarch64
$ mv clide-aarch64 $PREFIX/bin/clide
Restore vault on new device
$ curl -fsSL ...install.sh | bash --restore
  → prompts GitHub token + Gist ID
  → decrypts age vault + restores secrets
Start bot
clide bot
Interactive REPL
clide
Manage secrets
clide secret list
Trust model

Security by default

Clide controls a real shell. Every design decision reflects this. Maximum autonomy with minimum attack surface.

🚦
Fail-closed authorizationEmpty authorized_users silently blocks everyone. No user can send commands until explicitly listed.
🔇
Secret scrubber on all outbound textEvery string leaving the process is scanned for known secret values before transmission.
🧩
Placeholder injection, never raw valuesSkills use ${KEY_NAME}. Substitution happens inside the Executor after Gemini has generated its output.
🚫
Command blocklistrm -rf /, mkfs, dd if= and other destructive patterns rejected before execution. Configurable.
✅
Confirmation modeSet require_confirmation: true. Bot asks for YES before any command runs. Configurable timeout.
🔒
GNU pass GPG layerOptional: store secrets in pass (GPG-encrypted). Plaintext in RAM only — never written back to disk.
🌐
Pure-Rust TLS via rustlsNo OpenSSL. No dynamic libraries. All HTTPS through rustls — works on Android ARM64 without system libs.
🛑
/stop cancellationSend /stop while a task runs. A watcher task polls for it and sets an AtomicBool cancel flag the agent checks between every step.
History

Changelog

v0.3.0 — current
Element/Matrix Migration

Complete replacement of Signal/signal-cli with Element/Matrix. Pure HTTP API via reqwest. No Java, no JVM, no patchelf. Initial sync skipping prevents history replay.

v0.2.0
Rust Rewrite

Complete rewrite from Python. Native Rust binary with zero interpreter. reqwest-based Gemini client. rusqlite bundled SQLite. Pure-Rust TLS — no OpenSSL.

v0.1.0-alpha
Python Prototype

Initial prototype with Signal messenger. Gemini Flash for command interpretation. Autonomous execution. SQLite memory. Safety guardrails. Termux/Android support.

What's next

Roadmap

Shipped ✦
✓Core bot functionality
✓Gemini AI integration
✓Element/Matrix integration (v0.3.0)
✓Telegram integration
✓Android/Termux support
✓YAML skills system
✓Credential manager (clide secret)
✓SSH host registry (clide host)
✓GNU pass / GPG encryption layer
✓Age-encrypted vault backup & restore
✓Secret scrubber (auto-redact)
✓Vision mode (image/PDF inline)
Planned ○
○Web UI dashboard
○Docker support
○Multi-room support
○Scheduled commands
○Custom command aliases
○Workflow marketplace
○Claude API support
○Advanced monitoring dashboard
Open Source · MIT License

Built to be hacked on

Contributions welcome — bug fixes, new skills, platform improvements, docs. Drop by GitHub Discussions for questions, ideas, and show & tell.