AS AgentScopeAPI 手册 / API Reference
包package io.agentscope.harness.agent.subagent.task

io.agentscope.harness.agent.subagent.task

package io.agentscope.harness.agent.subagent.task

io.agentscope.harness.agent.subagent.task 属于多智能体与 A2A,委派、团队协作与跨进程通信。 该包共收录 18 个公开类型。

io.agentscope.harness.agent.subagent.task belongs to the Multi-agent & A2A layer and contains 18 public types.

所属构件Artifacts agentscope-harness

接口Interfaces

类型Type种类Kind说明Description
RemoteSubagentTransport接口interface
定义远程子智能体传输层契约的接口。
Transport abstraction for remote subagent execution (Agent Protocol today; A2A later).
TaskRepository接口interface
定义任务仓库契约的接口。
Repository for managing background subagent tasks, scoped by session.
TaskRunSpec接口interface
定义任务运行规格契约的接口。
Discriminated union describing how a background subagent task should execute.

类Classes

类型Type种类Kind说明Description
AgentProtocolTaskClient类class
智能体协议任务客户端,封装与远端服务的连接和调用。
Minimal HTTP client for the internal AgentScope task protocol (`POST/GET /tasks/...`).
AgentProtocolTransport类class
智能体协议传输层,支持智能体之间的发现、委派与协作。
`RemoteSubagentTransport` backed by the Agent Protocol HTTP client.
BackgroundTask类class
Background 任务,支持智能体之间的发现、委派与协作。
Wraps a `CompletableFuture` to track background subagent task execution with status, result, error, and lifecycle metadata.
RemoteSubmitContext类class
远程提交上下文,支持智能体之间的发现、委派与协作。
Context sent with a remote task submission (permissions, streaming preferences, parent identity).
RemoteTarget类class
远程目标,支持智能体之间的发现、委派与协作。
Remote endpoint identity: base URL plus optional auth/routing headers.
TaskRecord类class
任务记录,支持智能体之间的发现、委派与协作。
Persistent metadata for a background subagent task, stored as JSON in the workspace under `agents/<parentAgentId>/tasks/<parentSessionId>.json`.
WorkspaceTaskRepository类class
工作区任务仓库,负责持久化与读取数据。
Workspace-backed `TaskRepository` that uses `WorkspaceManager` as the authoritative truth source for task state, while maintaining in-memory `BackgroundTask` handles as a local performance overlay for tasks running on the current node.

枚举Enums

类型Type种类Kind说明Description
TaskStatus枚举enum
定义任务状态的枚举。
Lifecycle status of a background subagent task.

记录Records

类型Type种类Kind说明Description
RemoteTaskStatus记录record
承载远程任务状态数据的记录类型。
Status snapshot returned by the remote task HTTP API (`GET /tasks/{taskId}`).
TaskDelivery记录record
承载任务 Delivery数据的记录类型。
Snapshot of a terminal-state subagent task awaiting (or undergoing) push delivery to the parent agent's reasoning loop.
基于官方固定版本源码静态生成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.