Skip to main content

Interface: SpawnAgentSegment

Defined in: packages/core/src/stream-segments/types.ts:100

Deprecated

Use ToolCallSegment with name='spawn_agent' instead. Kept for v1 backward compatibility.

Extends

Properties

agentId?

optional agentId?: string

Defined in: packages/core/src/stream-segments/types.ts:20

Agent that produced this segment (populated in group chat contexts)

Inherited from

BaseSegment.agentId


agentName?

optional agentName?: string

Defined in: packages/core/src/stream-segments/types.ts:22

Display name of the agent

Inherited from

BaseSegment.agentName


agentType

agentType: string

Defined in: packages/core/src/stream-segments/types.ts:108

Agent type: "Task" (has write tools) or "Explore" (read-only tools)


avatarEmoji?

optional avatarEmoji?: string

Defined in: packages/core/src/stream-segments/types.ts:24

Avatar emoji for display

Inherited from

BaseSegment.avatarEmoji


childSegments

childSegments: StreamSegment[]

Defined in: packages/core/src/stream-segments/types.ts:110

Child agent segments - rendered with same UI as parent chat


currentIteration

currentIteration: number

Defined in: packages/core/src/stream-segments/types.ts:112

Current iteration count


error?

optional error?: string

Defined in: packages/core/src/stream-segments/types.ts:120

Error message if failed


goal

goal: string

Defined in: packages/core/src/stream-segments/types.ts:106

Goal passed to spawn_agent


id

id: string

Defined in: packages/core/src/stream-segments/types.ts:16

Unique identifier for React keys

Inherited from

BaseSegment.id


maxIterations

maxIterations: number

Defined in: packages/core/src/stream-segments/types.ts:114

Max iterations allowed


name?

optional name?: string

Defined in: packages/core/src/stream-segments/types.ts:104

Display name for this agent (set by parent)


result?

optional result?: unknown

Defined in: packages/core/src/stream-segments/types.ts:118

Final result when complete


status

status: "running" | "completed" | "failed"

Defined in: packages/core/src/stream-segments/types.ts:122

Status for display


timestamp

timestamp: number

Defined in: packages/core/src/stream-segments/types.ts:18

Timestamp for ordering

Inherited from

BaseSegment.timestamp


tokensUsed

tokensUsed: number

Defined in: packages/core/src/stream-segments/types.ts:116

Tokens used so far


toolCallId

toolCallId: string

Defined in: packages/core/src/stream-segments/types.ts:102


type

type: "spawn_agent"

Defined in: packages/core/src/stream-segments/types.ts:101