Óscar Romero Quincoces

Projects / Products and tools

Telegram task agent

Turns team chat into a task list

In daily use2026Albujón Energy
Team group on TelegramGrupo del equipo en Telegram text messages and voice notesmensajes de texto y notas de voz voice notes: Gemininotas de voz: Gemini transcribes them firstlas transcribe antes Claude classifiesClaude clasifica new task, update, done or noisetarea nueva, avance, hecha o ruido PostgresPostgres every task and its statuscada tarea y su estado Weekday scheduleHorario de lunes a viernes 8:30 open tasks, 17:00 review8:30 tareas abiertas, 17:00 repaso posts the summary,publica el resumen, with buttons tocon botones para confirm what's doneconfirmar lo hecho
Figure 1. How the bot works. It has no screen of its own, so this is a diagram rather than a screenshot

Summary

A bot in Albujón Energy's team group. It reads every message and voice note, picks out new tasks, updates and finished work, and posts a summary at 8:30 and 17:00 on weekdays, with buttons to confirm what got done. The team uses it every day.

Python, Claude for classification, Gemini for voice notes and Postgres, running on Railway.

The problem

In a small team, work gets handed out in the group chat and in voice notes, and then it disappears up the scroll. I wanted the task list to build itself from the conversation, without asking anyone to change how they talk.

What it does

The bot reads every message in Albujón Energy's team group and classifies it as a new task, an update, a context problem or finished work. It reacts with a thumbs-up when it records something and stays quiet when a message is just chat. Voice notes are transcribed with Gemini and go through the same pipeline; photos and videos only get an acknowledgement.

  • At 8:30 on weekdays it posts the open tasks; at 17:00 it posts the day's review.
  • Tasks waiting for confirmation come with inline buttons, done or still open, and that mode expires at midnight.
  • Commands let anyone list, create, close or change the state of a task by hand. The team uses it every day.

How it's built

Plain Python split into handlers and scheduled jobs, the LLM calls (Claude to classify, Gemini to transcribe) and a Postgres layer with a connection pool. It runs on Railway as a worker with no public port, next to a managed Postgres, and every push to main deploys it.

What I learned

In python-telegram-bot, the days of a daily job count from Sunday as 0, while Python's own weekday() starts with Monday as 0. Writing Monday to Friday the Python way silently drops Friday. I fixed the days and added a second check with Python's convention as a safety net.

Built with

Pythonpython-telegram-botClaude (classification)Gemini (voice transcription)PostgreSQL (psycopg 3)Railway