mirror of
https://github.com/anomalyco/opencode.git
synced 2026-11-20 18:57:17 +03:00
fix(core): only discourage unprompted subagent status checks (#63662)
This commit is contained in:
committed by
GitHub
Unverified
parent
5eac2802b7
commit
c4601e3d14
@@ -20,7 +20,7 @@ const backgroundResult = (sessionID: SessionSchema.ID) => ({
|
||||
status: "running" as const,
|
||||
output: [
|
||||
`The subagent is working in the background (sessionID: ${sessionID}). You will receive a <subagent> message when it goes idle, and again after each later round of work.`,
|
||||
"DO NOT sleep, poll for progress, ask the subagent for status, or duplicate this subagent's work; avoid working with the same files or topics it is using.",
|
||||
"DO NOT sleep, poll, proactively check on its progress, or duplicate this subagent's work.",
|
||||
"Work on non-overlapping tasks, or briefly tell the user what you launched and end your response.",
|
||||
"To send it follow-ups or change its instructions while it runs, call subagent again with this sessionID.",
|
||||
].join("\n"),
|
||||
@@ -50,7 +50,7 @@ export const Output = Schema.Struct({
|
||||
export const description = [
|
||||
"Spawns an agent in a child session to work on the specified task.",
|
||||
"Subagents always run in the background: the call returns immediately with a sessionID, and you receive a `<subagent>` message each time the child goes idle, including after later work.",
|
||||
"Keep working on non-overlapping tasks, or briefly tell the user what you launched and end your response. Do not sleep, poll for progress, or ask the child for status.",
|
||||
"Keep working on non-overlapping tasks, or briefly tell the user what you launched and end your response. Do not sleep, poll, or proactively check on the child's progress.",
|
||||
"New child sessions start with fresh context, so include all relevant context and instructions when you don't pass a sessionID.",
|
||||
"Pass the returned sessionID to continue that specific child conversation. A follow-up to a running child joins its current run.",
|
||||
].join("\n")
|
||||
|
||||
@@ -508,7 +508,7 @@ function subagentLaunch(sessionID: string) {
|
||||
return {
|
||||
output: [
|
||||
`The subagent is working in the background (sessionID: ${sessionID}). You will receive a <subagent> message when it goes idle, and again after each later round of work.`,
|
||||
"DO NOT sleep, poll for progress, ask the subagent for status, or duplicate this subagent's work; avoid working with the same files or topics it is using.",
|
||||
"DO NOT sleep, poll, proactively check on its progress, or duplicate this subagent's work.",
|
||||
"Work on non-overlapping tasks, or briefly tell the user what you launched and end your response.",
|
||||
"To send it follow-ups or change its instructions while it runs, call subagent again with this sessionID.",
|
||||
].join("\n"),
|
||||
|
||||
Reference in New Issue
Block a user