Skip to main content

Analytics dashboard

AfriAnnotate ships dashboards at two levels:

  • Organisation metrics — across all projects in the org. Useful for org admins doing capacity planning, contributor leaderboards, monthly reporting.
  • Project metrics — scoped to one project. Useful for project managers monitoring annotation velocity, lead times, agreement trends.

This is an AfriAnnotate-specific surface — built-in dashboards beyond what upstream Label Studio provides out of the box.

Where they live​

  • Organization → Analytics (/organization/analytics; the old /organization/metrics URL redirects). Visible to Managers and above (Owner / Admin / Manager, plus platform staff) — Annotators, Reviewers and Guests don't get the Organization area.
  • Project → Dashboard in the project view, for project managers.

What's on the organisation dashboard​

The org Analytics page is a set of panels driven by the endpoints below (the exact set evolves with releases):

PanelWhat it shows
Overview KPIsMembers, projects, annotations — totals and in-range counts for the selected period
Annotations over timeAnnotation counts bucketed by day / week / month across all projects, with the previous period for comparison
GrowthNew projects and new members created in the range
Top contributorsAnnotators ranked by output, with each person's share of the period's annotations
Audit activityAudit events across the org, bucketed over time plus a recent feed
Label distributionWhich labels are being applied across the org's projects — its own sub-page at /organization/analytics/labels

Quality signals — per-annotator evaluations and quality by project — live on the Quality tab (Owner / Admin). Evaluations can be exported as CSV through the API below.

What's on the project dashboard​

Panels include:

PanelWhat it shows
OverviewTasks, annotations, completion %, reviewer accept rate
TimeseriesDay-by-day annotation counts for this project, optionally stacked by annotator
AnnotatorsLeaderboard of annotators on this project — count, lead time, agreement, skip rate
AgreementDistribution of precomputed_agreement scores across tasks (see Agreement metrics for what populates these)

Further project endpoints (insights, readiness, delivery, evaluations) back the rest of the dashboard — see below.

Query semantics​

All metric endpoints accept these query parameters:

  • range=7d | 30d | 90d | 1y | all — presets (default 30d; an unknown value falls back to 30d). Each preset has a default bucket: 7d / 30d → day, 90d / 1y → week, all → month.
  • from=<iso-date> & to=<iso-date> & bucket=day|week|month — explicit range (to is inclusive) + bucket size (default day)

If both range and from/to are passed, from/to wins.

Time-zone handling​

Buckets are computed in UTC — a "day" bucket is a UTC calendar day. There is no tz parameter; convert client-side if you need local days.

Scope​

Org dashboards are scoped to the caller's active organisation. There is no cross-organisation toggle — platform staff see the same per-org view as an Owner.

API​

Every dashboard panel has a corresponding endpoint:

Organisation endpoints​

# Overview KPIs
curl "{{platformURL}}/api/organizations/<id>/metrics/overview?range=30d" \
-H "Authorization: Bearer YOUR_PAT"

# Timeseries
curl "{{platformURL}}/api/organizations/<id>/metrics/timeseries?range=90d&bucket=day" \
-H "Authorization: Bearer YOUR_PAT"

# Contributors
curl "{{platformURL}}/api/organizations/<id>/metrics/contributors?range=30d" \
-H "Authorization: Bearer YOUR_PAT"

# Audit activity, bucketed over time (+ recent events)
curl "{{platformURL}}/api/organizations/<id>/metrics/activity?range=30d" \
-H "Authorization: Bearer YOUR_PAT"

# Activity feed (paginated audit events)
curl "{{platformURL}}/api/organizations/<id>/activity?range=30d" \
-H "Authorization: Bearer YOUR_PAT"

# Quality by project
curl "{{platformURL}}/api/organizations/<id>/metrics/quality-by-project" \
-H "Authorization: Bearer YOUR_PAT"

# Per-annotator evaluations (days defaults to 90; optional project= / user=)
curl "{{platformURL}}/api/organizations/<id>/evaluations?days=90" \
-H "Authorization: Bearer YOUR_PAT"

# Export evaluations as CSV
curl "{{platformURL}}/api/organizations/<id>/evaluations/export" \
-H "Authorization: Bearer YOUR_PAT" \
-o evaluations.csv

# Label distribution
curl "{{platformURL}}/api/organizations/<id>/metrics/label-distribution" \
-H "Authorization: Bearer YOUR_PAT"

All organisation endpoints require an org role of Manager or higher (or platform staff).

Project endpoints​

# Project overview
curl "{{platformURL}}/api/projects/<id>/metrics/overview?range=30d" \
-H "Authorization: Bearer YOUR_PAT"

# Project timeseries
curl "{{platformURL}}/api/projects/<id>/metrics/timeseries?range=30d&bucket=day" \
-H "Authorization: Bearer YOUR_PAT"

# Project annotator leaderboard
curl "{{platformURL}}/api/projects/<id>/metrics/annotators?range=30d" \
-H "Authorization: Bearer YOUR_PAT"

# Project agreement distribution
curl "{{platformURL}}/api/projects/<id>/metrics/agreement" \
-H "Authorization: Bearer YOUR_PAT"

# Also: /metrics/insights, /metrics/readiness, /metrics/delivery,
# /metrics/evaluations

All endpoints return JSON. Time-bucketed responses use ISO 8601 date strings as bucket keys for easy parsing.

Performance notes​

  • Overview and the activity feed read counts and audit rows directly — fast on any reasonable database size.
  • Timeseries, Contributors and Evaluations group over the annotations / evaluations tables — heavier on very large orgs; narrow the range if they feel slow.
  • Agreement distribution reads Task.precomputed_agreement, which is computed when annotations are submitted, so dashboard reads scale with tasks, not annotations.

Responses are computed per request — there is no server-side cache to wait out after a change.

Embedding metrics elsewhere​

The metric endpoints are public-ish JSON — any tool that can hit an authenticated URL + parse JSON can ingest them. Common patterns:

  • Slack daily digest — a cron that hits the overview endpoint once a day and posts the count delta to a Slack channel
  • Grafana dashboard — point Grafana at the timeseries endpoints via the JSON-API plugin
  • Internal BI — schedule a Cloud Function to pull the CSV exports nightly and pipe to your warehouse

The endpoints don't currently emit Prometheus-format metrics directly; if that's important, write a thin adapter that reformats them.

What's next​

Activity details​

Activity entries show who did what and when; opening an entry reveals the full record — actor, exact timestamp, metadata, and event id. The platform Audit log works the same way. Top contributors are ranked by output with each person's share of the period's annotations.