research/reports/tsi/README.md
Marcin Pawlowski cb58cd7ead
Round-4 TSI report review: apply findings, editorial pass, code + figure fixes
Applied the reconstructed round-4 review to the TSI parameter-selection report
set (reports/tsi) and executed the follow-ups.

Report (reports/tsi):
- Applied the must+should findings across README + parts 1-4: cross-part numeric
  corrections, figure-caption fixes, spec reconciliation, and cross-file companions
  (hops-degradation and notch/reward numbers, tip-agreement ordering, density-window
  timing, VRF -> ZK Proof-of-Leadership, w_u window/reward gloss).
- Editorial pass for timeless voice (no "now adopted / merged / coin" narration) and
  a gentle spec-safety framing (recommendations are thresholds; the protocol's
  MAX_UNCLES=4 sits safely above them).
- Added the fork-rate-vs-scale table (6.10), defined "grinding gain", promoted the
  clock-skew study to its own paragraph, added the correlated-latency caveat, and
  moved fig27/fig28 beside their discussion.
- Documented the Blend cascade in 2: hops propagate over the shared gossip graph
  (not direct links), the final broadcast comes from the last relay, relays are
  blind forwarders.

Simulator (tools/simulators/tsi/tsi-sim-pernode):
- Docstring/dead-code fixes: theory.block_count_ceiling (legacy framing), measure,
  reorg (catch-up reading), metrics (removed two dead helpers), config (fixed_point
  10^-6; clock_skew_max/lottery_chunks documented inert), stake_vs_delay.
- Generator correctness + regenerated figures: figures_pernode.CONFIG_COLS now
  exhaustive (f no longer pooled); rho_boundary_analysis SEM across replicates +
  hollow floored markers + de-hardcoded ell_mean (measured from the run's graph);
  appendix_fluct per-N sigma + ~18x title (figB2); bootstrap_dynamics driving
  estimate so fig1 epoch-0 matches genesis.
- pytest: 186 passed; report links 528/0 dangling.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-31 13:13:03 +02:00

3.4 KiB
Raw Blame History

Total-Stake-Inference parameter selection

Per-node network simulation of Cryptarchia Total Stake Inference (TSI). Simulator: tsi-sim-pernode. All runs at the true security parameter k = 2160 unless noted; latency is in slots and 1 slot = 1 s.

This report selects and justifies the TSI parameters for Cryptarchia from a per-node network simulation. It is split into four cohesive parts; section numbers (§1§9, AC) are stable identifiers preserved across the set.

Parts

  1. Overview and recommendations — the executive summary, the per-knob parameter reference (§7), and the safest selection with residual risks and the recommendation-vs-spec deltas (§8).
  2. Accuracy and design — the model and counting rule (§2), the seven findings and their evidence (§3), the design equations and selection algorithm (§4), and the caveats and regime of validity (§5).
  3. Robustness and incentives — jitter, grinding, withholding, selfish mining, the reward design, fork/reorg depth, and organic churn (§6).
  4. Reproducibility and appendices — how to re-run every study (§9), the residual f-rounding offset (App A), the per-epoch noise floor (App B), and consensus detail (App C).

Headline recommendation

Cryptarchia baseline f = 1/30. Two design choices are foundational: count uncles per occupied slot, not per block — the density-bug fix that lands the estimate at exactly D (§2.1, §8.5) — and make genesis a single protocol constant, identical at every node, never client-configurable, since a per-node divergence is never self-corrected (§8.1 row 7). The settings: security k = 2160, uncle window W = 300 slots, uncle cap U ≥ ⌈ρ⌉ + 1 (2 at the Blend target; the protocol's MAX_UNCLES = 4 sits safely above it), learning rate β = 1, on-chain f at 10⁻⁶ precision, peering degree ≥ 6 at scale, soft uncle rewards with w_u + w_n < 1, and operate at load ρ = f·D_vis < 1. The full recommended-configuration table and rationale are in Part 1 →.

Figures

Figures are embedded from report-figures/ via relative links and are versioned here alongside the report. They are produced by the simulator's plotting scripts (scripts/*.py and tsi_sim.plotting) in tsi-sim-pernode; that simulation folder does not commit its own generated figures — the copies checked in here are the report's figures of record.

Reproducing the results

The simulation code, configs, and run data live in tools/simulators/tsi/tsi-sim-pernode. Every study's exact command is listed in Part 4 — Reproducibility (§9). In short, from the simulator directory: make install, then make <config> to run a sweep (results land under runs/<timestamp>_<label>/), and the per-figure generators under scripts/ render the figures. Regenerated figures must be copied into report-figures/ to update this report.