Skip to content

v0.2.0 — Message queue and file batching

Choose a tag to compare

@aebrer aebrer released this 26 Feb 21:12
· 1 commit to master since this release

What's New

Message Queue

Messages arriving while Claude is busy are now queued and processed sequentially. Only one Claude subprocess runs at a time per user, eliminating conversation forks entirely.

  • "Queued..." vs "Thinking..." status indicators so you know what's happening
  • Queue-aware /stop command: interrupts the current task AND clears pending items
  • DONE marker only sent when the queue drains normally (suppressed after /stop)

File Batching

Files sent in rapid succession are collected into a single batch before processing:

  • Media groups (photos/videos sent as album): batched via Telegram's media_group_id
  • Sequential documents: batched via 3s per-user debounce timer
  • Downloads start immediately but the prompt is built only after all files arrive
  • Partial download failures are reported to the user

Robustness

  • Exception handling in queue processor with user notification
  • Unique file naming ({message_id}_{filename}) prevents disk overwrites
  • Extracted _build_claude_cmd() and _is_claude_busy() helpers
  • /stop cleans up dangling "Queued..." status messages