Skip to content

feat(problems): the 20 MODAct problems, their best-known fronts and vamos zoo fetch-fronts - #370

Open
NicolasRodriguezUribe wants to merge 4 commits into
mainfrom
feat/modact-problems
Open

NicolasRodriguezUribe wants to merge 4 commits into
mainfrom
feat/modact-problems

Conversation

@NicolasRodriguezUribe

@NicolasRodriguezUribe NicolasRodriguezUribe commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

Problem

VAMOS has no MODAct problems. MODAct (Picard and Schiffmann, "Realistic constrained multiobjective optimization benchmark problems from design", IEEE TEVC 25(2):234-246, 2021, doi:10.1109/TEVC.2020.3020046) is a set of 20 constrained real-world problems from the design of an electro-mechanical actuator (a stepper motor and three spur-gear stages): 20 variables, 2 to 5 objectives and 7 to 10 constraints. Unlike CRE and RCM, which common algorithms solve easily, NSGA-II, NSGA-III and C-TAEA struggle on its constraint levels 3 and 4, with a large spread between runs, so they add the hard real-world case that the packaged suites lack.

The problems are not closed-form functions: the authors' Python package modact (epfl-lamd/modact, GPL-3.0) builds the actuator, meshes it with trimesh and checks collisions with python-fcl. VAMOS is MIT, so it cannot include that code.

Change

Three commits. The second holds only the third-party data (CC BY 4.0). The third adds vamos zoo fetch-fronts, which downloads the fronts that are not packaged, and renames this branch's documentation markers to VAMOS 1.5.1:, the release the maintainers chose for MODAct.

