The problem
Before AI, every crypto company kept a moderation budget: four or five mods answering community questions all day. Most of those questions were already answered in the docs or the whitepaper. Nobody wants to read a long whitepaper, so they ask in Discord instead. For a company that’s a fixed cost spent on repeating what’s already written down.
When LLMs arrived, that looked like a gap AI could fill. But a docs bot only knows what’s written down. In a live community, the useful answers are often in a mod’s reply from last week: a workaround, a date, a link that isn’t in the docs yet. So mods keep answering the same thing, and the bot can’t help with exactly the questions people ask most.
How it works
1Ingest
2Answer
3Learn
The next person who asks gets the mod's answer. Mods answer each question once.
Ingest. Five front doors into one knowledge base: a GitHub docs repo, a hosted docs site like GitBook, a PDF whitepaper, a Medium feed, and mod replies. Each source is split on headings into chunks, embedded with OpenAI’s ada-002, and stored in MongoDB under that community. The demo indexes the Astro Starlight docs. Medium sync pulls the latest articles, so announcements land in the bot’s knowledge without anyone re-uploading.
Answer. Mention the bot in Discord and it embeds the question, pulls the most relevant sections from MongoDB, and passes those sections plus the question to gpt-4o-mini to write a short answer with source links. If the sources don’t cover the question, it says “I don’t know. Please check with admin.” It doesn’t guess.
Learn from mods. When a mod replies in Discord, a small classifier first checks the original message was actually a question. If it was, the reply becomes training data. A job runs every 30–60 minutes and adds new mod answers to what the bot knows. The next person who asks gets the mod’s answer.
Guardrails. Learning from mods can leak internal info, so replies go through a filter before training. Anything that looks like a credential (passwords, tokens, API keys, vault references) is skipped. In the demo, a mod’s reply about where the staging password lives is never learned, and the bot defers to an admin.
- Press the button below to start the conversation.
- Member
Is there a discount code for the workshop?
BotI don't know. Please check with admin.
- Mod
Use the code from the launch post at checkout.
- Member
What's the staging deploy password?
ModIt is in the team vault under "Docs Staging".
- Training job
1 mod answer learned · 1 skipped by the credential filter
- Another member
Any discount for the workshop?
BotUse the code from the launch post at checkout.
source: mod answer - Another member
What's the staging password?
BotI don't know. Please check with admin.
credential filter: never learned
Decisions
Batch training, not real time. A job every 30–60 minutes was enough. A repeat question within the hour is still answered by a mod, and real-time training would have added cost and complexity for no real gain.
“I don’t know” over a guess. A wrong answer in a community channel costs more than no answer. Deferring to an admin also creates the exact moment a mod’s reply can teach the bot. Temperature 0 and a 300-token cap keep answers short and predictable.
Don’t call the LLM when you don’t have to. Communities ask the same thing over and over, so a near-identical past question (similarity above 0.97) reuses its answer. A strong match on a mod’s answer is returned directly. Both skip the model call, which matters when every answer is billed against a community’s credits.
Never cache “I don’t know”. An early version cached them, so a question could keep getting “I don’t know” even after a mod had taught the answer. Dropping them from the cache let the learning loop work.
Stack
Python, FastAPI, MongoDB Atlas, OpenAI text-embedding-ada-002 and gpt-4o-mini, tiktoken, NLTK, PyMuPDF, Discord bot API.
Where it landed
We piloted it with a couple of communities, including Router’s own, with a community manager running it day to day. While it ran, it cut query resolution time by ~35% and saved mods ~10 hours a week.
Over time, tools built entirely around this problem appeared, and we moved to one of them. Soon after, ChatGPT and later Claude could read docs directly, and people started asking them instead.
What I took from it
A team that makes a problem its whole business will usually move faster on it. Seeing others go all-in confirmed the problem was real.
The part with lasting value was learning from moderators, the knowledge that isn’t written down anywhere. That’s where I’d go deeper if I came back to it.