MCPcopy Create free account
hub / github.com/Qinbf/groundmap / hasAnswerSection

Function hasAnswerSection

tools/debug-console/lib/agent-loop.ts:53–56  ·  view source on GitHub ↗

文本里是否出现了 ANSWER 段标记(容忍各种间隔与加粗包裹)

(text: string)

Source from the content-addressed store, hash-verified

51
52/** 文本里是否出现了 ANSWER 段标记(容忍各种间隔与加粗包裹) */
53function hasAnswerSection(text: string): boolean {
54 // 匹配 【ANSWER】 / 【 ANSWER 】 / **【ANSWER】** 等
55 return /【\s*ANSWER\s*】/i.test(text);
56}
57
58function gatherAssistantText(msgs: ChatMessage[]): string {
59 return msgs

Callers 1

runAgentFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected