Skip to content

bigbrotr

bigbrotr

BigBrotr -- Modular Nostr data archiving and monitoring system.

Six independent async services discover, monitor, and archive data from the Nostr relay network, communicating exclusively through a shared PostgreSQL database.

Architecture follows a diamond DAG dependency structure where imports flow strictly downward:

              services         Business logic and orchestration
             /   |   \
          core  nips  utils    Infrastructure, protocol, and helpers
             \   |   /
              models           Pure frozen dataclasses (zero I/O)

Attributes:

  • models

    Pure frozen dataclasses. Zero I/O, depends only on stdlib.

  • core

    Connection pool, database facade, base service, exceptions, logging, metrics.

  • nips

    NIP-11 relay information, NIP-66 relay monitoring. Has I/O.

  • utils

    DNS resolution, Nostr key management, WebSocket/HTTP transport.

  • services

    Business logic. Six independent services.

Note

For lightweight usage, import directly from subpackages::

from bigbrotr.models import Relay
from bigbrotr.core import Brotr

Top-level imports (from bigbrotr import Relay) use lazy loading and resolve on first access.