MCPcopy Index your code
hub / github.com/CodebuffAI/codebuff / parseUserMessage

Function parseUserMessage

packages/agent-runtime/src/util/messages.ts:96–99  ·  view source on GitHub ↗
(str: string)

Source from the content-addressed store, hash-verified

94}
95
96export function parseUserMessage(str: string): string | undefined {
97 const match = str.match(/<user_message>(.*?)<\/user_message>/s)
98 return match ? match[1] : undefined
99}
100
101export function withSystemInstructionTags(str: string): string {
102 return `<system_instructions>${str}${closeXml('system_instructions')}`

Callers 3

isUserInputMessageFunction · 0.90
formatPromptFunction · 0.90
buildUserMessageContentFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected