Environment Setup

The monitoring example uses a small local stack. Python calculates metrics, PostgreSQL stores them, and Grafana displays them. Adminer is useful for inspecting the database while developing.

Create the Python environment

Create a dedicated environment for the monitoring code and install the packages in requirements.txt. The current requirements set Evidently to 0.6.7. We keep the newer API example in post-evidently-0.7.

The monitoring project files and Python setup

Store the reference data alongside the model under the local data/ and models/ directories. The repository ignores their generated contents, so each learner can create them locally.

Start the services

The Compose file defines the database, Adminer, and Grafana. Use volumes for database state and mount Grafana configuration so the data source survives a container restart.

PostgreSQL and Grafana services in Docker Compose

Run docker-compose up to start the stack, then open Grafana at http://localhost:3000. The example uses admin and admin as default credentials, while Adminer provides a separate browser interface for checking the PostgreSQL tables.

The local monitoring dashboard

Optional analytics

Optional analytics are off unless you allow them. Your choice does not affect access to DataTalks.Club, Slack, events, or courses.

Current choice: not chosen.

Privacy Policy

If you allow analytics, self-hosted Umami counts anonymous public pageviews without analytics cookies. Private account and learning pages are excluded. Read the Privacy Policy for the complete data boundary.