fix(missions): honor configured LLM temperature for bank mission merge (#2469 follow-up)#2477
Open
r266-tech wants to merge 1 commit into
Open
fix(missions): honor configured LLM temperature for bank mission merge (#2469 follow-up)#2477r266-tech wants to merge 1 commit into
r266-tech wants to merge 1 commit into
Conversation
vectorize-io#2469 made the internal LLM temperature configurable and documents that HINDSIGHT_API_LLM_TEMPERATURE=none "drops temperature from every operation", but bank/folder mission merging (_llm_merge_mission, scope="bank_mission") still hardcoded temperature=0.3 and never read the config. For models that reject explicit temperatures (Azure gpt-5.5 -- the vectorize-io#2459 case) the 0.3 is still sent, the exception is swallowed by the try/except, and the LLM merge silently degrades to naive "{current} {new_info}" concatenation -- so a user who applied vectorize-io#2469's documented HINDSIGHT_API_LLM_TEMPERATURE=none remedy still gets broken mission merging. Add bank_mission as a 5th per-operation temperature knob mirroring the four introduced in vectorize-io#2469 (verification/retain/reflect/consolidation): it resolves per-op env -> global HINDSIGHT_API_LLM_TEMPERATURE -> built-in default 0.3, so the documented global override now covers mission merging too. Regenerated the docs skill mirror; added env + pipeline regression tests.
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.
Problem
#2469 made the internal LLM temperature configurable and its docs state the global
HINDSIGHT_API_LLM_TEMPERATURE"applies to every operation" andnone"drops temperature from every operation" (the documented remedy for models that reject explicit temperatures, e.g. Azuregpt-5.5, issue #2459).But bank/folder mission merging is a 5th internal LLM call that #2469 didn't reach.
_llm_merge_mission(engine/retain/bank_utils.py,scope="bank_mission", used bymerge_bank_mission) still hardcodestemperature=0.3and never readsget_config():So setting
HINDSIGHT_API_LLM_TEMPERATURE=none(your documented fix for Azure gpt-5.5) does not cover mission merging — the0.3is still sent, the call raises, thetry/exceptin_llm_merge_missionswallows it, and the merge silently degrades to naive"{current} {new_info}"concatenation. With folder missions / mission-sandbox (#2455, #2254) actively shipping, this path is gaining users following the docs and still hitting a silent failure.Fix
Add
bank_missionas a 5th per-operation temperature knob, mirroring the four introduced in #2469 (verification / retain / reflect / consolidation):ENV_LLM_TEMPERATURE_BANK_MISSION+DEFAULT_LLM_TEMPERATURE_BANK_MISSION = 0.3(preserves the historical value)HindsightConfig.llm_temperature_bank_mission, resolved via the existing_resolve_operation_temperature(per-op env → globalHINDSIGHT_API_LLM_TEMPERATURE→ default0.3)bank_utils.pynow passestemperature=get_config().llm_temperature_bank_missionThe documented global override now genuinely covers mission merging, and
nonecorrectly omits the parameter there too. Default behavior is unchanged (still0.3).Docs / tests
configuration.mdand regenerated the CI-enforced skills mirror viascripts/generate-docs-skill.sh(diff is the single new row).test_llm_temperature_env.py:bank_missionadded to_OP_FIELDS, so the default / global-override / global-noneresolution cases now assert it too.test_llm_temperature_pipeline.py: two new tests drive_llm_merge_missionthrough the mock LLM and assert thebank_missioncall receives0.3by default andNone(omitted) underHINDSIGHT_API_LLM_TEMPERATURE=none.test_llm_temperature_env.pypasses locally (13 passed); the pipeline tests mirror the existing reflect/retain pipeline tests (they need the Postgres-backedmemoryfixture, which runs in CI).Follow-up to merged #2469.