{
  "slug": "swap-reduction",
  "domain": "Quantum compilation",
  "title": "Routing with fewer SWAPs.",
  "description": "A quantum circuit router that combines depth-weighted lookahead, topology-aware scoring, and penalties for reversing recent SWAPs.",
  "metric": "Added SWAPs on Q20",
  "unit": "SWAPs",
  "note": "The improvement is specific to Q20 under the shared evaluator. It is not a claim of superiority on every device topology.",
  "task": "Swap Reduction",
  "score": 14835,
  "reference": 15186,
  "direction": "min",
  "outcome": "Improved",
  "model": "GPT-5.6-Luna",
  "budget": 8,
  "seed": 42,
  "best_iteration": 78,
  "last_iteration": 100,
  "cost_usd": 50.898270999999994,
  "program_id": "90c289d7-c45d-4884-b42a-0cd51152bbca",
  "source_sha256": "1d25829c5f485742c5ec62046d6f4e3903280ed2207980bd8b5c610d7fdf015b",
  "source": "static/programs/swap_reduction.rs",
  "language": "Rust",
  "lines": 763,
  "history": {
    "points": [
      {
        "iteration": 0,
        "candidate_score": 6387.000000000058,
        "best_score": 6387.000000000058,
        "gate": "unrecorded"
      },
      {
        "iteration": 1,
        "candidate_score": 6497.999999999985,
        "best_score": 6497.999999999985,
        "gate": "retrieve"
      },
      {
        "iteration": 2,
        "candidate_score": 6565.799999999974,
        "best_score": 6565.799999999974,
        "gate": "retrieve"
      },
      {
        "iteration": 3,
        "candidate_score": 6957.000000000015,
        "best_score": 6957.000000000015,
        "gate": "retrieve"
      },
      {
        "iteration": 4,
        "candidate_score": 6957.000000000015,
        "best_score": 6957.000000000015,
        "gate": "retrieve"
      },
      {
        "iteration": 5,
        "candidate_score": 11325.600000000006,
        "best_score": 11325.600000000006,
        "gate": "retrieve"
      },
      {
        "iteration": 6,
        "candidate_score": 11325.600000000006,
        "best_score": 11325.600000000006,
        "gate": "retrieve"
      },
      {
        "iteration": 7,
        "candidate_score": 15174.00000000003,
        "best_score": 15174.00000000003,
        "gate": "retrieve"
      },
      {
        "iteration": 8,
        "candidate_score": 15341.399999999994,
        "best_score": 15341.399999999994,
        "gate": "retrieve"
      },
      {
        "iteration": 9,
        "candidate_score": 15493.800000000017,
        "best_score": 15493.800000000017,
        "gate": "retrieve"
      },
      {
        "iteration": 10,
        "candidate_score": 11602.800000000003,
        "best_score": 15493.800000000017,
        "gate": "retrieve"
      },
      {
        "iteration": 11,
        "candidate_score": 15493.800000000017,
        "best_score": 15493.800000000017,
        "gate": "retrieve"
      },
      {
        "iteration": 12,
        "candidate_score": 15493.800000000017,
        "best_score": 15493.800000000017,
        "gate": "retrieve"
      },
      {
        "iteration": 13,
        "candidate_score": 16871.40000000001,
        "best_score": 16871.40000000001,
        "gate": "retrieve"
      },
      {
        "iteration": 14,
        "candidate_score": 11325.600000000006,
        "best_score": 16871.40000000001,
        "gate": "retrieve"
      },
      {
        "iteration": 15,
        "candidate_score": 17197.800000000032,
        "best_score": 17197.800000000032,
        "gate": "retrieve"
      },
      {
        "iteration": 16,
        "candidate_score": 15512.400000000023,
        "best_score": 17197.800000000032,
        "gate": "retrieve"
      },
      {
        "iteration": 17,
        "candidate_score": 16285.800000000076,
        "best_score": 17197.800000000032,
        "gate": "retrieve"
      },
      {
        "iteration": 18,
        "candidate_score": 16457.399999999994,
        "best_score": 17197.800000000032,
        "gate": "retrieve"
      },
      {
        "iteration": 19,
        "candidate_score": 16912.800000000003,
        "best_score": 17197.800000000032,
        "gate": "retrieve"
      },
      {
        "iteration": 20,
        "candidate_score": 17041.20000000001,
        "best_score": 17197.800000000032,
        "gate": "retrieve"
      },
      {
        "iteration": 21,
        "candidate_score": 6936.60000000002,
        "best_score": 17197.800000000032,
        "gate": "retrieve"
      },
      {
        "iteration": 22,
        "candidate_score": 17197.800000000032,
        "best_score": 17197.800000000032,
        "gate": "retrieve"
      },
      {
        "iteration": 23,
        "candidate_score": 16927.800000000017,
        "best_score": 17197.800000000032,
        "gate": "retrieve"
      },
      {
        "iteration": 24,
        "candidate_score": 17197.800000000032,
        "best_score": 17197.800000000032,
        "gate": "retrieve"
      },
      {
        "iteration": 25,
        "candidate_score": 15512.400000000023,
        "best_score": 17197.800000000032,
        "gate": "retrieve"
      },
      {
        "iteration": 26,
        "candidate_score": 17197.800000000032,
        "best_score": 17197.800000000032,
        "gate": "retrieve"
      },
      {
        "iteration": 27,
        "candidate_score": 17197.800000000032,
        "best_score": 17197.800000000032,
        "gate": "retrieve"
      },
      {
        "iteration": 28,
        "candidate_score": 17201.400000000038,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 29,
        "candidate_score": 17201.400000000038,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 30,
        "candidate_score": 17041.20000000001,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 31,
        "candidate_score": 15512.400000000023,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 32,
        "candidate_score": 17197.800000000032,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 33,
        "candidate_score": 17201.400000000038,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 34,
        "candidate_score": 17197.800000000032,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 35,
        "candidate_score": 17041.20000000001,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 36,
        "candidate_score": 15512.400000000023,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 37,
        "candidate_score": 17201.400000000038,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 38,
        "candidate_score": 16872.60000000002,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 39,
        "candidate_score": 15512.400000000023,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 40,
        "candidate_score": 17104.199999999997,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 41,
        "candidate_score": 16353.00000000003,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 42,
        "candidate_score": 17200.20000000004,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 43,
        "candidate_score": 17201.400000000038,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 44,
        "candidate_score": 17197.800000000032,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 45,
        "candidate_score": 17104.199999999997,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 46,
        "candidate_score": 15493.800000000017,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 47,
        "candidate_score": 17191.800000000032,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 48,
        "candidate_score": 17046.60000000005,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 49,
        "candidate_score": 16285.800000000076,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 50,
        "candidate_score": 17104.199999999997,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 51,
        "candidate_score": 16896.0,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 52,
        "candidate_score": 17201.400000000038,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 53,
        "candidate_score": 17201.400000000038,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 54,
        "candidate_score": 17201.400000000038,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 55,
        "candidate_score": 17104.199999999997,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 56,
        "candidate_score": 16912.800000000003,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 57,
        "candidate_score": 17201.400000000038,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 58,
        "candidate_score": 17000.400000000023,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 59,
        "candidate_score": 17201.400000000038,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 60,
        "candidate_score": 17104.199999999997,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 61,
        "candidate_score": 16369.800000000017,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 62,
        "candidate_score": 17201.400000000038,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 63,
        "candidate_score": 17201.400000000038,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 64,
        "candidate_score": 17186.40000000001,
        "best_score": 17201.400000000038,
        "gate": "lookup"
      },
      {
        "iteration": 65,
        "candidate_score": 17104.199999999997,
        "best_score": 17201.400000000038,
        "gate": "retrieve"
      },
      {
        "iteration": 66,
        "candidate_score": 17608.200000000026,
        "best_score": 17608.200000000026,
        "gate": "retrieve"
      },
      {
        "iteration": 67,
        "candidate_score": 16895.400000000038,
        "best_score": 17608.200000000026,
        "gate": "retrieve"
      },
      {
        "iteration": 68,
        "candidate_score": 17489.400000000052,
        "best_score": 17608.200000000026,
        "gate": "lookup"
      },
      {
        "iteration": 69,
        "candidate_score": 16965.000000000015,
        "best_score": 17608.200000000026,
        "gate": "retrieve"
      },
      {
        "iteration": 70,
        "candidate_score": 17198.40000000001,
        "best_score": 17608.200000000026,
        "gate": "lookup"
      },
      {
        "iteration": 71,
        "candidate_score": 17672.400000000023,
        "best_score": 17672.400000000023,
        "gate": "retrieve"
      },
      {
        "iteration": 72,
        "candidate_score": 17201.400000000038,
        "best_score": 17672.400000000023,
        "gate": "retrieve"
      },
      {
        "iteration": 73,
        "candidate_score": 17200.20000000004,
        "best_score": 17672.400000000023,
        "gate": "retrieve"
      },
      {
        "iteration": 74,
        "candidate_score": 17201.400000000038,
        "best_score": 17672.400000000023,
        "gate": "retrieve"
      },
      {
        "iteration": 75,
        "candidate_score": 17784.600000000006,
        "best_score": 17784.600000000006,
        "gate": "retrieve"
      },
      {
        "iteration": 76,
        "candidate_score": 16892.399999999994,
        "best_score": 17784.600000000006,
        "gate": "retrieve"
      },
      {
        "iteration": 77,
        "candidate_score": 17875.800000000032,
        "best_score": 17875.800000000032,
        "gate": "retrieve"
      },
      {
        "iteration": 78,
        "candidate_score": 18160.20000000004,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 79,
        "candidate_score": 17201.400000000038,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 80,
        "candidate_score": 17784.600000000006,
        "best_score": 18160.20000000004,
        "gate": "noop"
      },
      {
        "iteration": 81,
        "candidate_score": 16173.599999999991,
        "best_score": 18160.20000000004,
        "gate": "lookup"
      },
      {
        "iteration": 82,
        "candidate_score": 17218.800000000032,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 83,
        "candidate_score": 17201.400000000038,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 84,
        "candidate_score": 17201.400000000038,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 85,
        "candidate_score": 17784.600000000006,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 86,
        "candidate_score": 16077.0,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 87,
        "candidate_score": 17218.800000000032,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 88,
        "candidate_score": 18160.20000000004,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 89,
        "candidate_score": 17201.400000000038,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 90,
        "candidate_score": 17784.600000000006,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 91,
        "candidate_score": 17682.00000000003,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 92,
        "candidate_score": 17218.800000000032,
        "best_score": 18160.20000000004,
        "gate": "noop"
      },
      {
        "iteration": 93,
        "candidate_score": 17201.400000000038,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 94,
        "candidate_score": 17201.400000000038,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 95,
        "candidate_score": 16087.800000000003,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 96,
        "candidate_score": 16936.200000000026,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 97,
        "candidate_score": 17218.800000000032,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 98,
        "candidate_score": 17194.800000000032,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 99,
        "candidate_score": 17201.400000000038,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      },
      {
        "iteration": 100,
        "candidate_score": 17784.600000000006,
        "best_score": 18160.20000000004,
        "gate": "retrieve"
      }
    ],
    "trace_sha256": "8d512aaa255fc014b8f47fcec657f850d1a380976a3eda01bc2fde2a76f604f9",
    "score_label": "Search-time evaluator score ↑",
    "note": "Best-so-far envelope of recorded, non-migrant programs. If multiple programs share an iteration, the highest recorded score is used. Missing iterations are not invented."
  },
  "run_fingerprint": "1d40a453690ba168cd7c0b3ab434fd4eadba54444d46681c2a1f0c43be5c23bb",
  "artifact": {
    "views": [
      {
        "image": "static/images/programs/swap-reduction-circuit.webp",
        "thumbnail": "static/images/programs/swap-reduction-circuit-thumb.webp",
        "pdf": "static/figures/programs/swap-reduction-circuit.pdf",
        "paper_pdf": "static/figures/programs/paper-quantum.pdf",
        "provenance": {
          "source": "figures/supp_figures/sota_objects_quantum.pdf",
          "source_sha256": "7bc3b611b119f91f8d5c94c2143957dffe75329757007071195ac18eee707c8f",
          "clip_points": [
            0.0,
            0.0,
            396.0,
            226.8000030517578
          ],
          "cropped": false,
          "pdf_sha256": "7bc3b611b119f91f8d5c94c2143957dffe75329757007071195ac18eee707c8f",
          "image_sha256": "f5b2340eedc0cac2c09c32f4fb5580a3d94bf420b38c47965dfb55aa7d414bae",
          "thumbnail_sha256": "f890bf6a330e098ec47b12b4c0f4cda05f0f8cac9ac17aecdec66fe3d9764518"
        },
        "label": "Routed circuits",
        "caption": "Matched replay of alu-v0_27 on Q20: SimpleTES inserts two SWAPs; EvoDuet inserts one. The headline score covers the full Q20 benchmark."
      }
    ],
    "kind": "views",
    "data": {
      "labels": [
        "Initial program",
        "Previous best",
        "EvoDuet"
      ],
      "added_swaps": [
        20001,
        15186,
        14835
      ]
    }
  },
  "related_trajectories": [
    {
      "slug": "swap-reduction",
      "title": "A better router, one question at a time.",
      "same_run": true
    }
  ]
}
