mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-07-08 13:12:08 +00:00
style(profile): frame comments around what the code does
This commit is contained in:
parent
a6175d1f93
commit
00eefc7f2b
3 changed files with 5 additions and 8 deletions
|
|
@ -25,9 +25,7 @@ _MAX_TEXT_CHARS = 2000
|
|||
|
||||
|
||||
def _store_path() -> str:
|
||||
# Resolve via get_hermes_home() so the profile override is honored; reading
|
||||
# os.environ["HERMES_HOME"] directly bypassed it and leaked the index into
|
||||
# the launch profile (multi-profile tui_gateway / gateway).
|
||||
# Resolve via get_hermes_home() so the active profile override is honored.
|
||||
from hermes_constants import get_hermes_home
|
||||
|
||||
home = get_hermes_home()
|
||||
|
|
|
|||
|
|
@ -144,9 +144,8 @@ def _run_async(coro):
|
|||
worker_loop.close()
|
||||
|
||||
pool = concurrent.futures.ThreadPoolExecutor(max_workers=1)
|
||||
# Propagate the profile override + approval/sudo callbacks into the
|
||||
# worker so async tools resolving get_hermes_home() see the active
|
||||
# profile, not the launch one (multi-profile tui_gateway / gateway).
|
||||
# Carry the active profile + approval/sudo callbacks into the worker so
|
||||
# async tools resolve get_hermes_home() under the active profile.
|
||||
from tools.thread_context import propagate_context_to_thread
|
||||
|
||||
future = pool.submit(propagate_context_to_thread(_run_in_worker))
|
||||
|
|
|
|||
|
|
@ -1532,8 +1532,8 @@ class AIAgent:
|
|||
review_memory=review_memory,
|
||||
review_skills=review_skills,
|
||||
)
|
||||
# Propagate the profile override into the review thread, else it writes
|
||||
# MEMORY.md / skill review into the launch profile (#54937).
|
||||
# Carry the active profile into the review thread so MEMORY.md / skill
|
||||
# review writes land in the right profile (#54937).
|
||||
t = threading.Thread(
|
||||
target=propagate_context_to_thread(target), daemon=True, name="bg-review"
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue