mirror of
https://github.com/peterlodri-sec/telegram-contest.git
synced 2026-11-22 00:09:58 +01:00
Telegram bot for the Digital Freedom Contest
- Python 100%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
- Replace editable path dep with PyPI ultragraph-1bit>=0.17.0 - Move CONTEST_BOT_TOKEN exit from import-time to main() - Fixes CI build on GitHub Actions |
||
| .github/workflows | ||
| src/contest_bot | ||
| .env.example | ||
| .gitignore | ||
| LICENSE | ||
| pyproject.toml | ||
| README.md | ||
| uv.lock | ||
| VIDEO_SCRIPT.md | ||
contest-bot — Telegram submission bot for the Digital Freedom Contest
A Telegram bot that accepts video submissions for the Digital Freedom Contest. Users pick a contest, answer two short questions, and submit links to videos on TikTok, Instagram, YouTube, Snapchat, or X. Submissions are stored in SQLite; /admin graph renders a knowledge-graph SVG via ultragraph.
Built to demonstrate that digital freedom is not just a topic — it's something you can build, fork, and run yourself.
quick start
git clone https://github.com/peterlodri-sec/telegram-contest.git
cd telegram-contest
cp .env.example .env
# edit .env and set CONTEST_BOT_TOKEN
uv run contest-bot
what it does
- Multi-step conversation via
python-telegram-bot: select contest → answer questions → submit links. - Link validation: accepts only TikTok, Instagram, YouTube, Snapchat, X/Twitter URLs.
- Bulk submissions: multiple links in a single message, separated by newlines.
- SQLite persistence: users, submissions, and conversation state.
- Admin commands:
/admin— stats dashboard/admin graph— SVG knowledge graph of all submissions
- Knowledge graph: built with
ultragraph, rendered as an SVG grouped by platform with status colors.
environment variables
| Variable | Required | Default |
|---|---|---|
CONTEST_BOT_TOKEN |
yes | — |
CONTEST_ADMIN_IDS |
no | (all users allowed) |
CONTEST_DB_PATH |
no | ./contest.db |
CONTEST_LOG_LEVEL |
no | INFO |
CONTEST_DEADLINE |
no | TBD |
stack
- Python 3.13+
python-telegram-botultragraph-1bit- SQLite (WAL mode)
uvfor packaging
genesis / provenance
This repository participates in the Vaked provenance chain.
⟳ 7c242080f5f821e5eaf563fe2208d60632c451687baf65f4fe8e4a0d226e3ecf
This is the Vaked genesis seal, notarized in DNS (dig TXT vaked.dev). It anchors the intent of the work: open systems, structural honesty, and the right to inspect, modify, and redistribute the code. The bot is MIT-licensed, but the provenance is immutable.
related
- pocoo.vaked.dev — blog post about the bot and the video submission
- VIDEO_SCRIPT.md — full script and production guide for the contest video
- ultragraph — the 1-bit ternary byte-graph library
- Vaked — structural honesty for agentic systems
license
MIT — see LICENSE.