feat(task): support subagent context forking#22398
Open
shaojunxu-1981 wants to merge 1 commit intoanomalyco:devfrom
Open
feat(task): support subagent context forking#22398shaojunxu-1981 wants to merge 1 commit intoanomalyco:devfrom
shaojunxu-1981 wants to merge 1 commit intoanomalyco:devfrom
Conversation
Add fork_context to let new task subagents fork the parent session history when needed. Also add reasoning_effort overrides for new subagent launches without changing resumed task sessions.
Contributor
|
Thanks for updating your PR! It now meets our contributing guidelines. 👍 |
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.
Issue for this PR
Closes #
Type of change
What does this PR do?
Adds
fork_contextandreasoning_effortto thetasktool so new subagent sessions can either inherit the current session history or stay isolated, and optionally override reasoning effort for that launch. This wires the new fields through session creation and prompt/model handling, updates the generated JS SDK and agent docs in both English and Chinese, and adds coverage for isolated vs forked child sessions plus reasoning override behavior on new and resumed tasks.How did you verify your code works?
npx -y bun typechecknpx -y bun test --timeout 30000 test/tool/task.test.tsnpx -y bun ./script/build.tsinpackages/sdk/jsScreenshots / recordings
N/A
Checklist