Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

Build a Nightly SQL Review Bot with Free Models and a Free Server

Описание и применение

Ночной бот для проверки SQL использует бесплатные модели и локальный сервер, автоматически сканирует слияния, выявляет риски и публикует отчёт.

Задача

A costly JOIN without an index stalled the checkout pipeline for six minutes and was missed in code review.

Результат

The bot runs nightly, identifies missing filters, limits, and inefficient joins, and outputs a concise report, reducing manual review effort.

Рабочий процесс

  • Deploy a free local server (Docker or Kubernetes) exposing an OpenAI-compatible API.
  • Configure the client to use the free model via the local endpoint.
  • Write a script that extracts SQL statements from commits made since midnight and sends each to the local model for review.
  • Schedule the script to run nightly (cron or GitHub Actions).
  • Evaluate the bot against a labeled dataset and adjust expectations with a decision table.

Доказательства

Pre-commit hooks interrupt developers. They create friction, prompt rework, and get disabled after the third false positive.

Источник

A nightly bot runs after everyone goes home. It scans the queries merged during the day, flags risky patterns, and posts a report to a channel or file.

Источник

  • Дата записи: 2026-09-05T18:22:33.254Z