MCPcopy Create free account
hub / github.com/di-sukharev/opencommit / serializeChatRequestToolMessage

Function serializeChatRequestToolMessage

out/cli.cjs:77688–77694  ·  view source on GitHub ↗
(obj)

Source from the content-addressed store, hash-verified

77686}
77687function serializeChatRequestAssistantMessage(obj) {
77688 if (obj.content === void 0) {
77689 obj.content = null;
77690 }
77691 const { functionCall, toolCalls } = obj, rest = __rest(obj, ["functionCall", "toolCalls"]);
77692 return Object.assign(Object.assign(Object.assign({}, snakeCaseKeys(rest)), !toolCalls || toolCalls.length === 0 ? {} : { tool_calls: toolCalls }), functionCall ? { function_call: functionCall } : {});
77693}
77694function serializeChatRequestToolMessage(obj) {
77695 return {
77696 role: obj["role"],
77697 content: obj["content"],

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected