Versions 7 to 318
new file, 244 lines
6+
12+ return { count: (id) => graph.atom(id).moves?.length ?? 0, at: (id, k) => graph.atom(id).moves?.[k] };
14+
31+const digest = (value: unknown) => createHash("sha256").update(JSON.stringify(value)).digest("hex");
32+const integer = (value: unknown): value is number => Number.isSafeInteger(value) && Number(value) >= 0;
44+function readProgress(value: unknown, graph: Graph, source: ProjectionMoveSource): Progress | undefined {
47+ if (value.format !== 1 || value.checksum !== digest(value.state)) throw Error("damaged move resolution cursor");
48+ shape(value.state, "identity phase mover move work item line slow fast meeting entry current weakest best");
54+ !["scan", "walk", "entry", "weakest", "repick", "mark", "done"].includes(String(state.phase)) ||
62+ if (Number(state.move) > (mover === undefined ? 0 : source.count(mover))) throw Error("invalid move offset");
64+ if (state[key] !== null && (typeof state[key] !== "string" || !state[key] || String(state[key]).length > 4096))
77+ (["entry", "weakest", "repick", "mark"].includes(String(state.phase)) && state.line === null) ||
84+
95+ if (!identity || identity.length > 4096 || !Number.isSafeInteger(maxSteps) || maxSteps < 1 || maxSteps > 256)
116+ const selected = (line: string) => storage.read("selected", line) as RelocationInfo | undefined;
122+ const terminal = (node: NodeId | null) => node === null || isStartNode(node) || !!storage.read("reached", node);
124+ const stronger = (a: RelocationInfo, b: RelocationInfo) => graph.comparePriority(a.atom, b.atom) > 0;
- MCP
- compare on this site's /mcp
- CLI
- abso diff 7 318 src/engine/experimental/projection-move-resolution.ts --json
- JSON
- /christopher/abso-core/compare/7..318?file=src%2Fengine%2Fexperimental%2Fprojection-move-resolution.ts&format=json