MCPcopy Create free account
hub / github.com/Noumena-Network/code / prepareUserContent

Function prepareUserContent

src/utils/messages.ts:526–544  ·  view source on GitHub ↗
({
  inputString,
  precedingInputBlocks,
}: {
  inputString: string
  precedingInputBlocks: ContentBlockParam[]
})

Source from the content-addressed store, hash-verified

524}
525
526export function prepareUserContent({
527 inputString,
528 precedingInputBlocks,
529}: {
530 inputString: string
531 precedingInputBlocks: ContentBlockParam[]
532}): string | ContentBlockParam[] {
533 if (precedingInputBlocks.length === 0) {
534 return inputString
535 }
536
537 return [
538 ...precedingInputBlocks,
539 {
540 text: inputString,
541 type: 'text',
542 },
543 ]
544}
545
546export function createUserInterruptionMessage({
547 toolUse = false,

Callers 5

processSlashCommandFunction · 0.85
onDoneFunction · 0.85
processBashCommandFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected