Skip to main content

Telegram bot for remote AI operations management — Memoriant Inc.

Project description

English | Deutsch | Nederlands | Francais | Russkij | Espanol | Portugues

MOPS

MOPS

Multi-provider AI agent control from your phone.

Quick Start · How It Works · Features · Use Cases · Install Guide · Architecture

Tests Providers Transport License Python PyPI


Run Claude Code, OpenAI Codex CLI, or Google Gemini CLI from Telegram or Matrix. Uses only official CLIs as subprocesses — nothing spoofed, nothing proxied. Your subscriptions, your machine, your data.

MOPS Demo — controlling AI agents from Telegram

Released March 12, 2026 — five days before Anthropic shipped Claude Dispatch. Same concept, different philosophy.

How does this compare to Claude Dispatch?

MOPS Claude Dispatch
Providers Claude + Codex + Gemini Claude only
Cost Free — uses your existing subscriptions Max plan required ($100+/mo)
Remote from Telegram, Matrix, any device Claude mobile app
Controls Any machine — servers, GPU rigs, cloud Mac desktop only
Parallel agents Unlimited — topics, sessions, sub-agents Single conversation
Open source MIT Proprietary
Background tasks Yes, with delegation + follow-ups Yes
Named sessions Yes No
Plugin system Yes — add Discord, Slack, Signal No

Quick Start

pipx install .
mops

The onboarding wizard walks you through CLI detection, transport setup (Telegram or Matrix), timezone, optional Docker sandbox, and background service installation.

You need: Python 3.11+, at least one CLI (claude, codex, or gemini), and a Telegram bot token or Matrix account.


How It Works

MOPS wraps official CLI binaries as subprocesses and bridges them to your messaging platform. No API keys, no SDK patches, no spoofed headers. When you send a message on Telegram, MOPS passes it to the CLI exactly as if you typed it in your terminal.

Phone (Telegram/Matrix)
  |
  v
MOPS daemon (your machine)
  |
  +---> claude     (subprocess)
  +---> codex      (subprocess)
  +---> gemini     (subprocess)
  |
  v
Response streamed back to phone

All state lives in ~/.mops/ as plain JSON and Markdown. No database, no external services.


Chat Modes

MOPS gives you five levels of interaction. Start simple, scale up as needed.

1 — Single Chat

Your main 1:1 conversation. Every message goes to the active CLI, responses stream back live.

You:   "Explain the auth flow in this codebase"
Bot:   [streams Claude Code response]

You:   /model
Bot:   [switch to Codex or Gemini]

2 — Group Topics

Create a Telegram group with topics enabled. Each topic gets its own isolated CLI context. Five topics = five parallel conversations, all from one group.

My Projects/
  General        -- own context
  Auth           -- own context, own model
  Frontend       -- own context
  Database       -- own context
  Refactor       -- own context

3 — Named Sessions

Spin up a side conversation without losing your current context. Like opening a second terminal.

You:   "Let's work on authentication"
Bot:   [responds about auth]

/session Fix the broken CSV export
Bot:   [works CSV in separate context]

You:   "Back to auth — add rate limiting"
Bot:   [picks up right where you left off]

4 — Background Tasks

Delegate long-running work. You keep chatting, the task runs autonomously, results flow back when done.

You:   "Research the top 5 competitors and write a summary"
Bot:   -> delegates, you keep working
Bot:   -> done, summary appears in your chat

5 — Sub-Agents

Fully isolated second bot — own workspace, own memory, own CLI, own config. Runs on a different provider if you want.

mops agents add codex-agent

Now you have Claude in your main chat and Codex in a separate chat, working in parallel with independent contexts. They can delegate tasks to each other.

Mode comparison table
Single Topics Sessions Tasks Sub-agents
What Main 1:1 One topic = one chat Side context "Do this in background" Separate bot
Context One per provider One per topic Own per session Own, result flows back Fully isolated
Workspace ~/.mops/ Shared Shared Shared Own under agents/
Setup Automatic Create group + topics /session <prompt> Automatic mops agents add

Features

Multi-provider — Switch between Claude, Codex, and Gemini with /model. Per-topic, per-session.

Multi-transport — Telegram and Matrix run simultaneously. Plugin system for Discord, Slack, Signal.

Real-time streaming — Live message edits on Telegram, segment-based on Matrix.

Persistent memory — Plain Markdown files that survive across sessions and reboots.

Cron & webhooks — Schedule recurring tasks with timezone support. Webhook triggers for external integrations.

Docker sandbox — Optional sidecar container with configurable host mounts for safe code execution.

Background service — Install as systemd (Linux), launchd (macOS), or Task Scheduler (Windows).

Cross-tool skill sync — Shared skills across ~/.claude/, ~/.codex/, ~/.gemini/.

Hot-reload config — Change language, model, permissions, scene — no restart needed.

7 languages — English, Deutsch, Nederlands, Francais, Russkij, Espanol, Portugues.


Transport Support

