类class
agentscope.ttsTTSResponse
@dataclass
class TTSResponse(DictMixin)
源码Source
agentscope/tts/_tts_response.py:30–56TTS 模型的响应。位于 agentscope.tts 包,继承自 DictMixin。
The response of TTS models. Declared in agentscope.tts. Extends DictMixin.
属性摘要Attribute Summary
| 属性Attribute | 类型Type | 说明Description | 值Value |
|---|---|---|---|
content | DataBlock | None | 内容字段。 | — |
id | str | 标识字段。 | field(default_factory=lambda: _get_timestamp(True)) |
created_at | str | 已创建 at字段。 | field(default_factory=_generate_timestamp) |
type | Literal['tts'] | 类型字段。 | field(default_factory=lambda: 'tts') |
usage | TTSUsage | None | 用量字段。 | field(default_factory=lambda: None) |
metadata | dict[str, JSONSerializableObject] | None | 元数据字段。 | field(default_factory=lambda: None) |
is_last | bool | 是最后字段。 | field(default_factory=lambda: True) |
属性详情Attribute Detail
content
DataBlock | None内容字段。声明为 DataBlock | None。
The content field.
源码Source
agentscope/tts/_tts_response.py:33id
str = field(default_factory=lambda: _get_timestamp(True))标识字段。声明为 str。
The id field.
源码Source
agentscope/tts/_tts_response.py:38created_at
str = field(default_factory=_generate_timestamp)已创建 at字段。声明为 str。
The created at field.
源码Source
agentscope/tts/_tts_response.py:41type
Literal['tts'] = field(default_factory=lambda: 'tts')类型字段。声明为 Literal['tts']。
The type field.
源码Source
agentscope/tts/_tts_response.py:44usage
TTSUsage | None = field(default_factory=lambda: None)用量字段。声明为 TTSUsage | None。
The usage field.
源码Source
agentscope/tts/_tts_response.py:47metadata
dict[str, JSONSerializableObject] | None = field(default_factory=lambda: None)元数据字段。声明为 dict[str, JSONSerializableObject] | None。
The metadata field.
源码Source
agentscope/tts/_tts_response.py:50is_last
bool = field(default_factory=lambda: True)是最后字段。声明为 bool。
The is last field.
源码Source
agentscope/tts/_tts_response.py:55