GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • ADK for TypeScript: API Reference

This view

  • Original page
  • New address

GeezerVison is showing adk.dev — CompactedEvent | ADK for TypeScript: API Reference - v2.5.0

  • CompactedEvent

Interface CompactedEvent

A specialized Event type that represents a synthesized summary of past events. This is used to compress session history without losing critical context.

interface CompactedEvent {
    "[EVENT_SIGNATURE_SYMBOL]"?: true;
    actions: EventActions;
    author?: string;
    branch?: string;
    citationMetadata?: CitationMetadata;
    compactedContent: string;
    content?: Content;
    customMetadata?: { [key: string]: unknown };
    endTime: number;
    errorCode?: string;
    errorMessage?: string;
    finishReason?: FinishReason;
    goAway?: LiveServerGoAway;
    groundingMetadata?: GroundingMetadata;
    id: string;
    inputTranscription?: Transcription;
    interactionId?: string;
    interrupted?: boolean;
    invocationId: string;
    isCompacted: true;
    isolationScope?: string;
    isScratchpad?: boolean;
    liveSessionId?: string;
    liveSessionResumptionUpdate?: LiveServerSessionResumptionUpdate;
    longRunningToolIds?: string[];
    modelVersion?: string;
    nodeInfo?: NodeInfo;
    output?: unknown;
    outputTranscription?: Transcription;
    partial?: boolean;
    route?: Route;
    startTime: number;
    timestamp: number;
    turnComplete?: boolean;
    usageMetadata?: GenerateContentResponseUsageMetadata;
}

Hierarchy (View Summary)

  • Event
    • CompactedEvent
  • Defined in core/src/events/compacted_event.ts:13

Properties

Optional Readonly[EVENT_SIGNATURE_SYMBOL]

"[EVENT_SIGNATURE_SYMBOL]"?: true

Signature brand identifying this object as an ADK Event.

Set by createEvent and checked by isEvent. Optional because events are also reconstructed from storage/session payloads, where the (non-serializable) brand is absent.

Inherited from Event.[EVENT_SIGNATURE_SYMBOL]

  • Defined in core/src/events/event.ts:82

actions

actions: EventActions

The actions taken by the agent.

Inherited from Event.actions

  • Defined in core/src/events/event.ts:105

Optionalauthor

author?: string

"user" or the name of the agent, indicating who appended the event to the session.

Inherited from Event.author

  • Defined in core/src/events/event.ts:100

Optionalbranch

branch?: string

The branch of the event. The format is like agent_1.agent_2.agent_3, where agent_1 is the parent of agent_2, and agent_2 is the parent of agent_3.

Branch is used when multiple sub-agent shouldn't see their peer agents' conversation history.

Inherited from Event.branch

  • Defined in core/src/events/event.ts:122

OptionalcitationMetadata

citationMetadata?: CitationMetadata

The citation metadata of the response.

Inherited from Event.citationMetadata

  • Defined in core/src/models/llm_response.ts:37

compactedContent

compactedContent: string

The summarized content of the compacted events.

  • Defined in core/src/events/compacted_event.ts:32

Optionalcontent

content?: Content

The content of the response.

Inherited from Event.content

  • Defined in core/src/models/llm_response.ts:27

OptionalcustomMetadata

customMetadata?: { [key: string]: unknown }

The custom metadata of the LlmResponse. An optional key-value pair to label an LlmResponse. NOTE: the entire object must be JSON serializable.

Inherited from Event.customMetadata

  • Defined in core/src/models/llm_response.ts:72

endTime

endTime: number

The end time of the context that was compacted.

  • Defined in core/src/events/compacted_event.ts:27

OptionalerrorCode

errorCode?: string

Error code if the response is an error. Code varies by model.

Inherited from Event.errorCode

  • Defined in core/src/models/llm_response.ts:54

OptionalerrorMessage

errorMessage?: string

Error message if the response is an error.

Inherited from Event.errorMessage

  • Defined in core/src/models/llm_response.ts:59

OptionalfinishReason

finishReason?: FinishReason

The finish reason of the response.

Inherited from Event.finishReason

  • Defined in core/src/models/llm_response.ts:82

OptionalgoAway

goAway?: LiveServerGoAway

Server-side signal that the live connection will be closed soon. The caller should reconnect using the latest session resumption handle.

Inherited from Event.goAway

  • Defined in core/src/models/llm_response.ts:93

OptionalgroundingMetadata

groundingMetadata?: GroundingMetadata

The grounding metadata of the response.

Inherited from Event.groundingMetadata

  • Defined in core/src/models/llm_response.ts:32

id

id: string

The unique identifier of the event. Do not assign the ID. It will be assigned by the session.

Inherited from Event.id

  • Defined in core/src/events/event.ts:88

