AS AgentScopeAPI 手册 / API Reference

ActivityDelta

record ActivityDelta( String threadId, String runId, String messageId, String activityType, List<JsonPatchOperation> patch, Long timestamp, Object rawEvent) implements AguiEvent
源码Source io/agentscope/core/agui/event/AguiEvent.java:1513–1566

承载 Activity 增量数据的记录类型。位于 io.agentscope.core.agui.event 包,实现 AguiEvent。核心成员包括 threadId、runId、messageId、activityType、patch、timestamp。

Event containing an incremental delta update to activity state. The patch contains a list of JSON Patch operations (RFC 6902) that should be applied to the client-side activity state for the given message.

记录组件摘要Record Component Summary

组件Component类型Type说明Description
threadIdString
执行会话线程标识相关操作。
Performs the thread id operation.
runIdString
运行标识。
Runs the id.
messageIdString
执行消息标识相关操作。
Performs the message id operation.
activityTypeString
执行 `activityType` 方法。
Performs the activity type operation.
patchList<JsonPatchOperation>
执行 `patch` 方法。
Performs the patch operation.
timestampLong
执行时间戳相关操作。
Performs the timestamp operation.
rawEventObject
执行原始事件相关操作。
Performs the raw event operation.

构造器摘要Constructor Summary

构造器Constructor说明Description
public ActivityDelta(String threadId, String runId, String messageId, String activityType, List<JsonPatchOperation> patch, Long timestamp, Object rawEvent)
初始化 `ActivityDelta` 实例。
Creates a new instance.
public ActivityDelta(String threadId, String runId, String messageId, String activityType, List<JsonPatchOperation> patch)
初始化 `ActivityDelta` 实例。
Creates a new instance.

方法摘要Method Summary

方法Method说明Description
public AguiEventType getType()
获取类型。
Returns the type.
public String getThreadId()
获取会话线程标识。
Returns the thread id.
public String getRunId()
获取运行标识。
Returns the run id.

记录组件详情Record Component Detail

threadId

String threadId

执行会话线程标识相关操作。

Performs the thread id operation.

源码Source io/agentscope/core/agui/event/AguiEvent.java:1513–1566

runId

String runId

运行标识。

Runs the id.

源码Source io/agentscope/core/agui/event/AguiEvent.java:1513–1566

messageId

String messageId

执行消息标识相关操作。

Performs the message id operation.

源码Source io/agentscope/core/agui/event/AguiEvent.java:1513–1566

activityType

String activityType

执行 activityType 方法。

Performs the activity type operation.

源码Source io/agentscope/core/agui/event/AguiEvent.java:1513–1566

patch

List<JsonPatchOperation> patch

执行 patch 方法。

Performs the patch operation.

源码Source io/agentscope/core/agui/event/AguiEvent.java:1513–1566

timestamp

Long timestamp

执行时间戳相关操作。

Performs the timestamp operation.

源码Source io/agentscope/core/agui/event/AguiEvent.java:1513–1566

rawEvent

Object rawEvent

执行原始事件相关操作。

Performs the raw event operation.

源码Source io/agentscope/core/agui/event/AguiEvent.java:1513–1566

构造器详情Constructor Detail

ActivityDelta

public ActivityDelta(String threadId, String runId, String messageId, String activityType, List<JsonPatchOperation> patch, Long timestamp, Object rawEvent)

初始化 ActivityDelta 实例。

Creates a new instance.

参数Parameters
名称Name类型Type说明Description
threadIdString会话线程标识(类型 `String`)。The thread id.
runIdString运行标识(类型 `String`)。The run id.
messageIdString消息标识(类型 `String`)。The message id.
activityTypeStringactivity 类型(类型 `String`)。The activity type.
patchList<JsonPatchOperation>patch(类型 `List`)。The patch.
timestampLong时间戳(类型 `Long`)。The timestamp.
rawEventObject原始事件(类型 `Object`)。The raw event.
源码Source io/agentscope/core/agui/event/AguiEvent.java:1523–1541

ActivityDelta

public ActivityDelta(String threadId, String runId, String messageId, String activityType, List<JsonPatchOperation> patch)

初始化 ActivityDelta 实例。

Creates a new instance.

参数Parameters
名称Name类型Type说明Description
threadIdString会话线程标识(类型 `String`)。The thread id.
runIdString运行标识(类型 `String`)。The run id.
messageIdString消息标识(类型 `String`)。The message id.
activityTypeStringactivity 类型(类型 `String`)。The activity type.
patchList<JsonPatchOperation>patch(类型 `List`)。The patch.
源码Source io/agentscope/core/agui/event/AguiEvent.java:1543–1550

方法详情Method Detail

getType

public AguiEventType getType()

获取类型。

Returns the type.

返回Returns AguiEventType
返回AguiEventType。Returns agui event type.
源码Source io/agentscope/core/agui/event/AguiEvent.java:1552–1555

getThreadId

public String getThreadId()

获取会话线程标识。

Returns the thread id.

返回Returns String
返回字符串结果。Returns a string.
源码Source io/agentscope/core/agui/event/AguiEvent.java:1557–1560

getRunId

public String getRunId()

获取运行标识。

Returns the run id.

返回Returns String
返回字符串结果。Returns a string.
源码Source io/agentscope/core/agui/event/AguiEvent.java:1562–1565

继承成员Inherited Members

继承自Methods inherited from AguiEvent
基于官方固定版本源码静态生成Generated from pinned official sources · Python 2.0.11 · Java 2.0.4
签名与文档为静态抽取;如有疑问请以源码为准。Signatures and docs are extracted statically; verify against the source when in doubt.