Skip to main content

SeededConversationMessage

This is a seeded version of a ConversationMessage. conversation is optional, this is because it can be used within the SeededConversation, however if this is passed into the /messages/create w/o a conversation uuid then we will throw an error.

Properties

NameType
schemaEmbeddedModelSchema
createdGroupedTimestamp
modelModel
fragmentFragmentFormat
conversationReferencedConversation
sentimentConversationMessageSentimentEnum
roleQGPTConversationMessageRoleEnum

Example

import { SeededConversationMessage } from '@pieces.app/pieces-os-client'

// TODO: Update the object below with actual values
const example: SeededConversationMessage = {
"schema": null,
"created": null,
"model": null,
"fragment": null,
"conversation": null,
"sentiment": null,
"role": null,
}

console.log(example)

// Convert the instance to a JSON string
const exampleJSON: string = JSON.stringify(example)
console.log(exampleJSON)

// Parse the JSON string back to an object
const exampleParsed = JSON.parse(exampleJSON) as SeededConversationMessage
console.log(exampleParsed)