1. The problems (src/vamos/foundation/problem/modact.py, family registry/families/modact.py):

  • 20 registered keys, modact_cs1-modact_cs4, modact_ct1-modact_ct4, modact_cts1-modact_cts4, modact_ctse1-modact_ctse4 and modact_ctsei1-modact_ctsei4: n = 20 (fixed), M = 2, 2, 3, 4, 5, and G = 7, 8, 10, 9 for constraint levels 1-4 (the paper's Table III). Real encoding: the motor and the numbers of teeth are the integer parts of variables, as the paper defines them. The modact_ prefix keeps the suite's short names (cs1, ct1) from reading as other families. The class MODActProblem takes MODAct's own name ("cts2") and is not exported by vamos.problems.
  • No modact code in VAMOS. The constructor imports modact.problems with importlib.import_module and takes the bounds, weights and c_weights from the package; it checks that the package defines the problem with the registered dimensions and that every weight is -1 or 1. evaluate calls the package once per row, on a copy of the row.
  • Signs: F = f * -weights (MODAct's weights: -1 minimized, 1 maximized; torque excess, safety factor and efficiency change sign, cost and transmission ratio keep it) and G = g * c_weights (c_weights: -1 for g >= 0, 1 for g <= 0), so every objective is minimized and G <= 0 is feasible. Both are multiplications by +-1, so the values are the package's, sign aside; pymoo's pymoo.problems.multi.modact converts them the same way. The instance exposes objective_signs, constraint_signs and modact_version.
  • Missing package: without modact, the problems are still listed (registry, CLI choices, Studio catalog), and creating one raises ImportError naming python -m pip install "vamos-optimization[modact]" (or python -m pip install modact). Like fs_real without scikit-learn, the registry-wide tests skip on that ImportError; _OPTIONAL_DEPENDENCIES in test_problem_registry.py lists the 20 keys.
  • Optional extra modact = ["modact>=1.0.1"]. modact 1.0.1 is on PyPI as a pure-Python wheel, and its compiled dependency python-fcl 0.7.0.11 has wheels for Windows, Linux and macOS for Python 3.9-3.14; it installed on Windows with Python 3.12 against constraints/ci.txt. all does not include it, because the package is GPL-3.0: tests/test_pyproject_optional_deps_all.py gains a COPYLEFT_EXTRAS class and a test that all installs none of them. No CI workflow installs it, and constraints/ci.txt does not pin it.
  • Typing: the import is dynamic (importlib.import_module), so mypy never resolves modact and the [tool.mypy] configuration, whose hash the typing baseline records, is unchanged.
  • Reproducibility: a run's environment.json already records every installed distribution, so it records the modact version; a test checks it, and that a stored MODAct run verifies as exact and replays exactly.
  • Docs, marked VAMOS 1.5.1: (MODAct ships in 1.5.1, so the markers name that release, as the 1.5.0 release turned its development markers into "VAMOS 1.5.0"): a MODAct section in the problems catalog (keys, dimensions, objective senses, constraint levels, signs, variables, evaluation cost, reproducibility, fronts), the catalog's count (260 -> 280) and entry points; the modact extra and its license in the installation guide; one line in architecture_health.md (the optional-dependency rule); and step 7 of docs/dev/add_problem.md (a problem that an optional package evaluates).

2. The fronts of CS1-CS4 and CT1-CT4 (src/vamos/resources/reference_fronts/modact_cs1.csv-modact_ct4.csv, LICENSE-modact-fronts.txt):

  • The authors' best-known fronts, <problem>_PF.dat of Zenodo record 10.5281/zenodo.3824302, version 1.1.0 (Picard and Schiffmann, CC BY 4.0), written by experiments/scripts/generate_reference_fronts.py --modact-dir PATH, which checks each file's MD5 against the record. The separator becomes a comma and the second column (safety factor, torque excess), which MODAct maximizes, changes sign at the text level: every value keeps its digits, no row is added or removed, and each file equals the Zenodo data times objective_signs exactly. 682 KB for the eight files.
  • LICENSE-modact-fronts.txt gives the CC BY 4.0 attribution: authors, title, version, DOI, license link, the changes made, and the source file and MD5 of each packaged file. It ships with the package (reference_fronts/LICENSE-*.txt is already package data).
  • The fronts of CTS1-CTS4 (1.4-2.8 MB each), CTSE1-CTSE4 and CTSEI1-CTSEI4 (11-193 MB each) are not packaged; the third commit downloads them.
  • The fronts hold objective vectors only, without designs, so no test can rebuild a design that reaches a row. The packaged rows are mutually non-dominated (the existing test covers them); CS2 repeats 17 rows, kept as published.

3. vamos zoo fetch-fronts, the other fronts on demand (src/vamos/foundation/problem/modact_fronts.py, src/vamos/experiment/zoo/cli.py, src/vamos/resources/__init__.py):

  • Usage:

    vamos zoo fetch-fronts                              # modact_cts1 to modact_cts4 (8.9 MB)
    vamos zoo fetch-fronts modact_ctse4 modact_ctsei1   # any of the 12 not packaged
    vamos zoo fetch-fronts --all                        # the twelve, about 730 MB
    vamos zoo fetch-fronts modact_cts2 --force          # download again
    vamos zoo fetch-fronts --output DIR                 # write elsewhere

    In Python: vamos.foundation.problem.modact_fronts.fetch_fronts(keys, directory=None, *, force=False).

  • One conversion path. modact_fronts.convert_front checks a file's MD5 against the record's (the table holds the record's MD5 and size of all 20 files), converts it line by line with the text-level sign change of the packaged fronts, and writes the CSV through a temporary file. generate_reference_fronts.py --modact-dir now calls the same function for the packaged files: regenerated through it, the eight packaged CSVs are byte-identical. modact_fronts.notice writes the CC BY 4.0 attribution and change notice for both: the packaged LICENSE-modact-fronts.txt is regenerated from it (its wording now covers every objective MODAct maximizes, and says that vamos zoo fetch-fronts downloads the rest), and every download directory gets its own LICENSE-modact-fronts.txt listing the files there, with their source file and MD5.

  • Where VAMOS finds them, with no further step. VAMOS already read reference fronts from VAMOS_REFERENCE_FRONTS_DIR before the packaged ones. vamos.resources.user_reference_fronts_dir() adds a per-user directory, searched after the packaged fronts so that a downloaded file never replaces a packaged front: reference_fronts under VAMOS_DATA_DIR when set, else %LOCALAPPDATA%\vamos\reference_fronts on Windows, ~/Library/Application Support/vamos/reference_fronts on macOS, $XDG_DATA_HOME/vamos/reference_fronts (~/.local/share/...) elsewhere. The helper writes there by default, so the resolver, Studio's catalog and --hv-reference-front vamos use the fronts at once. tests/conftest.py points VAMOS_DATA_DIR at an empty temporary directory, so the fronts a developer downloaded never change what the tests resolve.

  • Why here. VAMOS had no helper for downloaded data, but it had the pattern of a directory of user-supplied fronts that the lookup reads. A script under tools/ or experiments/ would not ship in the wheel, so a user of the released package could not run it. The command joins vamos zoo (Experimental), next to list, info and run. The conversion stays with the problem in foundation/problem, and the CLI only translates arguments and exit codes.

  • Network only on demand: standard-library urllib, a 60 s timeout, and a generic vamos-optimization/<version> user agent; --help and the tests reach no network. The download goes to a temporary file, and a failed download or checksum leaves no file behind. A front already present is kept unless --force. Packaged fronts (CS, CT) and unknown keys are refused, with exit code 1.

  • Docs, marked VAMOS 1.5.1:: "Downloading the other MODAct fronts" in the problems catalog (usage, checksum, conversion, the directory per platform, lookup order), which replaces the manual conversion steps; the reference-front notes; and the zoo line of the CLI guide.

Sources

  • Paper: C. Picard and J. Schiffmann, IEEE TEVC 25(2):234-246, 2021, doi:10.1109/TEVC.2020.3020046 (open-access version on EPFL Infoscience, record 280039): Table III (dimensions, constraint levels, bounds), Section III-B (objectives and their senses), Section V-B (how the best-known fronts were built).
  • Package: modact 1.0.1 from PyPI (sdist identical to tag 1.0.1, commit 8b71bf9, of github.com/epfl-lamd/modact), GPL-3.0. Read for the interface only (problems.get_problem, bounds(), weights, c_weights, __call__, and the README's sign conventions); no code copied. Since the Zenodo fronts (May 2020), the package's code changed by an Aug 2020 rewrite of the min_t test that gives the same value for the 20 problems, and by a 2025 Ruff pass whose only changes to the syntax tree are an unused import removed and math.tan replaced by np.tan inside a gear root finder (the same tangent; math.tan of the one-element array that fsolve passes needed NumPy's deprecated array-to-scalar conversion).
  • Fronts: Zenodo record 10.5281/zenodo.3824302, version 1.1.0, CC BY 4.0, MD5 checksums as the record lists them.
  • Precedent for the interface: pymoo 0.6.2, pymoo/problems/multi/modact.py (Apache-2.0), which also imports modact lazily and converts with -weights and c_weights.

Tests

tests/foundation/test_modact_problems.py (new). Without modact, which is how CI runs:

  • The 20 keys are registered with the paper's dimensions, fixed n and M, no options, and a description naming modact and its license; n_var or n_obj overrides are rejected.
  • An unknown name (cs5, the analysis-only constraint set; cs1s2, another number of stages; ...) raises ValueError before importing modact.
  • With modact hidden (sys.modules["modact"] = None), creating a problem, building it through the registry, and vamos.optimize("modact_cts1", ...) raise ImportError naming the extra.
  • With a stub of modact.problems: F is the stub's objectives times -weights, G its constraints times c_weights, VAMOS's feasibility equals modact's rule (g >= 0 where c_weights is -1, g <= 0 where it is 1), and the caller's population is unchanged although the stub overwrites its argument; a population of the wrong shape, and a package that defines another number of variables, objectives or constraints, or a weight other than +-1, are rejected.
  • Fronts (second commit): files exist for CS1-CS4 and CT1-CT4 only, have two finite columns in VAMOS's signs (negative safety factor; torque excess about -2 to 0.6; the second column decreases along the cost), and LICENSE-modact-fronts.txt carries the attribution and lists each file.

With modact installed (skipped otherwise, pytest.importorskip(..., exc_type=ImportError)):

  • For each of the 20 problems, at 4 random designs and one design per constraint level that is feasible for all five classes of the level (found with NSGA-II and stored in the test): the bounds and weights are the package's, F and G equal the package's outputs times -weights and c_weights exactly, and VAMOS's feasibility verdict equals modact's rule.
  • Fronts (second commit): the stored feasible design of each level does not dominate any row of the CS or CT front of its level, and would dominate rows of it if the front kept MODAct's sign.
  • NSGA-II on modact_ct1 through vamos.optimize (60 evaluations): save_result records modact's version in environment.json, verify_run reports exact replayability, and reproduce is exact.

Changed: test_problem_registry.py (_OPTIONAL_DEPENDENCIES), test_pyproject_optional_deps_all.py (copyleft extras).

Third commit, no network (a fake opener serves tiny local files; checksums are set for them with monkeypatch):

  • tests/foundation/test_modact_fronts.py (new):
    • the conversion negates exactly the maximized columns (CS, CTS, CTSEI) and keeps every digit, and the values equal the file times the objective signs;
    • a row with the wrong number of values, or a value that is not a finite number, is rejected;
    • a checksum that is not the record's raises, and leaves no file;
    • the record table lists the 20 files, the packaged and downloadable sets split them, and the packaged notice is exactly notice(PACKAGED, packaged=True);
    • fetch_fronts downloads the default CTS1-CTS4 from the record's URLs, converts them, adds CTSE and CTSEI fronts, and writes the notice listing every front of the directory with its MD5;
    • a front already there is kept unless force;
    • packaged and unknown keys are refused before any download, and a checksum or network failure leaves neither a front nor a partial file;
    • with VAMOS_DATA_DIR set, resolve_reference_front_path finds a downloaded front, honours its number of objectives, and keeps the packaged CS1 front over a downloaded file of the same name;
    • the user directory follows the platform (Windows, Linux, macOS, and the home-directory fallbacks).
  • tests/experiment/test_cli_zoo.py:
    • vamos zoo fetch-fronts without arguments and with modact_ctse4 writes the fronts where the resolver finds them, with the notice;
    • a packaged front, an unknown key and a failed download exit with code 1 and a message;
    • vamos zoo fetch-fronts --help (subprocess) exits 0 without network access.

Numeric checks (outside the test suite)

On Windows 11, Python 3.12, modact 1.0.1:

  • Agreement: the 20 problems at 220 designs (10 random per problem, plus the feasible design of the level): F and G equal modact's outputs after the sign conversion exactly (array_equal) for every problem, and the feasibility verdicts agree on all 220 (22 feasible).
  • Fronts: each packaged CSV equals the Zenodo file times objective_signs exactly (1664, 2123, 3056, 1783, 1113, 994, 1043 and 1630 rows).
  • End to end, NSGA-II through vamos.optimize, 2000 evaluations, population 100, seed 7:
Problem Time Final population feasible Found points the front dominates Front rows found points dominate Mean normalized distance to the front, VAMOS signs / maximized columns unflipped
modact_ct1 22 s (11 ms per evaluation) 100 of 100 100 of 100 0 of 1113 0.176 / 0.477
modact_cs1 25 s (12 ms) 100 of 100 100 of 100 0 of 1664 0.387 / 0.706
modact_cts1 23 s (12 ms) 100 of 100 100 of 100 0 of 30 534 (Zenodo front, converted) 0.077 / 0.429

The short runs land behind the best-known fronts and close to them only in VAMOS's signs, which is what a correct sign conversion of both the problems and the fronts gives.

  • vamos zoo fetch-fronts, run for real (no VAMOS_DATA_DIR, so the default directory %LOCALAPPDATA%\vamos\reference_fronts):
    • vamos zoo fetch-fronts modact_cts1: exit 0 in 4 s; cts1_PF.dat (2.3 MB) downloaded and MD5-checked, giving modact_cts1.csv (30 534 rows, 2.34 MB). It equals the separately downloaded Zenodo file times objective_signs exactly.
    • vamos zoo fetch-fronts modact_ctse4: exit 0 in 7 s; ctse4_PF.dat (11.0 MB) gives modact_ctse4.csv (109 150 rows, four columns, torque excess, safety factor and efficiency negated).
    • The directory's LICENSE-modact-fronts.txt lists both files with their MD5.
  • Picked up with no further step:
    • resolve_reference_front_path("modact_cts1") and ("modact_ctse4") return the downloaded files; modact_cts2 still has none, and modact_cs1 still resolves to the packaged file.
    • Studio's catalog reports a reference front for modact_cts1 and modact_ctse4.
    • vamos --problem modact_cts1 --algorithm nsgaii --max-evaluations 500 --population-size 100 --hv-threshold 0.99 --hv-reference-front vamos exits 0, and its stored termination records reference_front_path = the downloaded modact_cts1.csv and a target of 908.217 (0.99 of the front's hypervolume, 917.391).
    • NSGA-II through vamos.optimize, against the downloaded fronts:
Problem Budget Feasible in final population Normalized IGD Hypervolume
modact_cts1 1000 evaluations (9 s) 100 of 100 0.302 247.8, 27.0 % of the front's (point from the HV-termination configuration)
modact_ctse4 6000 evaluations (95 s; none feasible at 1000) 100 of 100 0.563 not computed

After Codex's review

fetch_fronts wrote LICENSE-modact-fronts.txt only after downloading every requested front. A later download or checksum failure therefore left the fronts already converted, which VAMOS finds at once, without their CC BY 4.0 attribution. The notice is now rewritten after each conversion, before the next download (463a2b5). test_a_front_kept_after_a_later_failure_has_its_notice failed before the fix. python tools/health.py (including the strict and full typecheck) and the MODAct tests (102 passed, with modact installed) pass after it.

Compatibility

Additive: 20 new registered problems, one new extra outside all, eight packaged CSV files and their notice, and one new vamos zoo subcommand (Experimental). The reference-front lookup gains a third location, the per-user directory, searched last: it resolves only names that neither VAMOS_REFERENCE_FRONTS_DIR nor the package provides, so every front that resolved before resolves to the same file. No existing problem, front, default, configuration or public export changes; vamos.problems and the API snapshot are unchanged. Users without modact see the new keys but cannot create them.

Licensing (for review)

  • VAMOS contains no modact code and does not redistribute modact. It imports it at run time, when a user who installed it creates a problem. The modact extra only declares the dependency; all leaves it out so that no blanket install pulls GPL code.
  • The eight front files are CC BY 4.0 data inside an MIT wheel, with their attribution and change notice in LICENSE-modact-fronts.txt, as jMetal's and Tanabe and Ishibuchi's fronts ship with their MIT notices. The package metadata stays License-Expression: MIT (the release tooling checks that value); whether to declare MIT AND CC-BY-4.0 is left to the maintainers. Dropping the second commit removes the CC BY data entirely.

Validation

All on Windows 11, Python 3.12, with PYTHONPATH set to the worktree's src (checked with vamos.__file__). Runtime venv with -c constraints/ci.txt -e ".[dev,docs,compute,analysis,examples,studio]" plus modact==1.0.1; typing and health with the canonical typing venv.

Final head (b164e80d, all three commits):

Command Result
ruff check and ruff format --check on the changed Python (14 files over the branch) passed (exit 0)
python -m compileall on the changed Python; git diff --check passed (exit 0)
python tools/check_agent_docs.py passed: 32 active files, 6 scoped AGENTS.md (exit 0)
python tools/typecheck.py --scope strict / --scope full 0 diagnostics / 0 diagnostics, ratchet new=0, increased=0, resolved=0 (exit 0)
python tools/health.py all health checks passed (exit 0); its hygiene step: 1915 tracked files. A first run failed the hygiene scan on a home-directory-like path in a test fixture (C:/Users/u/...), replaced by neutral paths
mkdocs build --strict --site-dir <outside the worktree> built, no warnings (exit 0); the new anchors resolve
pytest -q -n 4 -p no:cacheprovider -rfE (full suite, slow tests included, modact installed, real downloaded fronts present in the user directory) 11433 passed, 256 skipped, 9 xfailed, exit 0 (1 h 23 min)
pytest on test_modact_fronts.py, test_cli_zoo.py and test_modact_problems.py with modact hidden by a plugin (sys.modules["modact"] = None), as CI runs 72 passed, 29 skipped (the tests that need modact), exit 0
generate_reference_fronts.py modact_cs1 ... modact_ct4 --modact-dir <Zenodo files> through the shared conversion the eight packaged CSVs byte-identical; the notice regenerated
vamos zoo fetch-fronts modact_cts1, then modact_ctse4 (real network) exit 0 (4 s and 7 s); see "Numeric checks"

Earlier, on the first two commits (dc94ea8a): the same gates passed, with a full suite of 11409 passed, 256 skipped, 9 xfailed; the affected registry-wide tests with modact hidden gave 2159 passed, 127 skipped (the 29 modact tests, the 20 keys in four registry-wide tests, and 18 existing skips). The first commit alone, in a temporary worktree, passed its targeted tests (962 passed, 1 xfailed), mkdocs build --strict and check_agent_docs.

Changelog entry

Added (under [Unreleased])

  • Problems: the 20 MODAct problems of Picard and Schiffmann (2021), modact_cs1 to modact_ctsei4 (20 variables, 2 to 5 objectives, 7 to 10 constraints), evaluated by the authors' modact package, which VAMOS imports when a problem is created and does not include (GPL-3.0; new modact extra, left out of all). Objectives that MODAct maximizes change sign, and G = c_weights * g. The authors' best-known fronts of CS1-CS4 and CT1-CT4 are packaged under CC BY 4.0 (modact_cs1.csv to modact_ct4.csv, LICENSE-modact-fronts.txt).
  • vamos zoo fetch-fronts downloads the MODAct fronts that VAMOS does not package (CTS1-CTS4 by default; CTSE1-CTSE4 and CTSEI1-CTSEI4 on request) from Zenodo, checks their MD5 checksums, converts them as the packaged fronts, and writes them with their CC BY 4.0 notice in a per-user directory (vamos.resources.user_reference_fronts_dir(); VAMOS_DATA_DIR moves it), which the reference-front lookup now searches after the packaged fronts.

Checklist

Architecture health

  • I read the canonical rules in docs/dev/architecture_health.md relevant to this change.
  • I ran the local health command: python tools/health.py.
  • I updated docs/dev/architecture_health.md if I changed guardrails. (The optional-dependency rule now says that all leaves out the copyleft modact extra.)

Public API & dependencies

  • Public API changes are intentional; snapshot updated via python tools/update_public_api_snapshot.py if needed. (No public export changes: the problems are registered by name.)
  • No optional/heavy dependencies were added to core [project].dependencies. (modact is a new optional extra, outside all.)

Behavior & tests

  • Runtime behavior is unchanged (or explicitly documented as a bugfix). (New problems and a new command; the lookup's new directory is searched after every existing location.)
  • Tests pass locally.

Changelog

  • CHANGELOG.md is unchanged, and the changelog entry is under a "Changelog entry" heading in this description.

Reports/retention

  • Raw audit/Goal evidence is external or a CI artifact; only durable conclusions are added to maintained docs.
  • Generated output follows docs/dev/repository_hygiene.md and python tools/check_repository_hygiene.py passes.

🤖 Generated with Claude Code

MODAct (Picard and Schiffmann, IEEE TEVC 25(2):234-246, 2021) designs an
electro-mechanical actuator: 20 variables, 2 to 5 objectives and 7 to 10
constraints. The keys are modact_cs1 to modact_cs4, modact_ct1 to
modact_ct4, modact_cts1 to modact_cts4, modact_ctse1 to modact_ctse4 and
modact_ctsei1 to modact_ctsei4, with fixed n = 20, the paper's M, and
G = 7, 8, 10 and 9 for constraint levels 1 to 4 (Table III).

VAMOS implements none of the model. MODActProblem imports the authors'
modact package (GPL-3.0) with importlib when a problem is created, takes
the bounds, weights and c_weights from it, and checks that the package
defines the problem with the registered dimensions and +-1 weights:
- F = f * -weights: the objectives MODAct maximizes (torque excess,
  safety factor, efficiency) change sign, so every column is minimized;
- G = g * c_weights: c_weights is -1 for g >= 0 and 1 for g <= 0, so
  G <= 0 is feasible.
Both multiply by +-1, so the values are the package's, sign aside, as in
pymoo's wrapper. evaluate calls the package once per row, on a copy.

Without modact the problems are listed, and creating one raises
ImportError with the install command, as fs_real does without
scikit-learn, so the registry-wide tests skip them. The new extra
modact = ["modact>=1.0.1"] (a pure-Python wheel on PyPI; python-fcl has
Windows wheels for Python 3.12) stays out of `all`, because the package
is GPL-3.0; test_pyproject_optional_deps_all.py classes it as a copyleft
extra. The dynamic import keeps [tool.mypy] and the typing baseline
unchanged. A run's environment.json records the modact version.

Tests: registration and fixed dimensions, unknown names, the missing
package (ImportError through the class, the registry and optimize), the
conversion against a stub of modact.problems; with modact installed, F, G
and the feasibility verdict equal the package's outputs at random designs
and at a feasible design of each level for all 20 problems, and a stored
NSGA-II run records modact's version and replays exactly.

Docs, marked "Development after 1.5.0": the MODAct section of the
problems catalog (280 problems), the extra in the installation guide, the
optional-dependency rule in architecture_health.md and step 7 of
add_problem.md.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…der CC BY 4.0

The authors' best-known fronts, cs1_PF.dat to ct4_PF.dat of Zenodo record
10.5281/zenodo.3824302, version 1.1.0 (Picard and Schiffmann, CC BY 4.0),
packaged as modact_cs1.csv to modact_ct4.csv (682 KB).
generate_reference_fronts.py --modact-dir writes them: it checks each
file's MD5 against the record, replaces the separator by a comma and
negates the second column, which MODAct maximizes, at the text level, so
each value keeps its digits and each file is the Zenodo data times the
problem's objective_signs exactly. No row is added or removed; CS2
repeats 17 of its rows, as published, and no row dominates another.

LICENSE-modact-fronts.txt carries the attribution the license asks for:
authors, title, version, DOI, license link, the changes, and the source
file and MD5 of each packaged file. The fronts of CTS1-CTS4 (1.4 to
2.8 MB each) and of CTSE and CTSEI (11 to 193 MB each) are not packaged;
the catalog says how to convert and supply one.

The fronts hold objective vectors only, so no design can be rebuilt from
a row. Tests: files for CS and CT only, two finite columns in VAMOS's
signs, the attribution notice; with modact, the stored feasible design of
each level does not dominate the front of its level, and would if the
front kept MODAct's sign.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…at VAMOS does not package

The best-known fronts of CTS1-CTS4, CTSE1-CTSE4 and CTSEI1-CTSEI4 are
1.4 to 193 MB each, too large to package. `vamos zoo fetch-fronts
[PROBLEM ...] [--all] [--force] [--output DIR]` downloads them from the
Zenodo record 10.5281/zenodo.3824302, version 1.1.0 (CC BY 4.0). It takes
modact_cts1 to modact_cts4 by default. It checks each file's MD5 against
the record's, converts it, and writes modact_<problem>.csv with a
LICENSE-modact-fronts.txt that lists the files of the directory.

One conversion path: vamos.foundation.problem.modact_fronts holds the
record's MD5 and size of the 20 files, convert_front (text-level sign
change of the maximized columns, every digit kept, written through a
temporary file) and the attribution notice. generate_reference_fronts.py
now calls them for the packaged CS and CT fronts: the eight CSVs come out
byte-identical, and the packaged notice is regenerated from the shared
text.

The fronts land where VAMOS finds them with no further step.
vamos.resources.user_reference_fronts_dir() is `reference_fronts` under
VAMOS_DATA_DIR, or under the platform's per-user data directory
(%LOCALAPPDATA%\vamos, ~/Library/Application Support/vamos,
$XDG_DATA_HOME/vamos). The reference-front lookup searches it after
VAMOS_REFERENCE_FRONTS_DIR and the packaged fronts, so a downloaded file
never replaces a packaged front and every existing lookup is unchanged.
tests/conftest.py points VAMOS_DATA_DIR at an empty temporary directory,
so a developer's downloads do not change what the tests resolve.

The command joins `vamos zoo` (Experimental): a tools/ or experiments/
script would not ship in the wheel. Network access happens only when it
runs, through urllib with a timeout. A failed download or checksum leaves
no file, and packaged or unknown keys exit with code 1. The tests serve
tiny local files through a fake opener, and none reaches the network.

The markers this branch added become "VAMOS 1.5.1", the release that
ships MODAct, as the 1.5.0 release renamed its development markers.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 19, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-20T02:20:19.984014Z 463a2b5 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b164e80da5

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@github-actions

github-actions Bot commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

VAMOS documentation preview

https://pr-370-vamos-docs-preview.vamos-optimization.workers.dev

Built from 463a2b5. Canonical metadata points to the production .org domain; the preview itself remains isolated.

…ront

fetch_fronts wrote LICENSE-modact-fronts.txt only after its loop, so a
download or checksum failure after a successful conversion left a front
that VAMOS finds at once without its CC BY 4.0 attribution: fetching cts1
and cts2 with the cts2 download failing kept modact_cts1.csv alone. The
notice is now rewritten after each conversion, before the next download,
and lists every front in the directory. A single failed download still
leaves the directory empty.

test_a_front_kept_after_a_later_failure_has_its_notice fails without this
change.

Reported by Codex's review of #370.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@NicolasRodriguezUribe

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 463a2b5235

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +137 to +138
self.modact_version = _installed_version()
self._problem = problem

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Check MODAct dependency versions before declaring exact replay

When a saved MODAct run is verified after modact is upgraded or removed, recording modact_version here does not protect replay: artifacts/compatibility.py::_material_pairs compares only NumPy, SciPy and the selected backend's package, and resolved-spec reconstruction checks the registry without instantiating the problem. Consequently, verify_run can still report exact replayability with a different or missing objective evaluator, and reproduce proceeds past its environment guard before failing or executing a potentially different optimization. Include the MODAct evaluator's material dependency versions in compatibility checks for these problems, with a regression test that changes or removes the recorded package.

AGENTS.md reference: AGENTS.md:L55-L55

Useful? React with 👍 / 👎.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant