MCPcopy Create free account
hub / github.com/MoonshotAI/kimi-code / createUserMessage

Function createUserMessage

packages/kosong/src/message.ts:195–201  ·  view source on GitHub ↗
(content: string)

Source from the content-addressed store, hash-verified

193
194/** Create a simple user message with a single text part. */
195export function createUserMessage(content: string): Message {
196 return {
197 role: 'user',
198 content: [{ type: 'text', text: content }],
199 toolCalls: [],
200 };
201}
202
203/** Create an assistant message from content parts and optional tool calls. */
204export function createAssistantMessage(content: ContentPart[], toolCalls?: ToolCall[]): Message {

Callers 5

userMsgFunction · 0.90
message.test.tsFile · 0.90
regression.test.tsFile · 0.90
compactionRoundMethod · 0.90

Calls

no outgoing calls

Tested by 1

userMsgFunction · 0.72