Repository navigation
feat(cli): wire sibling change notices into child agents (#380, 2/2) - #395
Merged
Merged
Conversation
🔍 Cora AI Code Review✅ No issues found. Code looks good! Review powered by cora-code · BYOK · MIT |
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.
What
Part 2 of 2 of sibling change notices: the host wiring. Builds on the core merged in #394.
Why
#380. The core can track and notice, but nothing fed it yet.
Changes
agents.rs:agent_startsetsTOLE_AGENT_IDandTOLE_AGENT_TOUCH_LOG(one<root>/tole-agents/touch.logshared by every sibling of a parent) in the child's environment.sibling.rs(new, tole-cli lib):tracking_from_env(the id must pass the agent-id charset),track(wraps a file tool in theTrackeddecorator; identity outside a child) andstart_watcher(a thread folding the log every 300 ms and queueing each notice into the run's soft-interrupt queue; stops on drop).main.rs: the file tools (read_file,write_file,edit_file,delete_file) are wrapped when tracking, andtole runstarts the watcher. Outside a child nothing changes (no env, no wrapper, no thread). Compiles in the bare profile.Testing
sibling_notice_e2e): child A readsshared.txtand waits on a slow model step; child B overwrites it meanwhile; A's next model request carries the attributedsibling noticeand the mock only answersA_NOTICEDif it does.trackis the identity outside a child,agent_startpasses the id and the shared log path.cargo check --no-default-featurespass; cora review --staged clean.Refs #380