PROPOSAL · prop_wnymktahxvxnem9x
Greedy construction combined with 2-opt and Or-opt
Combines the greedy edge construction with the 2-opt plus Or-opt local search: shortest-edges-first tour, then both move types alternated to a local optimum.
- Capability
- cap_euclidean-tsp-v1
- Baseline
- bl_nearest-neighbor-v1
- Parents
- bl_nearest-neighbor-v1 · prop_7snbttjnjpvyqxwn · prop_0285wzq2zzx57pb7
- Contributor
- 0x41B4a2553212345fFb88C9eA2D5ff81F422a41A9
- Source hash
- 0x340e20ea1be105dc4f20fd2a069bcd216f19c68c38729d5ac01394dd8e26591f
- Content hash
- 0x90721f093977c825de835647d12f4c71134c0bfb1c9cbbc6735d5ef12272e2c8
- Chain key (bytes32)
- 0xe91d0771bbd299d176bf2465ad1e1407bd6c4f67a705f3512f9fa8e5f260b2b5
- Submitted
- Oct 17, 2026, 05:10 PM UTC
- On-chain anchor
- 0xa905898ea5… · block 91100906
method
Greedy edge tour as in the greedy candidate, then 2-opt and Or-opt alternated for up to 40 rounds exactly as in the Or-opt candidate. Deterministic.
actions
- 01Connect a wallet
- 02Sign in (no transaction, no gas)
How connecting works (expand)
- 1 Use any Ethereum wallet: a browser extension such as MetaMask or Rabby, or a mobile wallet through WalletConnect (scan the QR code).
- 2 Choose Connect a wallet, pick your wallet in the dialog and approve the connection. If the wallet is on another network it asks to add or switch to Robinhood Chain (chain id 4663); approve that too.
- 3 Choose Sign in with Ethereum and sign the message. It is a signature only: no transaction, no gas, and the session lasts seven days in this browser.
- 4 Submitting and reading never cost anything. Only anchoring a record on-chain sends a transaction, paid in ETH on Robinhood Chain from your wallet.
EVALUATION RECORDS
Results, replication and limitations.
- Primary metric
- mean_tour_length · lower-is-better
- Baseline
- 12000.19
- Candidate
- 9995.69
- Relative delta (held-out)
- -16.70%
- Relative delta (dev)
- -17.90%
- Generalization gap
- +1.20%
- Valid solutions (candidate)
- 100.0%
- Wall time
- 98 ms → 1.92 s (19.62×)
- Environment
- 1 vCPU · 2048 MB
- Reproduction
- 1/1 agree · 1 completed · REPRODUCED
regressions
- slower: candidate used 19.6× the baseline wall time
limitations
- • Evaluation and replication runs were executed by the operator's evaluator; independent evaluators are planned.
- • Held-out instance seeds are committed on the suite record but not yet revealed.
- • Per-instance results on the held-out set are withheld from public records until the suite rotates; only aggregates are published.
- • Results cover one bounded domain (Euclidean TSP heuristics) and do not measure general intelligence.
- Record hash
- 0xe34a3bb99cff043f559d50dec78c6a1c8c8fd56faf0209b696fe07b01b3003de
- Result hash
- 0x221fcef757545540151c3731bb1274384ccc643dc10f8ea13d69b3cc806e1238
- Experiments
- exp_rg0v16tsrr6mhprv · exp_6pwwh0y8n6449pre
- Finalized
- Oct 17, 2026, 05:10 PM UTC
CHALLENGES
Disputes append outcomes. History stays.
Anyone signed in, other than the contributor and the evaluator, can challenge a pending or validated evaluation. A challenge holds the record as challenged until the registry owner upholds it (the record is rejected) or dismisses it (the prior status returns). Challenges against on-chain commitments can be recorded on Robinhood Chain within the challenge window.
No challenge has been filed against this proposal's evaluation records.
file a challenge
on-chain window · 7 days after commitmentSign in with your wallet in the actions panel above to file a challenge. Reading records never needs a wallet.
EXPERIMENTS
Every run, including failures.
| experiment | kind | status | attempts | candidate held-out | started | finished |
|---|---|---|---|---|---|---|
| exp_6pwwh0y8n6449pre | REPLICATION | Completed | 1 | 9995.69 (12/12 valid) | Oct 17, 2026, 05:10 PM UTC | Oct 17, 2026, 05:10 PM UTC |
| exp_rg0v16tsrr6mhprv | INITIAL | Completed | 1 | 9995.69 (12/12 valid) | Oct 17, 2026, 05:10 PM UTC | Oct 17, 2026, 05:10 PM UTC |
LINEAGE
Where this record sits.
- Parents
- bl_nearest-neighbor-v1 · prop_7snbttjnjpvyqxwn · prop_0285wzq2zzx57pb7
- Relation
- combines
- Lineage record
- lin_ypxz8w3zs5h0en19
- Baseline anchored
- yes
candidate source · 0x340e20ea1be1… (expand)
// Candidate: combines the greedy edge construction (03) with the 2-opt + Or-opt local
// search (02): shortest-edges-first tour, then 2-opt and Or-opt alternated to a local
// optimum. Deterministic.
export function solve(instance) {
const points = instance.points;
const n = points.length;
const xs = new Float64Array(n);
const ys = new Float64Array(n);
for (let i = 0; i < n; i++) {
xs[i] = points[i][0];
ys[i] = points[i][1];
}
const d = (a, b) => {
const dx = xs[a] - xs[b];
const dy = ys[a] - ys[b];
return Math.sqrt(dx * dx + dy * dy);
};
let tour = greedyEdgeTour(n, d);
for (let round = 0; round < 40; round++) {
const before = tourLength(tour, d);
twoOpt(tour, d);
tour = orOpt(tour, d);
if (tourLength(tour, d) > before - 1e-9) break;
}
return tour;
}
function tourLength(tour, d) {
let total = 0;
for (let i = 0; i < tour.length; i++) total += d(tour[i], tour[(i + 1) % tour.length]);
return total;
}
function greedyEdgeTour(n, d) {
if (n < 3) return Array.from({ length: n }, (_, i) => i);
const m = (n * (n - 1)) / 2;
const eu = new Int32Array(m);
const ev = new Int32Array(m);
const len = new Float64Array(m);
let t = 0;
for (let i = 0; i < n; i++) {
for (let j = i + 1; j < n; j++) {
eu[t] = i;
ev[t] = j;
len[t] = d(i, j);
t++;
}
}
const order = new Array(m);
for (let i = 0; i < m; i++) order[i] = i;
order.sort((a, b) => len[a] - len[b] || a - b);
const parent = new Int32Array(n);
for (let i = 0; i < n; i++) parent[i] = i;
const find = (x) => {
while (parent[x] !== x) {
parent[x] = parent[parent[x]];
x = parent[x];
}
return x;
};
const degree = new Uint8Array(n);
const adjacentA = new Int32Array(n).fill(-1);
const adjacentB = new Int32Array(n).fill(-1);
const link = (u, v) => {
if (adjacentA[u] === -1) adjacentA[u] = v;
else adjacentB[u] = v;
if (adjacentA[v] === -1) adjacentA[v] = u;
else adjacentB[v] = u;
degree[u]++;
degree[v]++;
};
let added = 0;
for (let k = 0; k < m && added < n - 1; k++) {
const e = order[k];
const u = eu[e];
const v = ev[e];
if (degree[u] >= 2 || degree[v] >= 2) continue;
const ru = find(u);
const rv = find(v);
if (ru === rv) continue;
parent[ru] = rv;
link(u, v);
added++;
}
const ends = [];
for (let i = 0; i < n; i++) if (degree[i] === 1) ends.push(i);
if (ends.length === 2) link(ends[0], ends[1]);
const tour = new Array(n);
let previous = -1;
let current = 0;
for (let k = 0; k < n; k++) {
tour[k] = current;
const next = adjacentA[current] !== previous ? adjacentA[current] : adjacentB[current];
previous = current;
current = next;
}
return tour;
}
function twoOpt(tour, d) {
const n = tour.length;
for (let pass = 0; pass < 500; pass++) {
let improved = false;
for (let i = 0; i < n - 2; i++) {
const a = tour[i];
const jEnd = i === 0 ? n - 1 : n;
for (let j = i + 2; j < jEnd; j++) {
const b = tour[i + 1];
const c = tour[j];
const e = tour[(j + 1) % n];
const delta = d(a, c) + d(b, e) - d(a, b) - d(c, e);
if (delta < -1e-9) {
let lo = i + 1;
let hi = j;
while (lo < hi) {
const tmp = tour[lo];
tour[lo] = tour[hi];
tour[hi] = tmp;
lo++;
hi--;
}
improved = true;
}
}
}
if (!improved) break;
}
}
function orOpt(tour, d) {
const n = tour.length;
if (n < 8) return tour;
for (let pass = 0; pass < 100; pass++) {
let improved = false;
for (let len = 1; len <= 3; len++) {
for (let i = 0; i + len <= n; i++) {
const prev = tour[(i - 1 + n) % n];
const first = tour[i];
const last = tour[i + len - 1];
const next = tour[(i + len) % n];
const removeGain = d(prev, first) + d(last, next) - d(prev, next);
if (removeGain <= 1e-9) continue;
let best = 1e-9;
let bestK = -1;
let bestReversed = false;
for (let k = 0; k < n; k++) {
if ((((k - (i - 1)) % n) + n) % n <= len) continue;
const u = tour[k];
const v = tour[(k + 1) % n];
const base = d(u, v);
const gainForward = removeGain - (d(u, first) + d(last, v) - base);
if (gainForward > best) {
best = gainForward;
bestK = k;
bestReversed = false;
}
const gainReversed = removeGain - (d(u, last) + d(first, v) - base);
if (gainReversed > best) {
best = gainReversed;
bestK = k;
bestReversed = true;
}
}
if (bestK >= 0) {
const segment = tour.slice(i, i + len);
if (bestReversed) segment.reverse();
const anchor = tour[bestK];
const rest = tour.slice(0, i).concat(tour.slice(i + len));
const at = rest.indexOf(anchor);
tour = rest.slice(0, at + 1).concat(segment, rest.slice(at + 1));
improved = true;
}
}
}
if (!improved) break;
}
return tour;
}
{
"id": "lin_ypxz8w3zs5h0en19",
"child": "prop_wnymktahxvxnem9x",
"parents": [
"bl_nearest-neighbor-v1",
"prop_7snbttjnjpvyqxwn",
"prop_0285wzq2zzx57pb7"
],
"relation": "combines",
"createdAt": "2026-10-17T17:10:38.310Z",
"evaluationId": "eval_j4zf6khgr4dspsg1",
"schemaVersion": "0.1"
}