Discord Bot for chatting with your Maestro Agents
翻译准备中
取自仓库 README
正在加载完整 README。 以下为已保存的摘录。
Maestro Relay connects chat platforms to Maestro AI agents through maestro-cli. Discord and Slack ship in the box; Teams, Matrix, and others can be added by dropping in a provider adapter — the kernel is provider-agnostic.
Migrating from discord-maestro? Same codebase, new name. All DISCORD_* env vars work unchanged; the legacy maestro-discord binary has been retired in favour of maestro-relay. See "Migration" below.查看完整 README ↗Maestro Relay connects chat platforms to Maestro AI agents through maestro-cli. Discord and Slack ship in the box; Teams, Matrix, and others can be added by dropping in a provider adapter — the kernel is provider-agnostic.
Migrating from
discord-maestro? Same codebase, new name. AllDISCORD_*env vars work unchanged; the legacymaestro-discordbinary has been retired in favour ofmaestro-relay. See "Migration" below.
/session new or by mentioning the bot)PATHbash -c "$(curl -fsSL https://raw.githubusercontent.com/RunMaestro/Maestro-Relay/main/install.sh)"
After install:
maestro-relay-ctl start # boot the bot
maestro-relay-ctl logs # tail logs
maestro-relay-ctl status # service status
maestro-relay-ctl update # upgrade to latest release (preserves config)
maestro-relay-ctl uninstall # remove install + service files
| Path | Purpose |
|---|---|
~/.local/share/maestro-relay/ | Installed bot (built JS + dependencies) |
~/.config/maestro-relay/.env | Configuration (preserved across updates) |
~/.local/bin/maestro-relay-ctl | Service control wrapper |
~/.local/bin/maestro-relay | Agent → chat CLI (send, notify, status) |
| systemd user / launchd agent | Auto-start unit |
Override any of these with MAESTRO_RELAY_HOME, XDG_CONFIG_HOME, or MAESTRO_RELAY_BIN_DIR. Pin a specific version with MAESTRO_RELAY_VERSION=v1.0.0.
Choose a provider module at install time via MAESTRO_RELAY_MODULE (discord or slack).
The installer and maestro-relay-ctl update track the stable channel by default — the latest non-prerelease GitHub release. To try release candidates ahead of a stable cut, opt into the rc channel:
maestro-relay-ctl channel rc # persist the preference, then:
maestro-relay-ctl update # pulls the newest release, prereleases included
maestro-relay-ctl update --rc # …or switch + update in one step
maestro-relay-ctl channel stable # switch back (or: update --stable)
For a fresh install on the RC channel, set the env var:
MAESTRO_RELAY_CHANNEL=rc bash -c "$(curl -fsSL https://raw.githubusercontent.com/RunMaestro/Maestro-Relay/main/install.sh)"
RC builds are published as GitHub prereleases (tags like v0.5.0-rc.1), so the stable channel never picks them up. Pin an exact build with MAESTRO_RELAY_VERSION=vX.Y.Z-rc.N. The persisted channel lives at ~/.config/maestro-relay/channel.
git clone https://github.com/RunMaestro/Maestro-Relay.git
cd Maestro-Relay
npm install
cp .env.example .env
Set core values in .env:
ENABLED_PROVIDERS=discord # comma-separated; default 'discord'. Use 'slack' or 'discord,slack' for multi-provider deployments
API_PORT=3457 # optional, default 3457
Then fill in the provider-specific keys. The Discord provider needs DISCORD_BOT_TOKEN, DISCORD_CLIENT_ID, and DISCORD_GUILD_ID — see docs/discord.md for bot setup, the full env-var reference, and slash-command deployment. The Slack provider needs SLACK_BOT_TOKEN, SLACK_SIGNING_SECRET, SLACK_TEAM_ID, and SLACK_APP_ID — see docs/slack.md. For optional voice transcription (Discord), see docs/voice.md.
npm run deploy-commands
npm run dev
Optional for source-based local CLI usage:
npm link
npm run build
npm start
npm test
Coverage:
npm run build && node --test --experimental-test-coverage dist/__tests__/**/*.test.js
| Provider | Docs | Status |
|---|---|---|
| Discord | docs/discord.md — bot setup, env vars, slash commands, runtime behavior | Built-in |
| Slack | docs/slack.md — app setup, env vars, slash commands, runtime behavior | Built-in |
| Teams / Matrix / … | AGENTS-providers.md — provider development guide | Add your own |
Optional voice transcription (whisper.cpp, Discord-only today): docs/voice.md.
Optional ambient mode (Discord-only today): docs/ambient.md. Optional prompt-injection screening for every provider: docs/susfactor.md.
Mention the bot or run /session new in an agent channel to create a thread, then chat — messages are queued and forwarded to the agent via maestro-cli. See docs/architecture.md for the full message flow and kernel/provider split, and AGENTS-providers.md for the provider-development guide.
Agents can push messages to chat via the maestro-relay CLI / HTTP API. See docs/api.md for usage, endpoints, and error codes.
discord-maestroThis project was renamed from discord-maestro / Maestro-Discord. To smooth upgrades:
maestro-discord / maestro-bridge binaries have been retired; install + upgrade now scrub any leftover symlinks. Update any scripts that invoke them to maestro-relay send ….DISCORD_* env vars are unchanged. New optional ENABLED_PROVIDERS defaults to discord.agent_channels gains a provider column (existing rows default to discord); agent_threads is renamed to discord_agent_threads with rows preserved. No manual migration needed./api/send endpoint accepts an optional provider field that defaults to discord; existing callers are unaffected.The bridge stores channel ↔ agent mappings in a local SQLite database at maestro-bot.db.
Delete this file to reset all channel bindings.