Skip to content

feat: add angle_extended as a supported model - #1298

Merged
AlexanderFengler merged 1 commit into
mainfrom
feat/angle-extended-model
Sep 6, 2026
Merged

feat: add angle_extended as a supported model#1298
AlexanderFengler merged 1 commit into
mainfrom
feat/angle-extended-model

Conversation

@AlexanderFengler

@AlexanderFengler AlexanderFengler commented Sep 6, 2026

Copy link
Copy Markdown
Member

Adds angle_extended — the angle model with drift bounds widened to (−6, 6) — as a built-in.

  • New src/hssm/modelconfig/angle_extended_config.py; registered in SupportedModels, both constructor docstrings, and the docs model table.
  • Bounds are the network's training box from the ssms registry: v (−6, 6), a (0.3, 3), z (0.1, 0.9), t (0.001, 2), theta (−0.1, 1.3).
  • test_config_matches_ssms_registry extended to cover it — list_params order, choices, and the bounds dict are asserted against ssms.config.model_config element-for-element.
  • Raises the ssm-simulators floor to >=0.14.0 — the first release containing angle_extended (v0.13.2 predates it), so without the bump a pip user could hold a registered model the simulator doesn't know.

Ordering note: angle_extended.onnx is on franklab/HSSM_staging (commit 05feb708) with a passing 240-fit recovery report bound to the artifact; the production promote to franklab/HSSM is queued behind this PR's review, same sequence as gamma_drift_angle (#1296). Recommend merging this only once the promote lands, for the same clean-install-404 reason CodeRabbit raised on #1296.

Testing: 944 passed (fast suite) against released ssm-simulators 0.14.0; repo-root ruff unchanged (10 pre-existing notebook findings on main, none in these files).

🤖 Generated with Claude Code

Summary by CodeRabbit

  • New Features

    • Added support for the angle_extended model.
    • Added the model’s configurable parameters, response choices, likelihood, and parameter bounds.
    • Added documentation describing the model and its available likelihood kind.
  • Maintenance

    • Updated the minimum supported ssm-simulators version to 0.14.0.

The angle model with drift bounds widened to (-6, 6), for designs that
produce strong evidence. Bounds and parameter order are asserted against
the ssms registry by the existing cross-check test, now parametrized over
this model too.

Raises the ssm-simulators floor to >=0.14.0, the first release containing
the model.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Sep 6, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Team

Run ID: e3b9c8ef-3442-459a-bcc9-3419d21001cf

📥 Commits

Reviewing files that changed from the base of the PR and between b0f6ba1 and 82f616b.

📒 Files selected for processing (7)
  • docs/reference/models-and-likelihoods.md
  • pyproject.toml
  • src/hssm/_types.py
  • src/hssm/base.py
  • src/hssm/hssm.py
  • src/hssm/modelconfig/angle_extended_config.py
  • tests/test_modelconfig.py

Included review availability: Your plan provides up to 2 included reviews per hour; 1 remains after this review.


📝 Walkthrough

Walkthrough

The change adds angle_extended to the supported model types, defines its default configuration and bounds, validates it against ssm-simulators, updates the dependency requirement, and documents the model.

Changes

Angle Extended Model Support

Layer / File(s) Summary
Model configuration and registry validation
pyproject.toml, src/hssm/_types.py, src/hssm/modelconfig/angle_extended_config.py, tests/test_modelconfig.py
Adds the angle_extended model configuration with its ordered parameters, choices, bounds, ONNX-backed approx_differentiable likelihood, and registry validation. Updates the minimum ssm-simulators version to 0.14.0.
Model documentation
docs/reference/models-and-likelihoods.md, src/hssm/base.py, src/hssm/hssm.py
Adds angle_extended to the built-in model catalog and supported-model documentation.

Estimated code review effort: 2 (Simple) | ~10 minutes

Merge Risk: ⚪ Minimal · up to 82f61

This change adds the angle_extended model with its supported bounds and documentation. Registry validation covers its parameter contract, and no merge-blocking risk remains.

Suggested reviewers: digicosmos86, cpaniaguam

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 66.67% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 3 functions across 5 files. (2 skipped: 2… Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely identifies the primary change: adding angle_extended as a supported model.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

Docstring coverage is 66.67% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 3 functions across 5 files. (2 skipped: 2 unsupported.)

  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/angle-extended-model

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@AlexanderFengler
AlexanderFengler merged commit ff5831f into main Sep 6, 2026
7 checks passed
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