11Glassbox Arena
30:00 MOCK

8090-oriented system design rehearsal · mock 11

Evaluate agents under adversarial daylight.

A 30-minute mock for public/private holdouts, sandboxing untrusted submissions, deterministic scoring, anti-gaming controls, slice diagnostics, and reproducible attestations.

System
Evaluation-as-a-service for code/agent/model submissions
Threat
Entrant containers, leaderboard probing, hidden-label leakage
Deep dives
Sandbox reproducibility · anti-gaming score design
Clock
12 questions · 00:00–30:00
Output
Signed run + per-slice scorecard + release decision
Practice-only numbers. Every volume, latency, cost, and organization count on this page is an invented mock constraint—not an 8090 company fact.

Before the clock

An evaluator is a security boundary and a product specification.

If the harness ignores failed cases, normalizes malformed output creatively, leaks hidden labels, or runs a submission twice, the leaderboard rewards the wrong behavior. The scoring implementation—not the prose README—is the executable contract.

Research dossier ↗
Public holdout

A labeled or feedback-rich set used for iteration. It teaches the benchmark and therefore cannot be the final unbiased estimate.

Private holdout

Labels and often inputs withheld from entrants; access is isolated and repeated probing is budgeted to reduce overfitting.

Sandbox

A constrained execution environment: no network, read-only inputs/root, bounded CPU/memory/PIDs/time/output, ephemeral writable space.

Attestation

Signed manifest proving submission digest, dataset, runner, metric code, environment, seeds, outputs, and score.

Opening promptDesign Glassbox Arena, a multi-tenant evaluation platform. Teams submit code or agent containers; the service executes them on public and private datasets, scores deterministically, prevents gaming and leakage, diagnoses hard slices, and emits reproducible signed results. Treat submissions as hostile.
Starting question

The benchmark must deserve trust

Interviewer

Assume 2,000 submissions/day. A full private run has 500,000 cases and each case costs 150 CPU-ms. Design the platform end to end.

Candidate

I see four authority boundaries: specification, execution, ground truth, and scoring. Entrant code is untrusted. Private inputs/labels and metric code are privileged. A score is valid only for an immutable tuple: submission image digest, dataset snapshot, runner image/architecture, metric version, resource profile, environment/seed, and completed case-result manifest.

I will clarify submission languages/artifacts, interactive versus batch agents, network/tool simulation, deterministic requirements, per-case deadline, public feedback budget, risk weights, tenant privacy, and what “reproducible” means across CPU architectures. I will never compute a flattering metric over only successful rows.

Clarification

Define the evaluation lifecycle

Interviewer

What capabilities, actors, and exclusions are in scope?

Candidate

Actors are evaluation author, dataset curator, entrant/engineering team, CI service, sandbox scheduler, human reviewer, security operator, and release approver. The lifecycle is define spec → register versioned datasets/slices/metrics → upload and scan immutable image → public smoke/feedback run → quota-controlled private run → shard execution → strict output validation → deterministic aggregation → slice diagnostics/manual review → signed scorecard → promote or reject.

Functional requirements include private/public partitions, stratified slices, resource profiles, resumable shards, hidden labels, result access controls, leaderboard/project views, run comparison, artifact retention, appeals, and rerun policy. NFRs: no runtime network, P95 queue start under five minutes for smoke runs, full-run completion under two hours, deterministic score equality within an explicit tolerance, 99.9% scheduler availability, and no cross-tenant/label leakage. Foundation-model training is out of scope.

Correctness

Make gaming impossible by construction

Interviewer

What invariants protect the benchmark and the score?

Candidate
  1. Inputs, labels, slice membership, metric code, and submission artifact are content-addressed and immutable for a run.
  2. The entrant sees only the documented input view; labels, private slice names, other tenants, secrets, clocks, network, and host metadata are unavailable.
  3. Exactly one terminal result exists per expected case ID: valid output, timeout, crash, resource breach, malformed output, or missing.
  4. Every terminal category contributes to the denominator and policy-defined loss.
  5. Parser behavior is strict and versioned—no whitespace concatenation, locale guessing, duplicate IDs, NaN/Inf, or silent coercion.
  6. A shard retry never changes submission/dataset/runner tuple; aggregation consumes one fenced accepted attempt per case.
  7. Private feedback and submission frequency are budgeted so leaderboard probing cannot become label extraction.
Estimation

Compute is the first architecture constraint

Interviewer

Size compute, wall time, and result volume. Show the math.

Candidate

Two thousand submissions × 500,000 cases × 0.15 CPU-seconds is 150 million CPU-seconds/day, or 1,736 continuously busy cores. At 70% target utilization I provision around 2,480 cores before P99 and security overhead. This immediately suggests tiers: cheap smoke/public runs for every commit, full private runs only by policy or quota.

With 32 single-core shards, one full submission uses 15,625 cases/shard × .15 s ≈ 39 minutes ideal wall time; startup, skew, retries, and aggregation push the SLO higher. One billion case results/day at an 80-byte compact record is 80 GB/day, while stdout/artifacts must have strict caps and short hot retention. Datasets are mounted once per node/cache by immutable digest rather than copied per run.

2,000 × 500,000 × 0.150 s = 150,000,000 CPU-s/day
150,000,000 ÷ 86,400 = 1,736 busy cores; ÷ 0.70 ≈ 2,480 provisioned cores
500,000 ÷ 32 × .150 s = 2,344 s ≈ 39.1 minutes ideal shard wall time

Evaluation fleet lab

Change the mock workload. The calculator assumes one core per shard.

Interactive
Provisioned cores2,480
Ideal wall/submission39.1 min
Case executions/day1B
Compact results/day80 GB

Does not include container startup, skew, retries, I/O, speculative duplicate attempts, private-set encryption, or retained logs.

Contracts

A score begins with immutable manifests

Interviewer

What are the core entities and APIs? How do you prevent a run from mixing versions?

Candidate

EvaluationSpecVersion pins input/output schemas, resource profile, metric definitions, failure penalties, determinism tolerance, shard plan, and feedback policy. DatasetSnapshot pins objects, case IDs, private labels, and slice membership. Submission pins the scanned image digest and owner. Run pins all three plus runner/environment manifest before scheduling.

Each ShardAttempt has a lease epoch and output object hash; a committed CaseResult names case ID, terminal status, parsed value hash, duration/resource counters, and attempt. Aggregation first validates the complete expected case-ID set, then computes metric components from a canonical ordered record stream. APIs return run/score IDs, never mutable “latest,” and idempotency makes CI retries return the same logical run.

High-level design

Keep labels out of the execution plane

Interviewer

Walk a submission from upload to signed scorecard.

Candidate

The artifact gateway authenticates tenant/team, performs resumable upload, hashes the OCI image/archive, scans malware/SBOM/policy, and stores it immutable. The run API authorizes a spec and run tier, reserves compute quota, pins the manifest, and emits a scheduler event. Dataset staging decrypts private inputs inside the isolated evaluation boundary; label objects are mounted only to the scoring service—not the sandbox.

The scheduler shards stable case IDs, leases sandbox nodes, and records heartbeats/resource usage. Each sandbox has no network, read-only root/input, minimal env, bounded CPU/memory/PIDs/scratch/output/wall time, deterministic clock/randomness contract, and a trusted output side channel. Validators parse strict framing and create one terminal record per case. The aggregator verifies completeness, reduces deterministic metric components, computes slice scorecards, and signs an attestation. Public UI sees only policy-approved feedback.

Deep dive A

Reproducibility needs an environment contract

Interviewer

What makes execution secure and reproducible across reruns?

Candidate

I pin image digest, runner image, kernel/runtime profile, CPU architecture class, locale/timezone, dependency artifacts, input manifest, seeds, thread limits, and metric version. I remove network, cloud metadata, host mounts, privileged syscalls/capabilities, wall-clock detail, and ambient secrets. Namespaces plus cgroups are necessary but I prefer microVMs or equally strong isolation for hostile multi-tenant code.

Determinism is defined by contract. Integer/schema outputs should match exactly. Floating metrics specify canonical decimal parsing, stable ordering, numerically stable reduction, and tolerance. If the submitted model is inherently stochastic, the spec supplies deterministic seeds and may evaluate repeated trials; the attestation records each seed. A clean-room rerun pulls only content-addressed artifacts—never a developer cache.

We store stdout/stderr separately with byte caps and secret scanning. A failed process is not rerun merely to collect stderr because the second execution could behave differently or leak information.

Deep dive B

Score completeness before quality

Interviewer

Design the evaluator so a clever submission cannot game missing cases or parser quirks.

Candidate

