research(episodes): add bounded window-separated candidate core - #114
Merged
Conversation
Owner
Author
|
Post-CI diff review completed at
Final evidence: clean detached-tree MSVC |
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.
Summary
Why
The committed v0.7 fixture proves that adjacent-gap segmentation can keep two dense peaks in one activity segment. This PR isolates the candidate selection policy before any oracle or runtime integration, keeping the first review slice independently verifiable.
How to validate
Expected: 4 Python tests and 7 CTest entries pass.
Design decision
Use exhaustive contiguous-window enumeration plus deterministic weighted interval selection only as a bounded research core. Compatibility requires a gap strictly greater than one rule window; ties resolve by covered events, compactness, episode count, then chronological key.
Main risk
Worst-case candidate materialization and predecessor scanning are super-quadratic. The core therefore fails closed above 200 fixture events or 1,000 candidates per segment and is not production-ready.
Compatibility impact
None for
Detector::analyze(),loglens.report.v3, CLI output, configuration, or release behavior. Python is used only for research tests; C++ consumers without Python continue to build with that optional test skipped.Rollback path
Revert the three commits in this PR. No migration, schema transition, or generated artifact cleanup is required.
Follow-up
A separate PR will bind this core to the committed baseline, materialize the candidate oracle, validate cross-references and JSON Schema, and record the measured fixture outcome.