Repository navigation
Store semantic metadata lazily - #124
Conversation
|
No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Lazy cells and objective lifecycle crates/oximo-core/src/shared.rs, crates/oximo-core/src/model.rs, crates/oximo-core/src/display.rs, crates/oximo-core/src/model/tests.rs, crates/oximo-core/tests/function_representation.rs |
LazySharedCell provides optional shared storage with lazy initialization and revision tracking. Model objective state uses a scalar-kind signature and a lazy semantic-objective cache. Added tests cover cache reads, updates, and fork behavior. |
Run-based semantic storage crates/oximo-core/src/model/semantic/positions.rs, crates/oximo-core/src/model/semantic/storage.rs |
Semantic entries and native positions are stored as contiguous runs with sparse overrides. Iterators support seeking and forward and reverse traversal. Provenance changes use per-constraint overrides. |
Optional metadata access and registration crates/oximo-core/src/model/constraints.rs, crates/oximo-core/src/model/dependencies.rs, crates/oximo-core/src/model/indexed.rs, crates/oximo-core/src/model/semantic.rs, crates/oximo-core/src/model/semantic/views.rs, crates/oximo-core/src/model/variables.rs, crates/oximo-core/src/reformulation/*, crates/oximo-core/src/semantic/view.rs, crates/oximo-core/src/model/tests.rs |
Registration defers semantic writer creation, and access paths handle absent registries, views, and reformulation history. Added tests cover lazy metadata and view iteration. |
Priority:
Estimated code review effort: 4 (Complex) | ~45 minutes
Change: Refactor
Possibly related PRs
- oximo-rs/oximo#118: Adds parameter dependency traversal for semantic objectives, constraints, and inactive scalar views; this PR updates those access paths for optional lazy storage.
Merge Risk: 
Minimal · up to 3cecf
-
No actionable issue remains from the reviewed changes; the PR is mergeable after normal checks.
Pre-merge checks: 
4 · 
1
-
Failed checks: 1 warning Passed checks: 4 passed-
Full details: Description check
-
Explanation
The description states the main change and includes the core checklist items with reported completion. It omits the Changes Made and Related Issues sections, but the description is sufficiently complete for this change.
-
Full details: Docstring Coverage
-
Explanation
Docstring coverage is 52.27% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 44 functions across 15 files.
Resolution
Write docstrings for the functions missing them to satisfy the coverage threshold.
-
Finishing Touches: 💡 1
-
📝 Generate docstrings: 💡
-
- Commit to this branch
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
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.
Comment @coderabbitai help to get the list of available commands.
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
Description
This PR stores semantic metadata lazily.
Checklist
cargo fmtandcargo clippyto ensure code qualitycargo test)