Phase one validates the result set: expected IDs, exactly one row each, schema version, bounded UTF-8 framing, allowed finite numbers, checksums, and no extra rows. Every case receives a terminal status. Phase two assigns policy loss: valid prediction metric, timeout penalty, crash penalty, malformed penalty, and often catastrophic-policy penalties. The denominator is the full expected set.

For the reimbursement-style example, MAE over successes alone is wrong: one exact answer plus 499,999 crashes cannot beat a complete imperfect model. Likewise inclusive tolerances must be implemented as abs(error) <= threshold; parser whitespace must never turn 1 2 into 12; declared timeout, memory, output, and PID limits must actually be enforced.

Aggregation uses stable case ordering and pairwise/Kahan-style sums where needed. Metric code has golden unit/boundary/property tests and a separate reference implementation. The scorecard displays coverage, every failure bucket, weighted loss, confidence calibration, and slices—not one scalar alone.

Failure injection 01

The leaderboard rewards a crashing model

Interviewer

Production shows the top submission returned one exact case, crashed on 499,999, and still won because MAE ignored failures. What do you do?

Candidate

I freeze the leaderboard and mark affected scorecards invalid; do not silently recompute history. I issue a new metric/spec version with complete-set validation and explicit terminal penalties, run a migration audit to identify affected runs, and recompute into new signed scorecards linked to the originals. Entrants get a transparent incident note and appeal path.

Prevention adds invariants before metric reduction, golden adversarial submissions that crash/timeout/omit/duplicate/emit NaN, property tests that worsening any case cannot improve coverage-adjusted loss, and differential testing against a simple reference evaluator. Release requires full canonical container execution, not only metric-unit tests.

Failure injection 01 · denominator exploit
Exploit

MAE = error sum ÷ successful cases. Crash strategically on hard cases.

Revision

Materialize every expected case status first; metric denominator and failure loss cover all IDs.

Recovery

Version the evaluator, invalidate—not overwrite—old attestations, recompute, disclose, and allow appeal.

Failure injection 02

Private labels leak through the side channel

Interviewer

A submission infers private labels from per-case timing and repeated leaderboard feedback. Another tries DNS and output bombs. Revise the system.

Candidate

There is no network namespace route or DNS resolver, but I also remove clock precision, host contention signals, case filenames/order clues, and per-case feedback. The runner can randomize or batch case order from a hidden seed and equalize label-dependent scoring work because labels never enter the sandbox. Public results expose coarse aggregate/slice feedback only after minimum cohort sizes.

Private evaluation has submission quotas, cooldowns, similarity detection across near-identical submissions, and a privacy budget for feedback. Final holdout inputs/labels rotate and are inaccessible to normal developers/CI. Output bytes, files, PIDs, syscalls, memory, CPU, scratch, and wall time are bounded outside entrant code; violations become terminal results. Network or sandbox escape attempts trigger security quarantine, not merely a low score.

I monitor unusual query sequences, score deltas, timing correlation, artifacts trying to read host paths, and leaderboard overfitting. A final release decision also uses a never-before-seen confirmation set.

Evaluation quality

One score hides the product risk

Interviewer

The aggregate score improves 4%, but `.49/.99` amounts, decimal mileage, long documents, and low-contrast scans regress. Ship?

Candidate

Not until hard-gate slices pass. Slice definitions are versioned, private where they could leak labels, and can overlap. I require minimum support or confidence intervals; tiny slices trigger qualitative review rather than noisy rank changes. The scorecard shows coverage, central metric, worst-slice loss, catastrophic count, calibration, runtime/resource distribution, and reproducibility across reruns.

Schema/document drift is itself a slice: if prose says mileage integer but data contains floats, the canonical schema and validation behavior must be explicit. We do not coerce silently. I compare against the incumbent per slice and weight business harm, not merely sample frequency. A global gain cannot average away a safety or contractual regression.

Operations and rollout

Capacity, fairness, and audit

Interviewer

How do you schedule fairly, observe the platform, and roll it out?

Candidate

Hierarchical queues allocate tenant/team quotas, interactive smoke capacity, scheduled private evaluations, and low-priority backfills. Weighted fair scheduling with aging prevents one team from occupying the fleet; admission control reserves full-run budget before launch. Shards checkpoint only trusted result manifests; deterministic failures get finite retries, while node failures can retry with the same tuple and fenced attempt.

I monitor queue age, core utilization, sandbox startup, timeout/resource-breach rate, shard retries, result completeness, score determinism, metric drift, label-access attempts, private feedback budget, slice sample health, attestation gaps, and cost per valid evaluation. Rollout begins with internal reference submissions and shadow scoring, then public smoke runs, then small private canaries, then promotion gates. Old evaluator versions remain reproducible but cannot masquerade as current.

