类 AudioBlock
java.lang.Object
io.agentscope.core.message.ContentBlock
io.agentscope.core.message.AudioBlock
- 所有已实现的接口:
State
Represents audio content in a message.
This content block supports audio from two sources:
- URL source - audio files accessible via HTTP/HTTPS URLs or local file URLs
- Base64 source - audio encoded as Base64 strings with MIME type
Audio blocks enable multimodal AI interactions where agents need to process or generate audio content such as speech, music, sound effects, or other auditory information.
-
嵌套类概要
嵌套类 -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static AudioBlock.Builderbuilder()Creates a new builder for constructing AudioBlock instances.Gets the source of this audio content.
-
构造器详细资料
-
AudioBlock
Creates a new audio block for JSON deserialization.- 参数:
source- The audio source (URL or Base64)- 抛出:
NullPointerException- if source is null
-
-
方法详细资料
-
getSource
Gets the source of this audio content.- 返回:
- The audio source containing URL or Base64 data
-
builder
Creates a new builder for constructing AudioBlock instances.- 返回:
- A new builder instance
-