tactic search: announce the learned ranking only when it reordered a ladder - #108
Merged
Merged
Conversation
…ladder Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Contributor
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
AkiraTamai
marked this pull request as ready for review
July 27, 2026 05:15
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
Follow-up to #106. The run-level log line claimed a learned ranking whenever
data/tactic_search_history.jsonwas non-empty, even for runs where no obligation's ladder actually moved — the opposite of the per-atomtactic_search.history_rankedfield, which #106 fixed to mean "this obligation was reordered" (spec §12.4).The announcement is now emitted lazily, from the first obligation whose ladder the artifact actually reordered:
So it still prints at most once per run and carries the same path/fingerprint, but only when the ranking was applied.
_run_tactic_search_stagegains ahistory_pathparameter for the message (defaulting toHISTORY_PATH); no behavioural change to the search itself, and no contract, schema or artifact change.test_ranking_is_announced_only_when_an_obligation_was_reorderedpins both directions: a non-empty artifact scoped to a different(obligation_class, stage)prints nothing, an applicable one prints the line.Verification
PYTHONPATH=scripts MUMEI_LEAN_SKIP_LIVE=1 python -m pytest -q→ 307 passed, 10 skippedPYTHONPATH=scripts PATH="$HOME/.elan/bin:$PATH" python -m pytest tests/test_lean_bridge_e2e.py tests/test_tactic_search.py tests/test_tactic_history.py -q(reallake build) → 44 passedLink to Devin session: https://app.devin.ai/sessions/99669609dea14e2ba7a541689de09a0a
Requested by: @AkiraTamai