Closing minute

The answer in 45 seconds

Interviewer

Summarize your design and its defining trade-off.

Candidate

Glassbox Arena pins submission, dataset, runner, metric, resource, and seed into one immutable run. Hostile code executes without network or secrets in resource-bounded isolation; labels live only in the scoring plane. Every expected case gets a terminal result, so crashes and malformed output cannot improve the metric. Aggregation is deterministic, slice-aware, and signed.

Private feedback is budgeted, timing and output side channels are constrained, and promotion uses a final confirmation set plus reproducible clean-room reruns. The trade-off is rich feedback versus benchmark secrecy: I expose enough public diagnostics to improve engineering while rationing private information so teams cannot train on the test.

Study appendix

Complete reference

Data model: keys, invariants, access paths

EntityPrimary key / fieldsInvariantPrimary access path
EvaluationSpecVersion(tenant_id, spec_id, version); schemas, metrics, failure loss, limits, feedback policyImmutable once used; all boundary behavior executable and testedCreate run; audit evaluator contract
DatasetSnapshot(tenant_id, dataset_id, digest); case manifest, label object, slice manifest, visibilityInputs/labels/slices content-addressed; private objects separately authorizedStage cases; score/slice lookup
Submission(tenant_id, submission_id); image_digest, SBOM, owner, scan statusExecuted bytes exactly match accepted digestRun creation; incident/artifact lookup
EvaluationRun(tenant_id, run_id); submission/spec/dataset/runner digests, seed set, stateTuple frozen before queueing; one signed final scorecard versionStatus; compare; reproduce
ShardAttempt(run_id, shard_id, attempt_no); lease_epoch, node, resource counters, output_digestOnly fenced accepted attempt contributesRecovery; performance diagnosis
CaseResult(run_id, case_id); terminal_status, value_hash, metric components, attemptExactly one terminal row for every expected case IDAggregation; failure buckets; appeals
Scorecard(run_id, score_version); coverage, metrics, slices, catastrophic counts, signatureDerived only after completeness validationLeaderboard/release gate/audit
Attestation(run_id, attestation_digest); artifact manifests, environment, event roots, signerTamper-evident and reproducible from retained inputsCompliance export; rerun verification

Concrete API surface

POST/v1/submissionsResumable artifact upload; returns content digest after scan, never executes mutable tag.
POST/v1/evaluation-runsIdempotency-Key; pins submission/spec/dataset tier, seed policy, quota reservation.
GET/v1/runs/{id}State, queue position, manifest digests, coarse progress; no private case/label detail.
GET/v1/runs/{id}/scorecardCoverage, metric versions, allowed slices, failure buckets, signed attestation link.
POST/internal/shards/{id}:claimFenced lease with exact case manifest and resource profile.
POST/internal/shards/{id}:commitExpected lease epoch + output digest; completeness/schema validation before accept.
POST/v1/runs/{id}:reproduceAuthorized clean-room rerun with identical tuple or explicit comparison tuple.
POST/v1/runs/{id}/appealsVersioned reason/evidence; human review cannot mutate original scorecard.
END-TO-END MAP

Glassbox Arena isolation architecture

Submission bytes enter a hostile execution boundary. Private labels never do. A trusted validator and aggregator turn complete case results into a signed scorecard.

Glassbox Arena isolation architecture Entrants and CI upload submissions. The control plane pins evaluation manifests. Sandboxes run dataset inputs without labels. Trusted validators aggregate metrics and scorecards. EDGE / INTAKE AUTHORITATIVE CONTROL ASYNC / EXECUTION / DERIVED Entrant / CIcontent uploadSpec authormetric contractDataset curatorinputs + labelsRelease ownerpromotion policyArtifact gatehash + scan + SBOMRun authorityimmutable tupleDataset vaultinput/label splitQuota schedulertenant + tier fairnessMicroVM sandboxno network / boundedOutput validatorall case IDsMetric aggregatordeterministic reduceScore + attestationslices + signature Cross-cutting: tenant policy · audit · metrics · lineage · replay
HOLDOUT FIREWALL

Inputs may cross; labels never do

The sandbox writes predictions to a one-way trusted channel. Only the scoring plane can join predictions with labels and private slices.

