Breeding Values (EBV)
The /api/ebv endpoints provide access to genetic evaluation results: computation runs, EBV per queen, and consolidated results.
Runs
| Method | Route | Description |
|---|---|---|
GET | /api/ebv/runs | List runs (?status, ?limit, ?offset) |
GET | /api/ebv/runs/[id] | Run detail + artifacts + summary |
Each run represents a complete execution of the genetic pipeline. Possible statuses are: pending, running, completed, failed.
Results
| Method | Route | Description |
|---|---|---|
GET | /api/ebv/latest | Latest results (?trait, ?entity_type, ?sort, ?order) |
GET | /api/ebv/queens/[id] | EBV for a queen (?run_id, ?history=true) |
EBV Response Format
{
"trait": "honey",
"raw_value": 2.45,
"normalized_value": 112,
"reliability_r2": 0.68,
"run_id": "uuid-of-the-run",
"entity_type": "queen"
}
| Field | Description |
|---|---|
trait | Trait name (honey, gentleness, vigor, wintering, swarming, comb_sitting, hyg6, hyg24) |
raw_value | Raw EBV value |
normalized_value | BeeBreed-like normalized value (100 + 10 x (raw - mean) / std) |
reliability_r2 | Reliability r² (0 to 1) |
run_id | Computation run identifier |
entity_type | Entity type (queen or worker) |
The ?history=true parameter on /api/ebv/queens/[id] returns the EBV history across all runs to visualize the evolution over time.
Compute (admin only)
The compute endpoints trigger the various stages of the genetic pipeline. They require admin authentication (HMAC cookie).
| Method | Route | Description |
|---|---|---|
POST | /api/env/compute | Environment pipeline (geocoding + weather) |
POST | /api/xgb/compute | XGBoost correction (environmental effect) |
POST | /api/ebv/compute | BLUPF90 (continuous traits: honey) |
POST | /api/thrg/compute | THRGIBBS + normalization (ordinal traits) |
POST | /api/ebv/oneshot | Full pipeline (env + xgb + blup + thrg) |
Admin required
Compute endpoints require a valid admin HMAC cookie. They trigger heavy computations on the worker and should only be used by administrators.
See also: Evaluations | Queens | Export