Docs: Update benchmark for google/gemini-3-flash-preview TEMP:0.35

This commit is contained in:
github-actions[bot]
2025-12-17 16:55:05 +00:00
parent 47c178fc67
commit 3c12fd855f
9 changed files with 197 additions and 0 deletions

View File

@@ -0,0 +1,27 @@
async function findShortestPath(graph, start, end) {
const PQ = (await import('https://esm.sh/js-priority-queue')).default;
const dists = { [start]: 0 };
const pq = new PQ({ comparator: (a, b) => a.w - b.w });
pq.queue({ n: start, w: 0 });
while (pq.length) {
const { n, w } = pq.dequeue();
if (n === end) return w;
if (w > (dists[n] ?? Infinity)) continue;
for (const [m, weight] of Object.entries(graph[n] ?? {})) {
const d = w + weight;
if (d < (dists[m] ?? Infinity)) {
dists[m] = d;
pq.queue({ n: m, w: d });
}
}
}
return Infinity;
}
export default findShortestPath;
// Generation time: 20.870s
// Result: PASS