← All case studies

case · 003

Smart-contract risk monitor, 16 chains.

A continuously-running feed poller that watches 16 chains' Blockscout v2 explorers for newly verified smart contracts, runs each one through Slither (static analysis) plus a multi-label ML risk classifier, and persists contracts and findings to PostgreSQL with a per-chain cursor that's decoupled from analysis so crashes never cause re-fetching or data loss. Served to operators through an OAuth-gated dashboard with contract listings, findings, chain coverage, and an analysis console.

Client
Anonymised — risk monitor
Year
2026
Chains
Ethereum, Polygon, Optimism, Arbitrum, Base, BNB, Gnosis, Celo +9 more (16 total)
Role
Backend · recovery · dashboard rebuild

fig. 0.1

Cover image · pipeline diagram

The original linux install was lost when that machine was wiped, so we reconstructed everything from the surviving session logs of two production cron runs. The key insight those logs proved: cursor persistence was decoupled from analysis. The cursor advanced and was written to disk *before* the slow Slither/ML stage ran. A crash or timeout mid-analysis therefore never caused re-fetching — run 1 timed out at 64/110, run 2 timed out at 65/110 but still finished 110 fetched / 30 saved / 104 findings in the background.

The other key property: per-chain isolation. One chain failing — optimism 301, base 500 — degraded only that chain. The other 15 still completed and the run still exited 0.

16

chains covered by Blockscout v2 polling

7

risk vector categories classified by the ML model

2

production cron runs recovered verbatim

The rewritten pipeline loads the chain registry from a single source of truth, fetches new verified contracts past the cursor, persists the cursor immediately, then runs Slither and the ML model over the new contracts in parallel. Each per-contract output (`[n/total] on (0xADDR...)`) is logged with its Slither finding count and ML vector set + severity. The dashboard exposes a contracts table, a findings browser, and an analysis console where operators can paste raw source or a contract address for a one-off run.

The cursor-and-analysis separation was preserved end-to-end. The ML model itself is multi-label over the vector vocabulary (selfdestruct, access_control, uninitialized_storage, unchecked_call, frontrunning, integer_overflow, dos) — slimmer than a regression, simpler to retrain. PostgreSQL schema versioning via Alembic, FastAPI backend with Pydantic v2 validation, and a Next.js 15 dashboard with middleware-protected routes behind Google OAuth round out the rebuilt platform.

/ stack

on-chain
  • per-chain Blockscout v2 fetcher (API tier + HTML-scrape fallback)
off-chain
  • FastAPI
  • Pydantic v2
  • SQLAlchemy 2.0 async + Alembic
  • PostgreSQL
  • Next.js 15 with OAuth-gated dashboard

next case study

Telegram Mini App on TON..

A mobile-first Telegram Mini App that runs inside Telegram's web view with the Telegram WebApp SDK injected at runtime — a tap-to-earn game loop with mining boosts, daily rewards, task-based progression, referral mechanics, leaderboard rankings, and a full admin panel for task management. Built as a Next.js frontend paired with an Express + Prisma backend, designed to be opened from a Telegram bot without ever installing a separate app.

/ start a project

Have something similar in mind?