Answer Telegram questions from the web, with sources
Answers questions asked in a Telegram chat by searching the web, and replies with the answer and the pages it came from.
What it does
The integration steps this workflow runs, in the order it first runs them.
- 1
TelegramNew message trigger - 2
SerperSearch web - 3
TelegramSend message - 4
OpenAIQuery model
How it works
Everything the template sets up, and what to fill in before the first run.
Someone asks a question in your Telegram chat and gets a written answer back in the same chat, with the pages the answer came from listed under it. The workflow searches the web for the question, reads the top results, and writes the answer from those results only.
The sources listed under every answer are written by the workflow from what the search actually returned, never by the model - so a link in a reply is always a page the search found. The model is told to cite by number, never to write out an address, and to say plainly when the sources do not answer the question rather than guessing. If the search comes back with nothing citable, the chat is told that and no answer is written at all.
To set it up, paste the ID of the chat to watch onto the trigger step. Left blank, the trigger fires for every message your bot receives in any chat it has been added to; filling it in keeps the assistant to one chat. Then fill in the 'subjectsToAnswer' step with what this assistant is for, so it can decline questions outside that. 'sourcesToUse' is how many search results to read and cite, from 1 to 5, and 'minimumQuestionLength' is the number of characters below which a message is treated as chatter rather than a question.
Every reply starts with a fixed line so the workflow recognises its own answers and never searches for one of them, and a long answer is shortened so the reply and its sources still fit inside Telegram's message limit.
Start from a workflow that already works.
Add "Answer Telegram questions from the web, with sources" to your workspace, connect its apps, and make it yours. No credit card required.
Free plan available · No credit card required