Private holdout data flowPrivate input objects enter a sandbox, predictions exit to validation, and labels stay inside an isolated scoring vault.PRIVATE DATASET VAULTinput objectslabels + private slicesUNTRUSTED SANDBOXno network · no labels · no clockCPU / RAM / PID / time / bytesTRUSTED SCORING PLANEvalidate all IDsjoin labelsscore + signcoverage before qualityread-only inputspredictions onlylabel path bypasses sandbox completely

Consistency ledger

Invariant
Consistency
Why
Safe degraded behavior
Run manifest
Transactional immutable pin
No mixed spec/dataset/runner versions
Do not start if any artifact unresolved
Shard execution
At-least-once + fenced attempt
Nodes fail; one accepted output per shard/case
Retry infrastructure errors; penalize deterministic entrant errors
Case completeness
Strong validation before aggregate
Failures must remain in denominator
Score invalid/incomplete; never publish flattering partial
Leaderboard
Eventual projection of signed scorecards
UI can lag without changing truth
Show scorecard/version freshness
Private feedback budget
Transactional quota
Prevent adaptive label extraction
Queue or deny additional private run

Operational scorecard

Platform health

Queue start SLO
4.1m
Sandbox escapes
0
Shard retry rate
1.8%
Attestation coverage
99.9%

Outcome quality

Result completeness
100%
Score reproducibility
99.99%
Worst-slice gate
pass/12
Private leakage probes
0

Visual values are illustrative. In production, every metric needs a unit, time window, tenant/slice dimension, owner, alert threshold, and prescribed action.

Phased rollout

GATE 01

Reference corpus

Internal known-good, known-bad, malicious, crashing, timeout, and parser-edge submissions.

GATE 02

Shadow evaluator

Run beside incumbent; compare every case component and investigate disagreements.

GATE 03

Public smoke

Small disclosed set, strict sandbox, rich feedback, no release authority.

GATE 04

Private promotion

Quota-controlled holdouts, signed attestations, slice gates, final confirmation set, appeal path.

Interview traps

  1. 01Computing error only over successful cases and dropping crashes/timeouts from the denominator.
  2. 02Documenting inclusive tolerance but implementing strict less-than at the boundary.
  3. 03Rerunning failed code to capture stderr, allowing behavior and leakage to change.
  4. 04Removing all whitespace so malformed multiline numbers become a different valid number.
  5. 05Supplying private labels, slice names, filenames, timing, network, or host metadata to entrant code.
  6. 06Using mutable image tags, “latest” datasets, or developer caches in a supposedly reproducible run.
  7. 07Reporting one aggregate metric while hard-risk slices or catastrophic outcomes regress.
  8. 08Allowing unlimited private submissions and high-resolution feedback, effectively exposing the test set.
  9. 09Treating containers as a perfect hostile-code boundary without syscall/kernel isolation and quotas.
  10. 10Publishing a score before verifying every expected case ID and one accepted fenced attempt.

Glossary

Attestation
Signed evidence tying a score to exact artifacts, environment, events, and metric code.
Brier score
Mean squared error of probabilities; useful for calibration, but still requires slice and business-loss context.
Content address
Cryptographic digest identifying exact bytes, avoiding mutable tags or paths.
Differential test
Run two independent evaluator implementations on generated boundary cases and compare results.
Golden set
Human-validated cases used to check behavior; if repeatedly optimized against, it stops being an unbiased holdout.
Holdout
Dataset not used for fitting or ordinary iteration, retained to estimate generalization.
MicroVM
Lightweight virtual machine offering a stronger kernel boundary than ordinary process/container isolation.
Private feedback budget
Limit on how often and how precisely hidden-test behavior may be revealed.
Property test
Generates many inputs to assert general rules, such as adding failures must not improve coverage-adjusted loss.
Slice
Versioned subgroup such as decimals, low contrast, long input, language, or policy edge case.
Stable reduction
Deterministic numeric aggregation order/algorithm that limits floating-point drift.
Terminal result
Exactly one valid prediction or explicit failure category for every expected case.

One-minute spoken recap

Pin everything: submission, dataset, runner, metric, resource profile, environment, and seeds. Isolate execution: no labels, network, secrets, host mounts, or unbounded resources. Validate before scoring: exactly one terminal record for every expected case; failures remain in the denominator. Protect the holdout: feedback budgets, side-channel controls, rotating confirmation data. Explain quality: coverage, failure buckets, risk-weighted metrics, calibration, hard slices, reproducibility, and a signed attestation.