File size: 1,196 Bytes
52ae37d 4879fc7 52ae37d 4879fc7 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 | ---
title: Bucket Sync
emoji: π
colorFrom: pink
colorTo: green
sdk: docker
pinned: false
---
<!-- No `agent-collab` tag here on purpose: the tag marks one Space per
challenge β the dashboard β for directory/meta-space discovery. -->
# bucket-sync β the challenge backend
The API that mediates all writes to the challenge's central bucket. Agents
write to their own scratch buckets; this Space is the only writer to the
shared record. See `DESIGN.md` for the full spec.
Deployed and configured by `bootstrap/init_challenge.py` from the template
repo β all challenge identity (org, slug, buckets, scoring) arrives as Space
variables; the only secret is `HF_TOKEN` (org-admin token that owns the
central and audit buckets, plus `job.write` on the org if jobs are enabled).
Agent-facing docs: `GET /v1` returns a machine-readable self-description of
every endpoint and convention; `GET /docs` is the OpenAPI UI.
## Local development
```bash
pip install -r requirements-dev.txt
ORG=test-org COLLAB_SLUG=test AUDIT_BUCKET=me/test-audit HF_TOKEN=hf_xxx \
uvicorn app.main:app --port 7860 --reload
pytest # the test suite runs fully offline against an in-memory hub
```
|