{
  "experiment": "TankDev agent-write local durability lab v1",
  "started_utc": "2026-11-04T21:16:35.378063+00:00",
  "finished_utc": "2026-11-04T21:16:54.496807+00:00",
  "environment": {
    "os": "Linux-6.8.0-147-generic-x86_64-with-glibc2.39",
    "python": "3.12.3",
    "logical_cpus": 2,
    "memory_bytes": 8326615040,
    "postgresql": "PostgreSQL 16.15 (Ubuntu 16.15-0ubuntu0.24.04.1) on x86_64-pc-linux-gnu, compiled by gcc (Ubuntu 13.3.0-6ubuntu2~24.04.1) 13.3.0, 64-bit",
    "postgres_settings": {
      "fsync": "on",
      "synchronous_commit": "on",
      "shared_buffers": "128MB",
      "max_connections": "100"
    },
    "packages": {
      "asyncpg": "0.31.0",
      "httpx": "0.28.1",
      "uvicorn": "0.38.0"
    },
    "network": "same-host HTTP loopback; no TLS/proxy/broker/model",
    "database_role": "postgres, isolated lab only; RBAC not benchmarked",
    "configured_lab_process_cpu_quota_cores": 1,
    "configured_lab_process_memory_limit_mib": 512,
    "load_process": "HTTP client and ASGI server share one Python process; PostgreSQL separate"
  },
  "method": {
    "trials": 3,
    "warmup_requests": 50,
    "fresh_per_trial": 1000,
    "replays_per_trial": 200,
    "max_inflight": 8,
    "offered_http_per_second": 200,
    "quantiles": "nearest-rank ceil(p*n), no interpolation",
    "max_throughput_test": false,
    "paid_model_requests": 0,
    "aws_gateway_requests": 0,
    "synthetic_business_data": true,
    "shared_host": true
  },
  "trials": [
    {
      "trial": 1,
      "logical_orders": 1000,
      "http_attempts": 1200,
      "offered_rate_per_second": 200,
      "max_client_inflight": 8,
      "elapsed_seconds": 5.998465,
      "completed_http_per_second": 200.051,
      "lab_process_cpu_seconds": 2.766954,
      "http_error_count": 0,
      "fresh_ms": {
        "p50": 2.995,
        "p95": 4.223,
        "p99": 13.104,
        "mean": 3.335,
        "n": 1000
      },
      "replay_ms": {
        "p50": 2.207,
        "p95": 2.869,
        "p99": 4.038,
        "mean": 2.278,
        "n": 200
      },
      "schedule_wait_ms": {
        "p50": 0.627,
        "p95": 1.075,
        "p99": 9.034,
        "mean": 0.85,
        "n": 1200
      }
    },
    {
      "trial": 2,
      "logical_orders": 1000,
      "http_attempts": 1200,
      "offered_rate_per_second": 200,
      "max_client_inflight": 8,
      "elapsed_seconds": 5.997706,
      "completed_http_per_second": 200.077,
      "lab_process_cpu_seconds": 2.791978,
      "http_error_count": 0,
      "fresh_ms": {
        "p50": 3.078,
        "p95": 4.14,
        "p99": 7.219,
        "mean": 3.267,
        "n": 1000
      },
      "replay_ms": {
        "p50": 2.338,
        "p95": 3.394,
        "p99": 3.712,
        "mean": 2.446,
        "n": 200
      },
      "schedule_wait_ms": {
        "p50": 0.617,
        "p95": 1.071,
        "p99": 1.138,
        "mean": 0.653,
        "n": 1200
      }
    },
    {
      "trial": 3,
      "logical_orders": 1000,
      "http_attempts": 1200,
      "offered_rate_per_second": 200,
      "max_client_inflight": 8,
      "elapsed_seconds": 5.998665,
      "completed_http_per_second": 200.044,
      "lab_process_cpu_seconds": 2.665606,
      "http_error_count": 0,
      "fresh_ms": {
        "p50": 2.931,
        "p95": 3.884,
        "p99": 4.724,
        "mean": 3.044,
        "n": 1000
      },
      "replay_ms": {
        "p50": 2.252,
        "p95": 2.747,
        "p99": 3.258,
        "mean": 2.3,
        "n": 200
      },
      "schedule_wait_ms": {
        "p50": 0.622,
        "p95": 1.066,
        "p99": 1.103,
        "mean": 0.623,
        "n": 1200
      }
    }
  ],
  "correctness": [
    {
      "case": "8_concurrent_same_key",
      "attempts": 8,
      "orders": 1,
      "passed": true
    },
    {
      "case": "same_key_changed_payload",
      "http_status": 409,
      "orders": 1,
      "passed": true
    },
    {
      "case": "new_key_same_business_intent",
      "orders": 1,
      "passed": true
    },
    {
      "case": "rollback_before_outbox_then_retry",
      "orders_before_retry": 0,
      "orders_after_retry": 1,
      "passed": true
    },
    {
      "case": "naive_lost_reply",
      "client_attempts": 2,
      "orders": 2,
      "client_read_timeout_seconds": 0.05,
      "injected_post_commit_reply_delay_seconds": 0.2,
      "passed": true
    },
    {
      "case": "safe_lost_reply",
      "client_attempts": 2,
      "orders": 1,
      "client_read_timeout_seconds": 0.05,
      "injected_post_commit_reply_delay_seconds": 0.2,
      "passed": true
    },
    {
      "case": "receiver_commit_ack_timeout_replay",
      "delivery_attempts": 2,
      "erp_orders": 1,
      "passed": true
    }
  ],
  "receiver_batch_reconciled": 100,
  "cost_input": {
    "monthly_vps_usd": 100,
    "source": "owner supplied, 2026-11-05",
    "calendar_allocation_days": 30,
    "model_api_charge_usd": 0,
    "aws_gateway_charge_usd": 0,
    "note": "Fixed host bill is not measured marginal cost; process CPU excludes PostgreSQL and other services."
  }
}