Skip to main content

ModelOutput

A struct that represents the output provided by a model when calling Model.run().

Declaration

struct ModelOutput

Overview

This struct conforms to the Codable protocol, which allows it to be encoded and decoded from external representations such as JSON or property lists.

Topics

Initializers

init(from: Decoder) throws

Creates a new ModelOutput instance by decoding from the given decoder.

Instance Properties

let output: String

The main output string returned by the model.

let runtime: TimeInterval

The time it took to run the model, measured in seconds.

let usedCredits: Float

The number of credits used for running the model.