discord-community-manager avatar

discord-community-manager

AI community manager for Discord, Telegram, and Slack β€” answers FAQs and welcomes new members

communitydiscordtelegramslackfaqsupportchat-botgroup-chatmoderation
by openhatchβ€’about 2 months ago

Quick Start

# Install and run
openhatch run @openhatch/discord-community-manager

Template Contents

Browse files before installing this template.

Loading template files…

About

Discord Community Manager Agent

πŸ€– An AI-powered community manager for Discord servers, Telegram groups, and Slack workspaces β€” answers FAQs, welcomes new members, and keeps conversations on track.

What It Does

This agent acts as a helpful, always-on community manager in your group chats. It monitors conversations, answers frequently asked questions, welcomes new members, and provides helpful resources β€” all while respecting conversation flow and only jumping in when mentioned or when it can genuinely help.

Perfect for:

  • Discord servers with active Q&A channels
  • Telegram groups that need FAQ automation
  • Slack workspaces with community channels
  • Open source projects with support channels
  • NFT/crypto communities with repetitive questions

Key Features

βœ… Smart FAQ Answering β€” Pre-loaded knowledge base for common questions
βœ… New Member Welcoming β€” Friendly onboarding messages (when appropriate)
βœ… Mention-Only Mode β€” Only responds when @mentioned in groups (respects conversation flow)
βœ… Customizable Knowledge Base β€” Edit MEMORY.md to teach it about your community
βœ… Multi-Platform β€” Works with Discord, Telegram, Slack, Signal
βœ… Lightweight & Fast β€” Uses Claude Haiku for instant responses
βœ… Read-Only in Groups β€” Safe for public channels, no memory writes

Quick Start

# Install from Hatchery
hatchery run @openclaw/discord-community-manager my-community-bot

# Configure your messaging platform
cd ~/.hatchery/instances/my-community-bot
cp workspace/.env.example .env
nano .env  # Add your TELEGRAM_BOT_TOKEN or DISCORD_BOT_TOKEN

# Customize the knowledge base
nano workspace/MEMORY.md  # Add your FAQs, resources, community info

# Start the agent
hatchery start my-community-bot

Configuration

Required Environment Variables

Choose ONE messaging platform:

# For Telegram
TELEGRAM_BOT_TOKEN=your_bot_token_here
# Get from @BotFather: https://t.me/botfather

# For Discord
DISCORD_BOT_TOKEN=your_bot_token_here
# Get from: https://discord.com/developers/applications

# For Slack
SLACK_BOT_TOKEN=xoxb-your-token-here
SLACK_APP_TOKEN=xapp-your-token-here
# Get from: https://api.slack.com/apps

Customizing Your Knowledge Base

Edit workspace/MEMORY.md to teach the agent about your community:

## Common Questions

### "How do I get started?"
[Your onboarding process here]

### "Where can I find the documentation?"
Docs: https://your-docs-url.com

### "What are the server rules?"
1. Be respectful
2. No spam
3. Stay on topic

The agent will use this knowledge base to answer questions accurately.

Usage Examples

Basic Q&A

User in Discord:

@CommunityBot where can I find the docs?

Agent:

πŸ“š You can find our documentation at https://docs.yourproject.com β€” the Getting Started guide is a great place to begin!

New Member Welcome

When a new user joins (if your platform supports join events):

Agent:

πŸ‘‹ Welcome to the server, @newuser! Feel free to introduce yourself in #introductions. If you have questions, just @mention me or check out our docs at https://docs.yourproject.com

Handling Unknown Questions

User:

@CommunityBot what's the roadmap for Q3?

Agent:

I don't have specific information about the Q3 roadmap in my knowledge base. @mods might be able to help with that question!

How It Works

Architecture

  1. Group Session Only β€” Agent operates in group session mode (public, read-only)
  2. Mention Detection β€” Only responds when @mentioned (configurable)
  3. Knowledge Lookup β€” Searches MEMORY.md for relevant answers
  4. Context-Aware β€” Reads recent messages to understand context
  5. Safe & Sandboxed β€” No write access, can't execute commands

Session Security

  • No workspace writes β€” Agent can't modify files in group sessions
  • No command execution β€” Can't run shell commands
  • Web fetch only β€” Can fetch URLs to provide information
  • No sensitive data β€” Doesn't store conversation logs

Model Choice

Uses Claude Haiku for:

  • ⚑ Fast responses β€” Sub-second reply times
  • πŸ’° Low cost β€” Perfect for high-volume community channels
  • βœ… Good enough β€” FAQ answering doesn't need Opus-level reasoning

Customization

Adjusting Personality

Edit workspace/SOUL.md to change the agent's tone:

## Tone & Voice
Friendly and helpful, like a knowledgeable community member who's been
around for a while. Casual but not overly chatty. Uses emojis sparingly.

Adding More Knowledge

Add sections to workspace/MEMORY.md:

## Project Resources
- GitHub: https://github.com/yourorg/yourproject
- Discord: https://discord.gg/yourserver
- Twitter: @yourproject

## Common Issues
### "I can't install the package"
[Troubleshooting steps]

Changing Response Behavior

Edit workspace/AGENTS.md to modify when/how the agent responds:

## When to Respond
- Always: When @mentioned with a direct question
- Sometimes: When you see a FAQ you can answer (even without @mention)
- Never: In off-topic channels, during heated debates

Troubleshooting

Agent Isn't Responding in Groups

Check bot permissions:

  • Discord: Bot needs "Read Messages" and "Send Messages" permissions
  • Telegram: Bot must be added to the group and given permission to read all messages
  • Slack: App needs channels:history, chat:write, app_mentions:read scopes

Verify mention detection:

  • Make sure you're @mentioning the bot correctly
  • Check hatchery logs my-community-bot for errors

Agent Answering Too Often / Not Enough

Edit hatchery.yaml:

channels:
  groupPolicy:
    requireMention: true    # Set false to allow responses without @mention
    allowlist: ["*"]        # Or restrict to specific group IDs

Knowledge Base Not Working

  • Make sure MEMORY.md is well-structured with clear headings
  • Use simple, direct language
  • Test by asking the agent directly about a topic you added

Rate Limiting / Slow Responses

  • Haiku is fast, but check your API quota at https://console.anthropic.com
  • If hitting limits, consider upgrading your Anthropic plan

Advanced: Multi-Language Support

Add translations to MEMORY.md:

## FAQs (English)
### "How do I start?"
...

## FAQs (EspaΓ±ol)
### "ΒΏCΓ³mo empiezo?"
...

The agent will detect the user's language and respond accordingly.

Best Practices

  1. Start conservative β€” Use requireMention: true initially, relax later if needed
  2. Keep knowledge base current β€” Update FAQs as your project evolves
  3. Monitor for accuracy β€” Check logs to see if the agent is giving good answers
  4. Set expectations β€” Pin a message telling users the bot can help with FAQs
  5. Have human fallback β€” The bot should know when to defer to human mods

Contributing

Found a bug or have a feature request? Open an issue on the OpenClaw GitHub.

Want to improve the template? Submit a PR!

License

MIT License β€” free to use and modify.


Built with OpenClaw β€” Self-hosted AI agents that actually work.

Deploy to Hosted

Stats

Downloads0
Deployments0
Latest Version1.0.0
Runtime SupportAny
Size12.9 KB

Versions

1.0.0about 2 months ago