I Gave My Git History to a Free AI Bot. It Broke 7 Times in 3 Days
Описание и применение
Автоматизация nightly‑сводов Git‑логов с помощью бесплатного LLM‑бота привела к 7 сбоям за 3 дня. После исправлений, включая увеличение таймаута, ограничение токенов, обработку JSON‑файлов и ограничение памяти, бот стабилизировался.
Задача
Automating nightly Git log summaries with a free AI bot caused repeated failures due to timeouts, rate limits, memory limits, and parsing issues.
Результат
After seven iterations, the bot runs reliably, respecting free tier limits and handling edge cases, producing accurate daily commit summaries for Slack.
Рабочий процесс
- 1. Schedule cron at 23:00 to run summarize.py
- 2. Retrieve last 20 commits via git log
- 3. Send commits to LLM with system prompt
- 4. Receive JSON summary, strip code fences, parse JSON
- 5. Post summary to Slack webhook
- 6. Monitor usage dashboard and adjust input size
- 7. Apply retry, timeout, and memory limits to avoid failures
Доказательства
The first run died after 60 seconds.
openai.RateLimitError: Error code: 429 - quota exceeded
The process vanished. No error in the log. Just a Killed line.
- Дата записи: 2026-09-05T14:14:20.665Z