Small local services for running an OpenCode agent system:
telegram/polls Telegram bots, routes messages to agents, and sends replies.scheduler/runs cron-like jobs fromscheduler/schedule.json.intents/provides a filesystem-backed intent queue for publish, claim, and execute flows.heartbeat/runs agent heartbeat tasks and optional completion notifications.tasking/stores and manages natural-language tasks.automation/contains workflow graph/compiler/runtime experiments.
This repository should only contain source, tests, docs, and sanitized examples. Local runtime state and private config are intentionally ignored:
telegram/agents.jsoncontains bot identities, tokens, and session IDs.scheduler/schedule.jsoncan contain personal jobs and shell commands.telegram/data/,telegram/state/,intents/data/, logs, pid files, and pytest caches are generated runtime data..secrets.json,.env,auth.json, and credential files must remain local.
Before publishing, run a secret scan such as:
rg -i "token|secret|password|api[_-]?key|bot[0-9]+:|/home/[^/]+" .- Copy examples into local private files:
cp telegram/agents.example.json telegram/agents.json
cp scheduler/schedule.example.json scheduler/schedule.json
cp .secrets.example.json ~/.config/opencode/.secrets.json-
Fill in Telegram bot tokens in environment variables or
~/.config/opencode/.secrets.json. -
Configure a default Telegram chat for fallback notifications:
export OPENCODE_TELEGRAM_DEFAULT_CHAT_ID=123456789
export OPENCODE_TELEGRAM_DEFAULT_BOT_TOKEN=123456789:replace-with-token- Run tests:
python3 -m pytest automation/tests scheduler/tests telegram/tests telegram/group-chat/testsThe services assume they are installed under ~/.config/opencode/services and that agent data lives under ~/.config/opencode/data. The code avoids shipping personal Telegram IDs or bot tokens; local deployments provide those through ignored config files or environment variables.