🐛 Describe the bug
num_expanding_parents accepts 0 and negative values without validation.
A value of 0 causes select_candidates() to return an empty candidate list,
spawning zero workers per round. All max_rounds rounds complete silently
with no optimization progress and no error or warning surfaced.
location: triton_kernel_agent/opt_worker_component/searching/strategy/beam_search.py
reproduction:
from triton_kernel_agent.opt_worker_component.searching import BeamSearchStrategy
s = BeamSearchStrategy(num_expanding_parents=0)
s.initialize(program)
candidates = s.select_candidates(round_num=1)
# candidates is empty and zero workers spawn, rounds consumed silently
two related problems I found:
BeamSearchStrategy candidate dicts are missing the inspirations key
required by the SearchStrategy Protocol. GreedyStrategy already
provides this key; the inconsistency means future Mutator implementations
reading inspirations from the candidate dict would silently get nothing
under beam search.
ptx_hash_from_cache silently skips unreadable PTX files with no log
output, returning an incomplete fingerprint with no indication to the caller.
Have a fix ready for all three with 19 new tests in PR #146. All 72 existing tests
pass
Platform and Version
main branch, tested on Google Colab (NVIDIA T4 GPU), Python 3.12
🐛 Describe the bug
num_expanding_parentsaccepts 0 and negative values without validation.A value of 0 causes
select_candidates()to return an empty candidate list,spawning zero workers per round. All
max_roundsrounds complete silentlywith no optimization progress and no error or warning surfaced.
location:
triton_kernel_agent/opt_worker_component/searching/strategy/beam_search.pyreproduction:
two related problems I found:
BeamSearchStrategycandidate dicts are missing theinspirationskeyrequired by the
SearchStrategyProtocol.GreedyStrategyalreadyprovides this key; the inconsistency means future
Mutatorimplementationsreading
inspirationsfrom the candidate dict would silently get nothingunder beam search.
ptx_hash_from_cachesilently skips unreadable PTX files with no logoutput, returning an incomplete fingerprint with no indication to the caller.
Have a fix ready for all three with 19 new tests in PR #146. All 72 existing tests
pass
Platform and Version
main branch, tested on Google Colab (NVIDIA T4 GPU), Python 3.12