Repository navigation
CodeEraser 1.9.0
CodeEraser 1.9.0
Four judgments join the twelve the core answered in 1.8.0, sixteen in all: ce query / ce rules
(Datalog over the index, with a built-in [rules.pack] of five architecture
checks), ce flow (dead code inside a function, judged in ten languages after
each language's own frozen exam), ce merge (how a clone group would fold
into one function; advisory) and ce arch (directory layers, cycle cuts,
clusters, impact; advisory). Every judgment now runs in the Haskell core —
the reference ladders of all thirteen languages, the clone and
documentation candidate passes, the advisor's bags and ranking, the move
detector's first pass, the directory tree, the definition tables every
measurement reads (tables/1) and the text of every report and every
console line (document/1). The Rust side measures, stores and transports;
by source bytes the core is now the larger half. ce check scores are not
comparable with 1.8.x (the soft line is now the exact log-space median, it
can no longer exceed the hard line, and the complexity ratchet is priced in
points — the reasons are below); ce structure's split advice is priced per
[[rules.class]] curve. The wire moves 7.2.0 → 9.0.0 (major: a 1.8.x
ce and a 1.9.0 core refuse each other at the handshake, and texts cross
the local ce ↔ ce-core pipe for the first time; the core still opens no
file, reaches no network and keeps nothing), the daemon protocol
2.1.0 → 2.3.0 (additive), the observe feed 0.11.0 → 0.13.0
(additive), the index schema stays at 17 (the reference tables rebuild once,
GRAPH_REV 22 → 23; the mention census recomputes once, MENTION_REV
3 → 4), the baseline stays at ce.baseline/2, and no default guard tier
moved — the new flow class ships at observe. Binaries build for the same
five targets, sixteen assets.
Why the scores moved
- The soft line is the definition's median. S is median + k·MAD over
log line counts. With an even sample the core took the arithmetic mean of
the two middle values and did it again for the spread, which lands on
either side of the definition (k = 2:{150, 200, 250, 300}read 339,
the definition gives 335;{34, 57, 78, 183, 222, 224}read 381, the
definition gives 416). It now takes the geometric middle exactly, in
fourth powers with two integer square roots — no logarithm, no root of a
rational. Odd samples and most clamped trees do not move; this repository's
own S stays 334. - The soft line never exceeds the hard line. S is established under
min(softMax, H)and the size axis opens atmin(S, H), so a file that
ce scanfails and the hook refuses is also charged by the score. - The complexity ratchet is priced in points. The ADR-006 tolerance for a
function's cognitive-complexity row ismax(+2 %, +1 point)
(tol_abs_coc, default 1); it used to borrow the file row's +10 lines,
which let a function at the 15 ceiling grow to 25 in one edit. - C and C++ alternative tokens count with their operators.
and/or
(and_eq,bitand, …) are the same operator class as&&/||for the
cognitive-complexity reading; a C/C++ file written with them scores the
same as one written with the symbols. - Split advice is class-aware.
ce structure --split-candidatesopens each
file at its own[[rules.class]]lines, the same resolver the score uses.
This repository reads ce check 918 (1.8.0) → 925 on the release tree, the
tests submodule 952 → 950; the CI floors are 911 (unchanged) and
949 → 945. A --fail-under floor priced against a 1.8.x score has to be
re-priced; ce-baseline.json files stay valid (the knobs digest did not
move, and a knob below 1 for a ratio numerator is now refused by name).
Four new judgments
ce query/ce rules(query/1, wire 7.3.0). A Datalog program over
the index's facts — files, units, references, roles, clones, the dead
verdict — withassertclauses as a gate:ce rulesexits 1 on a
violation,--whyprints each answer's derivation. The prelude'sdead(F)
mirrorsce deadcode's file verdict rule for rule. The core lexes and
parses the program, stratifies it, evaluates it semi-naïvely with indexed
joins, and prints the proof.[rules.pack]ince.tomlswitches on five
common checks without writing Datalog:no_dir_cycles,fan_in_max,
fan_out_max,layers(ordered globs, lower may not reference higher) and
forbid(glob pairs). A 1.8.0cecannot read ace.tomlthat declares
[rules.pack]; the plugin follows thereleasebranch and picks 1.9.0 up
on its next session.ce flow(flow/1, 7.4.0). Per function: unreachable statements,
dead stores, unused parameters and never-read locals, from a control-flow
graph the core builds out of four integer tables the measuring side lowers
per language. Ten languages are judged (C, C++, Go, Java, Lua, Python, R,
Rust, TypeScript, TSX), each admitted only after a frozen exam over a pinned
corpus scored against a blind audit, with a false-positive ledger over
history. Thetry/finallyrule reads an implicit exception as reaching
finallytoo, so a write before a throwing call is live. A new guard class
flowwatches writes at[flow] tier(defaultobserve) and the Stop
audit counts the session's findings.ce merge(merge/1, 7.5.0, advisory). For a T1/T2 group or a T3
pair: the anti-unified skeleton, the holes and their parameters, which
member to keep and the lines saved, with the reason when a fold is not
feasible. Exits 0 with a judged document, 2 with a degraded one.ce arch(arch/1, 7.6.0, advisory). Directory layers, the cheapest
cuts that break reference cycles (exact up to the core's bound, greedy
past it), Louvain clusters, misplaced files, impact of a change and
fan-in / fan-out / instability per directory. Since 9.0.0 the measuring
side sends paths and arcs; the core builds the tables.
Each family has its three faces — CLI subcommand, MCP tool (query,
rules, flow, merge_suggestions, architecture) and GUI — and one
methodology booklet (16–19).
The core now decides, and spells, more (wire 7.7.0 → 9.0.0)
- Definitions live in the core (
tables/1, 7.7.0). The language tables,
flow and slot tables, site kinds, call tables, ladders' search roots,
walk exclusions, output caps and the protocol limits are one package the
measuring side fetches once per core version and caches beside the index,
pinned by the digest the handshake echoes. - Reports and console text come from the core (
document/1, 7.8.0 –
7.10.0). Every report document and every console line, English or Chinese,
is laid out by the core from the integers plus the strings it is sent;
Rust prints what comes back. The three faces render one document. - Reference ladders in the core (
resolve/1, 8.1.0, then 9.0.0 by
text). Python, Go, C / C++, Lua, R, Java, Haskell, TypeScript / TSX, Rust,
Markdown and HTML rungs, with the configuration they read (tsconfig
chains, package.json, Cargo.toml, go.mod,DESCRIPTION,.cabal,
pyproject.toml, compile databases), answer from the core; the measuring
side walks the tree and sends what it read. - Candidate passes and the advisor's arithmetic (8.2.0 – 8.5.0, W6):
candidates/1(T3 pairs),docpairs/1(documentation pairs),rank/1
(the advisor's BM25 ranking),moves/1(the four-class detector's first
pass) andbags/1(the advisor's bags, stems and channel terms). - Retired keys (8.0.0):
judgedMaskandpatterns— the core reads its
own language table and classifies pattern shapes itself. Since 9.0.0 the
keys the measuring side always sent are required by name. - One wire line up to 128 MiB (reply budget 256 MiB). A whole-corpus
pass that would exceed it is not sent and is reported by name as that
family's degradation, never truncated; two large TypeScript trees that
used to fail with a desync now judge.
Also in this release
ce similar --widenno longer pays a quadratic cost in the core.--core <path>names the core for the wholeceprocess; a hook that
cannot reach the definitions package says so instead of staying silent.- The methodology booklets, reference tracks and the site were re-read
against the code line by line; the architecture page now says Kosaraju
where it said Tarjan (Data.Graph.sccis King–Launchbury's Kosaraju).
Unsigned, as before
The binaries are built by the release workflow and pinned by SHA-256 in
plugin/bin/manifest.env; nothing is code-signed. SHA256SUMS is in the
assets.