Platform Status Streaming Interaction Install
Telegram Primary Live message edits Inline keyboards Built-in
Matrix Supported Segment-based Emoji reactions mops install matrix

Both run in parallel on the same agent. Adding a new messenger means implementing BotProtocol in a sub-package — the core is fully transport-agnostic.


Security

Dual-allowlist model. Every message must pass both checks:

Chat type Requirement
Private User ID in allowlist
Group Group ID in allowlist AND user ID in allowlist

Allowlists are hot-reloadable. Unauthorized groups trigger auto-leave. All state is local — nothing leaves your machine.


Commands

Command What it does
/model Switch provider/model
/new Reset session
/stop Stop current + queued
/session <prompt> Start named session
/tasks View background tasks
/cron Manage scheduled jobs
/agents Multi-agent status
/status Session/provider info
/diagnose Runtime diagnostics
/memory View persistent memory
CLI commands
mops                    # Start (auto-onboarding)
mops onboarding         # Re-run setup
mops stop               # Stop bot
mops restart            # Restart
mops upgrade            # Upgrade + restart
mops status             # Runtime status
mops uninstall          # Remove everything

mops service install    # Background service
mops service start|stop|logs

mops docker enable      # Docker sandbox
mops docker rebuild
mops docker mount /path

mops agents list        # Sub-agents
mops agents add NAME
mops agents remove NAME

mops install matrix     # Matrix transport
mops install api        # WebSocket API

Workspace

~/.mops/
  config/config.json          # Configuration
  sessions.json               # Chat state
  named_sessions.json         # Named sessions
  tasks.json                  # Background tasks
  cron_jobs.json              # Scheduled jobs
  agents.json                 # Sub-agent registry
  SHAREDMEMORY.md             # Cross-agent knowledge
  workspace/
    memory_system/            # Persistent memory
    cron_tasks/               # Cron scripts
    skills/ tools/            # Shared tooling
    tasks/                    # Per-task folders
  agents/<name>/              # Isolated sub-agent workspaces

Why This Approach

Other projects patch SDKs, spoof headers, or proxy API calls. That's fragile and risks violating provider ToS.

MOPS runs official CLIs as subprocesses. Nothing more. Your subscription, your machine, your auth. The bot is just a bridge between your phone and your terminal.


Docs

Guide Content
Installation Setup walkthrough
System Overview End-to-end runtime
Architecture Routing, streaming, callbacks
Configuration Full config reference
Use Cases & Workflows 10 real-world patterns with commands
FAQ Common questions answered
Troubleshooting Diagnostic steps by symptom
Plugin Guide Adding transports & providers
Matrix Setup Matrix transport
Automation Cron, webhooks, heartbeat
Service Management systemd / launchd / Task Scheduler

Contributing

See CONTRIBUTING.md for setup, quality gates, and contribution guidelines.

git clone https://github.com/NathanMaine/memoriant-ops-bot.git
cd memoriant-ops-bot
python -m venv .venv && source .venv/bin/activate
pip install -e ".[dev]"
pytest && ruff format . && ruff check . && mypy memoriant_ops_bot

Security Policy · Changelog

MIT License
Built by Memoriant Inc.

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

memoriant_ops_bot-0.15.1.tar.gz (1.1 MB view details)

Uploaded Source

Built Distribution

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

memoriant_ops_bot-0.15.1-py3-none-any.whl (1.3 MB view details)

Uploaded Python 3

File details

Details for the file memoriant_ops_bot-0.15.1.tar.gz.

File metadata

  • Download URL: memoriant_ops_bot-0.15.1.tar.gz
  • Upload date:
  • Size: 1.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for memoriant_ops_bot-0.15.1.tar.gz
Algorithm Hash digest
SHA256 c93ead43c668b111e0e4460cce4d28ec471a8bce2826af1ff9d878c5f276ecd0
MD5 65de7341cf87ef54c335475f740596f6
BLAKE2b-256 80cf709a7afb3c248e4cf81dea226742469d935c708893b657afad36ca2dfa0b

See more details on using hashes here.

Provenance

The following attestation bundles were made for memoriant_ops_bot-0.15.1.tar.gz:

Publisher: publish.yml on NathanMaine/memoriant-ops-bot

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

File details

Details for the file memoriant_ops_bot-0.15.1-py3-none-any.whl.

File metadata

File hashes

Hashes for memoriant_ops_bot-0.15.1-py3-none-any.whl
Algorithm Hash digest
SHA256 3910099d231966eee93834c298115ceb223625a185a9b1132d812c931f595497
MD5 14a44512f4365cdca7684a2d6661a5fa
BLAKE2b-256 5f0ef8043d3c927746abeb5ed004e90bf81350d6f170ce147bcc036b9e2722b5

See more details on using hashes here.

Provenance

The following attestation bundles were made for memoriant_ops_bot-0.15.1-py3-none-any.whl:

Publisher: publish.yml on NathanMaine/memoriant-ops-bot

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