A lightweight webhook service that listens for GitHub push events, generates plain-English summaries using a local LLM (via Ollama), and posts them to Slack.
Designed for teams where non-technical stakeholders want to stay informed about code changes without reading diffs.
- GitHub sends a push webhook to this service
- The service verifies the HMAC-SHA256 signature
- Commit data (messages, authors, files changed) is sent to a local Ollama model
- An AI-generated summary is posted to a Slack channel
- Python 3.10+
- Ollama running locally with a model pulled (default:
qwen2.5:3b) - A Slack app with an incoming webhook (for posting summaries) and slash commands (for
/pauseand/resume) - A GitHub webhook secret
curl -fsSL https://ollama.com/install.sh | sh
ollama pull qwen2.5:3bpython3 -m venv venv
source venv/bin/activate
pip install -r requirements.txtcp .env.example .env
# Edit .env with your actual valuespython app.pyOr deploy as a systemd service:
[Unit]
Description=Commit Summarizer Webhook
After=network.target ollama.service
[Service]
Type=simple
User=your-user
WorkingDirectory=/path/to/commit-summarizer
ExecStart=/path/to/commit-summarizer/venv/bin/python app.py
EnvironmentFile=/path/to/commit-summarizer/.env
Restart=on-failure
RestartSec=5
[Install]
WantedBy=multi-user.targetIn your repo: Settings → Webhooks → Add webhook
| Field | Value |
|---|---|
| Payload URL | https://your-domain.com/webhook |
| Content type | application/json |
| Secret | (your GITHUB_WEBHOOK_SECRET) |
| Events | Just the push event |
To pause and resume summaries from Slack, add two slash commands to your Slack app:
- https://api.slack.com/apps → your app → Slash Commands → Create New Command
- Command:
/pause - Request URL:
https://your-domain.com/slack/command - Save
- Command:
- Repeat for
/resume(same Request URL) - Basic Information → copy the Signing Secret into
SLACK_SIGNING_SECRET - Get the channel ID where the commands are allowed (right-click the channel → View channel details → bottom of the panel) and put it in
SLACK_ALLOWED_CHANNEL_ID - Reinstall the app to your workspace if Slack prompts you
When paused, the service still ACKs GitHub webhooks but skips the Ollama summary and the Slack post.
POST /webhook— GitHub webhook receiverPOST /slack/command— Slack slash command handler (/pause,/resume)GET /health— Health check (returnspausedstatus)
AGPL 3.0