MCPcopy Create free account
hub / github.com/astercloud/aster / ToolResultBlock

Struct ToolResultBlock

pkg/types/message.go:128–142  ·  view source on GitHub ↗

ToolResultBlock 工具结果块

Source from the content-addressed store, hash-verified

126
127// ToolResultBlock 工具结果块
128type ToolResultBlock struct {
129 ToolUseID string `json:"tool_use_id"`
130 Content string `json:"content"`
131 IsError bool `json:"is_error,omitempty"`
132
133 // 以下字段用于可恢复压缩(Manus Context Engineering)
134 // Compressed 标记内容是否已被压缩
135 Compressed bool `json:"compressed,omitempty"`
136 // OriginalLength 原始内容长度(用于统计和验证)
137 OriginalLength int `json:"original_length,omitempty"`
138 // ContentHash 原始内容哈希(用于验证恢复)
139 ContentHash string `json:"content_hash,omitempty"`
140 // References 可恢复的引用列表(文件路径、URL 等)
141 References []ToolResultReference `json:"references,omitempty"`
142}
143
144// ToolResultReference 工具结果中的引用
145type ToolResultReference struct {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected