Represents the actions attached to an event.
| 50 | |
| 51 | |
| 52 | class EventActions(BaseModel): |
| 53 | """Represents the actions attached to an event.""" |
| 54 | |
| 55 | model_config = ConfigDict( |
| 56 | extra='forbid', |
| 57 | alias_generator=alias_generators.to_camel, |
| 58 | populate_by_name=True, |
| 59 | ) |
| 60 | """The pydantic model config.""" |
| 61 | |
| 62 | skip_summarization: Optional[bool] = None |
| 63 | """If true, it won't call model to summarize function response. |
| 64 | |
| 65 | Only used for function_response event. |
| 66 | """ |
| 67 | |
| 68 | state_delta: dict[str, Any] = Field(default_factory=dict) |
| 69 | """Indicates that the event is updating the state with the given delta.""" |
| 70 | |
| 71 | artifact_delta: dict[str, int] = Field(default_factory=dict) |
| 72 | """Indicates that the event is updating an artifact. key is the filename, |
| 73 | value is the version.""" |
| 74 | |
| 75 | transfer_to_agent: Optional[str] = None |
| 76 | """If set, the event transfers to the specified agent.""" |
| 77 | |
| 78 | escalate: Optional[bool] = None |
| 79 | """The agent is escalating to a higher level agent.""" |
| 80 | |
| 81 | requested_auth_configs: dict[str, AuthConfig] = Field(default_factory=dict) |
| 82 | """Authentication configurations requested by tool responses. |
| 83 | |
| 84 | This field will only be set by a tool response event indicating tool request |
| 85 | auth credential. |
| 86 | - Keys: The function call id. Since one function response event could contain |
| 87 | multiple function responses that correspond to multiple function calls. Each |
| 88 | function call could request different auth configs. This id is used to |
| 89 | identify the function call. |
| 90 | - Values: The requested auth config. |
| 91 | """ |
| 92 | |
| 93 | requested_tool_confirmations: dict[str, ToolConfirmation] = Field( |
| 94 | default_factory=dict |
| 95 | ) |
| 96 | """A dict of tool confirmation requested by this event, keyed by |
| 97 | function call id.""" |
| 98 | |
| 99 | compaction: Optional[EventCompaction] = None |
| 100 | """The compaction of the events.""" |
| 101 | |
| 102 | end_of_agent: Optional[bool] = None |
| 103 | """If true, the current agent has finished its current run. Note that there |
| 104 | can be multiple events with end_of_agent=True for the same agent within one |
| 105 | invocation when there is a loop. This should only be set by ADK workflow.""" |
| 106 | |
| 107 | agent_state: Optional[dict[str, Any]] = None |
| 108 | """The agent state at the current event, used for checkpoint and resume. This |
| 109 | should only be set by ADK workflow.""" |
no outgoing calls