Skip to content

BaseIntelligence/prism

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

145 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

PRISM

An "ability to learn" ML challenge β€” two-script submissions, locked data, challenge-owned scoring.

Overview Β· Miners Β· Validators Β· Architecture Β· Scoring Β· Security

License Bittensor BASE

PRISM Banner


Overview

PRISM is a BASE subnet that measures a model's ability to learn from scratch. Miners submit a two-script bundle β€” architecture.py (build_model(ctx)) and training.py (train(ctx)) β€” and the challenge owns everything else: a locked FineWeb-Edu dataset (read-only, no network) and the scoring. The miner owns the model and the training loop; the challenge owns the data and the score.

Every scored run is re-executed by the challenge under a forced random init, so the score is a prequential (online) compression metric in bits-per-byte β€” the area under the from-scratch loss curve, normalized by bytes consumed. Weights are derived from those scores through the LLM gateway-gated pipeline and published dry-run. Faster learning β‡’ better compression β‡’ better score.

How It Works

flowchart LR
    M[Miner two-script bundle] --> G{Static sandbox + param cap}
    G -- reject --> X[[rejected]]
    G --> L{LLM gateway hard gate}
    L -- reject --> X
    L --> A[Master assigns 1 GPU work unit]
    A --> V[Validator re-executes<br/>forced random init]
    V --> S[Prequential bpb + held-out delta]
    S --> W[Two-tier dry-run weights]
Loading
  1. Submit β€” a signed architecture.py + training.py bundle (a single combined module is rejected).
  2. Static gates β€” AST sandbox, 150M parameter cap, single-node multi-GPU contract; any failure is terminal before GPU.
  3. LLM hard gate β€” a strong model reviews both scripts via the master gateway; a reject is terminal.
  4. Forced-init re-execution β€” one validator re-runs the loop on the locked FineWeb-Edu train split and captures the online loss itself (miner-reported numbers are ignored).
  5. Scoring β€” the master computes prequential bits-per-byte plus a secret held-out delta tie-breaker.
  6. Weights β€” emission splits two-tier (best architecture 0.60 / best training variant 0.40), published dry-run via get_weights (never on-chain here).

Anti-Cheat By Construction

Common cheats are inert, not merely detected:

  • No pretrained weights β€” forced random init makes smuggled weights inert; an anomalous step-0 loss zeroes the score; the container runs network=none.
  • No metric gaming β€” the challenge recomputes the metric from the loss it captured; miner-reported numbers and manifests are ignored.
  • No memorization β€” the secret val/test splits never leave the master; an excessive train-vs-held-out gap is penalized.
  • Deterministic β€” fixed seeds and a challenge-controlled data order reproduce the same score within tolerance.

Worker Plane (optional)

PRISM can move GPU re-execution onto miner-funded workers (deployed on Lium/Targon via the BASE base worker CLI). Validators then run verify-only plausibility checks plus probabilistic audits, and each result carries an ExecutionProof (manifest hash + worker sr25519 signature, with optional image-digest and attestation tiers). Gated behind worker_plane (default off). See the worker deployment guide.

Documentation

Guide Contents
Overview The subnet in one page
Miner guide Build and submit a two-script bundle
Validator guide Run evaluation on your own broker
Architecture Service design and forced-init re-execution
Submission format The two-script contract and PrismContext
Scoring & rewards Prequential bits-per-byte and tie-breakers
Scaling Single-node multi-GPU contract
Security model Sandbox, LLM gate, anti-cheat
API Internal and public routes
Operators Deploy and run

Development

uv run ruff check .
uv run mypy
uv run pytest --cov=prism_challenge --cov-fail-under=80

GPU re-execution, HuggingFace publication, and LLM provider calls are mocked in tests; the real GPU, HuggingFace token, and provider keys are wired only at deploy.

License

Apache-2.0

About

[πŸ”¬] Prism is a Platform challenge for decentralized neural architecture search, where miners submit architectures and training recipes to discover scalable AI improvements through competitive evaluation.

Resources

License

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors