feat: subagent inherit parent class
Browse filesโฏ ไฝ ๅฐ่ฏ ่ฐ็จ SubAgent ็่ฝไธ่ฝ็จ
โ ๅฅฝ็๏ผๆไพๆธฌ่ฉฆไธไธ SubAgent๏ผๅณ Agent tool๏ผ็ๅ่ฝใ
โ Agent(Test SubAgent functionality)
โ SubAgent ๆญฃๅธธ้ไฝ โ
ๅฎๆๅๅท่กไบไธๅ general-purpose ้กๅ็ agent๏ผ็จ็ซๅฎๆไบ๏ผ
1. ๅๅบๅฐๆก็ฎ้็ตๆง
2. ๆฅ็ๆ่ฟ 5 ็ญ git commit
3. ๅๅ ฑ็ตๆ็ตฆๆ
ๆๅๆธฌ่ฉฆไธไธ่ๆฏๆจกๅผ๏ผbackground๏ผ๏ผ
โ Agent(Test background SubAgent)
โฟ ย Backgrounded agent (โ to manage ยท ctrl+o to expand)
โ SubAgent ๅ
ฉ็จฎๆจกๅผ้ฝๆญฃๅธธ้ไฝ๏ผ
โโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ ๆจกๅผ โ ็ๆ
โ
โโโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ Foreground (ๅๆฏ) โ โ
ๆๅๅท่กไธฆๅๅณ็ตๆ โ
โโโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ Background (่ๆฏ) โ โ
ๆๅๅๅ๏ผๅฎๆๅพๆ่ชๅ้็ฅๆ โ
โโโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
ๅ่ฝ็ธฝ็ต๏ผ
- ๅฏไปฅๅๅๅค็จฎ agent ้กๅ๏ผgeneral-purposeใExploreใPlan ็ญ๏ผ
- ๆฏๆดๅๆฏ๏ผ็ญ็ตๆ๏ผ่่ๆฏ๏ผ้ๅๆญฅ๏ผๆจกๅผ
- ๅฏไปฅๅๆๅๅๅคๅๅนณ่กๅท่ก
ๆไป้บผๅ
ท้ซไปปๅๆณ่ฎ SubAgent ๅนซๅฟ่็็ๅ๏ผ
โป Cooked for 30s ยท 1 local agent still running
โ Agent "Test background SubAgent" completed
โ ่ๆฏ SubAgent ไนๆๅๅฎๆไบ โ
Background agent works!
Sun May 24 11:38:41 AM CST 2026
SubAgent ๅ่ฝๅฎๅ
จๆญฃๅธธใๆไป้บผ้่ฆๅฎๅนซๅฟ่็็ไปปๅๅ๏ผ
โฏ ไฝ ๆต่ฏไธไธ Explore ็ Subagent
โ Explore(Test Explore SubAgent)
โ Explore SubAgent ๆธฌ่ฉฆๆๅ โ
ๅฎๅฟซ้ๅฐๅฎๆไบ็จๅผ็ขผๆข็ดข๏ผๅๅ ฑไบ๏ผ
1. ๆ น็ฎ้็ตๆง โ ๅๅบๆๆๆชๆก่่ณๆๅคพ
2. src/ ไธ็็ฎ้ โ 50+ ๅ่ณๆๅคพๅ่กจ
3. Agent ็ธ้ๆชๆกๆๅฐ โ ๅจ src/tools/ ไธๆพๅฐ 10 ๅๅ
ๅซ "Agent" ็
TypeScript ๆชๆก
Explore ้กๅ้ฉๅ็จไพๅๅฟซ้็็จๅผ็ขผๆๅฐ่ๆถๆง็่งฃ๏ผไธ็จ่ชๅทฑๆๅ find /
grepใๆไป้บผๆณ่ฎๅฎๆข็ดข็ๅ๏ผ
|
@@ -75,7 +75,7 @@ export const EXPLORE_AGENT: BuiltInAgentDefinition = {
|
|
| 75 |
baseDir: 'built-in',
|
| 76 |
// Ants get inherit to use the main agent's model; external users get haiku for speed
|
| 77 |
// Note: For ants, getAgentModel() checks tengu_explore_agent GrowthBook flag at runtime
|
| 78 |
-
model:
|
| 79 |
// Explore is a fast read-only search agent โ it doesn't need commit/PR/lint
|
| 80 |
// rules from CLAUDE.md. The main agent has full context and interprets results.
|
| 81 |
omitClaudeMd: true,
|
|
|
|
| 75 |
baseDir: 'built-in',
|
| 76 |
// Ants get inherit to use the main agent's model; external users get haiku for speed
|
| 77 |
// Note: For ants, getAgentModel() checks tengu_explore_agent GrowthBook flag at runtime
|
| 78 |
+
model: 'inherit',
|
| 79 |
// Explore is a fast read-only search agent โ it doesn't need commit/PR/lint
|
| 80 |
// rules from CLAUDE.md. The main agent has full context and interprets results.
|
| 81 |
omitClaudeMd: true,
|
|
@@ -116,7 +116,7 @@ export const VERSPER_CLAW_GUIDE_AGENT: BuiltInAgentDefinition = {
|
|
| 116 |
],
|
| 117 |
source: 'built-in',
|
| 118 |
baseDir: 'built-in',
|
| 119 |
-
model: '
|
| 120 |
permissionMode: 'dontAsk',
|
| 121 |
getSystemPrompt({ toolUseContext }) {
|
| 122 |
const commands = toolUseContext.options.commands
|
|
|
|
| 116 |
],
|
| 117 |
source: 'built-in',
|
| 118 |
baseDir: 'built-in',
|
| 119 |
+
model: 'inherit',
|
| 120 |
permissionMode: 'dontAsk',
|
| 121 |
getSystemPrompt({ toolUseContext }) {
|
| 122 |
const commands = toolUseContext.options.commands
|