One Logo Pool Ball
FoundationModels · IOS API REFERENCE

LanguageModelExecutorGenerationChannel.Usage.Input

struct · iOS 27.0+ · SDK 27.1

struct Input

Token counts for the transcript submitted to the model.

Members (5)

init · iOS 27.0+

init

TypeScript
static init(totalTokenCount: number, cachedTokenCount: number): LanguageModelExecutorGenerationChannel_Usage_Input
Swift declaration
init(totalTokenCount: Int, cachedTokenCount: Int)
get · iOS 27.0+

totalTokenCount

TypeScript
get totalTokenCount(): number
Swift declaration
var totalTokenCount: Int

The total number of input tokens from the transcript.

set · iOS 27.0+

totalTokenCount

TypeScript
set totalTokenCount(value: number)
Swift declaration
var totalTokenCount: Int

The total number of input tokens from the transcript.

get · iOS 27.0+

cachedTokenCount

TypeScript
get cachedTokenCount(): number
Swift declaration
var cachedTokenCount: Int

The number of input tokens that were served from a cache.

set · iOS 27.0+

cachedTokenCount

TypeScript
set cachedTokenCount(value: number)
Swift declaration
var cachedTokenCount: Int

The number of input tokens that were served from a cache.

Skipped declarations

No declarations were skipped in this snapshot.

All FoundationModels types →