Exact symbolic growth, unified reduction size contracts, and deterministic solver backends - #1137
Draft
isPANN wants to merge 11 commits into
Draft
Exact symbolic growth, unified reduction size contracts, and deterministic solver backends#1137isPANN wants to merge 11 commits into
isPANN wants to merge 11 commits into
Conversation
Introduce exact symbolic expressions, rule-owned size relations, strict extraction and numeric contracts, model-owned construction metadata, and deterministic solver selection as one compile-time contract. Migrate directly from the main-branch APIs without recording discarded intermediate designs.
Use the unified registry for creation, inspection, deterministic solver selection, reduction paths, and size reporting. Keep CLI and MCP outputs consistent and cover their user-facing error paths and round trips.
Update executable examples and integration scenarios for the final size, extraction, and registry contracts, including source-relative path assertions and exact variant handling.
Align design, CLI, MCP, paper, and maintainer workflow documentation with exact expressions, rule-owned size relations, registry-owned construction, and deterministic solver dispatch.
Use the required HiGHS backend, keep benchmark-only dependencies out of ordinary builds, add portable stack handling, and exercise macOS ARM64, Windows x86_64, and RISC-V targets in CI.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1137 +/- ##
==========================================
- Coverage 98.00% 97.30% -0.71%
==========================================
Files 1044 1051 +7
Lines 107366 115531 +8165
==========================================
+ Hits 105228 112413 +7185
- Misses 2138 3118 +980 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
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.
Closes #1075, #1078, #1076, #788, and #1090.
Supersedes #1083 with a clean, function-oriented history built from the final code tree against
main.Summary
Exact symbolic reduction contracts
Registry-owned models and deterministic solving
CLI and MCP
pareto(default) andallpath selection.max_pathslimits selected output after comparison rather than limiting the candidate set, accepts at most 999, and rejects larger requests explicitly.pathsplus the necessarytruncatedflag.Required reduction removal
Output-layer
max_pathssemantics require concrete Pareto selection to execute every simple candidate path before limiting the selected output. This exposed the registered route:Review showed that
MinimumFeedbackArcSet → MaximumLikelihoodRankingcannot be made total and correct over the currently declared model domains. The classical linear-order equivalence assumes nonnegative arc weights, while the source accepts arbitraryi32weights. The source graph may also contain parallel arcs and self-loops, but the target is onei32matrix entry per ordered vertex pair: parallel weights must be aggregated, self-loops have no ranking representation, and pairwise weight differences can exceedi32. The previous implementation additionally overwrote parallel arcs.The registry has no conditional rule preconditions, and the target model cannot represent every valid source instance. A local formula change would therefore preserve an unsound registered edge. The rule implementation, registration, tests, canonical example, and paper entry are removed instead. Complete path selection continues through the remaining valid routes and its tests pass.
This deletion is required for the reduction algorithm change: retaining the rule either rejects valid source instances or silently changes their objective.
Build and documentation
Commit structure
Quality review
Verification
make checkmake mcp-testpython3 scripts/test_pipeline_checks.pyPolynomial upper-bound propagation
m <= n^2followed byk = 10 - mcomposes tok <= 10, while exactm = 4still evaluates tok = 6; graph complementation normalizesv(v - 1)/2 - eto the propagated upper boundv^2/2.