OptionalinputTranscription

inputTranscription?: Transcription

Audio transcription of user input.

Inherited from Event.inputTranscription

  • Defined in core/src/models/llm_response.ts:98

OptionalinteractionId

interactionId?: string

The interaction ID returned by the model, if any.

Inherited from Event.interactionId

  • Defined in core/src/models/llm_response.ts:108

Optionalinterrupted

interrupted?: boolean

Flag indicating that LLM was interrupted when generating the content. Usually it's due to user interruption during a bidi streaming.

Inherited from Event.interrupted

  • Defined in core/src/models/llm_response.ts:65

invocationId

invocationId: string

The invocation ID of the event. Should be non-empty before appending to a session.

Inherited from Event.invocationId

  • Defined in core/src/events/event.ts:94

ReadonlyisCompacted

isCompacted: true

Identifies this event as a compacted event.

  • Defined in core/src/events/compacted_event.ts:17

OptionalisolationScope

isolationScope?: string

Workflow: scope tag used to isolate multi-agent conversations so peer scopes don't see each other's events. Mirrors Python Event.isolation_scope.

Inherited from Event.isolationScope

  • Defined in core/src/events/event.ts:155

OptionalisScratchpad

isScratchpad?: boolean

Identifies this compacted event as the persistent context scratchpad.

  • Defined in core/src/events/compacted_event.ts:37

OptionalliveSessionId

liveSessionId?: string

The session ID of the Live session.

Inherited from Event.liveSessionId

  • Defined in core/src/models/llm_response.ts:114

OptionalliveSessionResumptionUpdate

liveSessionResumptionUpdate?: LiveServerSessionResumptionUpdate

The session resumption update of the LlmResponse

Inherited from Event.liveSessionResumptionUpdate

  • Defined in core/src/models/llm_response.ts:87

OptionallongRunningToolIds

longRunningToolIds?: string[]

Set of ids of the long running function calls. Agent client will know from this field about which function call is long running. Only valid for function call event

Inherited from Event.longRunningToolIds

  • Defined in core/src/events/event.ts:112

OptionalmodelVersion

modelVersion?: string

The model version used to generate the response.

Inherited from Event.modelVersion

  • Defined in core/src/models/llm_response.ts:111

OptionalnodeInfo

nodeInfo?: NodeInfo

Workflow: provenance of the emitting node. Mirrors Python Event.node_info.

Inherited from Event.nodeInfo

  • Defined in core/src/events/event.ts:148

Optionaloutput

output?: unknown

Workflow: the structured output produced by the emitting node, if any.

First-class field mirroring google/adk-python Event.output. Used by the workflow engine to carry a node's return value alongside its content.

Inherited from Event.output

  • Defined in core/src/events/event.ts:135

OptionaloutputTranscription

outputTranscription?: Transcription

Audio transcription of model output.

Inherited from Event.outputTranscription

  • Defined in core/src/models/llm_response.ts:103

Optionalpartial

partial?: boolean

Indicates whether the text content is part of a unfinished text stream. Only used for streaming mode and when the content is plain text.

Inherited from Event.partial

  • Defined in core/src/models/llm_response.ts:43

Optionalroute

route?: Route

Workflow: the route key(s) emitted by a routing node, used by the graph to select the matching outgoing edge(s). A single value fires one branch; an array fires every branch whose route matches any listed value (multi-route dispatch). Mirrors Python Event.route.

Inherited from Event.route

  • Defined in core/src/events/event.ts:143

startTime

startTime: number

The start time of the context that was compacted.

  • Defined in core/src/events/compacted_event.ts:22

timestamp

timestamp: number

The timestamp of the event.

Inherited from Event.timestamp

  • Defined in core/src/events/event.ts:127

OptionalturnComplete

turnComplete?: boolean

Indicates whether the response from the model is complete. Only used for streaming mode.

Inherited from Event.turnComplete

  • Defined in core/src/models/llm_response.ts:49

OptionalusageMetadata

usageMetadata?: GenerateContentResponseUsageMetadata

The usage metadata of the LlmResponse.

Inherited from Event.usageMetadata

  • Defined in core/src/models/llm_response.ts:77
Properties
[EVENT_SIGNATURE_SYMBOL]actionsauthorbranchcitationMetadatacompactedContentcontentcustomMetadataendTimeerrorCodeerrorMessagefinishReasongoAwaygroundingMetadataidinputTranscriptioninteractionIdinterruptedinvocationIdisCompactedisolationScopeisScratchpadliveSessionIdliveSessionResumptionUpdatelongRunningToolIdsmodelVersionnodeInfooutputoutputTranscriptionpartialroutestartTimetimestampturnCompleteusageMetadata
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.