Skip to main content

Model

This is a Machine Learning Model, that will give readable information about the Machine Learning Model Used.

Properties

NameType
schemaEmbeddedModelSchema
idstring
versionstring
createdGroupedTimestamp
namestring
descriptionstring
cloudboolean
typeModelTypeEnum
usageModelUsageEnum
bytesByteDescriptor
ramByteDescriptor
quantizationstring
foundationModelFoundationEnum
downloadedboolean
loadedboolean
uniquestring
parametersnumber
providerExternalMLProviderEnum
cpuboolean
downloadingboolean
maxTokensModelMaxTokens
customboolean

Example

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

// TODO: Update the object below with actual values
const example: Model = {
"schema": null,
"id": null,
"version": null,
"created": null,
"name": null,
"description": null,
"cloud": null,
"type": null,
"usage": null,
"bytes": null,
"ram": null,
"quantization": null,
"foundation": null,
"downloaded": null,
"loaded": null,
"unique": null,
"parameters": null,
"provider": null,
"cpu": null,
"downloading": null,
"maxTokens": null,
"custom": 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 Model
console.log(exampleParsed)