Skip to main content

Multi-model AI agent Telegram bot for multi-folder workspaces.

Project description

pochi

Multi-model AI agent Telegram bot for multi-folder workspaces.

Run AI coding agents (Claude Code, Codex, OpenCode, Pi, etc.) from Telegram with workspace-based organization. Each folder gets its own Telegram topic, enabling parallel work across multiple projects from a single bot.

features

  • multi-engine: supports multiple AI agent backends (Claude, Codex, OpenCode, Pi) via auto-discovery
  • workspace mode: organize multiple folders under one Telegram group with topic-based isolation
  • stateless resume: continue a thread in chat or pick up in the terminal with claude --resume <token>
  • progress updates: real-time streaming of commands, tools, file changes, and elapsed time
  • ralph wiggum loops: iterative Claude prompting where it reviews its own work until complete
  • folder management: clone repos, create folders (with or without git), or add existing directories from Telegram
  • robust rendering: markdown output with quality-of-life tweaks for Telegram

requirements

  • uv for installation (curl -LsSf https://astral.sh/uv/install.sh | sh)
  • python 3.14+ (uv can install it: uv python install 3.14)
  • claude CLI on PATH (npm install -g @anthropic-ai/claude-code)
  • a Telegram bot token (from @BotFather)
  • a Telegram group with forum/topics enabled

install

uv python install 3.14
uv tool install -U pochi
# or try it with
uvx pochi@latest

quick start

  1. create a Telegram bot via @BotFather and save the token

  2. create a Telegram group with topics enabled:

    • create a new group
    • go to group settings → Topics → enable
    • add your bot to the group as admin
  3. get the group ID: the easiest way is to add @RawDataBot to the group temporarily, it will show the chat ID (remove it after)

  4. initialize a workspace:

    mkdir my-workspace && cd my-workspace
    pochi init
    # or non-interactive:
    pochi init --bot-token "123:ABC" --group-id -100123456789
    
  5. run pochi:

    pochi
    
  6. add folders from the General topic in Telegram:

    /clone backend git@github.com:user/backend.git
    /create frontend
    /create knowledge-vault --no-git
    /add existing ~/dev/my-project
    

each folder gets its own topic. switch to a folder's topic to work on it.

workspace config

config lives at .pochi/workspace.toml:

[workspace]
name = "my-workspace"
telegram_group_id = -100123456789
bot_token = "123456789:ABCdefGHIjklMNOpqrsTUVwxyz"
default_engine = "claude"  # Optional, defaults to "claude"

[folders.backend]
path = "backend"
topic_id = 123
origin = "git@github.com:user/backend.git"

[folders.frontend]
path = "frontend"
topic_id = 456

[folders.knowledge-vault]
path = "vault"
topic_id = 789
description = "Team knowledge base"

[workers.ralph]
enabled = false
default_max_iterations = 3

# Per-engine configuration sections
[claude]
model = "opus"
allowed_tools = ["Bash", "Read", "Edit", "Write"]

Folders can be git repos or plain directories. The type is auto-detected based on .git presence.

commands

CLI

pochi init [folder]     # initialize workspace (prompts for bot token + group ID)
pochi                   # run the bot
pochi info              # show workspace info
pochi --version         # show version
pochi --debug           # enable debug logging
pochi --no-final-notify # edit progress message instead of sending new final message

Telegram (General topic)

command description
/clone <name> <url> [path] clone a git repo and create a topic
/create <name> [--no-git] create a new folder (with git init by default)
/add <name> <path> add an existing folder to the workspace
/list list all folders in the workspace
/remove <name> remove folder from workspace (keeps files)
/status show workspace status
/engine show current default engine and available engines
/engine <name> set default engine for new conversations
/help show available commands

Telegram (folder topics)

command description
/ralph <prompt> [--max-iterations N] start iterative Claude loop
/cancel cancel the current run or ralph loop

or just send a message to chat with your AI agent!

ralph wiggum loops

ralph loops run Claude iteratively, asking it to review its own work after each iteration. Claude signals completion by responding with RALPH_COMPLETE: <summary>.

/ralph-loop implement user authentication with tests --max-iterations 5

enable always-on ralph mode in config:

[workers.ralph]
enabled = true
default_max_iterations = 3

resume tokens

every response includes a resume line:

`claude --resume abc123`
  • reply to a message with a resume line to continue that thread
  • copy the command to resume interactively in your terminal
  • resume tokens are scoped to topics: topic:123:abc123

notes

  • the bot only responds to messages in the configured group
  • run only one pochi instance per bot token
  • run claude once interactively in each folder to trust the directory

development

see docs/specification.md and docs/developing.md.

acknowledgments

Built on top of takopi.

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

pochi-0.1.1.tar.gz (51.6 kB view details)

Uploaded Source

Built Distribution

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

pochi-0.1.1-py3-none-any.whl (64.5 kB view details)

Uploaded Python 3

File details

Details for the file pochi-0.1.1.tar.gz.

File metadata

  • Download URL: pochi-0.1.1.tar.gz
  • Upload date:
  • Size: 51.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pochi-0.1.1.tar.gz
Algorithm Hash digest
SHA256 5e983240158e989f710a466d987d993888739d49006f321b1e8b21a4a71e99f5
MD5 cde4447f56980475dcb7f82e597aba35
BLAKE2b-256 7ccf2484a0c33cb9466be320248102436701d741ec70d227ac09ef47ca03a87a

See more details on using hashes here.

Provenance

The following attestation bundles were made for pochi-0.1.1.tar.gz:

Publisher: release.yml on asianviking/pochi

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

File details

Details for the file pochi-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: pochi-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 64.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pochi-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 60b8217538aaca0bc309c0a864c2ea1706cd6fdd5c970cd55a5291ccf0b3bbc6
MD5 4a91ef8cf59660662a472274c336a1a6
BLAKE2b-256 d889fed88414b997bbcc2136c37908029eba7ed4912681b602f9a2309b263a46

See more details on using hashes here.

Provenance

The following attestation bundles were made for pochi-0.1.1-py3-none-any.whl:

Publisher: release.yml on asianviking/pochi

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