Tinkex.Types.SampledSequence (Tinkex v0.3.4)

View Source

A single sampled sequence from text generation.

Mirrors Python tinker.types.SampledSequence.

Summary

Functions

Parse a sampled sequence from JSON response.

Types

t()

@type t() :: %Tinkex.Types.SampledSequence{
  logprobs: [float()] | nil,
  stop_reason: Tinkex.Types.StopReason.t() | nil,
  tokens: [integer()]
}

Functions

from_json(json)

@spec from_json(map()) :: t()

Parse a sampled sequence from JSON response.