@juspay/neurolink
Version:
Universal AI Development Platform with working MCP integration, multi-provider support, and professional CLI. Built-in tools operational, 58+ external MCP servers discoverable. Connect to filesystem, GitHub, database operations, and more. Build, test, and
9 lines (8 loc) • 324 B
JavaScript
/**
* Formats a chat history array into a single string for use in a prompt.
* @param history The array of ChatMessage objects.
* @returns A formatted string representing the conversation.
*/
export function formatHistoryToString(history) {
return history.map((msg) => `${msg.role}: ${msg.content}`).join("\n\n");
}