AS AgentScopeAPI 手册 / API Reference

AguiAgentAdapterFactory

@FunctionalInterface public interface AguiAgentAdapterFactory
源码Source io/agentscope/core/agui/adapter/AguiAgentAdapterFactory.java:26–46

定义 AGUI 智能体适配器工厂契约的接口。位于 io.agentscope.core.agui.adapter 包。核心成员包括 create、defaultFactory。

Factory for creating AguiAgentAdapter instances for AG-UI requests.

Applications can provide a custom factory when they need to replace the default adapter, for example to use an AguiAgentAdapter subclass that customizes runtime context creation.

方法摘要Method Summary

方法Method说明Description
public AguiAgentAdapter create(Agent agent, AguiAdapterConfig config)
创建适配器用于已解析智能体。
Create an adapter for a resolved agent.
static public AguiAgentAdapterFactory defaultFactory()
static
返回默认工厂。
Return the default factory.

方法详情Method Detail

create

public AguiAgentAdapter create(Agent agent, AguiAdapterConfig config)

创建适配器用于已解析智能体。

Create an adapter for a resolved agent.

参数Parameters
名称Name类型Type说明Description
agentAgent已解析智能体。The resolved agent
configAguiAdapterConfigAG-UI 适配器配置。The AG-UI adapter configuration
返回Returns AguiAgentAdapter
适配器到使用用于请求。The adapter to use for the request
源码Source io/agentscope/core/agui/adapter/AguiAgentAdapterFactory.java:36

defaultFactory

static public AguiAgentAdapterFactory defaultFactory()
static

返回默认工厂。

Return the default factory.

返回Returns AguiAgentAdapterFactory
返回AguiAgentAdapterFactory。A factory that creates the standard `AguiAgentAdapter`
源码Source io/agentscope/core/agui/adapter/AguiAgentAdapterFactory.java:43–45
基于官方固定版本源码静态生成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.