MCPcopy Create free account
hub / github.com/aurora-develop/aurora / looksLikeJSONJunk

Function looksLikeJSONJunk

internal/toolcall/parser.go:156–162  ·  view source on GitHub ↗
(s string)

Source from the content-addressed store, hash-verified

154)
155
156func looksLikeJSONJunk(s string) bool {
157 t := strings.TrimSpace(s)
158 if t == "" {
159 return false
160 }
161 return strings.HasPrefix(t, "`") || strings.HasPrefix(t, "{") || strings.HasPrefix(t, "[")
162}
163
164// buildToolCallFromRaw 尝试把 <tool_call> 内的纯文本解析成 ToolCall。
165// 失败时返回 nil(让上层决定是否作为文本回吐)。

Callers 1

FeedMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected