InputContentSource
@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "type") @JsonSubTypes({ @JsonSubTypes.Type(value = InputContentDataSource.class, name = "data"), @JsonSubTypes.Type(value = InputContentUrlSource.class, name = "url") }) public sealed interface InputContentSource permits InputContentDataSource, InputContentUrlSource
源码Source
io/agentscope/core/agui/model/InputContentSource.java:37–42定义输入内容来源契约的接口。位于 io.agentscope.core.agui.model 包。
Sealed interface representing a content source in the AG-UI protocol.
Corresponds to the AG-UI protocol's InputContentSource union type:
-
"data"→InputContentDataSource(inline Base64 data) -
"url"→InputContentUrlSource(remote URL reference)
This is distinct from AgentScope's internal io.agentscope.core.message.Source
hierarchy (URLSource / Base64Source). The AguiMessageConverter
translates between the two layers.