Scenario Harness

The harness is the canonical input method for the OS. Each scenario writes 5 CSV files in the exact format the OS ingestion pipeline reads from mvp_build/data/.

Usage

python mvp_build/harness.py list
python mvp_build/harness.py run supplier_fail_sup005
python mvp_build/harness.py show supplier_fail_sup005
python mvp_build/harness.py snapshots
After running a scenario, the next CSVIngestor call reads the new files. Snapshots are preserved in mvp_build/data/.scenarios/.

Scenarios (16)

Scenario
Description
Expected
base
Base — Healthy
All suppliers delivering, inventory at 8d coverage for PROD003.
78.5
supplier_delay_sup005_10d
Supplier Delay +10d
Far East Imports (SUP005, PROD001) lead time +10d. Single-sourcing risk.
63
supplier_fail_sup005
Supplier Failure (SUP005)
Total failure. SUP005 reliability → 0, lead → 999d.
42
supplier_fail_sup003
Critical SKU Failure (SUP003)
Critical SKU supplier failure. SUP003 (PROD003 / Spice Blend) is the only supplier.
38
demand_spike_30pct
Demand Spike +30%
Demand +30% across all products. Inventory coverage collapses.
61.2
demand_spike_100pct
Demand Spike +100%
Demand doubled. Stockout imminent across multiple SKUs.
44
inventory_drawdown_50pct
Inventory Drawdown 50%
On-hand inventory halved. Write-off or shrinkage event.
55
single_supplier_prod001
Single Supplier Risk
PROD001 reduced to a single supplier. Concentration risk.
72
geopolitical_block_sup005
Geopolitical Block
Border closure blocks SUP005 (CN). Tests geo-risk detection.
39
critical_sku_stolen
Shrinkage / Theft
Mass shrinkage: 60 units of PROD001 (CRITICAL SKU) stolen.
51
stale_inventory_30d
Stale Inventory 30d
Inventory records 30 days old. Forecasting accuracy degraded.
70
customer_default_cust001
Customer Default
Lulu Hypermarket (CUST001, 18% revenue) enters payment default.
68
volume_surge
Volume Surge
+5 large orders added. Order book at all-time high; production stress.
58
country_concentration_uae
Country Concentration
92% of revenue from UAE enterprise accounts.
66
data_quality_negative_qty
Quality: Negative Qty
Negative quantity in inventory. Tests OS quality-flag handling.
78.5
data_quality_missing_inventory
Quality: Missing File
inventory.csv deleted. Tests OS error handling path.
0
Architecture: harness is an organization to the OS. Each scenario write = main API configuration. The OS picks up changes on its next ingest cycle.