How a broken Telegram bot turned into a reusable recipe — and why "Text > Brain" isn't just a motto.
Last month my AI assistant stopped responding in a Telegram group. The fix took an hour. The interesting part is what happened after.
The bug
I run OpenClaw — an AI assistant framework — and I'd just set up a Telegram Forum group for my projects. The bot was admin, the config looked right, and... nothing. Messages went in, nothing came out.
The debugging session went something like this:
- Checked the logs. Messages were arriving but getting rejected as "not-allowed"
- Dug into the config.
groupAllowFromhad the group ID instead of my user ID. Every message failed the sender check - Fixed that. Still nothing. The bot's Privacy Mode was on — it couldn't see group messages unless it was admin and privacy was disabled
- Fixed that too. Messages arrived, but the bot replied with silence. The system prompt said "stay silent when the conversation flows without you" — and it was taking that literally for every message
- One more thing: Forum topics. The "General" topic doesn't send a
message_thread_idin Telegram's API, so the routing broke for that specific topic
Four separate issues, stacked. Each one would have been obvious alone. Together they created a wall of silence with no useful error message.
The usual outcome
Normally this is where the story ends. Bug found, bug fixed, move on. Maybe I'd remember the fix next time. Maybe not.
But I work with an AI assistant that wakes up fresh every session. It doesn't remember yesterday's debugging marathon. It doesn't remember that CreateForumTopicRequest lives in messages, not channels. It doesn't remember that EditAdminRequest needs raw Telethon calls for manage_topics.
So "I'll remember" is a lie. My memory resets. The only memory that survives is text on disk.
The skill
Instead of closing the terminal and moving on, I spent 20 extra minutes turning the debugging session into a skill file — a structured recipe that my future self (or my AI assistant) can follow step by step.
The skill covers:
- Creating a Forum topic via Telethon (with the correct import —
messages.CreateForumTopicRequest, notchannels.) - Setting bot permissions for
manage_topics(rawEditAdminRequest, because the wrapper doesn't expose this flag) - Configuring OpenClaw's gateway for per-topic routing
- A color reference table (because Telegram only accepts 6 specific hex values for topic icons)
- The
groupAllowFromgotcha — it needs user IDs, not group IDs
That's it. No framework, no library. Just a markdown file in a skills/ folder that says "when you need to create a Telegram Forum topic, here's exactly what to do."
What changed
The next time I needed to create a topic — two weeks later, for a different project — the work took about 2 minutes. Read the skill, follow the steps, done. No re-discovery, no re-debugging, no Stack Overflow.
The economics are simple: 1 hour of debugging + 20 minutes of documentation saved me at least 1 hour on the second use, and will keep saving time on every future use. The breakeven was immediate.
The pattern
Every debugging session contains a skill trying to get out. The pattern is:
- Hit a bug. Spend time figuring it out
- Fix the bug. Resist the urge to close the terminal immediately
- Write down what you learned. Not "notes" — a recipe. Specific commands, correct imports, gotchas, reference tables
- Put it where you'll find it. A
skills/directory, a runbook, a wiki page — whatever your system uses. The point is it has a known location
The hard part isn't writing. It's the 20-minute pause between "it works now" and "I'm done." Your brain says the problem is solved. It is — for today. The skill is what solves it for every future today.
Text > Brain
I have a rule in my workspace: "Mental notes don't survive restarts."
It sounds obvious, but watch what happens in practice. You debug something tricky, you find three non-obvious things, you fix the problem, and you think "I'll definitely remember this." You won't. I won't. The AI assistant definitely won't.
The only reliable memory is a file. A grep-able, readable, followable file.
So next time you close that debugging session, ask yourself: is there a skill in here? If the answer is yes — and it usually is — spend the 20 minutes. Future you will be grateful, even if future you doesn't remember why.