Files
admin 0593ff7e62
nginx serve /uploads direct (audio speed) / patch-nginx (push) Failing after 1m34s
数字我 Digital Me:全量入库(大文件走 Git LFS)
2026-10-10 16:24:43 +08:00

20 lines
1.2 KiB
JavaScript

import { computeRank, profileFromSubs, DYNASTIES, computeAxes } from '../src/dynasties.js';
import { SUB_REGISTRY } from '../src/talents.js';
const SUBS = SUB_REGISTRY.map((s) => s.id);
const r = computeRank(profileFromSubs(['rigorous','datadriven','concise','shortfirst'], { wang: 0 }), 'weijin');
console.log('魏晋 clerk: nearest=', r.nearest, ' tie=', JSON.stringify(r.nearestTie), ' isDefault=', r.nearestIsDefault);
// 无路者里,nearest【没有】打平的格子占多少?找一个例子
let hasTie = 0, noTie = 0, ex = null;
for (let m = 0; m < (1 << 16); m++) {
const subs = []; for (let i = 0; i < 16; i++) if (m & (1 << i)) subs.push(SUBS[i]);
const axes = computeAxes(subs);
for (const wang of [0, 29, 30, 54, 55, 74, 75, 100]) for (const d of DYNASTIES) {
const r = computeRank({ axes, wang }, d.id);
if (r.channel || !r.nearest) continue;
if (r.nearestTie.length) hasTie++;
else { noTie++; if (!ex) ex = { d: d.id, subs, wang, nearest: r.nearest }; }
}
}
console.log(`\n无路者·nearest 打平的格子 ${hasTie.toLocaleString()};【没打平】的 ${noTie.toLocaleString()}`);
console.log('没打平的一个例子:', JSON.stringify(ex));