Phase 4k: richer geometry (full Hessian spectrum + mode connectivity) - #7
Merged
Conversation
Tests whether the Phase-4j "graph tie = redundancy" verdict is real or an artifact of thin curvature features (only lambda_max + trace). Adds two opt-in feature groups behind [eval] richer_geometry and re-runs the 4j complementarity test on all four (task, reasoner) cells. - geometry/spectrum.py: full d×d Hessian spectrum (exact eigh) -> lmin, negative-eigenvalue fraction, effective rank, log-det (mean + at best restart). - geometry/connectivity.py: energy barriers along the path from the best restart to the others (mode connectivity) -> barrier mean/max, connected fraction. - curvature.py: batched_spectrum + batched_path_energy (all new JAX stays in the core, invariant 1; the two feature modules are pure NumPy). - evaluate/config/features: richer appended AFTER the base 14 (order-preserving), metrics["feature_set"], ablation guards empty groups. - aggregate: feature_set_of + canonical tables/figures default feature_set="base" so richer never pollutes T1/T2/T4 or the pooled figures (e.g. S1's K=12 point). - make_tables T5 (base vs richer per cell); make_figures excludes richer rows. Verdict: richer geometry helps NOWHERE. Crux graph-IRED conditional signal over softmax stays -0.002 (0/5); a wash where geometry already wins (arith-IRED +0.007, 4/5, unchanged) and slightly worse on the fixed-bowl basin-center cells. So the graph redundancy is a task property, not thin features. Base rows reproduce the 4j numbers exactly (purely additive). 109 tests green, ruff clean. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What & why
The Phase-4j headline caveat — on graph, geometry is redundant with softmax — rested on a thin curvature description (only
λmax+tr(H)). This phase asks whether that redundancy is a task property or an artifact of feature poverty, by adding the two richer signals the paper names as future work and re-running the existing 4j complementarity test on all four (task, reasoner) cells.geometry/spectrum.py— fulld×dHessian spectrum (exacteigh, sincedis small):lmin, negative-eigenvalue fraction, effective rank (participation ratio), log-det — each mean-over-restarts and at the best restart.geometry/connectivity.py— mode connectivity: energy barriers along the straight-line path from the best restart to the others (barrier mean/max, connected fraction).batched_spectrum,batched_path_energy) lives incurvature.pyto keep invariant 1; the two feature modules are pure NumPy.[eval] richer_geometry; features appended after the base 14 so every prior result reproduces byte-identically. Aggregation is feature-set-aware (feature_set_of; canonical tables/figures defaultfeature_set="base"), so richer never pollutes T1/T2/T4 or the pooled figures.Verdict — redundancy confirmed as a task property
Richer geometry helps nowhere: the crux graph-IRED conditional signal stays −0.002 (0/5), it's a wash where geometry already wins (arith-IRED, unchanged), and slightly worse on the fixed-bowl basin-center cells (extra features add noise). So a well-calibrated softmax genuinely captures what even the richest descent geometry would add on graph. A decisive negative result that cements the headline caveat and closes the paper's stated "richer geometry" open question.
Tests
109 tests green (offline, CPU-only), ruff clean. New
test_spectrum.py/test_connectivity.pyverify exact spectra on a known quadratic and barriers on a double well; extended feature/evaluate/aggregate suites cover the richer path + feature-set aggregation. Paper rebuilds viatectonic.🤖 Generated with Claude Code